/* ═══════════════════════════════════════════
   REPORT PAGES — Market Intelligence
   Style: Warm Black Luxury · Vibrant Gold · Glass
   Typography: Cormorant Garamond (display) + IBM Plex Sans (body)
═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400&display=swap');

:root {
  /* Warm black — no blue tint */
  --bg:           #080808;
  --surface-1:    #0E0E0E;
  --surface-2:    #141414;
  --surface-3:    #1C1C1C;
  --surface-4:    #242424;

  /* Vibrant gold palette */
  --gold:         #C9A84C;
  --gold-bright:  #F5C842;
  --gold-light:   #E8C96A;
  --gold-warm:    #D4A030;
  --gold-glow:    rgba(232,201,106,0.30);
  --gold-glow-sm: rgba(201,168,76,0.18);
  --gold-dim:     rgba(201,168,76,0.10);
  --gold-border:  rgba(201,168,76,0.22);
  --gold-hard:    rgba(201,168,76,0.50);

  /* Glass amber surface */
  --glass-bg:     rgba(201,168,76,0.05);
  --glass-border: rgba(201,168,76,0.18);

  /* Weekend blue accent */
  --blue:         #7B9ED4;
  --blue-dim:     rgba(123,158,212,0.10);
  --blue-border:  rgba(123,158,212,0.28);

  /* Text */
  --text:         #F4EFE6;
  --text-2:       rgba(244,239,230,0.92);
  --text-3:       rgba(244,239,230,0.55);
  --text-4:       rgba(244,239,230,0.30);

  /* Data colours — vibrant */
  --green:        #34D399;
  --green-dim:    rgba(52,211,153,0.10);
  --red:          #F87171;
  --red-dim:      rgba(248,113,113,0.10);

  /* Structure */
  --divider:      rgba(244,239,230,0.06);
  --divider-hard: rgba(244,239,230,0.12);

  /* Typography */
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body:    'IBM Plex Sans', 'Montserrat', sans-serif;
  --font-mono:    'IBM Plex Mono', 'Courier New', monospace;

  --ease:         cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out:     cubic-bezier(0, 0, 0.2, 1);
  --nav-h:        62px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1.05rem;
  line-height: 1.85;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Warm grain texture */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  pointer-events: none; z-index: 9998; opacity: 0.4;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
}

a { color: var(--gold); text-decoration: none; transition: color 0.2s var(--ease); }
a:hover { color: var(--gold-light); }
a:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 2px; }

/* ════════════════════════════════════════
   READ PROGRESS BAR
════════════════════════════════════════ */
#read-progress {
  position: fixed; top: var(--nav-h); left: 0; right: 0;
  height: 2px; z-index: 600;
}
#read-progress-fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--gold-warm), var(--gold-bright), var(--gold-light));
  transition: width 0.08s linear;
  box-shadow: 0 0 12px var(--gold-glow);
}

/* ════════════════════════════════════════
   NAV
════════════════════════════════════════ */
.report-nav {
  position: sticky; top: 0; z-index: 500;
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 56px;
  background: rgba(8,8,8,0.96);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--gold-border);
}
.report-nav-logo {
  font-family: var(--font-display);
  font-size: 1.45rem; font-weight: 600;
  color: var(--gold); letter-spacing: 0.06em;
  cursor: pointer;
  text-shadow: 0 0 20px var(--gold-glow-sm);
}
.report-nav-links { display: flex; gap: 32px; list-style: none; }
.report-nav-links a {
  color: var(--text-3); font-size: 0.7rem;
  font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
  transition: color 0.2s var(--ease);
}
.report-nav-links a:hover { color: var(--gold); }

/* ════════════════════════════════════════
   ARCHIVE PAGE
════════════════════════════════════════ */
.archive-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  padding: 72px 56px 120px;
}

.archive-hero {
  margin-bottom: 60px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--divider);
  position: relative;
}

