/* ============================================================
   TKOneGEO — base design system
   paper white + forest green + mint
   ============================================================ */

@font-face {
  font-family: "Manrope";
  src: url("/assets/fonts/manrope-latin.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/assets/fonts/plex-mono-400-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/assets/fonts/plex-mono-500-latin.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #f7faf5;
  --paper-2: #eef7f1;
  --paper-3: #e6f2ea;
  --white: #ffffff;
  --ink: #0b1f14;
  --ink-2: #20382a;
  --muted: #5e6f63;
  --muted-2: #64766a;
  --line: #dde8df;
  --line-strong: #c9d8cd;
  --green: #0e7a4a;
  --green-deep: #0a5e39;
  --green-dark: #0a2e1f;
  --green-darker: #061a10;
  --mint: #38d996;
  --mint-2: #7fe7b8;
  --mint-soft: #dff5e7;
  --mint-wash: #eef9f2;
  --error: #b42318;
  --error-bg: #fef3f2;
  --error-line: #fecdca;
  --warning: #b54708;
  --warning-bg: #fffaeb;

  --radius-xs: 8px;
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-card: 28px;
  --radius-panel: 36px;

  --max: 1200px;
  --gutter: 24px;
  --section-y: clamp(84px, 10vw, 156px);

  --shadow-soft: 0 24px 60px -36px rgba(10, 46, 31, 0.24);
  --shadow-card: 0 18px 48px -30px rgba(10, 46, 31, 0.22);
  --shadow-pill: 0 10px 30px -18px rgba(10, 46, 31, 0.3);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-state: cubic-bezier(0.4, 0, 0.2, 1);

  --font-sans: "Manrope", "PingFang SC", "HarmonyOS Sans SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 108px;
}

html,
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  min-width: 320px;
  overflow-x: clip;
  font-size: 16px;
  line-height: 1.65;
}

::selection { background: rgba(56, 217, 150, 0.28); color: var(--ink); }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
code, pre { font-family: var(--font-mono); }

:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 3px;
  border-radius: 4px;
}
.btn-primary:focus-visible,
.auth-submit:focus-visible,
.code-copy:focus-visible,
.doc-code-copy:focus-visible { outline-color: var(--mint-2); }

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 999;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--green-dark);
  color: var(--white);
  font-size: 13px;
  font-weight: 600;
  transform: translateY(-160%);
  transition: transform 0.2s var(--ease-state);
}
.skip-link:focus { transform: translateY(0); }

.container {
  width: min(var(--max), calc(100% - 48px));
  margin-inline: auto;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--green);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  line-height: 1.2;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: currentColor;
  opacity: 0.55;
}
.eyebrow.light { color: var(--mint-2); }

.section-head { max-width: 720px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head.center .eyebrow { justify-content: center; }
.section-head h2 {
  margin-top: 18px;
  font-size: clamp(34px, 4.2vw, 54px);
  font-weight: 700;
  line-height: 1.14;
  letter-spacing: -0.035em;
  color: var(--ink);
}
.section-head p {
  margin-top: 16px;
  color: var(--muted);
  font-size: clamp(15px, 1.35vw, 17px);
  line-height: 1.75;
}
.nowrap { white-space: nowrap; }

.btn {
  --btn-bg: var(--green);
  --btn-fg: #ffffff;
  --btn-border: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  padding: 0 22px;
  border: 1px solid var(--btn-border);
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.005em;
  white-space: nowrap;
  transition: background 0.22s var(--ease-state), border-color 0.22s var(--ease-state), color 0.22s var(--ease-state), transform 0.22s var(--ease-state), box-shadow 0.22s var(--ease-state);
}
.btn svg { flex: none; transition: transform 0.22s var(--ease-state); }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0) scale(0.98); }
.btn-primary {
  background: var(--green);
  color: var(--white);
  box-shadow: 0 12px 26px -16px rgba(14, 122, 74, 0.55);
}
.btn-primary:hover { background: var(--green-deep); box-shadow: 0 16px 32px -16px rgba(14, 122, 74, 0.5); }
.btn-primary:hover svg { transform: translateX(3px); }
.btn-ghost {
  background: rgba(255, 255, 255, 0.74);
  color: var(--ink);
  border-color: var(--line-strong);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7) inset;
}
.btn-ghost:hover { background: var(--white); border-color: var(--green); color: var(--green); }
.btn-light { background: var(--white); color: var(--ink); }
.btn-light:hover { background: var(--mint-soft); color: var(--green-deep); }
.btn-outline-light { background: transparent; color: var(--white); border-color: rgba(255, 255, 255, 0.26); }
.btn-outline-light:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.45); }
.btn-lg { min-height: 54px; padding-inline: 28px; font-size: 15px; }
.btn-sm { min-height: 40px; padding-inline: 18px; font-size: 13px; }

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--green);
  font-size: 14px;
  font-weight: 600;
  transition: color 0.2s var(--ease-state), gap 0.2s var(--ease-state);
}
.text-link:hover { color: var(--green-deep); gap: 10px; }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 500;
  white-space: nowrap;
}
.status-pill i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 0 3px rgba(56, 217, 150, 0.16);
}
.status-pill b { color: var(--green); font-weight: 600; }

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

