/* ============================================================
   Naholosoft — design tokens
   Minimal, focused. Indigo accent (#6366F1) shared with BizCard.
============================================================ */

:root {
  /* Surface */
  --bg: #ffffff;
  --bg-muted: #fafbfc;
  --surface: #ffffff;
  --surface-raised: #ffffff;

  /* Text */
  --text: #0f172a;
  --text-soft: #475569;
  --text-muted: #64748b;
  --text-faint: #94a3b8;

  /* Borders & dividers */
  --border: #e5e7eb;
  --border-soft: #eef0f3;

  /* Brand */
  --accent: #6366f1;
  --accent-strong: #4f46e5;
  --accent-soft: #eef2ff;
  --accent-glow: rgba(99, 102, 241, 0.18);

  /* Code & numbers */
  --code-bg: #f3f4f6;
  --code-text: #4338ca;

  /* Layout */
  --max-width: 760px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;

  /* Shadow */
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04), 0 1px 1px rgba(15, 23, 42, 0.03);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.06), 0 2px 4px rgba(15, 23, 42, 0.04);
  --shadow-glow: 0 0 0 4px var(--accent-glow);

  /* Motion */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --t-fast: 0.12s;
  --t-mid: 0.22s;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #07080b;
    --bg-muted: #0c0e13;
    --surface: #0e1117;
    --surface-raised: #131720;

    --text: #e8eaf0;
    --text-soft: #b0b6c2;
    --text-muted: #8b92a1;
    --text-faint: #5e6573;

    --border: #1d2230;
    --border-soft: #161a24;

    --accent: #818cf8;
    --accent-strong: #a5b4fc;
    --accent-soft: rgba(129, 140, 248, 0.12);
    --accent-glow: rgba(129, 140, 248, 0.22);

    --code-bg: #161a24;
    --code-text: #c7d2fe;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 6px 18px rgba(0, 0, 0, 0.5);
  }
}

/* ============================================================
   Reset & base
============================================================ */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI Variable", "Segoe UI",
    "Pretendard Variable", Pretendard, "Apple SD Gothic Neo", "Noto Sans KR",
    Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01", "cv11";
}

::selection {
  background: var(--accent-soft);
  color: var(--text);
}

main, .container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================================
   Header
============================================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--t-mid) var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--border-soft); }

.site-header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--text);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.012em;
}
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

nav {
  display: flex;
  align-items: center;
  gap: 22px;
}
nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color var(--t-fast) var(--ease);
}
nav a:hover { color: var(--text); text-decoration: none; }
nav a.lang-toggle {
  font-size: 13px;
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-muted);
}
nav a.lang-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
}

@media (max-width: 540px) {
  .site-header-inner { padding: 14px 20px; }
  nav { gap: 14px; }
  nav a:not(.lang-toggle) { font-size: 13px; }
}

/* ============================================================
   Main content rhythm
============================================================ */

main {
  padding-top: 24px;
  padding-bottom: 96px;
}

h1, h2, h3, h4 {
  color: var(--text);
  letter-spacing: -0.02em;
}
h1 { font-size: 36px; font-weight: 700; line-height: 1.15; margin: 0 0 16px; }
h2 { font-size: 22px; font-weight: 650; line-height: 1.3; margin: 56px 0 14px; letter-spacing: -0.014em; }
h3 { font-size: 17px; font-weight: 600; line-height: 1.4; margin: 24px 0 8px; letter-spacing: -0.01em; }
h4 { font-size: 14px; font-weight: 600; margin: 16px 0 6px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.06em; }

p { margin: 12px 0; color: var(--text-soft); }
strong { color: var(--text); font-weight: 600; }

a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  transition: border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
a:hover {
  text-decoration: none;
  border-bottom-color: var(--accent);
}

ul, ol { padding-left: 22px; color: var(--text-soft); }
li { margin: 6px 0; }
li::marker { color: var(--text-faint); }

hr {
  border: 0;
  height: 1px;
  background: var(--border);
  margin: 56px 0;
}

code {
  background: var(--code-bg);
  color: var(--code-text);
  border-radius: var(--radius-sm);
  padding: 2px 6px;
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace;
  font-size: 13.5px;
}

table {
  border-collapse: collapse;
  width: 100%;
  margin: 16px 0;
  font-size: 14.5px;
}
th, td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: top;
  color: var(--text-soft);
}
th {
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  width: 36%;
}
td a { word-break: break-word; }