/* Warm radial glow behind title */
.archive-hero::before {
  content: '';
  position: absolute;
  top: -20px; left: -40px;
  width: 500px; height: 300px;
  background: radial-gradient(ellipse at 30% 50%, rgba(201,168,76,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.archive-label {
  font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 16px;
  position: relative;
}
.archive-title {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 5vw, 4.2rem);
  font-weight: 300; line-height: 1.1; color: var(--text);
  position: relative;
}
.archive-title em {
  font-style: italic; color: var(--gold-light);
  text-shadow: 0 0 40px var(--gold-glow);
}
.archive-subtitle {
  color: var(--text-3); margin-top: 14px;
  font-size: 0.84rem; font-weight: 300; letter-spacing: 0.02em;
  position: relative;
}

/* Stats strip */
.archive-stats {
  display: flex; gap: 0; margin-top: 40px; flex-wrap: wrap;
  border: 1px solid var(--gold-border);
  border-radius: 4px; overflow: hidden;
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  position: relative;
  width: fit-content;
}
.archive-stat {
  padding: 20px 40px;
  border-right: 1px solid var(--gold-border);
  text-align: center;
}
.archive-stat:last-child { border-right: none; }
.archive-stat-val {
  display: block;
  font-family: var(--font-display);
  font-size: 2.4rem; font-weight: 400; color: var(--gold-light);
  line-height: 1;
  text-shadow: 0 0 24px var(--gold-glow);
}
.archive-stat-label {
  font-size: 0.64rem; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-4); margin-top: 6px; display: block;
}

/* Filter tabs */
.archive-filters {
  display: flex; gap: 8px; margin-bottom: 28px; flex-wrap: wrap;
}
.filter-btn {
  padding: 7px 20px;
  border: 1px solid var(--divider-hard);
  background: transparent; color: var(--text-3);
  border-radius: 2px; cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  transition: all 0.22s var(--ease);
}
.filter-btn:hover { background: var(--gold-dim); color: var(--text-2); border-color: var(--gold-border); }
.filter-btn.active { background: var(--gold-dim); color: var(--gold); border-color: var(--gold-hard); }
.filter-btn.weekend-btn.active { background: var(--blue-dim); color: var(--blue); border-color: var(--blue-border); }
.filter-btn:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* Report grid */
.archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(420px, 1fr));
  gap: 14px;
}

/* Archive card — glass + warm glow on hover */
.archive-card {
  display: flex; flex-direction: column; gap: 12px;
  padding: 26px 28px;
  background: var(--surface-1);
  border: 1px solid var(--divider);
  border-radius: 4px;
  text-decoration: none; color: inherit;
  cursor: pointer;
  position: relative; overflow: hidden;
  transition: border-color 0.25s var(--ease),
              background 0.25s var(--ease),
              transform 0.2s var(--ease-out),
              box-shadow 0.25s var(--ease);
}
/* Animated gold shimmer on hover */
.archive-card::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, transparent 40%, rgba(201,168,76,0.05) 60%, transparent 80%);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
  pointer-events: none;
}
/* Left accent bar */
.archive-card::after {
  content: '';
  position: absolute; top: 0; left: 0;
  width: 3px; height: 100%;
  background: linear-gradient(180deg, var(--gold-bright), var(--gold-warm));
  transform: scaleY(0); transform-origin: top;
  transition: transform 0.3s var(--ease-out);
}
.archive-card.weekend-card::after {
  background: linear-gradient(180deg, #A8C4E8, var(--blue));
}
.archive-card:hover {
  border-color: var(--gold-border);
  background: var(--surface-2);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.5), 0 0 30px var(--gold-glow-sm);
}
.archive-card.weekend-card:hover {
  box-shadow: 0 12px 40px rgba(0,0,0,0.5), 0 0 24px rgba(123,158,212,0.12);
}
.archive-card:hover::before { opacity: 1; }
.archive-card:hover::after { transform: scaleY(1); }

.archive-card-top {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 12px;
}
.archive-card-date {
  font-size: 0.82rem; font-weight: 500;
  color: var(--text-2); letter-spacing: 0.02em; white-space: nowrap;
}
.archive-card-badge {
  font-size: 0.58rem; font-weight: 600;
  letter-spacing: 0.15em; text-transform: uppercase;
  padding: 3px 10px; border-radius: 2px; white-space: nowrap;
}
.badge-weekday { background: var(--gold-dim); color: var(--gold); border: 1px solid var(--gold-border); }
.badge-weekend { background: var(--blue-dim); color: var(--blue); border: 1px solid var(--blue-border); }

.archive-card-title {
  font-size: 0.84rem; font-weight: 300; color: var(--text-2);
  line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}
