/*
  ================================================================
  DPMPTSP KOTA BALIKPAPAN — PREMIUM DESIGN SYSTEM v4.0
  ================================================================
  Soft Dark Blue • Glassmorphism • Rounded 24px Cards
  Inspired by: Apple, Stripe, Linear, GovTech Singapore
  ================================================================
*/

/* ================================================================
   1. DESIGN TOKENS
   ================================================================ */
:root {
    /* ── Primary: Soft Dark Blue ─── */
    --primary: #1E3A6E;
    --primary-dark: #162D55;
    --primary-hover: #254A8A;
    --primary-light: #EDF2FA;
    --primary-xlight: #F5F8FC;

    /* ── Secondary: Bright Blue (CTA) ─── */
    --secondary: #2563EB;
    --secondary-dark: #1D4ED8;
    --secondary-light: #DBEAFE;

    /* ── Accent: Cyan ─── */
    --accent: #06B6D4;
    --accent-light: #ECFEFF;

    /* ── Semantics ─── */
    --success: #10B981;
    --success-light: #ECFDF5;
    --warning: #F59E0B;
    --warning-light: #FFFBEB;
    --danger: #EF4444;
    --danger-light: #FEF2F2;
    --info: #3B82F6;
    --info-light: #EFF6FF;

    /* ── Backgrounds ─── */
    --bg-base: #F8FAFC;
    --bg-card: #FFFFFF;
    --bg-section: #F1F5F9;
    --bg-dark: #0F172A;

    /* ── Text ─── */
    --text-main: #0F172A;
    --text-secondary: #334155;
    --text-muted: #64748B;
    --text-light: #94A3B8;
    --text-white: #FFFFFF;

    /* ── Borders ─── */
    --border: #E2E8F0;
    --border-light: #F1F5F9;
    --border-focus: #2563EB;

    /* ── Border Radius ─── */
    --radius-xs: 6px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 24px;
    --radius-pill: 9999px;

    /* ── Shadows ─── */
    --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.06), 0 2px 4px -2px rgba(15, 23, 42, 0.04);
    --shadow-lg: 0 10px 40px -10px rgba(15, 23, 42, 0.08);
    --shadow-xl: 0 20px 60px -15px rgba(15, 23, 42, 0.12);
    --shadow-float: 0 20px 25px -5px rgba(15, 23, 42, 0.1), 0 8px 10px -6px rgba(15, 23, 42, 0.1);
    --shadow-card: 0 1px 3px rgba(15, 23, 42, 0.05), 0 1px 2px rgba(15, 23, 42, 0.03);
    --shadow-card-hover: 0 12px 40px -8px rgba(30, 58, 110, 0.12);
    --shadow-btn: 0 4px 14px rgba(37, 99, 235, 0.25);
    --shadow-btn-hover: 0 8px 20px rgba(37, 99, 235, 0.35);

    /* ── Gradients ─── */
    --gradient-primary: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%);
    --gradient-primary-soft: linear-gradient(135deg, #1E3A6E 0%, #254A8A 100%);
    --gradient-hero: linear-gradient(160deg, #0F172A 0%, #1E3A6E 50%, #254A8A 100%);
    --gradient-cta: linear-gradient(135deg, #2563EB 0%, #1D4ED8 50%, #1E3A6E 100%);
    --gradient-dark: linear-gradient(160deg, #0F172A 0%, #1E3A6E 50%, #1C3F68 100%);
    --gradient-card: linear-gradient(135deg, #F5F8FC 0%, #EDF2FA 100%);
    --gradient-glass: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.7) 100%);

    /* ── Transitions ─── */
    --ease-out: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
    --transition-fast: 0.15s var(--ease-out);
    --transition-normal: 0.3s var(--ease-out);
    --transition-slow: 0.5s var(--ease-out);

    /* ── Typography ─── */
    --font-primary: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'SF Mono', 'Fira Code', monospace;

    /* ── Layout ─── */
    --max-width: 1320px;
    --navbar-height: 120px;
    --topbar-height: 36px;
}

/* Dark mode tokens */
[data-theme="dark"] {
    --bg-base: #0F172A;
    --bg-card: #1E293B;
    --bg-section: #1A2332;
    --text-main: #F1F5F9;
    --text-secondary: #CBD5E1;
    --text-muted: #94A3B8;
    --text-light: #64748B;
    --border: #334155;
    --border-light: #1E293B;
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-card-hover: 0 12px 40px -8px rgba(0, 0, 0, 0.4);
    --primary-light: rgba(37, 99, 235, 0.15);
    --primary-xlight: rgba(37, 99, 235, 0.08);
}


/* ================================================================
   2. BASE & TYPOGRAPHY
   ================================================================ */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
    overflow-x: hidden;
    max-width: 100vw;
}

body {
    font-family: var(--font-primary);
    background-color: var(--bg-base);
    background-image: url('../img/user-bg.png');
    background-size: cover;
    background-position: center top;
    background-attachment: fixed;
    background-repeat: no-repeat;
    color: var(--text-main);
    font-size: 16px;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    max-width: 100vw;
    width: 100%;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-primary);
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.02em;
    line-height: 1.2;
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1rem;
}

