/* ---------------------------------------------------------------------------
   Planism — planism.co.kr
   Shared stylesheet for the marketing site (landing, terms, privacy, 404).

   Colours are lifted straight from the app's own palette (lib/theme/palette.dart)
   so the site and the product read as one thing:
     bg      #161619   ← kPalettes['dark'].bg
     accent  #66a5ff   ← oklch(0.72, 0.15, 258) resolved to sRGB
--------------------------------------------------------------------------- */

:root {
  --bg: #161619;
  --bg-2: #1c1c20;
  --surface: rgba(255, 255, 255, .05);
  --surface-2: rgba(255, 255, 255, .09);
  --border: rgba(255, 255, 255, .10);
  --border-2: rgba(255, 255, 255, .16);
  --text-1: #ffffff;
  --text-2: rgba(255, 255, 255, .60);
  --text-3: rgba(255, 255, 255, .40);
  --accent: #66a5ff;
  --accent-ink: #0d0d10;
  --accent-dim: rgba(102, 165, 255, .14);
  --radius: 20px;
  --maxw: 1120px;
  --ease: cubic-bezier(.4, 0, .2, 1);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-1);
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
    "Segoe UI", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  font-size: 16px;
  line-height: 1.65;
  letter-spacing: -.011em;
  overflow-x: hidden;
  word-break: keep-all;
}

img, svg { max-width: 100%; display: block }
a { color: inherit; text-decoration: none }
h1, h2, h3, h4 { margin: 0; line-height: 1.25; letter-spacing: -.035em; font-weight: 800 }
p { margin: 0 }
ul, ol { margin: 0; padding-left: 1.15em }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px }
.center { text-align: center }
.accent { color: var(--accent) }
.muted { color: var(--text-2) }

/* --------------------------------------------------------------- header --- */

header.site {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(22, 22, 25, .72);
  backdrop-filter: saturate(180%) blur(18px);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s var(--ease);
}
header.site.scrolled { border-bottom-color: var(--border) }
header.site .bar {
  height: 66px;
  display: flex;
  align-items: center;
  gap: 28px;
}
.logo { display: flex; align-items: center; gap: 9px; font-weight: 800; font-size: 18px; letter-spacing: -.04em }
.logo .mark {
  width: 27px; height: 27px; border-radius: 9px;
  background: linear-gradient(145deg, var(--accent), #3f7fe0);
  display: grid; place-items: center;
  color: var(--accent-ink); font-size: 15px; font-weight: 900;
  box-shadow: 0 4px 16px rgba(102, 165, 255, .35);
}
nav.top { display: flex; gap: 26px; margin-left: auto; font-size: 14.5px; font-weight: 600; color: var(--text-2) }
nav.top a { transition: color .18s var(--ease) }
nav.top a:hover { color: var(--text-1) }

/* --------------------------------------------------------------- buttons -- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 22px; border-radius: 999px;
  font-size: 15px; font-weight: 700; letter-spacing: -.02em;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .16s var(--ease), background .18s var(--ease), border-color .18s var(--ease);
  white-space: nowrap;
}
.btn:active { transform: scale(.97) }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 8px 26px rgba(102, 165, 255, .28) }
.btn-primary:hover { background: #7db4ff }
.btn-ghost { background: var(--surface); color: var(--text-1); border-color: var(--border) }
.btn-ghost:hover { background: var(--surface-2); border-color: var(--border-2) }
.btn-sm { height: 38px; padding: 0 17px; font-size: 14px }

/* --------------------------------------------------------------- section -- */

section { position: relative; padding: 104px 0 }
.eyebrow {
  display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .04em;
  color: var(--accent); margin-bottom: 14px; text-transform: uppercase;
}
h2.sec { font-size: clamp(28px, 4.6vw, 42px) }
.sec-sub { margin-top: 16px; color: var(--text-2); font-size: clamp(15px, 2vw, 17px); max-width: 620px }
.center .sec-sub { margin-left: auto; margin-right: auto }

.badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px 6px 11px; border-radius: 999px;
  background: var(--accent-dim); border: 1px solid rgba(102, 165, 255, .28);
  color: var(--accent); font-size: 13px; font-weight: 700; letter-spacing: -.01em;
}
.badge .dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--accent);
  box-shadow: 0 0 0 0 rgba(102, 165, 255, .6); animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(102, 165, 255, .55) }
  70%  { box-shadow: 0 0 0 9px rgba(102, 165, 255, 0) }
  100% { box-shadow: 0 0 0 0 rgba(102, 165, 255, 0) }
}