.archive-card-arrow {
  font-size: 0.67rem; font-weight: 500; color: var(--text-4);
  letter-spacing: 0.12em; text-transform: uppercase;
  display: flex; align-items: center; gap: 6px;
  align-self: flex-end;
  transition: color 0.2s, gap 0.2s;
}
.archive-card:hover .archive-card-arrow { color: var(--gold-light); gap: 10px; }

/* ════════════════════════════════════════
   INDIVIDUAL REPORT — SINGLE COLUMN LAYOUT
════════════════════════════════════════ */
.report-page {
  min-height: calc(100vh - var(--nav-h));
}

/* ── Report Header ── */
.report-header {
  padding: 52px 56px 40px;
  border-bottom: 1px solid var(--divider);
  background: linear-gradient(180deg, var(--surface-1) 0%, var(--bg) 100%);
  position: relative;
  overflow: hidden;
}
/* Warm glow */
.report-header::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(ellipse at 15% 60%, rgba(201,168,76,0.07) 0%, transparent 60%);
  pointer-events: none;
}
.report-header-inner {
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
}
.report-back-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 24px;
  transition: color 0.2s;
}
.report-back-link:hover { color: var(--gold); }
.report-header-eyebrow {
  font-size: 0.65rem; font-weight: 600;
  letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 12px;
}
.report-header-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 300; line-height: 1.1; color: var(--text);
  text-shadow: 0 2px 40px rgba(0,0,0,0.8);
  margin-bottom: 16px;
}
.report-header-badge {
  display: inline-block;
  font-size: 0.6rem; font-weight: 600;
  letter-spacing: 0.15em; text-transform: uppercase;
  padding: 4px 12px; border-radius: 2px;
}

/* ── Report Body ── */
.report-body {
  padding: 56px 56px 120px;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg) 100%);
}

/* ════════════════════════════════════════
   REPORT CONTENT
════════════════════════════════════════ */
.report-content {
  max-width: 1100px;
  margin: 0 auto;
}

/* Executive briefing */
.report-content .exec-brief {
  font-size: 0.96rem; font-weight: 300;
  line-height: 1.85; color: var(--text-2);
  background: linear-gradient(135deg,
    rgba(201,168,76,0.06) 0%,
    rgba(201,168,76,0.03) 50%,
    transparent 100%);
  border-left: 3px solid var(--gold);
  padding: 28px 32px 26px;
  border-radius: 0 6px 6px 0;
  margin-bottom: 48px;
  position: relative;
  box-shadow: inset 0 1px 0 rgba(201,168,76,0.12),
              0 4px 32px rgba(0,0,0,0.3);
}
.report-content .exec-brief::before {
  content: 'Executive Briefing';
  position: absolute; top: -10px; left: 32px;
  font-size: 0.57rem; font-weight: 700;
  letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--gold);
  background: var(--surface-2);
  padding: 2px 10px;
  border: 1px solid var(--gold-border);
  border-radius: 2px;
}

/* Section headings with gold underline glow */
.report-content h2 {
  font-family: var(--font-display);
  font-size: 1.7rem; font-weight: 400;
  color: var(--text);
  margin: 64px 0 22px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--divider);
  letter-spacing: 0.01em;
  scroll-margin-top: calc(var(--nav-h) + 20px);
  position: relative;
}
/* Gold accent line under h2 */
.report-content h2::after {
  content: '';
  position: absolute; bottom: -1px; left: 0;
  width: 60px; height: 1px;
  background: linear-gradient(90deg, var(--gold), transparent);
  box-shadow: 0 0 8px var(--gold-glow-sm);
}
.report-content h2:first-child { margin-top: 0; }

.report-content h3 {
  font-family: var(--font-display);
  font-size: 1.2rem; font-weight: 400;
  color: var(--gold-light);
  margin: 40px 0 14px;
  scroll-margin-top: calc(var(--nav-h) + 20px);
}
.report-content h4 {
  font-size: 0.67rem; font-weight: 700;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--text-3); margin: 28px 0 10px;
}

.report-content p {
  color: var(--text-2); margin-bottom: 20px;
  line-height: 1.9; font-weight: 300;
}
.report-content strong { font-weight: 600; color: var(--text); }
.report-content em { font-style: italic; color: var(--gold-light); }
.report-content hr { border: none; border-top: 1px solid var(--divider); margin: 44px 0; }
.report-content ul, .report-content ol { padding-left: 22px; margin-bottom: 20px; }
.report-content li { color: var(--text-2); margin-bottom: 8px; line-height: 1.85; }

