/* FluzLink landing — token diselaraskan dengan design system NMS
   (frontend/src/style.css). Mendukung tema terang & gelap; default GELAP,
   sama seperti konsol NMS. Toggle disimpan di localStorage 'fluzlink-theme'. */
:root {
  color-scheme: light;

  /* surface — NMS light */
  --bg: #f4f7f7;        /* surface   */
  --bg-2: #ffffff;      /* surface-2 */
  --bg-3: #e9eff0;      /* surface-3 */
  --line: #d8e1e3;      /* line      */
  --ink: #14262b;       /* ink       */
  --ink-dim: #5a6f74;   /* ink-dim   */

  /* brand teal (sama di kedua mode) */
  --brand: #1f6c67;       /* fluz-600 — tombol primer (teks putih) */
  --brand-hover: #2b877f; /* fluz-500 */
  --brand-2: #1f6c67;     /* aksen teks/tautan (light = fluz-600) */

  --ico-bg: rgba(31, 108, 103, 0.12);
  --glow: rgba(31, 108, 103, 0.16);
  --grad-a: #1f6c67;
  --grad-b: #155e5a;
  --btn-shadow: rgba(15, 43, 42, 0.18);
  --card-shadow: rgba(20, 38, 43, 0.06);

  /* radius pipih (NMS: xl/2xl ~ 4–6px; tombol rounded-lg 4px) */
  --radius: 6px;
  --radius-sm: 4px;
  --maxw: 1120px;
}

:root.dark {
  color-scheme: dark;

  /* surface — NMS .dark */
  --bg: #0d1517;
  --bg-2: #121c1f;
  --bg-3: #1a262a;
  --line: #233236;
  --ink: #d8e4e6;
  --ink-dim: #8fa6ab;

  --brand: #1f6c67;
  --brand-hover: #2b877f;
  --brand-2: #45a39c;     /* aksen teks/tautan (dark = fluz-400) */

  --ico-bg: rgba(116, 192, 185, 0.16);
  --glow: rgba(116, 192, 185, 0.16);
  --grad-a: #74c0b9;
  --grad-b: #2b877f;
  --btn-shadow: rgba(31, 108, 103, 0.9);
  --card-shadow: rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }

/* Atribut hidden WAJIB menang atas aturan display milik kelas (mis.
   `.brand .mark { display: inline-flex }`), kalau tidak mark fallback tetap
   tampil berdampingan dengan logo dinamis. */
[hidden] { display: none !important; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.2s ease, color 0.2s ease;
}

a { color: inherit; text-decoration: none; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 56px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 15px; letter-spacing: -0.01em; }
.brand img { height: 32px; width: auto; max-width: 180px; object-fit: contain; border-radius: var(--radius); }
.brand .mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: var(--radius); font-weight: 800;
  background: var(--brand); color: #fff;
}
.nav { display: flex; align-items: center; gap: 6px; }
.nav a { padding: 6px 12px; border-radius: var(--radius-sm); font-size: 13px; font-weight: 600; color: var(--ink-dim); }
.nav a:hover { color: var(--ink); background: var(--bg-2); }
.nav a.primary {
  color: #fff; background: var(--brand);
  box-shadow: 0 6px 16px -10px var(--btn-shadow);
}
.nav a.primary:hover { background: var(--brand-hover); }

/* Tombol ganti tema (terang/gelap) — ikon polos tanpa background/border */
.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; padding: 0; border: 0; background: transparent;
  color: var(--ink-dim); cursor: pointer; transition: color .15s ease;
}
.theme-toggle:hover { color: var(--ink); }
.theme-toggle:focus-visible { outline: 2px solid var(--brand-2); outline-offset: 2px; border-radius: var(--radius-sm); }
.theme-toggle svg { width: 18px; height: 18px; }
/* Hanya SATU ikon tampil: terang -> bulan (menuju gelap), gelap -> matahari. */
.theme-toggle .ico-sun { display: none; }
.theme-toggle .ico-moon { display: block; }
:root.dark .theme-toggle .ico-sun { display: block; }
:root.dark .theme-toggle .ico-moon { display: none; }

