/* SaungCoding.com */

:root {
  --ink: #112B1E;
  --forest: #1F4D34;
  --paddy: #6FA33A;
  --paddy-soft: #DDEBC6;
  --bamboo: #E2B93B;
  --bamboo-deep: #9A7415;
  --mist: #F3F6EC;
  --white: #FFFFFF;
  --muted: #4C6355;
  --line: #CBD8BE;

  --font-display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --font-body: "Plus Jakarta Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;

  --wrap: 1120px;
  color-scheme: light;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font: 400 1.0625rem/1.65 var(--font-body);
}

img, svg { max-width: 100%; }

h1, h2, h3 {
  font-family: var(--font-display);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0 0 1rem; }

a { color: inherit; }

.wrap {
  width: min(100% - 2.5rem, var(--wrap));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip {
  position: absolute;
  left: 1rem; top: -4rem;
  background: var(--ink);
  color: var(--mist);
  padding: .6rem 1rem;
  border-radius: 8px;
  z-index: 100;
}
.skip:focus { top: 1rem; }

:focus-visible {
  outline: 3px solid var(--forest);
  outline-offset: 3px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  background: var(--forest);
  color: var(--white);
  font: 600 1rem/1 var(--font-body);
  text-decoration: none;
  padding: 1rem 1.5rem;
  border: 2px solid var(--forest);
  border-radius: 10px;
  cursor: pointer;
  transition: background-color .15s, color .15s, border-color .15s;
}
.btn:hover { background: var(--ink); border-color: var(--ink); }

.btn-ghost {
  background: transparent;
  color: var(--forest);
}
.btn-ghost:hover { background: var(--forest); color: var(--white); border-color: var(--forest); }

.btn-small { padding: .65rem 1.1rem; font-size: .95rem; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(243, 246, 236, .94);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  font: 700 1.25rem/1 var(--font-display);
  letter-spacing: -0.02em;
  text-decoration: none;
}
.brand-tld { color: var(--muted); font-weight: 500; }

.menu {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  font-weight: 600;
  font-size: .95rem;
}
.menu a:not(.btn) { text-decoration: none; padding: .4rem 0; }
.menu a:not(.btn):hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; text-decoration-color: var(--paddy); }

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  color: var(--ink);
  padding: .5rem;
  border-radius: 8px;
  cursor: pointer;
}

/* ---------- Hero ---------- */

.hero { padding: clamp(2.5rem, 6vw, 5rem) 0 clamp(3rem, 6vw, 5.5rem); }

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.hero h1 {
  font-size: clamp(2.5rem, 5.4vw, 4.4rem);
  font-weight: 750;
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
}

.lead {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 34rem;
  margin-bottom: 2rem;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: .85rem; margin-bottom: 1.75rem; }

.hero-note { font-size: .95rem; color: var(--muted); margin: 0; }

/* Ilustrasi saung */

.scene {
  position: relative;
  margin: 0;
  width: 100%;
  max-width: 560px;
  justify-self: center;
  aspect-ratio: 520 / 440;
  container-type: inline-size;
}
.scene svg { position: absolute; inset: 0; width: 100%; height: 100%; }

.code-window {
  position: absolute;
  left: 23.85%;
  top: 40.9%;
  width: 50%;
  height: 24.1%;
  padding: 3cqw 3.4cqw;
  background: var(--ink);
  border-radius: 8px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06);
  overflow: hidden;
  color: var(--mist);
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 11px;
  font-size: max(9px, 2.5cqw);
  line-height: 1.5;
}
.code-window code { font: inherit; }
.ln { display: block; white-space: pre; min-height: 1.5em; }

