/* Ngaio Apps — shared site styles */

/* Self-hosted fonts (variable weight, latin subset) — no third-party requests */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/assets/fonts/inter.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter Tight';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/assets/fonts/inter-tight.woff2') format('woff2');
}

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

:root {
  --bg:      #fbfbfa;
  --panel:   #ffffff;
  --text:    #16171a;
  --muted:   #6b6f76;
  --faint:   #9a9ea4;
  --border:  #e9e8e4;
  --hair:    #efeeea;
  --blue:    #2f6df0;
  --ink:     #1a1a1a;
  --max:     720px;
  --ease:    cubic-bezier(0.22, 1, 0.36, 1);
}

html { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.005em;
  min-height: 100vh;
  display: flex; flex-direction: column;
}
a { color: inherit; }

/* ── nav ───────────────────────────────────────── */
nav {
  position: sticky; top: 0; z-index: 20;
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--hair);
}
nav .inner {
  max-width: var(--max); margin: 0 auto; padding: 0 28px;
  height: 62px; display: flex; align-items: center; justify-content: space-between;
}
.brand {
  display: inline-flex; align-items: center; gap: 11px;
  text-decoration: none; color: var(--text);
}
.brand svg { display: block; }
.brand .name {
  font-family: 'Inter Tight', sans-serif;
  font-weight: 600; font-size: 16px; letter-spacing: -0.02em;
}
.brand .name .dot { color: var(--blue); }
nav ul { list-style: none; display: flex; align-items: center; gap: 26px; }
nav ul a {
  font-size: 14px; color: var(--muted); text-decoration: none;
  transition: color 0.18s var(--ease);
}
nav ul a:hover { color: var(--text); }
nav ul a[aria-current="page"] { color: var(--text); }

/* ── layout ────────────────────────────────────── */
main { max-width: var(--max); margin: 0 auto; padding: 0 28px; width: 100%; flex: 1; }

