/* ==========================================================================
   TPPK SMK MEKARWANGI - ULTRA RESPONSIVE DESIGN SYSTEM
   Kompatibel Sepenuhnya untuk: iPhone (iOS Notch / Dynamic Island), Android,
   Tablet / iPad (Portrait & Landscape), Laptop, dan Desktop Luas.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #1e3a8a;
    --primary-dark: #0f172a;
    --primary-light: #3b82f6;
    --secondary: #0d9488;
    --secondary-dark: #0f766e;
    --secondary-light: #2dd4bf;
    --accent: #f59e0b;
    --accent-gold: #d97706;
    --danger: #e11d48;
    --success: #10b981;
    --info: #0284c7;
    --warning: #f59e0b;
    
    --bg-page: #f8fafc;
    --bg-surface: #ffffff;
    --bg-surface-alt: #f1f5f9;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --border-focus: #3b82f6;

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-full: 9999px;

    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 25px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.04);
    --shadow-xl: 0 20px 30px -5px rgba(15, 23, 42, 0.12), 0 8px 10px -6px rgba(15, 23, 42, 0.06);

    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-page);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.drawer-open {
    overflow: hidden !important;
    touch-action: none !important;
}

/* ==========================================================================
   TYPOGRAPHY & UTILITIES
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
    color: var(--primary-dark);
    font-weight: 700;
    line-height: 1.25;
}

a {
    color: var(--primary-light);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
}

.container-narrow {
    max-width: 860px;
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.section-padding {
    padding: clamp(48px, 7vw, 84px) 0;
}

.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(13, 148, 136, 0.1);
    color: var(--secondary);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    font-size: clamp(0.75rem, 2vw, 0.85rem);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.section-title {
    font-size: clamp(1.6rem, 4.5vw, 2.35rem);
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--primary-dark);
    letter-spacing: -0.02em;
}

.section-subtitle {
    font-size: clamp(0.92rem, 2.2vw, 1.1rem);
    color: var(--text-secondary);
    max-width: 680px;
    margin: 0 auto clamp(28px, 4vw, 42px) auto;
    line-height: 1.65;
}

/* ==========================================================================
   TOP ANNOUNCEMENT & CONTACT BAR
   ========================================================================== */
.top-info-bar {
    background: #0f172a;
    color: #cbd5e1;
    font-size: 0.8125rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    z-index: 1001;
}

.top-info-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 7px;
    padding-bottom: 7px;
    gap: 16px;
}

.top-info-left {
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.82rem;
}

.top-info-left span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #e2e8f0;
}

.top-info-left i {
    color: var(--secondary-light);
}

.top-info-right {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-shrink: 0;
}

.top-info-right a {
    color: #cbd5e1;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
    transition: var(--transition);
}

.top-info-right a:hover {
    color: #ffffff;
}

.top-info-right i {
    color: var(--secondary-light);
}

.top-info-right .fa-whatsapp {
    color: #25d366;
}

/* Base class for mobile bottom navigation (hidden on desktop) */
.mobile-bottom-nav {
    display: none;
}

/* ==========================================================================
   HEADER & NAVBAR (DESKTOP + MOBILE DRAWER)
   ========================================================================== */
.site-header {
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
    padding-top: env(safe-area-inset-top);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
    gap: 16px;
}

.brand-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    flex-shrink: 0;
}

.brand-logo {
    width: 44px;
    height: 44px;
    object-fit: contain;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    flex-shrink: 0;
}

.brand-text h1 {
    font-size: clamp(1.05rem, 3.2vw, 1.25rem);
    font-weight: 800;
    color: var(--primary);
    line-height: 1.15;
    margin: 0;
    letter-spacing: -0.01em;
}

.brand-text span {
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--secondary);
    letter-spacing: 0.02em;
    display: block;
}

.desktop-nav {
    display: flex;
    align-items: center;
}

.nav-menu {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 4px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.92rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary);
    background: rgba(30, 58, 138, 0.06);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.mobile-toggle {
    display: none;
    background: #f1f5f9;
    border: 1px solid var(--border-color);
    width: 44px;
    height: 44px;
    border-radius: var(--radius-sm);
    font-size: 1.25rem;
    color: var(--primary-dark);
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.mobile-toggle:active {
    transform: scale(0.95);
    background: #e2e8f0;
}

/* ==========================================================================
   OFF-CANVAS MOBILE DRAWER
   ========================================================================== */
.mobile-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 1040;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-drawer-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(360px, 86vw);
    background: #ffffff;
    box-shadow: -10px 0 35px rgba(15, 23, 42, 0.18);
    transform: translateX(100%);
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 1050;
    display: flex;
    flex-direction: column;
    padding-top: max(16px, env(safe-area-inset-top));
    padding-bottom: max(20px, env(safe-area-inset-bottom));
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
}

