/* ═══════════════════════════════════════════════════════════════════════════
 * CARBON MULTIMEDIA · DESIGN SYSTEM v1.0
 * ═══════════════════════════════════════════════════════════════════════════
 *
 * Canonical stylesheet for all Carbon Multimedia web properties.
 * Anchor reference: rates.html
 * Last updated: May 5, 2026
 *
 * IMPORT IN ALL PAGES:
 * <link href="design-system.css" rel="stylesheet">
 *
 * Override page-specific styles inline AFTER this import in each HTML file.
 * NEVER hardcode values — always use the tokens defined here.
 *
 * Documentation:
 * - Notion → Brand System → Design Tokens
 * - Notion → Knowledge Base → SOPs → Workflow Philosophy
 * ═══════════════════════════════════════════════════════════════════════════ */


/* ──────────────────────────────────────────────────────────────────────────
 * 01. DESIGN TOKENS
 * ────────────────────────────────────────────────────────────────────────── */

:root {
  /* Backgrounds */
  --bg: #fbf9f6;
  --bg2: #f4f1eb;
  --bg3: #eae6df;

  /* Text */
  --text: #0e0c0a;
  --muted: #3d3830;
  --muted2: #8a8480;

  /* Gold accent */
  --gold: #b8924a;
  --gold-dim: rgba(184, 146, 74, 0.12);
  --gold-line: rgba(184, 146, 74, 0.30);
  --gold-line-strong: rgba(184, 146, 74, 0.55);

  /* Typography families */
  --font-display: 'Cormorant Garamond', serif;
  --font-display-sc: 'Cormorant SC', serif;
  --font-body: 'Barlow', sans-serif;
  --font-cond: 'Barlow Condensed', sans-serif;

  /* Type scale — desktop defaults */
  --text-h1-hero: 88px;
  --text-h1-doc: 64px;
  --text-h2: 44px;
  --text-h3: 28px;
  --text-lede: 22px;
  --text-body: 16px;
  --text-small: 14px;
  --text-eyebrow: 12px;

  /* Line heights */
  --lh-tight: 1.1;
  --lh-snug: 1.3;
  --lh-normal: 1.5;
  --lh-relaxed: 1.7;

  /* Letter spacing */
  --tracking-tight: -0.01em;
  --tracking-normal: 0;
  --tracking-wide: 0.05em;
  --tracking-wider: 0.15em;
  --tracking-widest: 0.25em;

  /* Spacing scale */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 16px;
  --space-4: 24px;
  --space-5: 32px;
  --space-6: 48px;
  --space-7: 64px;
  --space-8: 96px;
  --space-9: 128px;

  /* Container widths */
  --container-standard: 1040px;
  --container-doc-main: 920px;
  --container-doc-sidebar: 240px;
  --container-hero-copy: 720px;

  /* Border / hairline */
  --hairline: 1px solid var(--gold-line);
  --hairline-strong: 1px solid var(--gold-line-strong);

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition: 0.25s ease;
  --transition-slow: 0.4s ease;
}


/* ──────────────────────────────────────────────────────────────────────────
 * 02. RESET / BASE
 * ────────────────────────────────────────────────────────────────────────── */

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

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: var(--text-body);
  line-height: var(--lh-relaxed);
  min-height: 100vh;
  overflow-x: hidden;
}

img, svg, video {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
}


/* ──────────────────────────────────────────────────────────────────────────
 * 03. TYPOGRAPHY
 * ────────────────────────────────────────────────────────────────────────── */

/* Hero H1 (index, site-preview, rates) */
.h1-hero,
h1.hero {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--text-h1-hero);
  line-height: var(--lh-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--text);
  margin: 0 0 var(--space-4);
}

.h1-hero .accent,
h1.hero .accent {
  color: var(--gold);
}

/* Document H1 (terms) */
.h1-doc,
h1.doc {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--text-h1-doc);
  line-height: var(--lh-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--text);
  margin: 0 0 var(--space-4);
}

/* H2 — section header */
h2,
.h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--text-h2);
  line-height: var(--lh-snug);
  letter-spacing: var(--tracking-tight);
  color: var(--text);
  margin: 0 0 var(--space-4);
}

/* H3 — subsection */
h3,
.h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-h3);
  line-height: var(--lh-snug);
  color: var(--text);
  margin: 0 0 var(--space-3);
}

/* Lede / Subhead — italic intro paragraphs */
.lede {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: var(--text-lede);
  line-height: var(--lh-normal);
  color: var(--muted);
  max-width: var(--container-hero-copy);
  margin: 0 auto var(--space-5);
}

/* Eyebrow — canonical style (NO lines, NO dashes, just text) */
.eyebrow {
  font-family: var(--font-cond);
  font-weight: 500;
  font-size: var(--text-eyebrow);
  letter-spacing: var(--tracking-widest);
  text-transform: uppercase;
  color: var(--gold);
  text-align: center;
  margin: 0 0 var(--space-4);
  display: block;
}

/* Body paragraph helper */
p {
  margin: 0 0 var(--space-3);
  color: var(--muted);
}

/* Small / footnote */
.small,
small {
  font-size: var(--text-small);
  color: var(--muted2);
}


/* ──────────────────────────────────────────────────────────────────────────
 * 04. NAVIGATION — UNIFIED SECONDARY NAV
 *     Used by: rates.html, carbon-multimedia-terms.html
 *     index.html: NO nav (intentional)
 *     site-preview.html: full nav (overrides inline in that file)
 * ────────────────────────────────────────────────────────────────────────── */

