*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

  :root {
    --blue-deep:   #0b2a4a;
    --blue-dark:   #103a63;
    --blue-mid:    #1a5fa0;
    --blue-bright: #2980d4;
    --blue-light:  #5baae8;
    --blue-pale:   #ddeef9;
    --blue-softer: #edf5fc;
    --sky:         #b8daf5;
    --gold:        #e6a817;
    --gold-light:  #ffd97a;
    --cream:       #f7f9fc;
    --white:       #ffffff;
    --text-dark:   #0d1b2a;
    --text-mid:    #3a5068;
    --text-light:  #6b8ba4;
    --border:      #d0e4f2;
  }

  html { scroll-behavior: smooth; }
  body { font-family: 'DM Sans', sans-serif; background: var(--cream); color: var(--text-dark); overflow-x: hidden; }

  /* ─ NAVBAR ─ */
  nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 200;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 5vw; height: 66px;
    background: rgba(11, 42, 74, 0.96);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(91,170,232,.18);
  }
  .nav-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
  .nav-logo {
    width: 42px; height: 42px; border-radius: 10px;
    background: linear-gradient(135deg, var(--blue-bright), var(--blue-light));
    display: flex; align-items: center; justify-content: center;
    font-family: 'Cormorant Garamond', serif;
    font-size: 20px; font-weight: 700; color: #fff;
  }
  .nav-title { color: #fff; font-size: 14.5px; font-weight: 600; line-height: 1.25; }
  .nav-title span { display: block; font-weight: 300; font-size: 11px; opacity: .6; letter-spacing: .06em; margin-top: 1px; }
  .nav-links { display: flex; gap: 30px; list-style: none; }
  .nav-links a { color: rgba(255,255,255,.65); text-decoration: none; font-size: 13px; font-weight: 500; transition: color .2s; }
  .nav-links a:hover { color: var(--gold-light); }

  /* ─ HERO ─ */
  #hero {
    min-height: 100vh;
    background:
      linear-gradient(160deg, rgba(11,42,74,.88) 0%, rgba(16,58,99,.6) 55%, rgba(26,95,160,.75) 100%),
      url('image/Kantordesa.png') center/cover no-repeat;
    display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
    padding: 110px 8vw 80px;
    position: relative; overflow: hidden;
  }
  .hero-bg-circle {
    position: absolute; right: -80px; top: 50%;
    transform: translateY(-50%);
    width: 560px; height: 560px; border-radius: 50%;
    border: 1.5px solid rgba(91,170,232,.15);
    pointer-events: none;
  }
  .hero-bg-circle::before {
    content: ''; position: absolute; inset: 40px; border-radius: 50%;
    border: 1px solid rgba(91,170,232,.1);
  }
  .hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(41,128,212,.22); border: 1px solid rgba(91,170,232,.4);
    color: var(--sky); font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
    padding: 7px 18px; border-radius: 100px; margin-bottom: 26px;
    animation: fadeUp .7s ease both;
  }
  .hero-badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--blue-light); }
  .hero-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(46px, 7.5vw, 96px);
    color: #fff; line-height: 1.05; font-weight: 700; letter-spacing: -.02em;
    animation: fadeUp .7s .1s ease both; max-width: 700px;
  }
  .hero-title em { color: var(--gold-light); font-style: italic; }
  .hero-sub {
    margin-top: 20px; max-width: 500px;
    color: rgba(255,255,255,.65); font-size: 16px; line-height: 1.8;
    animation: fadeUp .7s .2s ease both;
  }
  .hero-actions {
    display: flex; gap: 14px; margin-top: 38px;
    animation: fadeUp .7s .3s ease both;
  }
  .btn-primary {
    background: var(--blue-bright); color: #fff;
    padding: 13px 28px; border-radius: 10px; font-size: 14px; font-weight: 600;
    text-decoration: none; transition: background .2s, transform .15s;
  }
  .btn-primary:hover { background: var(--blue-light); transform: translateY(-2px); }
  .btn-outline {
    background: transparent; color: rgba(255,255,255,.8);
    border: 1.5px solid rgba(255,255,255,.3);
    padding: 13px 28px; border-radius: 10px; font-size: 14px; font-weight: 500;
    text-decoration: none; transition: border-color .2s, color .2s;
  }
  .btn-outline:hover { border-color: var(--blue-light); color: #fff; }
  .hero-stats {
    display: flex; gap: 0; margin-top: 64px;
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 14px; overflow: hidden;
    animation: fadeUp .7s .4s ease both;
  }
  .hero-stat { padding: 20px 34px; border-right: 1px solid rgba(255,255,255,.1); }
  .hero-stat:last-child { border-right: none; }
  .hero-stat-n {
    font-family: 'Cormorant Garamond', serif;
    font-size: 30px; font-weight: 700; color: var(--gold-light); line-height: 1;
  }
  .hero-stat-l { font-size: 11px; color: rgba(255,255,255,.5); margin-top: 3px; letter-spacing: .05em; }
  .hero-scroll-hint {
    position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%);
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    color: rgba(255,255,255,.3); font-size: 10px; letter-spacing: .14em; text-transform: uppercase;
    animation: fadeIn 1.5s .8s ease both;
  }
  .scroll-arrow { width: 20px; height: 20px; border-right: 1.5px solid rgba(255,255,255,.3); border-bottom: 1.5px solid rgba(255,255,255,.3); transform: rotate(45deg); animation: bounce 1.6s ease infinite; }

  /* ─ SECTION BASE ─ */
  section { padding: 96px 8vw; }
  .sec-label { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--blue-bright); font-weight: 600; margin-bottom: 10px; }
  .sec-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(30px, 4vw, 48px); font-weight: 700; line-height: 1.15; color: var(--blue-deep);
  }
  .sec-title em { font-style: italic; color: var(--blue-bright); }
  .sec-body { font-size: 15.5px; line-height: 1.85; color: var(--text-mid); margin-top: 14px; max-width: 620px; }

  /* ─ PROFIL ─ */
  #profil { background: var(--white); }
  .profil-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; margin-top: 60px; }
  .profil-img-stack { position: relative; height: 520px; }
  .pimg-main {
    position: absolute; left: 0; top: 0; width: 78%; height: 80%;
    border-radius: 20px; overflow: hidden;
    box-shadow: 0 24px 60px rgba(11,42,74,.18);
  }
  .pimg-main img { width: 100%; height: 100%; object-fit: cover; }
  .pimg-accent {
    position: absolute; right: 0; bottom: 0; width: 58%; height: 55%;
    border-radius: 16px; overflow: hidden;
    border: 4px solid var(--white);
    box-shadow: 0 16px 40px rgba(11,42,74,.2);
  }
  .pimg-accent img { width: 100%; height: 100%; object-fit: cover; }
  .pimg-badge {
    position: absolute; left: 16px; bottom: 44%;
    background: var(--blue-deep); color: #fff;
    border-radius: 12px; padding: 14px 18px;
    border: 3px solid var(--white);
    box-shadow: 0 8px 24px rgba(11,42,74,.25);
    font-size: 12px; line-height: 1.5;
    min-width: 140px;
  }
  .pimg-badge strong { font-size: 22px; font-family: 'Cormorant Garamond', serif; display: block; color: var(--gold-light); }
  .info-table { margin-top: 32px; border-collapse: collapse; width: 100%; }
  .info-table tr { border-bottom: 1px solid var(--blue-softer); }
  .info-table td { padding: 13px 0; font-size: 14px; vertical-align: top; }
  .info-table td:first-child { color: var(--text-light); width: 130px; font-weight: 500; }
  .info-table td:last-child { color: var(--text-dark); font-weight: 600; }

  /* ─ GALERI ─ */
  #galeri { background: var(--blue-softer); padding: 80px 8vw; }
  .galeri-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 36px; }
  .galeri-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: 200px 200px; gap: 16px; }
  .gal-item { border-radius: 16px; overflow: hidden; position: relative; }
  .gal-item.big { grid-row: 1 / 3; }
  .gal-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
  .gal-item:hover img { transform: scale(1.05); }
  .gal-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(11,42,74,.6) 0%, transparent 60%);
    opacity: 0; transition: opacity .3s;
    display: flex; align-items: flex-end; padding: 16px;
    color: #fff; font-size: 13px; font-weight: 500;
  }
  .gal-item:hover .gal-overlay { opacity: 1; }

  /* ─ SEJARAH ─ */
  #sejarah {
    background: linear-gradient(155deg, var(--blue-deep) 0%, #071e36 100%);
    color: #fff; position: relative; overflow: hidden;
  }
  #sejarah::before {
    content: ''; position: absolute;
    width: 600px; height: 600px; border-radius: 50%;
    background: radial-gradient(circle, rgba(41,128,212,.12) 0%, transparent 70%);
    top: -150px; right: -100px; pointer-events: none;
  }
  #sejarah .sec-label { color: var(--gold-light); }
  #sejarah .sec-title { color: #fff; }
  .sejarah-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; margin-top: 56px; align-items: start; }
  .sejarah-img {
    border-radius: 20px; overflow: hidden; height: 420px;
    position: relative;
    box-shadow: 0 32px 64px rgba(0,0,0,.4);
  }
  .sejarah-img img { width: 100%; height: 100%; object-fit: cover; }
  .sejarah-img-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(11,42,74,.75) 0%, transparent 55%);
    display: flex; align-items: flex-end; padding: 24px;
  }
  .sejarah-img-caption { color: rgba(255,255,255,.85); font-size: 13px; }
  .sejarah-img-caption strong { display: block; font-family: 'Cormorant Garamond', serif; font-size: 18px; margin-bottom: 2px; }
  .sejarah-desc {
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(91,170,232,.18);
    border-left: 3px solid var(--gold);
    border-radius: 14px; padding: 22px 24px;
    font-size: 14.5px; line-height: 1.85; color: rgba(255,255,255,.68);
    margin-bottom: 36px;
  }
  .timeline { position: relative; padding-left: 28px; }
  .timeline::before {
    content: ''; position: absolute; left: 7px; top: 0; bottom: 0;
    width: 1.5px; background: rgba(91,170,232,.25);
  }
  .tl-item { position: relative; padding: 0 0 32px 24px; }
  .tl-dot {
    position: absolute; left: -24px; top: 5px;
    width: 14px; height: 14px; border-radius: 50%;
    background: var(--blue-bright); border: 2.5px solid var(--blue-deep);
    box-shadow: 0 0 0 3px rgba(41,128,212,.3);
  }
  .tl-year { font-size: 11px; font-weight: 600; color: var(--gold-light); letter-spacing: .1em; margin-bottom: 3px; }
  .tl-name { font-family: 'Cormorant Garamond', serif; font-size: 19px; color: #fff; font-weight: 600; }
  .tl-note { font-size: 12.5px; color: rgba(255,255,255,.4); margin-top: 3px; }

  /* ─ WILAYAH ─ */
  #wilayah { background: var(--white); }
  .wilayah-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; margin-top: 56px; }
  .wilayah-map-mock {
    border-radius: 20px; overflow: hidden; height: 380px; position: relative;
    box-shadow: 0 20px 50px rgba(11,42,74,.12);
  }
  .wilayah-map-mock img { width: 100%; height: 100%; object-fit: cover; }
  .map-overlay {
    position: absolute; inset: 0;
    background: rgba(11,42,74,.3);
    display: flex; align-items: center; justify-content: center;
  }
  .map-pin {
    background: var(--blue-bright); color: #fff;
    border-radius: 100px; padding: 10px 20px;
    font-size: 13px; font-weight: 600;
    border: 3px solid #fff;
    box-shadow: 0 8px 24px rgba(11,42,74,.35);
  }
  .batas-list { display: flex; flex-direction: column; gap: 14px; }
  .batas-item {
    display: flex; gap: 16px; align-items: center;
    background: var(--blue-softer); border-radius: 14px; padding: 18px 20px;
    border: 1px solid var(--border); transition: transform .2s, box-shadow .2s;
  }
  .batas-item:hover { transform: translateX(6px); box-shadow: 0 8px 24px rgba(11,42,74,.08); }
  .batas-dir {
    width: 44px; height: 44px; border-radius: 12px;
    background: var(--blue-pale); display: flex; align-items: center; justify-content: center;
    font-size: 18px; flex-shrink: 0;
  }
  .batas-info-key { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--text-light); font-weight: 600; }
  .batas-info-val { font-size: 15px; font-weight: 600; color: var(--blue-deep); margin-top: 2px; }
  .batas-info-sub { font-size: 12px; color: var(--text-light); }

  /* ─ KEPENDUDUKAN ─ */
  #kependudukan { background: var(--cream); }
  .kep-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: start; margin-top: 56px; }
  .kep-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
  .kep-card {
    background: var(--white); border-radius: 16px; padding: 26px 22px;
    border: 1px solid var(--border); text-align: center;
    transition: transform .2s, box-shadow .2s;
  }
  .kep-card:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(11,42,74,.1); }
  .kep-card.featured { background: var(--blue-deep); border-color: var(--blue-deep); grid-column: 1 / -1; }
  .kep-n {
    font-family: 'Cormorant Garamond', serif;
    font-size: 42px; font-weight: 700; color: var(--blue-mid); line-height: 1;
  }
  .kep-card.featured .kep-n { color: var(--gold-light); font-size: 56px; }
  .kep-u { font-size: 11px; font-weight: 600; letter-spacing: .08em; color: var(--blue-light); margin-top: 2px; }
  .kep-card.featured .kep-u { color: rgba(255,255,255,.55); }
  .kep-l { font-size: 13px; color: var(--text-mid); margin-top: 6px; }
  .kep-card.featured .kep-l { color: rgba(255,255,255,.65); }
  .kep-img { border-radius: 20px; overflow: hidden; height: 280px; margin-bottom: 28px; }
  .kep-img img { width: 100%; height: 100%; object-fit: cover; }
  .mp-block { background: var(--white); border-radius: 18px; padding: 28px; border: 1px solid var(--border); }
  .mp-title { font-family: 'Cormorant Garamond', serif; font-size: 20px; font-weight: 600; color: var(--blue-deep); margin-bottom: 20px; }
  .mp-row { margin-bottom: 16px; }
  .mp-meta { display: flex; justify-content: space-between; font-size: 13px; color: var(--text-mid); margin-bottom: 7px; font-weight: 500; }
  .mp-bg { height: 9px; background: var(--blue-softer); border-radius: 100px; overflow: hidden; }
  .mp-fill { height: 100%; border-radius: 100px; background: linear-gradient(90deg, var(--blue-dark), var(--blue-bright)); }

  /* ─ LAYANAN ─ */
  #layanan {
    background: linear-gradient(180deg, var(--blue-deep) 0%, #0e3457 100%);
    color: #fff;
  }
  #layanan .sec-label { color: var(--gold-light); }
  #layanan .sec-title { color: #fff; }
  .layanan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 48px; }
  .layanan-card {
    background: rgba(255,255,255,.06); border-radius: 18px; padding: 28px 24px;
    border: 1px solid rgba(91,170,232,.15);
    transition: background .25s, transform .2s;
    cursor: default;
  }
  .layanan-card:hover { background: rgba(255,255,255,.1); transform: translateY(-5px); }
  .layanan-icon {
    width: 50px; height: 50px; border-radius: 13px;
    background: rgba(41,128,212,.25); display: flex; align-items: center; justify-content: center;
    margin-bottom: 18px;
  }
  .layanan-icon svg { width: 24px; height: 24px; stroke: var(--blue-light); fill: none; stroke-width: 1.8; }
  .layanan-nm { font-weight: 600; font-size: 15px; color: #fff; margin-bottom: 8px; }
  .layanan-ds { font-size: 13.5px; color: rgba(255,255,255,.55); line-height: 1.7; }
  .jam-pelayanan {
    margin-top: 44px; text-align: center;
    background: rgba(255,255,255,.06); border: 1px solid rgba(91,170,232,.15);
    border-radius: 14px; padding: 20px 28px; display: inline-block;
    font-size: 14px; color: rgba(255,255,255,.65);
  }
  .jam-pelayanan strong { color: var(--gold-light); }
  .layanan-bottom { display: flex; justify-content: center; }

  /* ─ FOOTER ─ */
  footer { background: #071e36; color: #fff; padding: 72px 8vw 36px; }
  .footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 56px; margin-bottom: 52px; }
  .footer-brand { font-family: 'Cormorant Garamond', serif; font-size: 26px; font-weight: 700; margin-bottom: 12px; }
  .footer-brand span { color: var(--gold-light); font-style: italic; }
  .footer-desc { font-size: 14px; color: rgba(255,255,255,.45); line-height: 1.75; max-width: 300px; }
  .footer-col-title { font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--blue-light); margin-bottom: 18px; font-weight: 600; }
  .footer-links { list-style: none; display: flex; flex-direction: column; gap: 10px; }
  .footer-links a { color: rgba(255,255,255,.5); font-size: 13.5px; text-decoration: none; transition: color .2s; }
  .footer-links a:hover { color: var(--gold-light); }
  .fc-item { display: flex; gap: 10px; align-items: flex-start; color: rgba(255,255,255,.5); font-size: 13.5px; margin-bottom: 12px; }
  .fc-item svg { width: 15px; height: 15px; stroke: var(--blue-light); fill: none; stroke-width: 2; flex-shrink: 0; margin-top: 2px; }
  .footer-bottom {
    border-top: 1px solid rgba(255,255,255,.08); padding-top: 26px;
    display: flex; justify-content: space-between;
    font-size: 12px; color: rgba(255,255,255,.28);
  }

  /* ─ ANIMATIONS ─ */
  @keyframes fadeUp {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
  }
  @keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
  @keyframes bounce {
    0%, 100% { transform: rotate(45deg) translateY(0); }
    50%       { transform: rotate(45deg) translateY(5px); }
  }
  .reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s ease; }
  .reveal.visible { opacity: 1; transform: translateY(0); }

  /* ─ RESPONSIVE ─ */
  @media (max-width: 900px) {
    .profil-grid, .sejarah-layout, .wilayah-layout, .kep-layout, .footer-grid { grid-template-columns: 1fr; }
    .galeri-grid { grid-template-columns: 1fr 1fr; grid-template-rows: auto; }
    .gal-item.big { grid-row: auto; }
    .layanan-grid { grid-template-columns: 1fr 1fr; }
    .nav-links { display: none; }
    .hero-stats { flex-wrap: wrap; }
    .hero-stat { border-right: none; border-bottom: 1px solid rgba(255,255,255,.1); flex: 1 1 45%; }
  }
