/* ============================================================
   STYLE DESA GOWONG — Layanan Surat Digital
   Semua warna & jarak dikumpulkan di :root supaya gampang
   diubah tanpa perlu mengganti kode di banyak tempat.
   ============================================================ */

:root {
  /* --- Warna utama (ganti di sini untuk ubah tema semuanya) --- */
  --color-bg: #cee0f1;          /* warna kertas / latar halaman */
  --color-surface: #FFFFFF;     /* warna kartu / kotak */
  --color-ink: #0c1b6e;         /* warna teks utama */
  --color-ink-soft: #7288AE;    /* warna teks sekunder */
  --color-primary: #1a309e;     /* hijau sawah - warna identitas desa */
  --color-primary-dark: #1A2CA3;
  --color-accent: #F68048;      /* emas/ochre - aksen stempel resmi */
  --color-border: #E3F2FD;

  /* --- Tipografi --- */
  --font-display: 'Google Sans', system-ui, sans-serif;
  --font-body: 'Google Sans', system-ui, sans-serif;
  --font-mono: 'Google Sans', system-ui, sans-serif;


  /* --- Ukuran & jarak --- */
  --radius: 14px;
  --shadow: 0 8px 24px rgba(31,77,58,0.08);
  --max-width: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}
.wrap-narrow { max-width: 640px; }

h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--color-primary-dark);
  margin: 0 0 0.4em;
}

h2 {
  font-size: 2rem;
}

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

.hidden { display: none !important; }

/* ============ HEADER ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.60);
  backdrop-filter: blur(5px);
  border-bottom: 1px solid var(--color-border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-seal {
  width: 40px; height: 40px;
  border-radius: 50%;
  object-fit: cover;           /* gambar mengisi penuh lingkaran, tidak gepeng */
  border: 2px solid var(--color-accent);
  flex: none;
  background: var(--color-primary); /* tampak sesaat sebelum gambar termuat */
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-family: var(--font-display); font-size: 1.05rem; }
.brand-text small { color: var(--color-ink-soft); font-size: 0.75rem; }
.header-nav { display: flex; gap: 22px; }
.header-nav a { text-decoration: none; font-weight: 600; font-size: 0.92rem; color: var(--color-primary-dark); }
.header-nav a:hover { color: var(--color-accent); }

