:root {
  --primary: #166534;
  --primary-2: #22c55e;
  --accent: #f59e0b;
  --bg: #f6f8f5;
  --panel: #ffffff;
  --text: #1f2937;
  --muted: #6b7280;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Inter, Arial,
    sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* Utilities */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}
.section {
  padding: 56px 0;
}
.section-title {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  margin: 0 0 18px;
  color: var(--primary);
}
.section-sub {
  text-align: center;
  color: var(--muted);
  margin-top: -4px;
}

/* Navbar */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: saturate(1.1) blur(8px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.nav-wrap {
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  font-weight: 800;
  text-decoration: none;
  color: var(--primary);
  letter-spacing: 0.3px;
}
.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  font-size: 1.6rem;
}
.nav-list {
  display: flex;
  gap: 18px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.nav-list a {
  color: var(--text);
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 10px;
}
.nav-list a:hover {
  background: #f1f5f9;
}
@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }
  .nav-list {
    position: absolute;
    top: 60px;
    right: 16px;
    flex-direction: column;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: var(--shadow);
    padding: 10px;
    border-radius: 12px;
    display: none;
  }
  .nav-list.open {
    display: flex;
  }
}

/* Hero */
.hero {
  min-height: 92vh;
  display: grid;
  place-items: center;
  text-align: center;
  color: #fff;
  background-image: radial-gradient(
      1200px 500px at 50% 30%,
      rgba(34, 197, 94, 0.25),
      transparent 60%
    ),
    linear-gradient(rgba(22, 101, 52, 0.65), rgba(22, 101, 52, 0.65)),
    image-set(
      url("assets/khitan-cover.webp") type("image/webp"),
      url("assets/khitan-cover.jpg") type("image/jpeg")
    );
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
}
.hero::after {
  /* subtle pattern */
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.16;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="160" height="160" viewBox="0 0 160 160"><path d="M80 0l80 80-80 80L0 80 80 0z" fill="none" stroke="%23ffffff" stroke-opacity=".25"/></svg>');
  background-size: 160px 160px;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at 50% 0%,
    rgba(255, 255, 255, 0.18),
    transparent 60%
  );
}
.bismillah {
  font-size: clamp(1.4rem, 5vw, 2.2rem);
  opacity: 0.95;
}
.display {
  font-size: clamp(2.2rem, 7vw, 3.8rem);
  margin: 0.2rem 0 0.6rem;
  text-shadow: 0 4px 32px rgba(0, 0, 0, 0.35);
  font-weight: 700;
}
.eyebrow {
  letter-spacing: 0.5px;
}
.date {
  display: inline-block;
  padding: 8px 14px;
  border: 2px solid rgba(255, 255, 255, 0.85);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(5px);
}
.divider {
  width: 86px;
  height: 3px;
  background: var(--accent);
  margin: 14px auto;
}

/* Countdown */
.countdown {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin: 18px 0 8px;
}
.countdown > div {
  min-width: 70px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(6px);
  padding: 10px;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}
.countdown span {
  font-size: 1.4rem;
  font-weight: 800;
  display: block;
}
.countdown small {
  font-size: 0.75rem;
}

/* Buttons */
.btn-primary {
  display: inline-block;
  background: linear-gradient(90deg, var(--primary), var(--primary-2));
  color: #fff;
  text-decoration: none;
  border: 0;
  padding: 12px 18px;
  border-radius: 999px;
  box-shadow: 0 8px 20px rgba(22, 101, 52, 0.35);
  cursor: pointer;
}
.btn-outline {
  display: inline-block;
  color: var(--primary);
  border: 1.6px solid var(--primary);
  text-decoration: none;
  padding: 10px 14px;
  border-radius: 10px;
}

/* Cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}
.card {
  background: var(--panel);
  border-radius: 14px;
  padding: 18px;
  text-align: center;
  box-shadow: var(--shadow);
  border: 1px solid rgba(0, 0, 0, 0.04);
}
.card-icon {
  font-size: 1.8rem;
}

/* Lokasi */
.location {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}
.loc-card,
.map-card {
  background: var(--panel);
  border-radius: 14px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(0, 0, 0, 0.04);
}
.loc-card {
  padding: 18px;
}
.map-card iframe {
  width: 100%;
  height: 260px;
  border: 0;
  border-radius: 14px;
}

/* Doa */
.doa-section .doa {
  background: var(--panel);
  border-left: 5px solid var(--primary);
  padding: 18px;
  border-radius: 10px;
  box-shadow: var(--shadow);
  color: #0f172a;
}
.doa footer {
  color: var(--muted);
  margin-top: 6px;
}

/* Galeri */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}
.gallery-item {
  display: block;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.gallery-item img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
  transition: transform 0.4s;
}
.gallery-item:hover img {
  transform: scale(1.04);
}

/* Amplop Digital */
.amplop .ewallets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin-top: 10px;
}
.ewallet-card {
  background: var(--panel);
  border-radius: 14px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(0, 0, 0, 0.04);
  padding: 16px;
  text-align: center;
}
.ewallet-qr {
  width: 140px;
  height: 140px;
  object-fit: contain;
  display: block;
  margin: 4px auto 10px;
}
.btn-copy {
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: 10px 14px;
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
}
.btn-copy:hover {
  background: #ecfdf5;
}

/* RSVP */
.rsvp-form {
  background: var(--panel);
  border-radius: 14px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(0, 0, 0, 0.04);
  padding: 18px;
  max-width: 820px;
  margin: 0 auto;
}
.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}
.form-group {
  display: grid;
  gap: 6px;
}
label {
  font-weight: 600;
}
.required::after {
  content: " *";
  color: #dc2626;
}
input,
select,
textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  font: inherit;
  background: #fff;
  transition: 0.2s;
}
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2);
}
.invalid {
  display: none;
  color: #dc2626;
  font-size: 0.85rem;
}
.choice {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-right: 10px;
}
.choice input {
  accent-color: var(--primary);
}

.form-note {
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 8px;
}

/* Footer */
.footer {
  background: #0b3b22;
  color: #ecfdf5;
  text-align: center;
  padding: 34px 0;
}
.signature {
  font-weight: 700;
}

/* Toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: 70px;
  transform: translateX(-50%) translateY(20px);
  background: #0b3b22;
  color: #ecfdf5;
  padding: 10px 14px;
  border-radius: 12px;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: 0.25s;
  z-index: 60;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Lightbox */
.lightbox {
  border: 0;
  padding: 0;
  width: min(96vw, 980px);
  background: #0000;
}
.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.7);
}
.lightbox img {
  max-width: 100%;
  max-height: 75vh;
  display: block;
  border-radius: 10px;
  margin: 0 auto;
}
.lightbox-close {
  position: absolute;
  top: 10px;
  right: 14px;
  background: #fff;
  border: 0;
  border-radius: 999px;
  width: 36px;
  height: 36px;
  cursor: pointer;
}
.lightbox-cap {
  text-align: center;
  color: #fff;
  margin-top: 8px;
}

/* Reveal animation */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s, transform 0.6s;
}
.reveal.in {
  opacity: 1;
  transform: none;
}

/* Mobile tweaks */
@media (max-width: 480px) {
  .countdown > div {
    min-width: 60px;
    padding: 8px;
  }
  .gallery-item img {
    height: 200px;
  }
}