.tk-c { color: #86A98F; }
.tk-v { color: #BFE08A; }
.tk-s { color: var(--bamboo); }
.tk-f { color: #8FD3C4; }
.tk-o { color: var(--bamboo); margin-top: .35em; }

.cursor {
  display: inline-block;
  width: .55em;
  height: 1.1em;
  background: var(--bamboo);
  vertical-align: -0.18em;
  margin-left: 1px;
  animation: blink 1s steps(2, start) infinite;
}
@keyframes blink { to { visibility: hidden; } }

/* ---------- Sections ---------- */

.section { padding: clamp(3.5rem, 7vw, 6rem) 0; }
.section-soft { background: var(--paddy-soft); }

.section-head { max-width: 40rem; margin-bottom: clamp(2rem, 4vw, 3rem); }
.section-head h2 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); font-weight: 700; margin-bottom: .9rem; }
.section-head p { color: var(--muted); margin: 0; }

.section-soft .section-head p,
.section-soft .muted { color: #3B5645; }

.muted { color: var(--muted); }

/* ---------- Program ---------- */

.program {
  display: grid;
  grid-template-columns: 104px 1fr;
  gap: 2rem;
  padding: 2.25rem 0;
  border-top: 1px solid var(--line);
}
.program:last-child { padding-bottom: 0; }

.glyph {
  width: 104px;
  height: 104px;
  display: grid;
  place-items: center;
  border-radius: 20px;
  font: 700 2rem/1 var(--font-display);
  letter-spacing: -0.02em;
}
.glyph-py  { background: var(--forest); color: var(--bamboo); }
.glyph-js  { background: var(--bamboo); color: var(--ink); }
.glyph-sql { background: var(--paddy);  color: var(--ink); }
.glyph-web { background: var(--ink);    color: #BFE08A; }

.program h3 { font-size: 1.7rem; font-weight: 700; margin-bottom: .6rem; }
.program-body > p { color: var(--muted); max-width: 40rem; }

.topics {
  list-style: none;
  padding: 0;
  margin: 1.25rem 0 1.25rem;
  columns: 2;
  column-gap: 2.5rem;
  max-width: 44rem;
}
.topics li {
  position: relative;
  padding-left: 1.25rem;
  margin-bottom: .45rem;
  break-inside: avoid;
}
.topics li::before {
  content: "";
  position: absolute;
  left: 0; top: .7em;
  width: .5rem; height: .5rem;
  background: var(--paddy);
  border-radius: 2px;
}

.final { margin: 0; color: var(--ink) !important; }

/* ---------- Langkah ---------- */

.steps {
  list-style: none;
  counter-reset: langkah;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}
.steps li { position: relative; counter-increment: langkah; }
.steps li::before {
  content: counter(langkah);
  display: grid;
  place-items: center;
  width: 46px; height: 46px;
  margin-bottom: 1.1rem;
  border-radius: 50%;
  background: var(--bamboo);
  color: var(--ink);
  font: 700 1.2rem/1 var(--font-display);
}
.steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 22px;
  left: 62px;
  right: 0;
  border-top: 2px dashed var(--paddy);
}
.steps h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: .45rem; }
.steps p { color: #3B5645; margin: 0; font-size: 1rem; }

/* ---------- Untuk siapa ---------- */

.audience { background: var(--ink); color: var(--mist); }
.audience .section-head h2 { color: var(--mist); }
.audience-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
}
.audience-grid > div { border-top: 3px solid var(--bamboo); padding-top: 1.5rem; }
.audience h3 { font-size: 1.7rem; font-weight: 700; margin-bottom: .75rem; }
.audience p { color: #CFE0CC; max-width: 30rem; margin: 0; }

/* ---------- Lokasi ---------- */

.location-grid {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.location-grid h2 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); font-weight: 700; margin-bottom: 1.25rem; }
address { font-style: normal; margin-bottom: 1.75rem; }

.map {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--paddy-soft);
  aspect-ratio: 4 / 3;
}
.map iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ---------- Daftar ---------- */

.signup-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
.signup-grid h2 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); font-weight: 700; margin-bottom: 1rem; }

.form {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: clamp(1.25rem, 3vw, 2rem);
}

.field { margin-bottom: 1.15rem; }
.field label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: .4rem; }

.field input,
.field select {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--white);
  padding: .8rem .9rem;
  border: 1.5px solid #8FA67E;
  border-radius: 10px;
}
.field input:focus,
.field select:focus {
  outline: 3px solid var(--forest);
  outline-offset: 1px;
  border-color: var(--forest);
}
.field .invalid { border-color: #B3261E; }

.form .btn { width: 100%; margin-top: .4rem; text-align: center; }

.form-status { margin: .9rem 0 0; min-height: 1.5em; font-size: .95rem; color: var(--muted); }
.form-status.error { color: #B3261E; font-weight: 600; }

/* ---------- Footer ---------- */

.site-footer { background: var(--ink); color: #CFE0CC; padding: 3rem 0; font-size: .95rem; }
.site-footer p { margin: 0 0 .35rem; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr auto;
  gap: 2rem;
  align-items: start;
}
.footer-brand { font: 700 1.25rem/1.2 var(--font-display); color: var(--mist); }
.site-footer address { margin: 0; }

/* ---------- Responsif ---------- */

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .scene { max-width: 460px; }
  .steps { grid-template-columns: 1fr 1fr; row-gap: 2.5rem; }
  .steps li:nth-child(2)::after { display: none; }
  .location-grid,
  .signup-grid,
  .audience-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.25rem; }
}

@media (max-width: 820px) {
  .nav-toggle { display: inline-flex; }
  .menu {
    display: none;
    position: absolute;
    left: 0; right: 0; top: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: .5rem 1.25rem 1.25rem;
    background: var(--mist);
    border-bottom: 1px solid var(--line);
  }
  .menu.open { display: flex; }
  .menu a:not(.btn) { padding: .9rem 0; border-bottom: 1px solid var(--line); }
  .menu .btn { margin-top: 1rem; text-align: center; }
}

@media (max-width: 600px) {
  .program { grid-template-columns: 1fr; gap: 1.1rem; }
  .glyph { width: 72px; height: 72px; border-radius: 16px; font-size: 1.4rem; }
  .topics { columns: 1; }
  .steps { grid-template-columns: 1fr; }
  .steps li::after { display: none; }
  .hero-actions .btn { flex: 1 1 100%; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .cursor { animation: none; }
  .btn { transition: none; }
}
