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

:root {
  --bg: #FFFBF5;
  --surface: #FFFFFF;
  --surface-alt: #F6EFE5;
  --ink: #1F1B17;
  --muted: #5F574E;
  --line: #EAE0D2;
  --accent: #D9432F;
  --accent-ink: #FFFFFF;
  --accent-soft: #FFF0ED;
  --teal: #17776B;
  --teal-soft: #EBF8F6;
  --green: #1B7A3E;
  --green-soft: #ECF9F0;
  --sky: #1A66B3;
  --sky-soft: #EDF5FE;
  --band: #231E19;
  --band-ink: #FAF5EE;
  --band-muted: #C2B8AB;
  --display: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, monospace;
  --radius: 18px;
  --radius-sm: 12px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #161412; --surface: #201D1A; --surface-alt: #292520; --ink: #FAF6F0;
    --muted: #B2A89C; --line: #332E28; --accent: #FF7866; --accent-ink: #1F1B17;
    --accent-soft: #31211E; --teal: #6DD3C6; --teal-soft: #1B2C2A; --green: #58D67D;
    --green-soft: #1A2B20; --sky: #6BB4FF; --sky-soft: #1A2635; --band: #0F0D0C;
    --band-ink: #FAF6F0; --band-muted: #A99F92; color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #161412; --surface: #201D1A; --surface-alt: #292520; --ink: #FAF6F0;
  --muted: #B2A89C; --line: #332E28; --accent: #FF7866; --accent-ink: #1F1B17;
  --accent-soft: #31211E; --teal: #6DD3C6; --teal-soft: #1B2C2A; --green: #58D67D;
  --green-soft: #1A2B20; --sky: #6BB4FF; --sky-soft: #1A2635; --band: #0F0D0C;
  --band-ink: #FAF6F0; --band-muted: #A99F92; color-scheme: dark;
}

html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--body); line-height: 1.55; -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
.wrap { width: 100%; max-width: 1040px; margin: 0 auto; padding: 0 24px; }

a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* Nav */
.nav { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.nav-in { display: flex; align-items: center; gap: 20px; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--display); font-weight: 800; font-size: 17px; letter-spacing: -0.02em; }
.brand img { border-radius: 9px; }
.nav-links { display: flex; gap: 22px; margin-left: auto; }
.nav-links a { text-decoration: none; color: var(--muted); font-size: 14px; font-weight: 500; transition: color .14s; }
.nav-links a:hover { color: var(--ink); }
.controls { display: flex; align-items: center; gap: 8px; }
.seg { display: inline-flex; padding: 3px; gap: 2px; border-radius: 999px; background: var(--surface-alt); border: 1px solid var(--line); }
.seg button { appearance: none; border: 0; background: transparent; color: var(--muted); font: 600 12px/1 var(--body); padding: 7px 11px; border-radius: 999px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.theme-btn { appearance: none; width: 34px; height: 34px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface-alt); color: var(--ink); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.i-moon { display: none; }
:root[data-theme="dark"] .i-sun { display: none; }
:root[data-theme="dark"] .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .i-sun { display: none; }
  :root:not([data-theme="light"]) .i-moon { display: block; }
}