/* ---------------------------------------------------------------- cards --- */

.grid { display: grid; gap: 18px }
.grid-3 { grid-template-columns: repeat(3, 1fr) }
.grid-2 { grid-template-columns: repeat(2, 1fr) }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 26px;
  transition: background .2s var(--ease), border-color .2s var(--ease), transform .2s var(--ease);
}
.card:hover { background: var(--surface-2); border-color: var(--border-2); transform: translateY(-3px) }
.card .ico {
  width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center;
  background: var(--accent-dim); color: var(--accent); margin-bottom: 18px;
}
.card .ico svg { width: 21px; height: 21px }
.card h3 { font-size: 18.5px; margin-bottom: 9px }
.card p { color: var(--text-2); font-size: 14.5px; line-height: 1.7 }

/* --------------------------------------------------------------- footer --- */

footer.site { border-top: 1px solid var(--border); padding: 52px 0 44px; color: var(--text-3); font-size: 14px }
footer.site .cols { display: flex; flex-wrap: wrap; gap: 40px; justify-content: space-between; margin-bottom: 38px }
footer.site h4 { font-size: 13px; color: var(--text-2); margin-bottom: 14px; font-weight: 700; letter-spacing: .02em }
footer.site ul { list-style: none; padding: 0; display: grid; gap: 9px }
footer.site a { color: var(--text-3); transition: color .18s var(--ease) }
footer.site a:hover { color: var(--text-1) }
footer.site .legal { border-top: 1px solid var(--border); padding-top: 22px; display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; font-size: 13px }

/* ------------------------------------------------------------ doc pages --- */

.doc { padding: 64px 0 96px; max-width: 780px }
.doc h1 { font-size: clamp(28px, 5vw, 38px); margin-bottom: 12px }
.doc .updated { color: var(--text-3); font-size: 14px; margin-bottom: 8px }
.doc .notice {
  margin: 26px 0 40px; padding: 16px 18px; border-radius: 14px;
  background: rgba(255, 183, 75, .09); border: 1px solid rgba(255, 183, 75, .26);
  color: #ffcf8a; font-size: 14px; line-height: 1.7;
}
.doc h2 { font-size: 20px; margin: 44px 0 14px; padding-top: 4px }
.doc h3 { font-size: 16.5px; margin: 26px 0 10px; font-weight: 700 }
.doc p, .doc li { color: var(--text-2); font-size: 15px; line-height: 1.85 }
.doc p + p { margin-top: 12px }
.doc ul, .doc ol { margin-top: 10px; display: grid; gap: 7px }
.doc a { color: var(--accent) }
.doc a:hover { text-decoration: underline }
.doc strong { color: var(--text-1); font-weight: 600 }
.doc table { width: 100%; border-collapse: collapse; margin-top: 14px; font-size: 14.5px }
.doc th, .doc td { border: 1px solid var(--border); padding: 11px 13px; text-align: left; vertical-align: top; color: var(--text-2) }
.doc th { background: var(--surface); color: var(--text-1); font-weight: 700; white-space: nowrap }
.doc .tablewrap { overflow-x: auto; -webkit-overflow-scrolling: touch }
/* Three columns or more get squeezed unreadably on a phone. Give them a floor
   and let the wrapper scroll instead — the page itself still never moves. */
.doc .tablewrap.wide table { min-width: 560px }
.doc .tablewrap.wide.xwide table { min-width: 760px }
.doc .toc { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 20px 24px; margin: 30px 0 6px }
.doc .toc ol { padding-left: 1.2em; gap: 5px }
.doc .toc a { color: var(--text-2) }

/* --------------------------------------------------------------- mobile --- */

@media (max-width: 900px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr) }
}
@media (max-width: 720px) {
  section { padding: 76px 0 }
  .wrap { padding: 0 20px }
  nav.top { display: none }
  .grid-3, .grid-2 { grid-template-columns: 1fr }
  footer.site .cols { gap: 30px }
}

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