:root {
  --bg: #f4f7f6;
  --surface: #ffffff;
  --text: #13201e;
  --muted: #5b6b68;
  --line: #d9e2e0;
  --brand: #0f766e;
  --brand-strong: #0b5e57;
  --brand-soft: #e3f3f1;
  --radius: 14px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1615;
    --surface: #17211f;
    --text: #e6eeec;
    --muted: #9aaba7;
    --line: #2a3734;
    --brand: #2dd4bf;
    --brand-strong: #5eead4;
    --brand-soft: #123532;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  padding: env(safe-area-inset-top) 16px env(safe-area-inset-bottom);
}

body > * { max-width: 760px; margin-inline: auto; }

a { color: var(--brand-strong); }

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

/* ---------- Header ---------- */
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 0; }
.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; }
.brand-name { font-size: 1.375rem; font-weight: 700; letter-spacing: -0.01em; }

.lang { display: flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.lang button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 6px 12px;
  cursor: pointer;
}
.lang button[aria-pressed="true"] { background: var(--brand); color: var(--surface); }

/* ---------- Hero ---------- */
.hero { padding: 28px 0 24px; }
.hero h1 { margin: 0 0 12px; font-size: clamp(1.875rem, 7vw, 2.75rem); line-height: 1.15; letter-spacing: -0.02em; text-wrap: balance; }
.lead { margin: 0; font-size: 1.0625rem; color: var(--muted); max-width: 58ch; text-wrap: pretty; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.primary, .ghost {
  display: inline-block;
  font-weight: 600;
  padding: 12px 20px;
  border-radius: 10px;
  text-decoration: none;
  text-align: center;
}
.primary { background: var(--brand); color: var(--surface); border: 1px solid var(--brand); }
.primary:hover { background: var(--brand-strong); }
.ghost { color: var(--text); border: 1px solid var(--line); background: var(--surface); }

/* ---------- Prinsip ---------- */
.values ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}
.values li {
  display: grid;
  gap: 2px;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.value-icon { font-size: 1.25rem; }
.values li span:last-child { color: var(--muted); font-size: 0.875rem; }

/* ---------- Aplikasi ---------- */
.apps, .about { padding-top: 32px; }
h2 { font-size: 1.25rem; margin: 0 0 12px; }
.app-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.app {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.app img, .app-placeholder {
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  border-radius: 14px;
}
.app-placeholder {
  display: grid;
  place-items: center;
  font-size: 1.625rem;
  background: var(--bg);
  border: 1px dashed var(--line);
}
.app-info { min-width: 0; }
.app h3 { margin: 0; font-size: 1.0625rem; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.app p { margin: 4px 0 0; color: var(--muted); font-size: 0.9375rem; }
.app-link { display: inline-block; margin-top: 8px; font-weight: 600; text-decoration: none; }
.app.soon h3 { color: var(--muted); }
.badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--bg);
  color: var(--muted);
  border: 1px solid var(--line);
}
.badge.ready { background: var(--brand-soft); color: var(--brand-strong); border-color: transparent; }

/* ---------- Tentang & footer ---------- */
.about p { margin: 0 0 8px; color: var(--muted); max-width: 62ch; }
footer { padding: 32px 0; color: var(--muted); font-size: 0.875rem; text-align: center; }
footer a { color: inherit; }

/* ---------- Halaman dokumen (privasi) ---------- */
.doc {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 4px 20px 20px;
}
.doc h1 { font-size: 1.375rem; margin: 20px 0 4px; }
.doc h2 { font-size: 1.0625rem; margin: 22px 0 6px; }
.doc p, .doc li { overflow-wrap: anywhere; }
.doc ul { padding-left: 20px; }
.doc article + article { border-top: 1px solid var(--line); margin-top: 28px; }
.muted { color: var(--muted); margin-top: 0; font-size: 0.875rem; }
.doc-lang { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 0 0; }
.doc-lang a { font-size: 0.875rem; padding: 4px 12px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; }

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