/* ============ HERO ============ */
.hero {
  position: relative;
  background: linear-gradient(180deg, #ffe5d3 0%, var(--color-bg) 100%);
  padding: 72px 0 96px;
  overflow: hidden;
}
.hero-inner { position: relative; z-index: 2; max-width: 720px; }
.eyebrow {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.85rem;
  color: var(--color-accent);
  font-weight: 600;
  margin-bottom: 14px;
}
.hero h1 {
  font-size: clamp(3.5rem, 4.5vw, 4rem);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.01em;
}
.hero-lede {
  font-size: 1.08rem;
  color: var(--color-ink-soft);
  max-width: 560px;
  margin: 18px 0 30px;
}
/* elemen "lipatan surat" dekoratif di sudut hero — jadi ciri khas halaman */
.hero-fold {
  position: absolute;
  right: -60px; top: -60px;
  width: 260px; height: 260px;
  background: var(--color-primary);
  opacity: 0.06;
  clip-path: polygon(100% 0, 0 0, 100% 100%);
}
/* ============ BUTTON ============ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  font-size: 1.2rem;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  font-family: var(--font-body)
}
.btn-primary {
  background: var(--color-primary);
  color: #fff;
  box-shadow: var(--shadow);
}
.btn-primary:hover { transform: translateY(-1px); background: var(--color-accent); }
.btn-wide { width: 100%; justify-content: center; padding: 15px; font-size: 1.2rem; }
.btn-link {
  background: none; border: none; cursor: pointer;
  color: var(--color-primary); font-weight: 600; font-family: var(--font-body);
  padding: 0; margin-bottom: 18px; font-size: 1.2rem;
}
.btn-link:hover {
  color: var(--color-accent);
}

/* ============ SECTION ============ */
.section { padding: 40px 0; }
.section.alt { background: var(--color-surface); border-top: 1px solid var(--color-border); border-bottom: 1px solid var(--color-border); }
.section-lede { color: var(--color-ink-soft); margin-bottom: 32px; max-width: 560px; }

/* ============ GRID SURAT ============ */
.letter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 18px;
}
.letter-card {
  position: relative;
  background: var(--color-surface);
  border: 0px solid var(--color-border);
  border-radius: var(--radius);
  padding: 22px 22px 20px;
  cursor: pointer;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  overflow: hidden;
}
.letter-card::before {
  /* lipatan pojok kartu, seperti amplop surat */
  content: "";
  position: absolute;
  top: 0; right: 0;
  border-width: 0 22px 22px 0;
  border-style: solid;
  border-color: transparent var(--color-bg) transparent transparent;
}
.letter-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(255, 134, 79, 0.2);
  border-color: var(--color-accent);
  border-width: 2px;
}
.letter-card:hover h3 {
  color: var(--color-accent);
}
.letter-card .code {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.letter-card h3 { font-size: 1.2rem; margin: 6px 0 8px; }
.letter-card p { font-family: var(--font-mono); margin: 0; font-size: 0.88rem; color: var(--color-ink-soft); }

/* ============ FORM ============ */
.letter-card-preview { position: relative; padding-top: 8px; margin-bottom: 26px; }
.perforation {
  display: block;
  height: 0;
  border-top: 2px dashed var(--color-border);
  margin-bottom: 20px;
}
.field-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-bottom: 18px;
}
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 600; font-size: 0.95rem; }
.field input, .field select, .field textarea {
  font-family: var(--font-body);
  padding: 11px 13px;
  border-radius: 10px;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  font-size: 0.95rem;
  color: var(--color-ink);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--color-accent);
  outline-offset: 1px;
}
.field small { color: var(--color-ink-soft); font-size: 0.78rem; }
.email-field { margin: 6px 0 18px; }
.checkbox-field {
  display: flex; gap: 10px; align-items: flex-start;
  font-size: 0.88rem; color: var(--color-ink-soft);
  margin-bottom: 22px; cursor: pointer;
}
.checkbox-field input { margin-top: 3px; }
.form-status { margin-top: 14px; font-size: 0.9rem; font-weight: 600; min-height: 1.2em; }
.form-status.ok { color: var(--color-primary); }
.form-status.err { color: #A6402A; }

.checklist-wrap { grid-column: 1 / -1; } /* supaya tabel selebar penuh, tidak sejajar field lain */
.checklist-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 8px;
  font-size: 0.85rem;
}
.checklist-table th, .checklist-table td {
  border: 1px solid var(--color-border);
  padding: 8px 10px;
  text-align: left;
}
.checklist-table th { background: var(--color-bg); }
.checklist-table td.center { text-align: center; }
.checklist-table input[type="text"] { width: 100%; padding: 6px 8px; }

/* ============ CARA KERJA ============ */
.steps {
  position: relative;
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

/* Garis horizontal */
.steps::before {
  content: "";
  position: absolute;
  top: 34px;
  left: 10%;
  right: 10%;
  height: 4px;
  background: var(--color-primary);
  z-index: 0;
}

/* Setiap langkah */
.steps li {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0 18px;
}

/* Lingkaran nomor */
.step-no {
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;

  background: var(--color-primary);
  color: white;

  border-radius: 50%;
  border: 3px solid white;

  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.25);

  font-family: var(--font-mono);
  font-size: 1.8rem;
  font-weight: 700;

  margin-bottom: 14px;
}

/* Judul langkah */
.steps strong {
  display: block;
  margin-bottom: 6px;
  font-size: 1.25rem;
  color: var(--color-primary-dark);
}

/* Deskripsi */
.steps p {
  margin: 0;
  color: var(--color-ink-soft);
  font-size: 0.92rem;
  line-height: 1.5;
}

/* ============ FOOTER ============ */
.site-footer { padding: 30px 0 50px; text-align: center; color: var(--color-ink-soft); font-size: 0.85rem; }

/* ============ RESPONSIVE ============ */
@media (max-width: 640px) {
  .header-nav {
    display: none;
  }

  .hero {
    padding: 48px 0 64px;
  }

  .steps {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .steps::before {
    display: none;
  }

  .steps li {
    padding: 0 10px;
  }
}