a {
    color: var(--secondary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--secondary-dark);
}

/* ── HR Styling ─── */
hr {
    border: none;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, var(--border) 20%, var(--border) 80%, transparent 100%);
    margin: 32px 0;
    opacity: 0.6;
}

section+section {
    border-top: none;
}

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

::selection {
    background: var(--secondary);
    color: white;
}


/* ================================================================
   3. GLASSMORPHISM UTILITIES
   ================================================================ */
.glass-panel {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.glass-dark {
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.08);
}


/* ================================================================
   4. CARDS
   ================================================================ */
.premium-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-card);
    padding: 28px;
    transition: all var(--transition-normal);
    position: relative;
}

.premium-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card-hover);
    border-color: var(--border);
}

.premium-card.no-hover:hover {
    transform: none;
    box-shadow: var(--shadow-card);
}

.premium-card.radius-lg {
    border-radius: var(--radius-lg);
}

.premium-card.radius-md {
    border-radius: var(--radius-md);
}

.premium-card.glass {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.5);
}

/* Stat card */
.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-card);
    padding: 28px;
    text-align: center;
    transition: all var(--transition-normal);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card-hover);
}

.stat-number {
    font-size: 36px;
    font-weight: 800;
    color: var(--primary);
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-muted);
}


/* ================================================================
   5. BUTTONS
   ================================================================ */
.btn-premium {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--gradient-primary);
    color: white;
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 15px;
    padding: 13px 28px;
    border-radius: var(--radius-pill);
    border: none;
    cursor: pointer;
    transition: all var(--transition-normal);
    box-shadow: var(--shadow-btn);
    text-decoration: none;
    line-height: 1.4;
    white-space: nowrap;
}

.btn-premium:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-btn-hover);
    color: white;
    text-decoration: none;
}

.btn-premium:active {
    transform: translateY(0);
    box-shadow: var(--shadow-sm);
}

.btn-premium-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: transparent;
    color: var(--secondary);
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 15px;
    padding: 12px 28px;
    border-radius: var(--radius-pill);
    border: 2px solid var(--secondary);
    cursor: pointer;
    transition: all var(--transition-normal);
    text-decoration: none;
    line-height: 1.4;
}

.btn-premium-outline:hover {
    background: var(--primary-light);
    color: var(--secondary-dark);
    border-color: var(--secondary-dark);
    text-decoration: none;
}

.btn-premium-ghost {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    color: var(--text-main);
    font-weight: 600;
    font-size: 15px;
    padding: 12px 24px;
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
}

.btn-premium-ghost:hover {
    color: var(--secondary);
    text-decoration: none;
}

.btn-sm {
    padding: 8px 20px;
    font-size: 13px;
}

.btn-lg {
    padding: 16px 36px;
    font-size: 16px;
}


/* ================================================================
   6. BADGES
   ================================================================ */
.badge-premium {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 14px;
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 600;
    background: var(--primary-light);
    color: var(--primary);
    line-height: 1.4;
}

.badge-success {
    background: var(--success-light);
    color: var(--success);
}

.badge-warning {
    background: var(--warning-light);
    color: var(--warning);
}

.badge-danger {
    background: var(--danger-light);
    color: var(--danger);
}