.site-header {
  position: fixed;
  inset: 18px 0 auto;
  z-index: 60;
  transition: inset 0.3s var(--ease-state);
}
.nav-shell {
  width: min(1240px, calc(100% - 40px));
  margin-inline: auto;
  min-height: 64px;
  padding: 8px 10px 8px 18px;
  display: flex;
  align-items: center;
  gap: 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  transition: background 0.3s var(--ease-state), border-color 0.3s var(--ease-state), box-shadow 0.3s var(--ease-state), backdrop-filter 0.3s var(--ease-state);
}
.site-header.is-scrolled,
.site-header.is-solid { inset: 10px 0 auto; }
.site-header.is-solid .nav-shell {
  background: rgba(255, 255, 255, 0.86);
  border-color: rgba(201, 216, 205, 0.72);
  box-shadow: 0 18px 44px -26px rgba(10, 46, 31, 0.3);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}
.site-header.is-scrolled .nav-shell {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(201, 216, 205, 0.72);
  box-shadow: 0 18px 44px -26px rgba(10, 46, 31, 0.3);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}
.brand { display: inline-flex; align-items: center; gap: 10px; flex: none; }
.brand img { width: 38px; height: 38px; border-radius: 12px; box-shadow: 0 8px 18px -10px rgba(10, 46, 31, 0.5); }
.brand .brand-logo { width: auto; height: 34px; border-radius: 0; box-shadow: none; }
.brand-name { display: flex; flex-direction: column; line-height: 1.08; }
.brand-name strong { font-size: 16px; font-weight: 700; letter-spacing: -0.02em; }
.brand-name span { margin-top: 3px; color: var(--muted-2); font-size: 10px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; }
.nav-links { display: flex; align-items: center; gap: 2px; margin-left: 14px; }
.nav-links a {
  position: relative;
  padding: 10px 13px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 500;
  transition: color 0.2s var(--ease-state), background 0.2s var(--ease-state);
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 13px;
  right: 13px;
  bottom: 6px;
  height: 1px;
  background: var(--green);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s var(--ease-state);
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after { transform: scaleX(1); }
.nav-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.menu-btn {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.8);
  align-items: center;
  justify-content: center;
}
.menu-btn span { display: block; width: 16px; height: 1.5px; background: var(--ink); position: relative; }
.menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; width: 16px; height: 1.5px; background: var(--ink); transition: transform 0.25s var(--ease-state); }
.menu-btn span::before { top: -5px; }
.menu-btn span::after { top: 5px; }
.menu-btn[aria-expanded="true"] span { background: transparent; }
.menu-btn[aria-expanded="true"] span::before { transform: translateY(5px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span::after { transform: translateY(-5px) rotate(-45deg); }

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: none;
  padding: 108px 24px 32px;
  background: rgba(247, 250, 245, 0.98);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s var(--ease-state);
}
.mobile-menu.is-open { opacity: 1; pointer-events: auto; }
.mobile-menu nav { display: flex; flex-direction: column; }
.mobile-menu nav a {
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.mobile-menu .mobile-actions { display: grid; gap: 10px; margin-top: 28px; }
.mobile-menu .mobile-actions .btn { width: 100%; }

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

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--paper);
  padding: 72px 0 30px;
}
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 48px; }
.footer-brand .brand { margin-bottom: 18px; }
.footer-brand p { max-width: 300px; color: var(--muted); font-size: 14px; line-height: 1.75; }
.footer-brand .status-pill { margin-top: 22px; }
.footer-col h3 {
  color: var(--muted-2);
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.footer-col ul { display: grid; gap: 11px; margin-top: 18px; }
.footer-col a { color: var(--muted); font-size: 14px; transition: color 0.2s var(--ease-state); }
.footer-col a:hover { color: var(--green); }
.footer-bottom {
  margin-top: 64px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  color: var(--muted-2);
  font-size: 12px;
}
.footer-bottom .legal { display: flex; flex-wrap: wrap; gap: 14px; }
.footer-bottom a:hover { color: var(--green); }

/* ---------- reveal motion ---------- */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.75s var(--ease-out), transform 0.75s var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}
.js [data-reveal].is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
}

@media (max-width: 1080px) {
  .nav-links { display: none; }
  .menu-btn { display: inline-flex; }
  .mobile-menu { display: block; }
  .nav-shell { gap: 12px; }
  .nav-actions .status-pill { display: none; }
}

@media (max-width: 760px) {
  .container { width: calc(100% - 40px); }
  .site-header { inset: 10px 0 auto; }
  .nav-shell { min-height: 58px; padding: 7px 8px 7px 12px; width: calc(100% - 24px); }
  .brand img { width: 34px; height: 34px; border-radius: 10px; }
  .brand .brand-logo { width: auto; height: 29px; border-radius: 0; }
  .brand-name strong { font-size: 15px; }
  .brand-name span { display: none; }
  .nav-actions .btn { display: none; }
  .menu-btn { display: inline-flex; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px 24px; }
  .footer-brand { grid-column: 1 / -1; }
  .footer-bottom { align-items: flex-start; flex-direction: column; }
  .site-footer { padding-top: 56px; }
}

@media (max-width: 520px) {
  .container { width: calc(100% - 32px); }
  .btn-lg { min-height: 52px; width: 100%; }
  .footer-grid { grid-template-columns: 1fr; }
}
