/*
 * TokenCap Advisors — Base styles
 * Modern CSS reset + typographic defaults + accessibility baseline
 */

/* ── Modern CSS reset ─────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

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

html, body {
  height: 100%;
}

body {
  line-height: var(--lh-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  color: var(--color-text);
  background: var(--color-forest);
  text-rendering: optimizeLegibility;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: none;
  cursor: pointer;
}

p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

#root, #__next, main {
  isolation: isolate;
}

/* ── Accessibility — visible focus ────────────────────── */
:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: var(--radius-sm);
}

:focus:not(:focus-visible) {
  outline: none;
}

/* Skip-to-content link for keyboard users — hidden until focused */
.skip-to-content {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
  z-index: var(--z-toast);
}

.skip-to-content:focus {
  position: fixed;
  left: 1rem;
  top: 1rem;
  width: auto;
  height: auto;
  padding: var(--space-3) var(--space-4);
  background: var(--color-gold);
  color: var(--color-forest);
  font-weight: var(--fw-bold);
  text-decoration: none;
  border-radius: var(--radius-sm);
  font-size: var(--fs-sm);
}

/* Screen-reader-only utility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── Typography defaults ──────────────────────────────── */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: var(--fw-medium);
  line-height: var(--lh-tight);
  color: var(--color-white);
  letter-spacing: var(--tracking-tight);
}

h1 {
  font-size: clamp(var(--fs-3xl), 5vw, var(--fs-5xl));
}

h2 {
  font-size: clamp(var(--fs-2xl), 3.5vw, var(--fs-3xl));
}

h3 {
  font-size: var(--fs-xl);
}

h4 {
  font-size: var(--fs-md);
  font-weight: var(--fw-semibold);
}

/* Italic emphasis in serif headings gets gold treatment */
h1 em, h2 em, h3 em {
  font-style: italic;
  color: var(--color-gold-light);
  font-weight: var(--fw-medium);
}

p {
  line-height: var(--lh-relaxed);
  color: var(--color-text-muted);
}

p.lead {
  font-size: var(--fs-lg);
  line-height: var(--lh-relaxed);
  color: var(--color-text);
  font-family: var(--font-serif);
  font-weight: var(--fw-regular);
}

strong, b {
  color: var(--color-white);
  font-weight: var(--fw-semibold);
}

em, i {
  font-style: italic;
}

small {
  font-size: var(--fs-sm);
  color: var(--color-text-faint);
}

/* ── Links ────────────────────────────────────────────── */
a {
  color: var(--color-gold-light);
  text-decoration: underline;
  text-decoration-color: var(--color-border-gold);
  text-underline-offset: 3px;
  transition: color var(--dur-base) var(--ease-out),
              text-decoration-color var(--dur-base) var(--ease-out);
}

a:hover {
  color: var(--color-gold);
  text-decoration-color: var(--color-gold);
}

/* Links within nav and buttons don't get underlines by default */
nav a, .btn, .nav-link-item, .channel-card, .sector-card,
.research-card, .meth-card, .tier-cta, .consult-btn {
  text-decoration: none;
}

/* ── Lists ────────────────────────────────────────────── */
ul, ol {
  padding-left: 1.25em;
  color: var(--color-text-muted);
  line-height: var(--lh-relaxed);
}

li {
  margin-bottom: var(--space-2);
}

li::marker {
  color: var(--color-gold);
}

ul.plain, ol.plain {
  list-style: none;
  padding-left: 0;
}

/* ── Horizontal rules ─────────────────────────────────── */
hr {
  border: none;
  border-top: 1px solid var(--color-border-subtle);
  margin: var(--space-8) 0;
}

hr.gold {
  border-top-color: var(--color-border-gold);
}

/* ── Utility: eyebrow label ───────────────────────────── */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  font-family: var(--font-display);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  color: var(--color-gold);
  letter-spacing: var(--tracking-widest);
  text-transform: uppercase;
  margin-bottom: var(--space-4);
}

.eyebrow::before {
  content: "";
  display: inline-block;
  width: 1.5rem;
  height: 1px;
  background: var(--color-gold);
}

/* Section titles */
.section-title {
  font-family: var(--font-serif);
  font-weight: var(--fw-medium);
  font-size: clamp(var(--fs-3xl), 4vw, var(--fs-4xl));
  line-height: var(--lh-tight);
  color: var(--color-white);
  margin-bottom: var(--space-6);
  letter-spacing: var(--tracking-tight);
}

.section-desc {
  font-size: var(--fs-md);
  color: var(--color-text-muted);
  line-height: var(--lh-relaxed);
  max-width: var(--content-max);
}