.mobile-drawer.open {
    transform: translateX(0);
}

.mobile-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 16px;
}

.mobile-drawer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mobile-drawer-logo {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: contain;
}

.mobile-drawer-brand strong {
    display: block;
    font-size: 0.95rem;
    color: var(--primary);
    line-height: 1.2;
}

.mobile-drawer-brand span {
    font-size: 0.72rem;
    color: var(--secondary);
    display: block;
}

.mobile-drawer-close {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #f1f5f9;
    border: none;
    font-size: 1.15rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.mobile-drawer-close:active {
    background: #fee2e2;
    color: var(--danger);
    transform: scale(0.92);
}

.mobile-drawer-body {
    flex-grow: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-right: 4px;
}

.mobile-drawer-menu {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 24px;
}

.mobile-drawer-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    background: #f8fafc;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    transition: var(--transition);
}

.mobile-drawer-link:active, .mobile-drawer-link.active {
    background: #eff6ff;
    border-color: var(--primary-light);
}

.drawer-icon-box {
    width: 38px;
    height: 38px;
    border-radius: var(--radius-sm);
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: var(--primary);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    flex-shrink: 0;
}

.drawer-link-text strong {
    display: block;
    font-size: 0.92rem;
    color: var(--primary-dark);
}

.drawer-link-text span {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.drawer-hotline-card {
    background: linear-gradient(135deg, rgba(37,211,102,0.1), rgba(13,148,136,0.1));
    border: 1px dashed #25d366;
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 20px;
}

.mobile-drawer-footer {
    padding-top: 14px;
    border-top: 1px solid var(--border-color);
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 22px;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    line-height: 1.4;
    font-family: inherit;
    touch-action: manipulation;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, #1d4ed8 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.22);
}

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

.btn-secondary {
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-dark) 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.22);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, var(--secondary-dark) 0%, #115e59 100%);
    color: #ffffff;
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: #ffffff;
    transform: translateY(-2px);
}

.btn-outline-white {
    background: transparent;
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.8);
}

.btn-outline-white:hover {
    background: #ffffff;
    color: var(--primary-dark);
}

.btn-danger {
    background: var(--danger);
    color: #ffffff;
}
.btn-danger:hover {
    background: #be123c;
    color: #ffffff;
}

.btn-lg {
    padding: 13px 26px;
    font-size: 1.02rem;
    border-radius: var(--radius-md);
}

.btn-sm {
    padding: 7px 14px;
    font-size: 0.85rem;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
    position: relative;
    background: radial-gradient(circle at top right, rgba(56, 189, 248, 0.12), transparent 50%),
                radial-gradient(circle at bottom left, rgba(13, 148, 136, 0.1), transparent 50%),
                #ffffff;
    padding: clamp(40px, 6vw, 76px) 0 clamp(50px, 8vw, 86px) 0;
    border-bottom: 1px solid var(--border-color);
    overflow: hidden;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: clamp(24px, 4vw, 48px);
    align-items: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
    padding: 6px 14px;
    border-radius: var(--radius-full);
    font-size: clamp(0.75rem, 2vw, 0.86rem);
    font-weight: 700;
    margin-bottom: 18px;
    max-width: 100%;
}

.hero-title {
    font-size: clamp(1.9rem, 5.2vw, 3rem);
    font-weight: 800;
    line-height: 1.18;
    color: var(--primary-dark);
    margin-bottom: 18px;
    letter-spacing: -0.02em;
}

.hero-title span.highlight {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-desc {
    font-size: clamp(0.96rem, 2.2vw, 1.12rem);
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 28px;
}

.hero-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 30px;
}