/* ── hero ──────────────────────────────────────── */
.hero { position: relative; padding: 104px 0 88px; }
.hero .eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12.5px; font-weight: 500; color: var(--muted);
  letter-spacing: 0.02em; margin-bottom: 26px;
  padding: 5px 12px 5px 10px; border: 1px solid var(--border);
  border-radius: 999px; background: var(--panel);
}
.hero .eyebrow .pulse {
  width: 7px; height: 7px; border-radius: 50%; background: var(--blue);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--blue) 60%, transparent);
  animation: pulse 2.6s var(--ease) infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 color-mix(in srgb, var(--blue) 55%, transparent); }
  70%  { box-shadow: 0 0 0 7px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.hero h1 {
  font-family: 'Inter Tight', sans-serif;
  font-size: clamp(34px, 6.2vw, 54px);
  font-weight: 600; letter-spacing: -0.035em; line-height: 1.05;
  margin-bottom: 22px; text-wrap: balance;
}
.hero h1 em { font-style: normal; color: var(--blue); }
.hero .lede {
  font-size: clamp(17px, 2.4vw, 19px); color: var(--muted);
  max-width: 480px; line-height: 1.55;
}
.hero .cta-row { margin-top: 36px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }

.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14.5px; font-weight: 500; text-decoration: none;
  padding: 11px 18px; border-radius: 10px;
  transition: transform 0.18s var(--ease), background 0.18s var(--ease), border-color 0.18s var(--ease);
}
.btn-primary { background: var(--ink); color: #fff; }
.btn-primary:hover { transform: translateY(-1px); background: #000; }
.btn-ghost { color: var(--text); border: 1px solid var(--border); background: var(--panel); }
.btn-ghost:hover { border-color: #d7d5cf; transform: translateY(-1px); }
.btn svg { transition: transform 0.18s var(--ease); }
.btn-ghost:hover svg { transform: translateX(2px); }

.hero-motif {
  position: absolute; top: 40px; right: -36px; width: 260px; height: 260px;
  pointer-events: none; opacity: 0.5;
  -webkit-mask-image: radial-gradient(circle at 70% 30%, #000 0%, transparent 70%);
          mask-image: radial-gradient(circle at 70% 30%, #000 0%, transparent 70%);
}
@media (max-width: 640px) { .hero-motif { display: none; } }

/* ── divider ───────────────────────────────────── */
.rule { height: 1px; background: var(--hair); border: 0; }

/* ── sections ──────────────────────────────────── */
.section { padding: 64px 0; }
.section-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 28px; }
.section-label {
  font-size: 12px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--faint);
  font-family: 'Inter Tight', sans-serif; white-space: nowrap;
}
.section-head .line { flex: 1; height: 1px; background: var(--hair); }
.section .body { font-size: 17px; color: var(--muted); max-width: 540px; line-height: 1.6; }
.section .body strong { color: var(--text); font-weight: 550; }

.values { margin-top: 36px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
@media (max-width: 640px) { .values { grid-template-columns: 1fr; gap: 22px; } }
.value h4 {
  font-family: 'Inter Tight', sans-serif; font-size: 15px; font-weight: 600;
  letter-spacing: -0.01em; margin-bottom: 6px; display: flex; align-items: center; gap: 8px;
}
.value .tick { width: 6px; height: 6px; border-radius: 50%; background: var(--blue); }
.value p { font-size: 14px; color: var(--muted); line-height: 1.55; }

.apps-grid { display: grid; gap: 12px; }
.app-card {
  background: var(--panel); border: 1px solid var(--border); border-radius: 14px;
  padding: 20px 22px; display: flex; align-items: center; gap: 16px; text-decoration: none; color: inherit;
  transition: border-color 0.18s var(--ease), transform 0.18s var(--ease);
}
.app-card:hover { border-color: #dcdad4; transform: translateY(-1px); }
.app-card .icon {
  width: 44px; height: 44px; border-radius: 11px; flex: none;
  background: #f3f2ee; display: grid; place-items: center; color: var(--ink);
}
.app-card h3 { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; margin-bottom: 2px; }
.app-card p { font-size: 13.5px; color: var(--muted); }
.app-meta {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--blue);
  margin-bottom: 2px;
}

.empty {
  border: 1px dashed var(--border); border-radius: 14px; background: transparent;
  padding: 34px 24px; text-align: center;
}
.empty .ico { display: inline-flex; margin-bottom: 12px; opacity: 0.7; }
.empty p { font-size: 14.5px; color: var(--muted); }
.empty .small { font-size: 13px; color: var(--faint); margin-top: 4px; }

/* ── content pages (support / privacy) ─────────── */
.page-head { padding: 84px 0 8px; }
.page-head .kicker {
  font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--blue); font-family: 'Inter Tight', sans-serif; margin-bottom: 14px;
}
.page-head h1 {
  font-family: 'Inter Tight', sans-serif; font-size: clamp(30px, 5vw, 42px);
  font-weight: 600; letter-spacing: -0.03em; line-height: 1.08;
}
.page-head .updated { margin-top: 14px; font-size: 13.5px; color: var(--faint); }

.prose { padding: 40px 0 72px; max-width: 620px; }
.prose h2 {
  font-family: 'Inter Tight', sans-serif; font-size: 19px; font-weight: 600;
  letter-spacing: -0.02em; margin: 40px 0 12px; color: var(--text);
}
.prose h2:first-child { margin-top: 0; }
.prose p { font-size: 16px; color: var(--muted); line-height: 1.65; margin-bottom: 14px; }
.prose p strong { color: var(--text); font-weight: 550; }
.prose a { color: var(--blue); text-decoration: none; }
.prose a:hover { text-decoration: underline; }
.prose ul { list-style: none; margin: 4px 0 18px; }
.prose ul li {
  position: relative; padding-left: 22px; font-size: 16px; color: var(--muted);
  line-height: 1.6; margin-bottom: 9px;
}
.prose ul li::before {
  content: ""; position: absolute; left: 4px; top: 10px;
  width: 6px; height: 6px; border-radius: 50%; background: var(--blue);
}

.contact-card {
  margin-top: 14px; border: 1px solid var(--border); background: var(--panel);
  border-radius: 14px; padding: 22px 24px; display: flex; align-items: center;
  justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.contact-card .q { font-family: 'Inter Tight', sans-serif; font-weight: 600; font-size: 15.5px; letter-spacing: -0.01em; }
.contact-card .s { font-size: 13.5px; color: var(--muted); margin-top: 2px; }

/* ── footer ────────────────────────────────────── */
footer { border-top: 1px solid var(--hair); margin-top: 24px; }
footer .inner {
  max-width: var(--max); margin: 0 auto; padding: 30px 28px;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 14px;
}
footer .left { display: flex; align-items: center; gap: 10px; }
footer .copy { font-size: 13px; color: var(--faint); }
footer .links { display: flex; gap: 22px; }
footer .links a { font-size: 13px; color: var(--muted); text-decoration: none; transition: color 0.18s var(--ease); }
footer .links a:hover { color: var(--text); }

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1012; --panel: #16181c; --text: #ecebe7; --muted: #9da2a9;
    --faint: #6b7077; --border: #24262b; --hair: #1d1f23; --ink: #ecebe7; --blue: #5b8def;
  }
  .btn-primary { background: #2f6df0; color: #fff; }
  .btn-primary:hover { background: #3f7bf7; }
  .app-card .icon { background: #1d1f24; color: #ecebe7; }
  .value .tick, .hero .eyebrow .pulse { background: #5b8def; }
}