/* Hero */
.hero { position: relative; overflow: hidden; text-align: center; padding: 56px 0 44px; }
.hero::before {
  content: ""; position: absolute; left: 50%; top: -120px; transform: translateX(-50%);
  width: 720px; height: 400px; background: radial-gradient(closest-side, var(--glow), transparent);
  filter: blur(10px); pointer-events: none;
}
.pill {
  display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--bg-2);
  font-size: 10px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--brand-2);
}
.hero h1 { margin: 16px auto 0; max-width: 720px; font-size: clamp(23px, 4.4vw, 46px); line-height: 1.12; letter-spacing: -0.02em; }
.hero h1 .grad { background: linear-gradient(90deg, var(--grad-a), var(--grad-b)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { margin: 14px auto 0; max-width: 620px; color: var(--ink-dim); font-size: clamp(13px, 1.9vw, 16.5px); }
.cta-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
  max-width: 440px; margin: 24px auto 0;
}
@media (min-width: 560px) {
  .cta-row { display: flex; flex-wrap: wrap; justify-content: center; max-width: none; }
}
.btn {
  display: inline-block; padding: 10px 20px; border-radius: var(--radius-sm); font-weight: 700; font-size: 14px;
  border: 1px solid transparent; text-align: center; white-space: nowrap; transition: transform .12s ease, background .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 10px 22px -14px var(--btn-shadow); }
.btn-primary:hover { background: var(--brand-hover); }
.btn-ghost { background: var(--bg-2); border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { background: var(--bg-3); }

.stats { display: flex; flex-wrap: wrap; gap: 22px; justify-content: center; margin-top: 32px; }
.stats .stat { text-align: center; }
.stats .stat b { display: block; font-size: 14px; }
.stats .stat span { font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-dim); }

/* Sections */
section.block { padding: 44px 0; }
.grid { display: grid; gap: 14px; }
@media (min-width: 720px) { .grid.cols-2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .grid.cols-3 { grid-template-columns: repeat(3, 1fr); } }
.card {
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; box-shadow: 0 1px 2px var(--card-shadow); transition: border-color .15s ease;
}
.card:hover { border-color: color-mix(in srgb, var(--brand-2) 55%, var(--line)); }
.card h3 { margin: 12px 0 5px; font-size: 15px; }
.card p { margin: 0; color: var(--ink-dim); font-size: 13.5px; }
.card .ico {
  display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px;
  border-radius: var(--radius-sm); background: var(--ico-bg); color: var(--brand-2);
}
.card .ico svg { width: 18px; height: 18px; }

.steps { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.steps h2 { text-align: center; margin: 0 0 22px; font-size: 18px; }
.steps .row { display: grid; gap: 20px; }
@media (min-width: 720px) { .steps .row { grid-template-columns: repeat(3, 1fr); } }
.steps .num {
  display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; margin: 0 auto;
  border-radius: 999px; background: var(--brand); color: #fff; font-weight: 800; font-size: 14px;
}
.steps .step { text-align: center; }
.steps .step h3 { margin: 10px 0 4px; font-size: 14px; }
.steps .step p { margin: 0; color: var(--ink-dim); font-size: 12.5px; }
.steps .foot { text-align: center; margin-top: 24px; }

/* Document pages (about/privacy) */
.doc { padding: 40px 0 56px; }
.doc h1 { font-size: clamp(22px, 3.4vw, 30px); letter-spacing: -0.02em; }
.doc h2 { margin-top: 28px; font-size: 17px; }
.doc p, .doc li { color: var(--ink-dim); font-size: 14px; }
.doc .muted { color: var(--ink-dim); font-size: 12.5px; }
.doc a { color: var(--brand-2); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); margin-top: 20px; }
.footer-inner {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between;
  padding: 18px 0; font-size: 12px; color: var(--ink-dim);
}
.footer-links { display: flex; gap: 16px; }
.footer-links a:hover { color: var(--ink); }

/* Desktop: tipografi sedikit lebih besar (ukuran mobile sudah pas) */
@media (min-width: 980px) {
  .hero h1 { font-size: clamp(32px, 3.6vw, 46px); }
  .hero p.lead { font-size: 16.5px; }
  .card h3 { font-size: 15.5px; }
  .card p { font-size: 14px; }
  .steps h2 { font-size: 18.5px; }
  .steps .step h3 { font-size: 14.5px; }
  .steps .step p { font-size: 13px; }
  .stats .stat b { font-size: 15px; }
  .stats .stat span { font-size: 10.5px; }
  .doc h1 { font-size: clamp(26px, 3vw, 34px); }
  .doc h2 { font-size: 17.5px; }
  .doc p, .doc li { font-size: 14.5px; }
  .btn { font-size: 14.5px; }
}