.hero-trust-badges {
    display: flex;
    align-items: center;
    gap: clamp(14px, 3vw, 24px);
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.trust-item i {
    color: var(--secondary);
    font-size: 1.15rem;
}

.hero-image-wrapper {
    position: relative;
    width: 100%;
}

.hero-img {
    width: 100%;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    border: 4px solid #ffffff;
    transition: var(--transition);
}

.hero-floating-card {
    position: absolute;
    bottom: -16px;
    left: -16px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(226, 232, 240, 0.8);
    padding: 12px 18px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: floatAnim 4s ease-in-out infinite;
    max-width: 90%;
}

.floating-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #ecfdf5;
    color: var(--secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

@keyframes floatAnim {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

/* ==========================================================================
   CARDS & FEATURES
   ========================================================================== */
.card {
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    box-shadow: var(--shadow-lg);
    border-color: #cbd5e1;
    transform: translateY(-3px);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: clamp(16px, 2.5vw, 24px);
}

.feature-box {
    padding: clamp(20px, 3.5vw, 30px);
    border-radius: var(--radius-md);
    background: #ffffff;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    position: relative;
}

.feature-box:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.feature-icon-wrapper {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 18px;
}

.icon-blue { background: #eff6ff; color: #2563eb; }
.icon-teal { background: #f0fdf4; color: #059669; }
.icon-amber { background: #fffbeb; color: #d97706; }
.icon-purple { background: #faf5ff; color: #9333ea; }
.icon-rose { background: #fff1f2; color: #e11d48; }

.feature-box h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: var(--primary-dark);
}

.feature-box p {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.6;
}

/* ==========================================================================
   POSTER GALLERY SECTION
   ========================================================================== */
.poster-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: clamp(18px, 3vw, 28px);
}

.poster-card {
    background: #ffffff;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.poster-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: var(--secondary);
}

.poster-thumb-wrapper {
    position: relative;
    aspect-ratio: 3/4;
    overflow: hidden;
    background: #f1f5f9;
}

.poster-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.poster-card:hover .poster-thumb {
    transform: scale(1.03);
}

.poster-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    color: #ffffff;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 700;
}

.poster-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.poster-card:hover .poster-overlay {
    opacity: 1;
}

.poster-info {
    padding: 18px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.poster-info h4 {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--primary-dark);
}

.poster-info p {
    color: var(--text-secondary);
    font-size: 0.86rem;
    line-height: 1.5;
    margin-bottom: 14px;
    flex-grow: 1;
}

.poster-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
    gap: 8px;
    flex-wrap: wrap;
}

/* ==========================================================================
   TIM TPPK SECTION
   ========================================================================== */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: clamp(16px, 2.5vw, 26px);
}

.team-card {
    background: #ffffff;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: 24px 18px;
    text-align: center;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.team-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.team-avatar-wrapper {
    position: relative;
    width: 110px;
    height: 110px;
    margin: 0 auto 16px auto;
}

.team-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #ffffff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

.team-badge-icon {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 30px;
    height: 30px;
    background: var(--primary);
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    border: 2px solid #ffffff;
}

.team-card h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 4px;
}

.team-tppk-role {
    display: inline-block;
    background: rgba(30, 58, 138, 0.08);
    color: var(--primary);
    font-weight: 700;
    font-size: 0.8rem;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    margin-bottom: 6px;
}

.team-school-role {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.team-desc {
    font-size: 0.86rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-top: auto;
}

/* ==========================================================================
   ALUR PENANGANAN (WORKFLOW TIMELINE)
   ========================================================================== */
.workflow-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 18px;
    position: relative;
}

.workflow-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px 18px;
    text-align: center;
    position: relative;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.workflow-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.workflow-step-num {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 26px;
    height: 26px;
    background: var(--primary);
    color: #ffffff;
    font-weight: 800;
    font-size: 0.82rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(30, 58, 138, 0.3);
}

.workflow-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(13, 148, 136, 0.1);
    color: var(--secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    margin: 10px auto 14px auto;
}

.workflow-card h4 {
    font-size: 1rem;
    margin-bottom: 6px;
}

.workflow-card p {
    font-size: 0.84rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ==========================================================================
   FORM PENGADUAN & HOTLINE
   ========================================================================== */
.report-form-card {
    background: #ffffff;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}

.form-header {
    background: linear-gradient(135deg, var(--primary) 0%, #1e40af 100%);
    color: #ffffff;
    padding: clamp(24px, 5vw, 36px) clamp(20px, 4vw, 30px);
    text-align: center;
}

.form-header h2 {
    color: #ffffff;
    font-size: clamp(1.4rem, 4vw, 1.85rem);
    margin-bottom: 8px;
}

.form-header p {
    color: #cbd5e1;
    font-size: clamp(0.85rem, 2vw, 0.95rem);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.5;
}

.form-body {
    padding: clamp(20px, 4vw, 36px) clamp(16px, 4vw, 32px);
}

.identity-toggle-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 24px;
}

.identity-option-label {
    display: block;
    cursor: pointer;
}

.identity-option-label input[type="radio"] {
    display: none;
}

.identity-option-box {
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: clamp(14px, 3vw, 20px);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    transition: var(--transition);
    height: 100%;
}

.identity-option-label input[type="radio"]:checked + .identity-option-box {
    border-color: var(--secondary);
    background: rgba(13, 148, 136, 0.05);
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.15);
}

.identity-icon {
    font-size: 1.5rem;
    color: var(--secondary);
    flex-shrink: 0;
    margin-top: 2px;
}

.identity-text h5 {
    font-size: 0.98rem;
    margin-bottom: 4px;
}

.identity-text p {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 8px;
    color: var(--primary-dark);
}

.form-label span.required {
    color: var(--danger);
}

.form-control {
    width: 100%;
    padding: 12px 14px;
    font-size: 0.95rem;
    font-family: inherit;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #ffffff;
    color: var(--text-primary);
    transition: var(--transition);
    min-height: 46px;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

textarea.form-control {
    resize: vertical;
    min-height: 110px;
}

.form-hint {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 6px;
    display: block;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.safety-notice-box {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: var(--radius-md);
    padding: 14px 18px;
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 24px;
}

.safety-notice-box i {
    font-size: 1.6rem;
    color: var(--secondary);
    flex-shrink: 0;
}

.safety-notice-box p {
    font-size: 0.85rem;
    color: #166534;
    line-height: 1.45;
}

/* ==========================================================================
   TRACKING / LACAK TIKET
   ========================================================================== */
.ticket-track-box {
    background: #ffffff;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: clamp(20px, 4vw, 30px);
    box-shadow: var(--shadow-md);
    margin-bottom: 30px;
}

.timeline-tracker {
    position: relative;
    padding-left: 32px;
    margin-top: 24px;
}

.timeline-tracker::before {
    content: '';
    position: absolute;
    left: 12px;
    top: 8px;
    bottom: 8px;
    width: 3px;
    background: var(--border-color);
    border-radius: 3px;
}

.timeline-item {
    position: relative;
    margin-bottom: 24px;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-dot {
    position: absolute;
    left: -32px;
    top: 2px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #ffffff;
    border: 3px solid var(--primary-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    color: var(--primary);
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
}

.timeline-item.active .timeline-dot {
    background: var(--secondary);
    border-color: #a7f3d0;
    color: #ffffff;
}

.timeline-content {
    background: #f8fafc;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
    flex-wrap: wrap;
    gap: 6px;
}

.timeline-header h5 {
    font-size: 0.95rem;
    color: var(--primary-dark);
}

.timeline-time {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.timeline-body {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ==========================================================================
   BADGES & STATUS
   ========================================================================== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 0.76rem;
    font-weight: 700;
}

.badge-warning { background: #fef3c7; color: #b45309; }
.badge-info { background: #e0f2fe; color: #0369a1; }
.badge-primary { background: #dbeafe; color: #1d4ed8; }
.badge-success { background: #d1fae5; color: #047857; }
.badge-danger { background: #ffe4e6; color: #be123c; }
.badge-secondary { background: #f1f5f9; color: #475569; }

/* ==========================================================================
   FLOATING EMERGENCY BUTTON (WITH SAFE AREA INSETS)
   ========================================================================== */
.floating-hotline-btn {
    position: fixed;
    bottom: max(20px, calc(14px + env(safe-area-inset-bottom)));
    right: max(20px, calc(14px + env(safe-area-inset-right)));
    z-index: 999;
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
    color: #ffffff;
    border-radius: var(--radius-full);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.4);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.92rem;
    transition: var(--transition);
    animation: pulseHotline 3s infinite;
}

.floating-hotline-btn:hover, .floating-hotline-btn:active {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 14px 30px rgba(37, 211, 102, 0.5);
    color: #ffffff;
}

.floating-hotline-icon {
    font-size: 1.35rem;
}

@keyframes pulseHotline {
    0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.6); }
    70% { box-shadow: 0 0 0 14px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
    background: #0f172a;
    color: #cbd5e1;
    padding: clamp(48px, 7vw, 70px) 0 max(24px, env(safe-area-inset-bottom)) 0;
    margin-top: clamp(48px, 8vw, 80px);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
    gap: clamp(24px, 4vw, 40px);
    margin-bottom: 40px;
}

.footer-brand h3 {
    color: #ffffff;
    font-size: 1.25rem;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-brand p {
    font-size: 0.88rem;
    line-height: 1.6;
    color: #94a3b8;
    margin-bottom: 18px;
}

.footer-col h4 {
    color: #ffffff;
    font-size: 1rem;
    margin-bottom: 16px;
    position: relative;
    padding-bottom: 8px;
}

.footer-col h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 3px;
    background: var(--secondary);
    border-radius: 2px;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #94a3b8;
    font-size: 0.88rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.footer-links a:hover {
    color: #ffffff;
    transform: translateX(4px);
}

.footer-contact-item {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 0.88rem;
    color: #94a3b8;
}

.footer-contact-item i {
    color: var(--secondary-light);
    margin-top: 4px;
}

.footer-bottom {
    padding-top: 20px;
    border-top: 1px solid #1e293b;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    font-size: 0.82rem;
    color: #64748b;
}

/* ==========================================================================
   MODAL DIALOG (RESPONSIVE)
   ========================================================================== */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 1060;
    display: none;
    align-items: center;
    justify-content: center;
    padding: clamp(14px, 3vw, 24px);
}

.modal-backdrop.show {
    display: flex;
    animation: fadeIn 0.2s ease-out;
}

.modal-dialog {
    background: #ffffff;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 640px;
    max-height: 90vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: var(--shadow-xl);
    position: relative;
    animation: scaleUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-header {
    padding: 18px 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-close {
    background: #f1f5f9;
    border: none;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    font-size: 1.1rem;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.modal-close:active {
    color: var(--danger);
    background: #fee2e2;
}

.modal-body {
    padding: 20px;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scaleUp {
    from { transform: scale(0.95); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* ==========================================================================
   ADMIN LAYOUT (RESPONSIVE WITH MOBILE OFF-CANVAS)
   ========================================================================== */
.admin-layout {
    display: flex;
    min-height: 100vh;
    background: #f1f5f9;
    position: relative;
}

.admin-sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1020;
    display: none;
}

.admin-sidebar-overlay.show {
    display: block;
}

.admin-sidebar {
    width: 260px;
    background: var(--primary-dark);
    color: #ffffff;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    z-index: 1030;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.admin-sidebar-header {
    padding: 22px 20px;
    border-bottom: 1px solid #1e293b;
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-nav {
    list-style: none;
    padding: 16px 12px;
    flex-grow: 1;
    overflow-y: auto;
}

.admin-nav-item {
    margin-bottom: 4px;
}

.admin-nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    color: #94a3b8;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 600;
    transition: var(--transition);
}

.admin-nav-link:hover, .admin-nav-link.active {
    color: #ffffff;
    background: #1e293b;
}

.admin-main {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    min-width: 0;
}

.admin-topbar {
    background: #ffffff;
    min-height: 66px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px clamp(16px, 3vw, 30px);
    border-bottom: 1px solid var(--border-color);
    gap: 14px;
}

.admin-content {
    padding: clamp(16px, 3vw, 30px);
    flex-grow: 1;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: clamp(14px, 2.5vw, 20px);
    margin-bottom: 24px;
}

.stat-card {
    background: #ffffff;
    border-radius: var(--radius-md);
    padding: 20px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 16px;
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}

.stat-info h3 {
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: 2px;
}

.stat-info span {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
}

.table-custom {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
    background: #ffffff;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.table-custom th {
    background: #f8fafc;
    padding: 12px 16px;
    text-align: left;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}

.table-custom td {
    padding: 12px 16px;
    font-size: 0.88rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.table-custom tr:hover {
    background: #f8fafc;
}

/* ==========================================================================
   SUPER-RESPONSIVE MEDIA QUERIES (TABLETS, PHONES, iPHONE NOTCH)
   ========================================================================== */

/* 1. Tablet Landscape & Kecil (<= 1024px) */
@media (max-width: 1024px) {
    .desktop-nav {
        display: none;
    }
    .mobile-toggle {
        display: inline-flex;
    }
    .hero-grid {
        grid-template-columns: 1fr;
        gap: 36px;
        text-align: center;
    }
    .hero-cta {
        justify-content: center;
    }
    .hero-trust-badges {
        justify-content: center;
    }
    .hero-image-wrapper {
        max-width: 560px;
        margin: 0 auto;
    }
    .hero-floating-card {
        left: 50%;
        transform: translateX(-50%);
        bottom: -16px;
    }
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 32px;
    }
    .admin-sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        transform: translateX(-100%);
    }
    .admin-sidebar.open {
        transform: translateX(0);
    }
}

/* 2. Mobile Tablets & HP (<= 768px) */
@media (max-width: 768px) {
    /* Safe spacing at bottom for the fixed mobile navigation bar */
    body {
        padding-bottom: calc(68px + env(safe-area-inset-bottom, 0px)) !important;
    }

    /* Hide top info strip on phones to maximize screen space */
    .top-info-bar {
        display: none !important;
    }

    .header-inner {
        height: 64px;
    }
    .brand-logo {
        width: 38px;
        height: 38px;
    }
    .nav-cta-btn {
        display: none; /* Tombol ini sudah sangat menonjol di dalam mobile drawer & bottom bar */
    }
    .hero-cta {
        flex-direction: column;
        width: 100%;
    }
    .hero-cta .btn {
        width: 100%;
    }
    .identity-toggle-group {
        grid-template-columns: 1fr;
    }
    .form-row {
        grid-template-columns: 1fr;
    }
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .footer-bottom {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }
    
    /* Hide floating button on mobile to avoid overlapping the bottom nav bar */
    .floating-hotline-btn {
        display: none !important;
    }
    
    /* Native App-Like Mobile Bottom Navigation Bar */
    .mobile-bottom-nav {
        display: flex !important;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: calc(64px + env(safe-area-inset-bottom, 0px));
        padding-bottom: env(safe-area-inset-bottom, 0px);
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        border-top: 1px solid rgba(226, 232, 240, 0.9);
        box-shadow: 0 -4px 20px rgba(15, 23, 42, 0.08);
        z-index: 1030;
        align-items: center;
        justify-content: space-around;
        user-select: none;
    }

    .bottom-nav-item {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        color: #64748b;
        text-decoration: none;
        font-size: 0.68rem;
        font-weight: 600;
        height: 100%;
        transition: color 0.15s ease;
        padding-top: 4px;
        position: relative;
    }

    .bottom-nav-item i {
        font-size: 1.15rem;
        transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
    }

    .bottom-nav-item:active i {
        transform: scale(0.88);
    }

    .bottom-nav-item.active {
        color: var(--primary);
        font-weight: 700;
    }

    .bottom-nav-item.active i {
        color: var(--primary);
    }

    /* Central Elevated Floating Action Button (Lapor) */
    .bottom-nav-fab-wrapper {
        position: relative;
        overflow: visible;
    }

    .bottom-nav-fab {
        width: 52px;
        height: 52px;
        border-radius: 50%;
        background: linear-gradient(135deg, #e11d48 0%, #be123c 100%);
        color: #ffffff;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.25rem;
        margin-top: -24px;
        margin-bottom: 2px;
        box-shadow: 0 6px 16px rgba(225, 29, 72, 0.42);
        border: 3.5px solid #ffffff;
        transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s ease;
    }

    .bottom-nav-fab-wrapper:active .bottom-nav-fab {
        transform: scale(0.92);
        box-shadow: 0 2px 8px rgba(225, 29, 72, 0.35);
    }

    .bottom-nav-fab-wrapper span {
        font-weight: 700;
        color: #e11d48;
    }

    /* iOS Safari Auto-Zoom Fix on Input Focus (must be at least 16px) */
    input[type="text"],
    input[type="password"],
    input[type="email"],
    input[type="tel"],
    input[type="date"],
    select,
    textarea {
        font-size: 16px !important;
    }
    
    /* Admin Detail View */
    .admin-content div[style*="grid-template-columns: 1.2fr 0.8fr"] {
        grid-template-columns: 1fr !important;
    }
    
    .admin-content .card[style*="position: sticky"] {
        position: static !important;
        top: 0 !important;
    }
}

/* 3. Small Screen Phones (<= 480px, misal iPhone SE, iPhone mini, Galaxy A) */
@media (max-width: 480px) {
    .brand-text span {
        display: none; /* Sembunyikan sub-teks di layar sangat kecil agar tidak sempit */
    }
    .brand-text h1 {
        font-size: 1.05rem;
    }
    .hero-trust-badges {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .hero-floating-card {
        display: none; /* Sembunyikan floating card jika layar terlalu sempit agar tidak menutupi gambar */
    }
    .form-body {
        padding: 18px 14px;
    }
    .safety-notice-box {
        flex-direction: column;
        text-align: center;
    }
    .card {
        border-radius: var(--radius-sm);
    }
    .section-title {
        font-size: 1.6rem;
    }
    .section-subtitle {
        font-size: 0.92rem;
    }
}