.badge-info {
    background: var(--info-light);
    color: var(--info);
}

.badge-accent {
    background: var(--accent-light);
    color: var(--accent);
}


/* ================================================================
   7. FORM ELEMENTS
   ================================================================ */
.form-control-premium {
    width: 100%;
    background: var(--bg-card);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    padding: 13px 18px;
    font-family: var(--font-primary);
    font-size: 15px;
    color: var(--text-main);
    transition: all var(--transition-fast);
    outline: none;
}

.form-control-premium:focus {
    border-color: var(--border-focus);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.form-control-premium::placeholder {
    color: var(--text-light);
}

.form-label-premium {
    display: block;
    font-weight: 600;
    font-size: 14px;
    color: var(--text-main);
    margin-bottom: 8px;
}


/* ================================================================
   8. TOPBAR
   ================================================================ */
.navbar-topbar-premium {
    background: var(--primary-dark);
    color: rgba(255, 255, 255, 0.85);
    font-size: 13px;
    padding: 8px 0;
    font-weight: 500;
    letter-spacing: 0.01em;
    position: relative;
    z-index: 1001;
}

.navbar-topbar-premium a {
    color: rgba(255, 255, 255, 0.75);
    transition: color var(--transition-fast);
}

.navbar-topbar-premium a:hover {
    color: white;
}


/* ================================================================
   9. NAVBAR
   ================================================================ */
.navbar-premium {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-light);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all var(--transition-normal);
    height: var(--navbar-height);
    display: flex;
    align-items: center;
}

.navbar-premium.scrolled {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
    border-bottom-color: transparent;
}

[data-theme="dark"] .navbar-premium {
    background: var(--bg-card);
    border-bottom-color: var(--border);
}

[data-theme="dark"] .navbar-premium.scrolled {
    background: rgba(30, 41, 59, 0.92);
}

/* Brand */
.navbar-brand-premium {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.navbar-brand-premium img {
    height: 42px;
    width: auto;
}

.navbar-brand-premium h1 {
    font-size: 18px;
    margin: 0;
    font-weight: 800;
    color: var(--primary);
    line-height: 1.15;
    letter-spacing: -0.01em;
}

.navbar-brand-premium p {
    font-size: 11px;
    margin: 0;
    color: var(--text-muted);
    font-weight: 500;
    line-height: 1.2;
}

/* Desktop Menu */
.navbar-menu-premium {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    flex: 1;
    min-width: 0;
    /* flex-wrap: wrap; Prevents overflow by allowing items to wrap if they exceed container width */
}

.navbar-menu-premium>li {
    position: relative;
    flex-shrink: 0;
    margin: 0 1px;
    /* Slightly reduced margin */
}

.navbar-menu-premium>li>a {
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 12.5px;
    /* Slightly smaller font to fit more items */
    padding: 6px 8px;
    /* Reduced padding */
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    border-radius: var(--radius-sm);
    transition: color var(--transition-fast), background var(--transition-fast);
    text-decoration: none;
    white-space: nowrap;
}

.navbar-menu-premium>li>a:hover,
.navbar-menu-premium>li.active>a {
    color: var(--secondary);
    background: var(--primary-light);
}

/* Remove underline animation — use background instead */
.navbar-menu-premium li a::after {
    display: none;
}

/* Dropdown */
.nav-dropdown-premium {
    position: relative;
}

.nav-dropdown-premium .dropdown-menu-content {
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    min-width: 240px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-light);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s var(--ease-out);
    padding: 8px;
    z-index: 1100;
}