/* Hero */
.hero { padding: 72px 0 64px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 48px; align-items: center; }
.hero h1 { margin: 0 0 18px; font-family: var(--display); font-size: clamp(34px, 5vw, 52px); font-weight: 800; line-height: 1.06; letter-spacing: -0.035em; text-wrap: balance; }
.hero-sub { margin: 0 0 28px; font-size: 17px; color: var(--muted); max-width: 46ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn { display: inline-flex; align-items: center; justify-content: center; padding: 12px 20px; border-radius: 999px; font-size: 15px; font-weight: 600; text-decoration: none; border: 1px solid transparent; transition: transform .14s, border-color .14s; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-ghost { background: var(--surface); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink); }

.directory { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; display: flex; flex-direction: column; gap: 4px; }
.dir-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--radius-sm); border: 1px solid transparent; text-decoration: none; transition: background-color .14s; }
a.dir-row:hover { background: var(--surface-alt); }
.dir-icon { width: 34px; height: 34px; border-radius: 9px; overflow: hidden; flex-shrink: 0; object-fit: cover; }
.dir-icon svg { width: 100%; height: 100%; }
.plumb-icon { background: #0C0C0D; transform: none; }
.dir-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.who { font-size: 11.5px; font-weight: 600; line-height: 1.3; }
.who-sinau { color: var(--accent); } .who-aura { color: var(--teal); } .who-plumb { color: var(--green); } .who-tidy { color: var(--sky); } .who-next { color: var(--muted); }
.dir-name { font-family: var(--display); font-weight: 700; font-size: 15px; line-height: 1.25; }
.dir-domain { font-family: var(--mono); font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.dir-next { border: 1px dashed var(--line); margin-top: 2px; }
.dir-plus { display: flex; align-items: center; justify-content: center; background: var(--surface-alt); color: var(--muted); font-family: var(--display); font-weight: 700; font-size: 18px; }

/* Apps */
.section { padding: 56px 0 64px; border-top: 1px solid var(--line); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 8px 20px; margin-bottom: 28px; }
.section-head h2 { margin: 0; font-family: var(--display); font-size: clamp(24px, 3vw, 30px); font-weight: 800; letter-spacing: -0.03em; }
.section-head p { margin: 0; color: var(--muted); font-size: 15px; }
.apps-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.card { display: flex; flex-direction: column; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; transition: transform .16s, border-color .16s; }
.card:hover { transform: translateY(-2px); }
.card-sinau:hover { border-color: var(--accent); } .card-aura:hover { border-color: var(--teal); } .card-plumb:hover { border-color: var(--green); } .card-tidy:hover { border-color: var(--sky); }
.card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.app-icon { width: 48px; height: 48px; border-radius: 13px; overflow: hidden; object-fit: cover; }
.app-icon svg { width: 100%; height: 100%; }
.pill { font-size: 12px; font-weight: 600; padding: 4px 11px; border-radius: 999px; white-space: nowrap; }
.pill-sinau { background: var(--accent-soft); color: var(--accent); } .pill-aura { background: var(--teal-soft); color: var(--teal); } .pill-plumb { background: var(--green-soft); color: var(--green); } .pill-tidy { background: var(--sky-soft); color: var(--sky); }
.card-body { flex: 1; }
.card-title-row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.card h3 { margin: 0; font-family: var(--display); font-size: 19px; font-weight: 700; letter-spacing: -0.02em; }
.platform { font-size: 12px; color: var(--muted); white-space: nowrap; }
.card p { margin: 0; font-size: 14.5px; color: var(--muted); }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
.domain { font-family: var(--mono); font-size: 12.5px; font-weight: 500; }
.card-link { font-size: 13.5px; font-weight: 600; text-decoration: none; }
.card-sinau .card-link { color: var(--accent); } .card-aura .card-link { color: var(--teal); } .card-plumb .card-link { color: var(--green); } .card-tidy .card-link { color: var(--sky); }
.card-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.card-link::after { content: " \2192"; }

.strip { margin-top: 16px; padding: 16px 20px; border-radius: var(--radius-sm); background: var(--surface-alt); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.strip-copy { font-size: 14px; color: var(--muted); }
.strip-copy strong { color: var(--ink); font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips a { font-family: var(--mono); font-size: 12px; text-decoration: none; background: var(--surface); border: 1px solid var(--line); padding: 5px 11px; border-radius: 999px; transition: border-color .14s; }
.chips a:hover { border-color: var(--ink); }

/* Spirit */
.spirit { background: var(--band); color: var(--band-ink); padding: 64px 0; }
.spirit-lead { margin-bottom: 32px; }
.spirit h2 { margin: 0 0 10px; font-family: var(--display); font-size: clamp(24px, 3vw, 30px); font-weight: 800; letter-spacing: -0.03em; }
.spirit-lead p { margin: 0; max-width: 60ch; color: var(--band-muted); font-size: 16px; }
.principles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.principles h3 { margin: 0 0 8px; font-family: var(--display); font-size: 16.5px; font-weight: 700; }
.principles p { margin: 0; font-size: 14.5px; color: var(--band-muted); }

/* Footer */
.footer { padding: 26px 0; border-top: 1px solid var(--line); }
.footer-in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; font-size: 13px; color: var(--muted); }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.footer-links a { font-family: var(--mono); font-size: 12px; }

@media (max-width: 760px) {
  .nav-links { display: none; }
  .controls { margin-left: auto; }
  .hero { padding: 40px 0 44px; }
  .hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .apps-grid, .principles { grid-template-columns: 1fr; }
  .principles { gap: 22px; }
}
@media (max-width: 420px) { .wrap { padding: 0 16px; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .card, .dir-row { transition: none; }
  .btn:hover, .card:hover { transform: none; }
}