.muted { color: var(--text-muted); }
.last-updated {
  color: var(--text-faint);
  font-size: 13.5px;
  margin-top: -6px;
  margin-bottom: 36px;
  font-variant-numeric: tabular-nums;
}
.footer-note {
  margin-top: 24px;
  font-size: 13.5px;
  color: var(--text-muted);
}

/* ============================================================
   Hero
============================================================ */

.hero {
  position: relative;
  padding: 72px 0 48px;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -40px -120px auto -120px;
  height: 320px;
  background: radial-gradient(60% 80% at 50% 0%,
    color-mix(in srgb, var(--accent) 22%, transparent) 0%,
    transparent 70%);
  pointer-events: none;
  z-index: -1;
  filter: blur(2px);
}
.hero h1 {
  font-size: 48px;
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.028em;
  background: linear-gradient(180deg, var(--text) 0%, color-mix(in srgb, var(--text) 78%, var(--text-muted)) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero .lead {
  font-size: 18px;
  line-height: 1.55;
  color: var(--text-soft);
  margin: 0 0 32px;
  max-width: 560px;
}
.hero .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 24px;
}
.hero .eyebrow::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-glow);
}

@media (max-width: 540px) {
  .hero { padding: 40px 0 28px; }
  .hero h1 { font-size: 34px; }
  .hero .lead { font-size: 16.5px; }
  h1 { font-size: 28px; }
}

/* ============================================================
   Cards
============================================================ */

.product-card {
  display: block;
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 26px;
  text-decoration: none;
  color: inherit;
  margin: 18px 0;
  background: var(--surface);
  transition: border-color var(--t-mid) var(--ease),
              transform var(--t-mid) var(--ease),
              box-shadow var(--t-mid) var(--ease);
}
.product-card::after {
  content: "→";
  position: absolute;
  right: 24px;
  top: 26px;
  color: var(--text-faint);
  font-size: 18px;
  transition: color var(--t-fast) var(--ease), transform var(--t-mid) var(--ease);
}
.product-card:hover {
  border-color: color-mix(in srgb, var(--accent) 60%, var(--border));
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
  text-decoration: none;
}
.product-card:hover::after {
  color: var(--accent);
  transform: translateX(3px);
}
.product-card h3 {
  margin: 0 0 6px;
  font-size: 17px;
  color: var(--text);
}
.product-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 14.5px;
  max-width: calc(100% - 28px);
}
.product-card .tag {
  display: inline-block;
  margin-left: 10px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 2px 8px;
  border-radius: 999px;
  vertical-align: middle;
}

/* Feature grid */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 16px 0 8px;
}
.feature {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  background: var(--bg-muted);
}
.feature h4 {
  margin: 0 0 4px;
  text-transform: none;
  letter-spacing: -0.005em;
  font-size: 14.5px;
  color: var(--text);
}
.feature p {
  margin: 0;
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.5;
}
@media (max-width: 540px) {
  .feature-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   Buttons
============================================================ */

.cta-row {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 10px;
  font-weight: 550;
  font-size: 14.5px;
  border: 1px solid var(--border);
  color: var(--text);
  background: var(--surface);
  text-decoration: none;
  transition: border-color var(--t-fast) var(--ease),
              transform var(--t-fast) var(--ease),
              background var(--t-fast) var(--ease);
}
.btn:hover {
  text-decoration: none;
  border-color: var(--text-faint);
  transform: translateY(-1px);
}
.btn-primary {
  background: var(--accent);
  color: #ffffff;
  border-color: var(--accent);
  box-shadow: 0 1px 0 0 rgba(255,255,255,0.06) inset, 0 6px 16px -8px var(--accent);
}
.btn-primary:hover {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
}

/* ============================================================
   Footer
============================================================ */

.site-footer {
  border-top: 1px solid var(--border-soft);
  background: var(--bg-muted);
  margin-top: 64px;
  padding: 32px 0 48px;
  color: var(--text-muted);
  font-size: 13.5px;
}
.site-footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.site-footer a {
  color: var(--text-muted);
  border-bottom-color: transparent;
  margin-left: 18px;
}
.site-footer a:first-child,
.site-footer a:first-of-type { margin-left: 0; }
.site-footer a:hover {
  color: var(--text);
  border-bottom-color: transparent;
}
.site-footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.site-footer-brand .brand-mark { width: 16px; height: 16px; }

/* ============================================================
   404 / center screen
============================================================ */

.center-screen {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 8px;
}
.center-screen .code {
  font-size: 84px;
  font-weight: 700;
  letter-spacing: -0.04em;
  margin: 0;
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-strong) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ============================================================
   Reduced motion
============================================================ */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