.nav-dropdown-premium:hover>.dropdown-menu-content {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Nested dropdowns */
.dropdown-menu-content .nav-dropdown-premium .dropdown-menu-content {
    top: 0;
    left: calc(100% + 8px);
    transform: translateX(8px) translateY(0);
}

.dropdown-menu-content .nav-dropdown-premium:hover>.dropdown-menu-content {
    transform: translateX(0) translateY(0);
}

.dropdown-menu-content li {
    list-style: none;
    margin: 0;
    padding: 0;
}

.dropdown-menu-content a {
    display: block !important;
    padding: 10px 16px !important;
    color: var(--text-muted) !important;
    font-weight: 500 !important;
    font-size: 14px !important;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    text-decoration: none !important;
}

.dropdown-menu-content a::after {
    display: none !important;
}

.dropdown-menu-content a:hover {
    background: var(--primary-light) !important;
    color: var(--secondary) !important;
}


/* ================================================================
   10. MOBILE NAV
   ================================================================ */
.mobile-overlay-premium {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 1999;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
}

.mobile-overlay-premium.active {
    opacity: 1;
    visibility: visible;
}

.mobile-nav-premium {
    position: fixed;
    top: 0;
    left: -320px;
    width: 300px;
    height: 100vh;
    background: var(--bg-card);
    z-index: 2000;
    box-shadow: var(--shadow-xl);
    transition: left var(--transition-normal);
    overflow-y: auto;
    padding: 28px;
}

.mobile-nav-premium.active,
.mobile-nav-premium.open {
    left: 0;
}


/* ================================================================
   11. SEARCH OVERLAY
   ================================================================ */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 9999;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 15vh;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
}

.search-overlay.active {
    opacity: 1;
    visibility: visible;
}


/* ================================================================
   12. HERO SECTION
   ================================================================ */
.hero-premium {
    padding: 80px 0 100px;
    background: transparent;
    position: relative;
    overflow: hidden;
}

.hero-title {
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 800;
    line-height: 1.1;
    color: var(--text-main);
    margin-bottom: 20px;
    letter-spacing: -0.03em;
}

.hero-subtitle {
    font-size: clamp(16px, 2vw, 18px);
    color: var(--text-muted);
    margin-bottom: 36px;
    line-height: 1.7;
    max-width: 540px;
}

/* Hero decorative blob */
.hero-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.4;
    z-index: 0;
    pointer-events: none;
    max-width: 90vw;
    max-height: 90vw;
}

.hero-blob-1 {
    width: 500px;
    height: 500px;
    background: var(--secondary-light);
    top: -15%;
    right: 0;
}

.hero-blob-2 {
    width: 300px;
    height: 300px;
    background: var(--accent-light);
    bottom: -10%;
    left: 5%;
}


.perizinan-hero {
    background: var(--gradient-hero);
    padding: 60px 0 50px;
    color: white;
    position: relative;
    overflow: hidden;
}

.perizinan-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
    opacity: 0.5;
}

.perizinan-hero h1 {
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 800;
    color: white;
    margin-bottom: 12px;
}

.perizinan-hero p {
    color: rgba(255, 255, 255, 0.75);
    font-size: 16px;
    margin: 0;
}

.perizinan-section {
    padding: 60px 0 80px;
    background: transparent;
}

.perizinan-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    padding: 20px;
    cursor: pointer;
    transition: all var(--transition-normal);
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    color: var(--text-main);
}

.perizinan-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-card-hover);
    border-color: var(--secondary-light);
}

.perizinan-card .perizinan-icon {
    width: 44px;
    height: 44px;
    background: var(--primary-light);
    color: var(--secondary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 18px;
    transition: all var(--transition-fast);
}

.perizinan-card:hover .perizinan-icon {
    background: var(--secondary);
    color: white;
}

.perizinan-card span {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
    line-height: 1.4;
}

.section-header .tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--secondary);
    color: white;
    padding: 6px 18px;
    border-radius: var(--radius-pill);
    font-size: 13px;
    font-weight: 600;
}


/* ================================================================
   14. FOOTER
   ================================================================ */
.footer-premium {
    background: var(--gradient-dark);
    color: white;
    padding: 80px 0 30px;
    margin-top: 0;
    position: relative;
}

.footer-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(37, 99, 235, 0.3), transparent);
}

.footer-premium h4 {
    color: white;
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 24px;
    letter-spacing: 0;
}

.footer-links-premium {
    list-style: none;
    padding: 0;
    margin: 0;
}

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

.footer-links-premium a {
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.footer-links-premium a:hover {
    color: white;
    padding-left: 4px;
}

.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.65);
    font-size: 14px;
    line-height: 1.5;
}

.footer-contact-item i {
    margin-top: 2px;
    color: var(--accent);
    flex-shrink: 0;
}


/* ================================================================
   15. ACCORDION / FAQ
   ================================================================ */
