/* ============================================================================
   ProfileCoach.ai design tokens — extracted from the landing page so all
   authed surfaces feel like a continuation of /
   ============================================================================ */

:root {
  /* Editorial paper palette */
  --paper: #F4EFE6;
  --paper-2: #EDE5D6;
  --paper-3: #E5DAC4;
  --ink: #1A1612;
  --ink-soft: #3A2F26;
  --rule: #1A1612;

  /* Stage accents */
  --accent: #D63F2B;      /* stage red */
  --accent-deep: #A82D1D;
  --spot: #F5C451;        /* warm bulb */
  --glow: #E8D9B8;

  /* Neutrals */
  --muted: #8B7355;
  --shadow: rgba(26, 22, 18, 0.08);
  --shadow-2: rgba(26, 22, 18, 0.14);

  /* Fonts */
  --f-display: 'Fraunces', Georgia, serif;
  --f-body: 'Inter Tight', -apple-system, BlinkMacSystemFont, sans-serif;
  --f-mono: 'JetBrains Mono', ui-monospace, monospace;

  /* Layout */
  --max-w: 1280px;
  --gutter: clamp(16px, 3vw, 40px);

  /* Status colors */
  --success: #2F7D32;
  --danger: #A82D1D;
  --warning: #B45309;
}

/* ============ GLOBAL RESETS ============ */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Subtle paper-grain overlay (matches landing). Opt-in via .theme-grain on body. */
body.theme-grain::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  opacity: 0.30;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.1 0 0 0 0 0.08 0 0 0 0 0.07 0 0 0 0.22 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  mix-blend-mode: multiply;
}

a { color: var(--accent-deep); }
a:hover { color: var(--accent); }

/* ============ TYPOGRAPHY PRIMITIVES ============ */

h1, h2, h3, h4 {
  font-family: var(--f-display);
  font-weight: 500;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.01em;
}

h1 { font-size: 28px; line-height: 1.15; }
h2 { font-size: 22px; line-height: 1.2; }
h3 { font-size: 17px; line-height: 1.25; }

.cue {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.cue-red { color: var(--accent); }
.cue-muted { color: var(--muted); }

/* Stage-direction label — wraps section headings */
.stage-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 4px 8px;
  border: 1px solid var(--accent);
  border-radius: 2px;
  background: transparent;
  white-space: nowrap;
}

.stage-label.subtle {
  color: var(--ink-soft);
  border-color: var(--ink-soft);
  opacity: 0.7;
}

/* Thin ruled separator */
.rule {
  height: 1px;
  background: var(--ink);
  opacity: 0.18;
  width: 100%;
  border: 0;
  margin: 14px 0;
}

/* ============ BUTTONS ============ */

.btn,
button.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
  padding: 10px 16px;
  border-radius: 2px;
  border: 1px solid var(--ink);
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
  transition: transform 0.08s ease, box-shadow 0.08s ease;
  text-decoration: none;
  box-shadow: 3px 3px 0 var(--ink);
}

.btn:hover,
button.btn:hover {
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 var(--ink);
}

.btn:active,
button.btn:active {
  transform: translate(2px, 2px);
  box-shadow: 1px 1px 0 var(--ink);
}

.btn-primary,
button.btn-primary {
  background: var(--accent);
  color: var(--paper);
  border-color: var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
}

.btn-primary:hover {
  background: var(--accent-deep);
}

.btn-spot {
  background: var(--spot);
  color: var(--ink);
}

.btn-ghost {
  background: transparent;
  box-shadow: 3px 3px 0 var(--ink-soft);
}

.btn-danger {
  background: var(--accent-deep);
  color: var(--paper);
  border-color: var(--ink);
}

.btn-sm {
  font-size: 11px;
  padding: 6px 10px;
  box-shadow: 2px 2px 0 var(--ink);
}

.btn-sm:hover {
  box-shadow: 3px 3px 0 var(--ink);
}

.btn-sm:active {
  box-shadow: 1px 1px 0 var(--ink);
}

button:disabled,
.btn:disabled,
.btn[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
  box-shadow: 3px 3px 0 rgba(26, 22, 18, 0.3);
}

button:disabled:hover {
  transform: none;
}