/* === KHITAN THEME OVERRIDES (merged) === */
:root {
  --primary: #0b5d3b;
  --primary-2: #28a96b;
  --accent: #d4a017;
  --bg: #f5f7f4;
  --panel: #fcfdfb;
  --text: #142017;
  --muted: #6b7c6d;
}
.hero {
  background-image: radial-gradient(
      1000px 420px at 50% 18%,
      rgba(212, 160, 23, 0.18),
      transparent 60%
    ),
    linear-gradient(rgba(11, 93, 59, 0.72), rgba(11, 93, 59, 0.72)),
    url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="180" height="180" viewBox="0 0 180 180"><path d="M90 0l20 30-20 30-20-30L90 0zm0 60l20 30-20 30-20-30 20-30zm0 60l20 30-20 30-20-30 20-30zM30 30l20 30-20 30L10 60 30 30zm120 0l20 30-20 30-20-30 20-30z" fill="none" stroke="%23ffffff" stroke-opacity=".16"/></svg>'),
    image-set(
      url("assets/khitan-cover.webp") type("image/webp"),
      url("assets/khitan-cover.jpg") type("image/jpeg")
    );
  background-blend-mode: overlay, normal, normal, normal;
}
.display {
  letter-spacing: 0.5px;
  text-shadow: 0 6px 28px rgba(0, 0, 0, 0.35);
}
.date {
  border-color: rgba(255, 255, 255, 0.95);
}
.btn-primary {
  border-radius: 14px;
  box-shadow: 0 10px 26px rgba(11, 93, 59, 0.35);
  font-weight: 700;
}
.btn-outline {
  border-radius: 12px;
  font-weight: 600;
}
.hero-cta {
  margin-top: 16px;
}
.card,
.loc-card,
.map-card,
.ewallet-card,
.rsvp-form {
  border-radius: 12px;
  border: 1px solid rgba(11, 93, 59, 0.1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  position: relative;
}
.card::before,
.loc-card::before,
.map-card::before,
.ewallet-card::before,
.rsvp-form::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  background: linear-gradient(180deg, var(--accent), transparent 70%);
  border-top-left-radius: 12px;
  border-bottom-left-radius: 12px;
  opacity: 0.85;
}
.section-title {
  letter-spacing: 0.6px;
  position: relative;
  display: inline-block;
}
.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -10px;
  width: 92px;
  height: 3px;
  background: var(--accent);
  margin-inline: auto;
  border-radius: 2px;
}
.gallery-item {
  border-radius: 10px;
}
.gallery-item img {
  filter: grayscale(0.25) contrast(1.02);
}
.gallery-item:hover img {
  filter: none;
  transform: scale(1.035);
}
.amplop .ewallet-card {
  background-image: linear-gradient(
      0deg,
      rgba(11, 93, 59, 0.03) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, rgba(11, 93, 59, 0.03) 1px, transparent 1px);
  background-size: 16px 16px;
}
.choice {
  margin: 4px 8px 4px 0;
  border: 1.6px solid #e5efe9;
  padding: 6px 10px;
  border-radius: 999px;
  background: #fff;
}
.choice input {
  display: none;
}
.choice span {
  display: inline-block;
}
.choice input:checked + span {
  background: linear-gradient(90deg, var(--primary), var(--primary-2));
  color: #fff;
  padding: 6px 10px;
  border-radius: 999px;
  box-shadow: 0 6px 16px rgba(11, 93, 59, 0.25);
  border: none;
}
.footer {
  background: radial-gradient(
      700px 260px at 50% -10%,
      rgba(212, 160, 23, 0.14),
      transparent 60%
    ),
    #0a3e28;
}
@media (max-width: 480px) {
  .section {
    padding: 48px 0;
  }
  .cards {
    gap: 14px;
  }
  .gallery-item img {
    height: 180px;
  }
  .countdown > div {
    min-width: 58px;
    padding: 8px;
  }
  .btn-primary {
    padding: 10px 16px;
  }
}
.hero-content {
  position: relative;
}
.hero-content::before {
  content: "";
  position: absolute;
  inset: auto 12px 12px auto;
  width: 70px;
  height: 70px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-left: 0;
  border-top: 0;
  border-radius: 0 12px 0 0;
}