.premium-accordion .accordion-item {
    border: 1px solid var(--border-light) !important;
    border-radius: var(--radius-md) !important;
    margin-bottom: 12px;
    overflow: hidden;
    background: var(--bg-card);
    box-shadow: none;
    transition: all var(--transition-normal);
}

.premium-accordion .accordion-item:hover {
    border-color: var(--border) !important;
}

.premium-accordion .accordion-button {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
    padding: 18px 24px;
    box-shadow: none !important;
    background: transparent;
    border: none;
    font-family: var(--font-primary);
}

.premium-accordion .accordion-button:not(.collapsed) {
    color: var(--secondary);
    background: var(--primary-light);
}

.premium-accordion .accordion-button::after {
    width: 16px;
    height: 16px;
    background-size: 16px;
}

.premium-accordion .accordion-body {
    padding: 0 24px 20px;
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-muted);
}


/* ================================================================
   16. MODAL OVERRIDES
   ================================================================ */
.modal-content.premium-card {
    border-radius: var(--radius-xl) !important;
    border: none !important;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}

.modal-content .modal-header {
    border-bottom: 1px solid var(--border-light);
    padding: 24px 28px;
    background: var(--bg-base);
}

.modal-content .modal-body {
    padding: 24px 28px;
}

.modal-content .btn-close {
    opacity: 0.5;
}

.modal-content .btn-close:hover {
    opacity: 1;
}


/* ================================================================
   17. PAGINATION
   ================================================================ */
.custom-pagination nav>ul {
    gap: 6px;
    flex-wrap: wrap;
}

.custom-pagination .page-item .page-link {
    border-radius: var(--radius-sm);
    padding: 8px 16px;
    color: var(--text-main);
    border: 1px solid var(--border-light);
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.custom-pagination .page-item .page-link:hover {
    background: var(--primary-light);
    border-color: var(--secondary-light);
    color: var(--secondary);
}

.custom-pagination .page-item.active .page-link {
    background: var(--secondary);
    border-color: var(--secondary);
    color: white;
}


/* ================================================================
   18. ARTICLE BODY
   ================================================================ */
.article-body {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-main);
}

.article-body h1,
.article-body h2,
.article-body h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.article-body img {
    border-radius: var(--radius-md);
    margin: 1.5rem 0;
}

.article-body a {
    color: var(--secondary);
    text-decoration: underline;
}

.article-body ul,
.article-body ol {
    padding-left: 1.5rem;
    margin-bottom: 1rem;
}

.article-body blockquote {
    border-left: 4px solid var(--secondary);
    padding: 1rem 1.5rem;
    background: var(--primary-light);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    margin: 1.5rem 0;
    color: var(--text-secondary);
}

.article-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

.article-body table th,
.article-body table td {
    border: 1px solid var(--border);
    padding: 10px 14px;
    font-size: 14px;
}

.article-body table th {
    background: var(--bg-base);
    font-weight: 600;
}


