/**
 * FRAMIZE - Professional Design System & Responsive Styles
 * Clean, Modern, Elegant, and Intuitive.
 */

:root {
    --primary-blue: #1e40af;
    --primary-blue-light: #2563eb;
    --primary-blue-dark: #1e3a8a;
    --primary-blue-hover: #1d4ed8;
    --primary-subtle: #eff6ff;
    --accent-emerald: #10b981;
    --accent-emerald-light: #d1fae5;
    --bg-page: #f8fafc;
    --card-bg: #ffffff;
    --border-color: #e2e8f0;
    --border-focus: #3b82f6;
    --text-main: #0f172a;
    --text-secondary: #334155;
    --text-muted: #64748b;
    --radius-sm: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.25rem;
    --shadow-xs: 0 1px 2px 0 rgba(15, 23, 42, 0.04);
    --shadow-sm: 0 1px 3px 0 rgba(15, 23, 42, 0.06), 0 1px 2px -1px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.07), 0 2px 4px -2px rgba(15, 23, 42, 0.05);
    --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.04);
    --shadow-xl: 0 20px 25px -5px rgba(15, 23, 42, 0.08), 0 8px 10px -6px rgba(15, 23, 42, 0.04);
    --shadow-sheet: 0 12px 32px -8px rgba(15, 23, 42, 0.12), 0 4px 8px -2px rgba(15, 23, 42, 0.06);
}

html, body {
    max-width: 100%;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-page);
    background-image: 
        radial-gradient(at 0% 0%, rgba(224, 231, 255, 0.45) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(219, 234, 254, 0.35) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Touch Friendly Targets */
button, .btn, input, select, textarea, .nav-link {
    touch-action: manipulation;
}

.btn {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    letter-spacing: -0.01em;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Navbar */
.navbar-public {
    background-color: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.03);
    padding: 0.85rem 0;
    position: sticky;
    top: 0;
    z-index: 1020;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.brand-logo:hover {
    opacity: 0.92;
}

.brand-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
    color: #ffffff;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

.brand-name {
    font-family: 'Poppins', sans-serif;
    font-weight: 800;
    font-size: 1.35rem;
    color: var(--primary-blue-dark);
    letter-spacing: -0.03em;
    line-height: 1.1;
    margin: 0;
}

.brand-sub {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
    margin: 0;
    letter-spacing: 0.01em;
}

/* Responsive Step Wizard */
.step-wizard {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    margin: 1.5rem 0 2.25rem 0;
    padding: 0 0.5rem;
}

.step-wizard::before {
    content: '';
    position: absolute;
    top: 21px;
    left: 8%;
    right: 8%;
    height: 3px;
    background: #e2e8f0;
    z-index: 1;
    border-radius: 4px;
}

.step-item {
    position: relative;
    z-index: 2;
    text-align: center;
    background: transparent;
    padding: 0 0.4rem;
    flex: 1;
    transition: transform 0.2s ease;
}

.step-circle {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #ffffff;
    border: 2px solid #cbd5e1;
    color: var(--text-muted);
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.4rem auto;
    font-size: 0.95rem;
    box-shadow: var(--shadow-xs);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.step-item.active .step-circle {
    background: linear-gradient(135deg, #1e40af 0%, #2563eb 100%);
    border-color: #2563eb;
    color: #ffffff;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.18), 0 4px 8px rgba(37, 99, 235, 0.2);
    transform: scale(1.06);
}

.step-item.completed .step-circle {
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    border-color: #10b981;
    color: #ffffff;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.25);
}

.step-label {
    font-size: 0.785rem;
    font-weight: 600;
    color: var(--text-muted);
    display: block;
    line-height: 1.25;
    transition: color 0.2s ease;
}

.step-item.active .step-label {
    color: var(--primary-blue-light);
    font-weight: 700;
}

.step-item.completed .step-label {
    color: #059669;
}

@media (max-width: 576px) {
    .step-label {
        font-size: 0.685rem;
    }
    .step-circle {
        width: 34px;
        height: 34px;
        font-size: 0.85rem;
    }
    .step-wizard::before {
        top: 17px;
    }
}

/* Card & Interactive UI */
.card-custom {
    background: var(--card-bg);
    border-radius: var(--radius-xl);
    border: 1px solid rgba(226, 232, 240, 0.85);
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-custom-primary {
    background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    font-weight: 600;
    padding: 0.65rem 1.45rem;
    border-radius: 50rem;
    box-shadow: 0 2px 6px rgba(37, 99, 235, 0.2);
}

.btn-custom-primary:hover {
    background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 100%);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.3);
}

.btn-custom-light {
    background-color: #f1f5f9;
    border: 1px solid #cbd5e1;
    color: #334155;
    font-weight: 600;
    padding: 0.65rem 1.35rem;
    border-radius: 50rem;
}

.btn-custom-light:hover {
    background-color: #e2e8f0;
    color: #0f172a;
    border-color: #94a3b8;
}

/* Photo Upload Box */
.photo-upload-card {
    border: 2px dashed #cbd5e1 !important;
    background-color: #ffffff !important;
    transition: all 0.22s ease-in-out;
    border-radius: var(--radius-lg) !important;
}

.photo-upload-card:hover {
    border-color: var(--primary-blue-light) !important;
    background-color: #f8fafc !important;
    box-shadow: var(--shadow-md);
}

.photo-upload-card.has-file {
    border: 2px solid #93c5fd !important;
    background-color: #eff6ff !important;
    box-shadow: var(--shadow-sm);
}

/* PDF Preview Sheet Container */
.pdf-sheet-wrapper {
    width: 100%;
    margin-bottom: 2.25rem;
}

.pdf-sheet-page {
    background-color: #ffffff;
    border-radius: var(--radius-md);
    border: 1px solid rgba(203, 213, 225, 0.8);
    width: 100%;
    max-width: 100%;
    min-height: 520px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-sheet);
}

@media (min-width: 768px) {
    .pdf-sheet-page {
        min-height: 720px;
    }
}

.sheet-frame-header {
    border-bottom: 2px solid #e2e8f0;
    background: #f8fafc;
    text-align: center;
    padding: 0.5rem;
}

.sheet-judul-text {
    font-family: 'Poppins', sans-serif;
    font-size: clamp(1.1rem, 2.5vw, 1.6rem);
    line-height: 1.35;
    color: #1e3a8a !important;
    letter-spacing: -0.01em;
}

.sheet-page-footer {
    margin-top: auto;
    padding: 0.75rem 1.25rem;
    border-top: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    font-size: 0.775rem;
    color: #94a3b8;
    font-weight: 500;
    background: #fafafa;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* Responsive Table & Overflow Prevention */
.table-responsive {
    -webkit-overflow-scrolling: touch;
}

/* Form Controls */
.form-control:focus, .form-select:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3.5px rgba(59, 130, 246, 0.15);
}

/* Prevent horizontal scroll */
img, svg, video, canvas, audio, iframe, embed, object {
    max-width: 100%;
    height: auto;
}

