/* TruePyramids design tokens and components, matching the design canvas. */
:root {
  --green-900: #004D1F;
  --green-700: #007F32;
  --green-500: #3E9F5E;
  --green-300: #8CCB9F;
  --green-100: #CBE8D3;
  --green-50: #E8F4EC;
  --purple-900: #431566;
  --purple-800: #5B1F8A;
  --purple-600: #7A2FB5;
  --purple-100: #D9C2EE;
  --purple-50: #F4ECFB;
  --ink: #13171F;
  --ink-2: #4B5563;
  --ink-3: #5B6472;
  --line: #DDE1E7;
  --line-strong: #C9CFD8;
  --line-soft: #E8EBEF;
  --page: #F5F6F8;
  --surface: #FFFFFF;
  --surface-2: #F9FAFB;
  --gold: #E0A100;
  --font-body: 'IBM Plex Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-head: 'Space Grotesk', system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.55; }
a { color: var(--green-700); }
a:hover { color: var(--green-900); }
:focus-visible { outline: 2px solid var(--green-700); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--font-head); font-weight: 600; letter-spacing: -0.015em; margin: 0; }
h1 { font-size: 36px; line-height: 1.1; }
h2 { font-size: 22px; line-height: 1.2; }
p { margin: 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Header */
.tp-header { background: var(--surface); border-bottom: 1px solid var(--line); }
.tp-header__inner { max-width: 1200px; margin: 0 auto; padding: 10px 24px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.tp-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: var(--font-head); font-weight: 700; font-size: 20px; letter-spacing: -0.01em; }
.tp-brand:hover { color: var(--ink); }
.tp-nav { display: flex; gap: 4px; }
.tp-nav a { display: inline-flex; align-items: center; height: 44px; padding: 0 14px; border-radius: 8px; color: var(--ink-2); text-decoration: none; font-weight: 500; }
.tp-nav a[aria-current="page"] { background: var(--green-50); color: var(--green-900); font-weight: 600; }
.tp-account { display: flex; align-items: center; gap: 14px; font-size: 14px; color: var(--ink-2); }
.tp-avatar { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--green-900); color: #fff; font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.tp-menu { position: relative; }
.tp-menu__panel { position: absolute; right: 0; top: 48px; z-index: 50; min-width: 220px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 32px rgba(0,0,0,.12); padding: 8px; display: flex; flex-direction: column; }
.tp-menu__panel[hidden] { display: none; }
.tp-menu__panel a, .tp-menu__panel button { display: flex; align-items: center; height: 44px; padding: 0 12px; border: 0; border-radius: 8px; background: transparent; color: var(--ink); font: inherit; text-decoration: none; cursor: pointer; text-align: left; width: 100%; }
.tp-menu__panel a:hover, .tp-menu__panel button:hover { background: var(--page); }

/* Layout */
.tp-main { max-width: 1200px; margin: 0 auto; padding: 32px 24px 96px; display: flex; flex-direction: column; gap: 24px; }
.tp-narrow { max-width: 560px; margin: 0 auto; padding: 64px 16px 96px; }
.tp-center { min-height: calc(100vh - 66px); display: flex; align-items: center; justify-content: center; padding: 48px 16px 96px; }
.eyebrow { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--green-700); }
.muted { color: var(--ink-2); }
.small { font-size: 14px; }

/* Cards and panels */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 20px 24px; }
.card--auth { width: 100%; max-width: 440px; border-radius: 16px; padding: 40px; display: flex; flex-direction: column; gap: 28px; box-shadow: 0 24px 48px -24px rgba(0, 77, 31, 0.2); }
.card--form { border-radius: 16px; padding: 40px; display: flex; flex-direction: column; gap: 24px; }
.stack { display: flex; flex-direction: column; gap: 8px; }
.stack-lg { display: flex; flex-direction: column; gap: 16px; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.row--between { justify-content: space-between; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 16px; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); gap: 24px; }
.divider-top { border-top: 1px solid var(--line-soft); padding-top: 20px; }
.notice { padding: 14px 18px; border-radius: 10px; background: var(--purple-50); border: 1px solid var(--purple-100); color: var(--purple-900); }
.notice b { color: var(--purple-800); }
.notice--ok { background: var(--green-50); border-color: var(--green-100); color: #33473B; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 18px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface); color: var(--ink); font: inherit; font-weight: 500; text-decoration: none; cursor: pointer; }
.btn:hover { color: var(--ink); border-color: #A3ABB8; }
.btn--primary { background: var(--green-700); border-color: var(--green-700); color: #fff; font-weight: 600; }
.btn--primary:hover { background: var(--green-900); border-color: var(--green-900); color: #fff; }
.btn--lg { height: 48px; padding: 0 28px; }
.btn--provider { height: 52px; justify-content: flex-start; gap: 12px; padding: 0 20px; width: 100%; }
.btn--link { border: 0; background: transparent; padding: 0 8px; color: var(--ink-2); text-decoration: underline; }
.provider-mark { width: 22px; height: 22px; border-radius: 4px; background: #EEF1F5; border: 1px solid var(--line-strong); font-size: 12px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; }
.btn[aria-disabled="true"] { opacity: 0.55; pointer-events: none; }

/* Forms */
.field { display: flex; flex-direction: column; gap: 6px; }
.field__label { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-weight: 600; }
.field__from { font-size: 12px; font-weight: 600; color: var(--green-700); }
.field__hint { font-size: 14px; color: var(--ink-3); }
.input { height: 48px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 8px; font: inherit; color: var(--ink); background: var(--surface); width: 100%; }
.input--prefilled { background: var(--surface-2); }
.input-validation-error { border-color: var(--purple-600); }
.field-validation-error { font-size: 14px; color: var(--purple-800); font-weight: 600; }

/* Plus tag */
.plus-tag { background: var(--green-50); color: var(--green-900); border: 1px solid var(--green-100); font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 10px; }

@media (max-width: 600px) {
  h1 { font-size: 30px; }
  .card--auth, .card--form { padding: 28px 20px; }
}