/* ================================================================
   19. ANIMATIONS
   ================================================================ */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse-soft {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.7;
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

@keyframes scrollLeft {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.animate-fade-up {
    animation: fadeUp 0.6s var(--ease-out) forwards;
}

.animate-fade-in {
    animation: fadeIn 0.5s var(--ease-out) forwards;
}

.animate-slide-up {
    animation: slideUp 0.7s var(--ease-out) forwards;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}


/* ================================================================
   20. RESPONSIVE
   ================================================================ */

/* Tablet */
@media (max-width: 991px) {
    .navbar-menu-premium {
        display: none !important;
    }

    .hero-title {
        font-size: clamp(28px, 6vw, 40px);
    }

    .premium-card {
        padding: 20px;
        border-radius: var(--radius-lg);
    }

    .footer-premium {
        padding: 60px 0 24px;
    }
}

/* Mobile */
@media (max-width: 767px) {
    body {
        font-size: 15px;
    }

    .hero-title {
        font-size: clamp(26px, 7vw, 36px);
    }

    .premium-card {
        padding: 18px;
        border-radius: 16px;
    }

    .stat-number {
        font-size: 28px;
    }

    .perizinan-hero {
        padding: 40px 0 36px;
    }

    .perizinan-hero h1 {
        font-size: 24px;
    }

    .footer-premium {
        padding: 48px 0 20px;
    }

    .footer-premium h4 {
        font-size: 15px;
        margin-bottom: 16px;
    }
}

/* Small Mobile (390px / 360px) */
@media (max-width: 400px) {
    .premium-card {
        padding: 16px;
        border-radius: 14px;
    }

    .btn-premium {
        padding: 11px 22px;
        font-size: 14px;
    }

    .navbar-brand-premium img {
        height: 36px;
    }

    .navbar-brand-premium h1 {
        font-size: 15px;
    }
}

/* Lucide icon fix */
.lucide {
    stroke-width: 2;
}

/* ================================================================
   21. SKELETON LOADING
   ================================================================ */

@keyframes shimmer {
    0% {
        background-position: -800px 0;
    }

    100% {
        background-position: 800px 0;
    }
}

.skeleton {
    background: linear-gradient(90deg,
            #e8edf2 0%,
            #f4f7fa 40%,
            #e8edf2 80%);
    background-size: 800px 100%;
    animation: shimmer 1.6s ease-in-out infinite;
    border-radius: 8px;
    display: block;
}

[data-theme="dark"] .skeleton {
    background: linear-gradient(90deg,
            #1e293b 0%,
            #2d3748 40%,
            #1e293b 80%);
    background-size: 800px 100%;
    animation: shimmer 1.6s ease-in-out infinite;
}

/* Skeleton shapes */
.skeleton-text {
    height: 14px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.skeleton-title {
    height: 22px;
    border-radius: 6px;
    margin-bottom: 12px;
}

.skeleton-img {
    width: 100%;
    border-radius: var(--radius-lg);
}

.skeleton-badge {
    height: 22px;
    width: 80px;
    border-radius: 50px;
}

.skeleton-btn {
    height: 40px;
    width: 140px;
    border-radius: var(--radius-pill);
}

.skeleton-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
}

.skeleton-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
}

.skeleton-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-light);
}

/* Skeleton item wrapper — fades out after JS removes it */
.skeleton-item {
    transition: opacity 0.4s ease;
}

/* PDF inline viewer / Dokumen Lampiran (A4 Ratio) */
.pdf-viewer-container {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-sm);
    background: var(--bg-base);
}

.pdf-viewer-container iframe,
.pdf-embed-frame {
    display: block;
    width: 100%;
    aspect-ratio: 210 / 297; /* Proporsi standar kertas A4 (210mm x 297mm) */
    min-height: 750px;
    border: none;
    background: #fff;
}

/* ================================================================
   PORTAL & QUICK LINK CARDS (Modern Government Button Style)
   ================================================================ */
.portal-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    text-decoration: none;
    color: var(--text-main);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), 
                box-shadow 0.25s cubic-bezier(0.4, 0, 0.2, 1), 
                border-color 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    height: 100%;
}

.portal-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: transparent;
    transition: background 0.25s ease;
}

.portal-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px -8px rgba(30, 58, 110, 0.12);
    border-color: var(--secondary-light);
    color: var(--text-main);
}

.portal-card:hover::before {
    background: var(--secondary);
}

.portal-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 20px;
    transition: transform 0.25s ease, background 0.25s ease;
}

.portal-card:hover .portal-card-icon {
    transform: scale(1.08);
}

.portal-card-icon.icon-blue {
    background: rgba(37, 99, 235, 0.1);
    color: #2563EB;
}
.portal-card-icon.icon-red {
    background: rgba(239, 68, 68, 0.1);
    color: #EF4444;
}
.portal-card-icon.icon-amber {
    background: rgba(245, 158, 11, 0.1);
    color: #D97706;
}
.portal-card-icon.icon-emerald {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
}
.portal-card-icon.icon-teal {
    background: rgba(13, 148, 136, 0.1);
    color: #0D9488;
}
.portal-card-icon.icon-cyan {
    background: rgba(6, 182, 212, 0.1);
    color: #0891B2;
}
.portal-card-icon.icon-indigo {
    background: rgba(99, 102, 241, 0.1);
    color: #4F46E5;
}
.portal-card-icon.icon-purple {
    background: rgba(147, 51, 234, 0.1);
    color: #7C3AED;
}