.nav-secondary {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: var(--hairline);
  padding: var(--space-3) var(--space-5);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-secondary .nav-brand {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-display-sc);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: var(--tracking-wide);
  color: var(--text);
}

.nav-secondary .nav-brand svg {
  width: 24px;
  height: 28px;
  fill: var(--text);
}


/* ──────────────────────────────────────────────────────────────────────────
 * 05. BUTTONS — 3-TIER SYSTEM
 * ────────────────────────────────────────────────────────────────────────── */

/* Tier 1: Primary — Gold fill, ONE per page */
.btn-primary {
  display: inline-block;
  background: var(--gold);
  color: #fff;
  border: 1px solid var(--gold);
  padding: 14px 28px;
  font-family: var(--font-cond);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
}

.btn-primary:hover {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

/* Tier 2: Secondary — Gold outline */
.btn-secondary,
.nav-back {
  display: inline-block;
  background: transparent;
  color: var(--gold);
  border: 1px solid var(--gold);
  padding: 13px 27px;
  font-family: var(--font-cond);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
}

.btn-secondary:hover,
.nav-back:hover {
  background: var(--gold);
  color: #fff;
}

/* Tier 3: Tertiary — Italic underlined text link */
.btn-tertiary,
.text-link {
  color: var(--gold);
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-body);
  border-bottom: 1px solid var(--gold-line);
  padding-bottom: 2px;
  transition: var(--transition);
  text-decoration: none;
}

.btn-tertiary:hover,
.text-link:hover {
  border-bottom-color: var(--gold);
}


/* ──────────────────────────────────────────────────────────────────────────
 * 06. LAYOUT CONTAINERS
 * ────────────────────────────────────────────────────────────────────────── */

.container {
  max-width: var(--container-standard);
  margin: 0 auto;
  padding: 0 var(--space-4);
}

.container-doc {
  max-width: calc(var(--container-doc-main) + var(--container-doc-sidebar));
  margin: 0 auto;
  padding: 0 var(--space-4);
}

section {
  padding: var(--space-7) var(--space-4);
}

/* Hero centered copy block */
.hero-copy {
  max-width: var(--container-hero-copy);
  margin: 0 auto;
  text-align: center;
}


/* ──────────────────────────────────────────────────────────────────────────
 * 07. DIVIDERS / HAIRLINES
 * ────────────────────────────────────────────────────────────────────────── */

.hr {
  height: 1px;
  background: var(--gold-line);
  border: none;
  margin: var(--space-6) 0;
}

.hr-dotted {
  height: 1px;
  background: none;
  border: none;
  border-top: 1px dotted var(--gold-line);
  margin: var(--space-5) 0;
}


/* ──────────────────────────────────────────────────────────────────────────
 * 08. CARDS / FEATURE BLOCKS
 * ────────────────────────────────────────────────────────────────────────── */

.card {
  background: var(--bg);
  border: 1px solid var(--gold-line);
  padding: var(--space-5);
  border-radius: 0;
}

.card h3 {
  margin-top: 0;
}


/* ──────────────────────────────────────────────────────────────────────────
 * 09. RESPONSIVE — MOBILE FIRST OVERRIDES
 *     Mobile is ≤640px
 * ────────────────────────────────────────────────────────────────────────── */

@media (max-width: 640px) {
  :root {
    --text-h1-hero: 52px;
    --text-h1-doc: 42px;
    --text-h2: 32px;
    --text-h3: 22px;
    --text-lede: 18px;
    --text-body: 15px;
    --text-small: 13px;
    --text-eyebrow: 11px;
  }

  section {
    padding: var(--space-6) var(--space-4);
  }

  .nav-secondary {
    padding: var(--space-3) var(--space-4);
  }

  /* Mobile nav: hide brand text, show only logo mark */
  .nav-secondary .nav-brand .brand-text {
    display: none;
  }

  /* Mobile nav-back: show shortened "← RETURN" */
  .nav-back .full-text {
    display: none;
  }

  .nav-back .short-text {
    display: inline;
  }
}

@media (min-width: 641px) {
  .nav-back .short-text {
    display: none;
  }

  .nav-back .full-text {
    display: inline;
  }
}


/* ──────────────────────────────────────────────────────────────────────────
 * 10. PRINT STYLES
 * ────────────────────────────────────────────────────────────────────────── */

@media print {
  nav,
  .nav-secondary,
  .nav-back,
  footer {
    display: none;
  }

  body {
    background: #fff;
  }

  .doc-header {
    padding-top: 40px;
  }
}


/* ──────────────────────────────────────────────────────────────────────────
 * 11. ANIMATION UTILITIES
 * ────────────────────────────────────────────────────────────────────────── */

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.fade-up {
  animation: fadeUp 0.6s ease-out both;
}

.fade-in {
  animation: fadeIn 0.5s ease-out both;
}


/* ──────────────────────────────────────────────────────────────────────────
 * 12. ACCESSIBILITY
 * ────────────────────────────────────────────────────────────────────────── */

/* Focus states */
*:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--gold);
  color: #fff;
  padding: 8px 16px;
  z-index: 999;
}

.skip-link:focus {
  top: 0;
}

/* Screen-reader only */
.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;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