/* ── Tables — warm gold-tinted header ── */
.table-wrap {
  width: 100%; overflow-x: auto; margin: 20px 0 32px;
  border: 1px solid var(--gold-border); border-radius: 6px;
  background: var(--surface-1);
  box-shadow: 0 4px 24px rgba(0,0,0,0.3), inset 0 1px 0 rgba(201,168,76,0.08);
  -webkit-overflow-scrolling: touch;
}
.report-content table {
  width: 100%; border-collapse: collapse; font-size: 0.82rem;
  font-family: var(--font-body);
}
.report-content thead th {
  background: linear-gradient(180deg,
    rgba(201,168,76,0.12) 0%,
    rgba(201,168,76,0.06) 100%);
  color: var(--gold);
  font-size: 0.62rem; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase;
  padding: 13px 18px; text-align: left;
  border-bottom: 1px solid var(--gold-border);
  white-space: nowrap;
}
.report-content tbody tr {
  border-bottom: 1px solid var(--divider);
  transition: background 0.15s;
}
.report-content tbody tr:last-child { border-bottom: none; }
.report-content tbody tr:hover { background: rgba(201,168,76,0.04); }
.report-content tbody td {
  padding: 10px 18px; color: var(--text-2); vertical-align: top;
  font-weight: 300;
}
.report-content table td:nth-child(2),
.report-content table td:nth-child(3),
.report-content table td:nth-child(4) {
  text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap;
}

.report-content blockquote {
  border-left: 3px solid var(--gold);
  padding: 18px 24px; margin: 24px 0;
  background: linear-gradient(135deg, rgba(201,168,76,0.05), transparent);
  color: var(--text-2); font-style: italic; font-weight: 300;
  border-radius: 0 4px 4px 0;
}
.report-content code {
  background: var(--surface-3); color: var(--gold-light);
  padding: 2px 7px; border-radius: 3px;
  font-size: 0.82em; font-family: var(--font-mono);
}

/* ════════════════════════════════════════
   BACK TO TOP
════════════════════════════════════════ */
#back-top {
  position: fixed; bottom: 32px; right: 32px;
  width: 42px; height: 42px;
  background: var(--surface-3);
  border: 1px solid var(--gold-border);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--gold); font-size: 0.9rem;
  cursor: pointer; z-index: 400;
  opacity: 0; transform: translateY(12px);
  transition: opacity 0.25s, transform 0.25s, background 0.2s, box-shadow 0.2s;
  pointer-events: none;
}
#back-top.visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
#back-top:hover {
  background: var(--gold-dim);
  box-shadow: 0 0 20px var(--gold-glow), 0 4px 16px rgba(0,0,0,0.4);
}
#back-top:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

/* ════════════════════════════════════════
   FOOTER
════════════════════════════════════════ */
.report-footer {
  padding: 28px 56px;
  border-top: 1px solid var(--divider);
  display: flex; justify-content: space-between; align-items: center;
  color: var(--text-4); font-size: 0.72rem;
  letter-spacing: 0.06em; font-weight: 300;
  max-width: 1500px; margin: 0 auto;
}

/* ════════════════════════════════════════
   RESPONSIVE
════════════════════════════════════════ */
@media (max-width: 768px) {
  .report-nav { padding: 0 24px; }
  .report-nav-links { gap: 20px; }
  .archive-wrapper { padding: 48px 24px 80px; }
  .archive-grid { grid-template-columns: 1fr; }
  .archive-stats { width: 100%; }
  .archive-stat { flex: 1; padding: 16px 20px; }
  .report-header { padding: 36px 24px 28px; }
  .report-body { padding: 36px 24px 80px; }
  .report-footer { flex-direction: column; gap: 8px; text-align: center; padding: 24px; }
  #back-top { bottom: 20px; right: 20px; }
}
@media (max-width: 480px) {
  .archive-grid { grid-template-columns: 1fr; gap: 10px; }
  .report-content table { font-size: 0.82rem; }
  .report-content thead th, .report-content tbody td { padding: 8px 12px; }
  .report-header { padding: 28px 16px 24px; }
  .report-body { padding: 24px 16px 80px; }
}