.portal-card-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.portal-card-tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--secondary);
    line-height: 1.2;
}

.portal-card-title {
    font-size: 14.5px;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.35;
    margin: 0;
    transition: color 0.2s ease;
}

.portal-card:hover .portal-card-title {
    color: var(--secondary);
}

.portal-card-sub {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.3;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.portal-card-arrow {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-base);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.25s ease;
}

.portal-card:hover .portal-card-arrow {
    background: var(--primary-light);
    color: var(--secondary);
    transform: translate(2px, -2px);
}

/* Hero Explore Button */
.hero-btn-explore {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 11px 32px;
    background: #ffffff;
    color: #0F172A;
    font-size: 15px;
    font-weight: 600;
    border: 1.5px solid #2563EB;
    border-radius: 9999px;
    box-shadow: 0 4px 18px rgba(37, 99, 235, 0.12);
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-btn-explore:hover {
    background: #2563EB;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.25);
}

.hero-btn-explore .compass-icon {
    width: 20px;
    height: 20px;
    color: #2563EB;
    transition: color 0.3s ease;
}

.hero-btn-explore:hover .compass-icon {
    color: #ffffff;
}

[data-theme="dark"] .hero-btn-explore {
    background: var(--bg-card);
    color: var(--text-main);
    border-color: var(--secondary);
}

[data-theme="dark"] .hero-btn-explore:hover {
    background: var(--secondary);
    color: #ffffff;
}

/* ================================================================
   15. COMPREHENSIVE MOBILE RESPONSIVENESS & TOUCH ADAPTATIONS
   ================================================================ */

/* Global container & media guard */
img, svg, video, canvas, audio, iframe, embed, object {
    max-width: 100%;
}

/* Article Body CMS content responsiveness */
.article-body {
    word-break: break-word;
    overflow-wrap: break-word;
}

.article-body img {
    max-width: 100% !important;
    height: auto !important;
    border-radius: var(--radius-md);
    margin: 12px 0;
}

.article-body table {
    max-width: 100% !important;
    width: 100% !important;
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-collapse: collapse;
    margin: 16px 0;
}

.article-body iframe,
.article-body embed,
.article-body video {
    max-width: 100% !important;
    width: 100% !important;
    border-radius: var(--radius-md);
}

/* Side articles in berita list */
.side-article-card {
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.side-article-img {
    width: 140px;
    height: 120px;
    object-fit: cover;
    border-radius: var(--radius-md) 0 0 var(--radius-md);
    flex-shrink: 0;
}

.side-article-content {
    padding: 16px 20px;
    flex: 1;
    min-width: 0;
}

/* Article prev / next navigation */
.article-nav-btn {
    flex-grow: 1;
    padding: 14px 18px;
    border-radius: var(--radius-md);
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    text-decoration: none;
    transition: all var(--transition-fast);
    min-width: 180px;
}

.article-nav-btn:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

/* Tablet & Mobile Media Queries (< 992px) */
@media (max-width: 991.98px) {
    .navbar-topbar-premium {
        display: none !important;
    }
    
    .navbar-premium {
        padding: 8px 0;
    }

    .hero-btn-explore {
        padding: 10px 24px;
        font-size: 14px;
    }
}

/* Mobile Devices (< 768px) */
@media (max-width: 767.98px) {
    .hero-blob-1 {
        width: 220px;
        height: 220px;
        top: -5%;
        right: 0;
    }

    .hero-blob-2 {
        width: 180px;
        height: 180px;
        bottom: 0;
        left: 0;
    }

    .pdf-viewer-container iframe,
    .pdf-embed-frame {
        aspect-ratio: 210 / 297;
        min-height: 480px !important;
    }

    .berita-pagination li a,
    .berita-pagination li span {
        width: 36px;
        height: 36px;
        font-size: 13px;
    }

    .berita-pagination {
        gap: 4px;
    }
}

/* Extra Small Phones (< 576px) */
@media (max-width: 575.98px) {
    .side-article-card {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .side-article-img {
        width: 100% !important;
        height: 160px !important;
        border-radius: var(--radius-md) var(--radius-md) 0 0 !important;
    }

    .side-article-content {
        padding: 14px 16px !important;
    }

    .article-nav-btn {
        min-width: 100% !important;
        width: 100% !important;
    }

    .perizinan-card {
        padding: 12px 10px !important;
        gap: 10px !important;
        border-radius: var(--radius-md) !important;
    }

    .perizinan-card .perizinan-icon {
        width: 36px !important;
        height: 36px !important;
        font-size: 14px !important;
        border-radius: 10px !important;
    }

    .perizinan-card span,
    .perizinan-card .layanan-nama {
        font-size: 12px !important;
        line-height: 1.35 !important;
    }

    .portal-card {
        padding: 14px 16px;
        gap: 12px;
    }

    .portal-card-icon {
        width: 42px;
        height: 42px;
        font-size: 18px;
    }

    .portal-card-title {
        font-size: 13.5px;
    }

    .modal-header {
        padding: 16px 20px !important;
    }

    .modal-body {
        padding: 16px 20px !important;
    }

    .modal-footer {
        padding: 12px 20px 16px !important;
    }

    /* Custom popup poster fit */
    #customPopupBox {
        max-width: 95vw !important;
        max-height: 85vh !important;
        border-radius: 14px !important;
    }

    #customPopupBox img.popup-img {
        max-width: 95vw !important;
        max-height: 85vh !important;
    }

    /* Swiper banner pagination */
    .custom-banner-pagination {
        text-align: center !important;
        padding-right: 0 !important;
        bottom: 12px !important;
    }
}

/* ================================================================
   PROGRAM UNGGULAN SECTION & MODAL (OPTION B)
   ================================================================ */
.program-card-item {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease;
    cursor: pointer;
    border: 1px solid var(--border-light);
    outline: none;
}
.program-card-item:hover,
.program-card-item:focus-visible {
    transform: translateY(-6px);
    box-shadow: 0 20px 35px -8px rgba(15, 23, 42, 0.1);
    border-color: rgba(37, 99, 235, 0.3);
}
.program-cover-wrapper {
    width: 100%;
    height: 220px;
    background: #F8FAFC;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}
.program-cover-backdrop {
    position: absolute;
    inset: -20px;
    background-size: cover;
    background-position: center;
    filter: blur(24px) opacity(0.22);
    transform: scale(1.15);
    pointer-events: none;
    z-index: 0;
}
.program-cover-img {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    max-height: 220px;
    object-fit: contain;
    object-position: center;
    padding: 16px 20px;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.program-card-item:hover .program-cover-img {
    transform: scale(1.05);
}
.program-card-title {
    font-size: 17px;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 48px;
    transition: color 0.2s ease;
}
.program-card-item:hover .program-card-title {
    color: var(--secondary);
}
.program-card-desc {
    font-size: 13.5px;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 64px;
}
.program-card-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 12px;
    border-top: 1px solid var(--border-light);
    font-size: 13px;
    font-weight: 600;
    color: var(--secondary);
    transition: color 0.2s ease;
}
.program-card-item:hover .program-card-action {
    color: var(--secondary-dark);
}
.program-detail-html {
    color: var(--text-secondary);
    font-size: 14.5px;
    line-height: 1.75;
}
.program-detail-html p {
    margin-bottom: 12px;
}
.program-detail-html ul,
.program-detail-html ol {
    margin-left: 20px;
    margin-bottom: 14px;
    padding-left: 4px;
}
.program-detail-html li {
    margin-bottom: 6px;
    line-height: 1.65;
}
.program-detail-html a {
    color: var(--secondary);
    text-decoration: underline;
    font-weight: 500;
}
.program-detail-html a:hover {
    color: var(--secondary-dark);
}
.program-detail-html img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-sm);
    margin: 12px 0;
}
.program-detail-html h1,
.program-detail-html h2,
.program-detail-html h3,
.program-detail-html h4 {
    color: var(--text-main);
    font-weight: 700;
    margin-top: 16px;
    margin-bottom: 8px;
}

/* Modal Stacking Context & Backdrop Safety */
.modal {
    z-index: 1060 !important;
}
.modal-backdrop {
    z-index: 1050 !important;
}
.modal-backdrop.show {
    opacity: 0.5 !important;
}