/* ============================================================
   Infosec Battlebots — Main Stylesheet
   Dual theme: DARK (default) + LIGHT (toggle).

   Brand purple: #6655B5 (from logo mark)
   Dark bg:      #0E0C1A (very dark navy-purple)
   Light bg:     #FFFFFF

   Switching is done by toggling data-theme="light" on <html>.
   Dark mode is the default — no attribute needed.
   ============================================================ */

/* ── DARK MODE — default ── */
:root {
  /* Backgrounds */
  --bg:           #0E0C1A;
  --surface:      #141228;
  --surface-2:    #1C1938;
  --surface-3:    #252248;

  /* Borders */
  --border:       #2E2A52;
  --border-accent:#4A4488;

  /* Text */
  --text:         #E2DEFF;
  --text-muted:   #9B96B8;
  --text-faint:   #564F75;

  /* Brand purple — lightened ~20% for contrast on dark bg */
  --purple:       #9988DD;
  --purple-light: #B0A5EE;
  --purple-dark:  #7B6CC7;
  --purple-xdark: #E2DEFF;   /* "darkest" purple = light on dark bg */
  --purple-glow:  rgba(153,136,221,0.12);
  --logo-grey:    #8E8AAA;

  /* Semantic */
  --green:        #4ADE80;
  --green-bg:     rgba(74,222,128,0.08);
  --green-border: rgba(74,222,128,0.25);

  /* Nav */
  --nav-bg:       rgba(14,12,26,0.96);
  --nav-border:   rgba(153,136,221,0.18);

  /* White always white */
  --white:        #FFFFFF;
}

/* ── LIGHT MODE — applied via data-theme="light" on <html> ── */
[data-theme="light"] {
  --bg:           #FFFFFF;
  --surface:      #F8F7FF;
  --surface-2:    #F0EEF8;
  --surface-3:    #E8E5F4;

  --border:       #E0DCEF;
  --border-accent:#C8C0E8;

  --text:         #1E1B3A;
  --text-muted:   #6B6882;
  --text-faint:   #A8A5C0;

  --purple:       #6655B5;
  --purple-light: #7B6CC7;
  --purple-dark:  #4A3D90;
  --purple-xdark: #1E1B3A;
  --purple-glow:  rgba(102,85,181,0.10);
  --logo-grey:    #A8A5C0;

  --green:        #16A34A;
  --green-bg:     rgba(22,163,74,0.08);
  --green-border: rgba(22,163,74,0.25);

  --nav-bg:       rgba(255,255,255,0.96);
  --nav-border:   #E0DCEF;
}

/* ── Colours that never change with theme (footer / CTA are always dark) ── */
:root {
  --footer-bg:      #1E1B3A;
  --footer-text:    #a8a4cc;
  --footer-muted:   #7a768e;
  --footer-faint:   #555270;
  --footer-border:  rgba(255,255,255,0.06);
  --cta-bg:         #1E1B3A;
}

/* ── Shared design tokens ── */
:root {
  --font-sans:      -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-condensed: 'Arial Narrow', 'Impact', 'Franklin Gothic Medium',
                    'Gill Sans Nova Condensed', Arial, sans-serif;
  --radius:         6px;
  --radius-lg:      12px;
  --shadow-sm:      0 1px 4px rgba(0,0,0,0.2);
  --shadow:         0 4px 20px rgba(0,0,0,0.25);
  --shadow-lg:      0 8px 40px rgba(0,0,0,0.35);
  --shadow-purple:  0 4px 24px rgba(102,85,181,0.22);
  --max-width:      1100px;
  --nav-height:     70px;
  --transition:     0.18s ease;
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  /* Theme transition — smooth swap, but only after first paint */
  transition: background var(--transition), color var(--transition);
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background var(--transition), color var(--transition);
}
main { flex: 1; }
img  { max-width: 100%; height: auto; display: block; }
a    { color: var(--purple); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--purple-light); }

h1, h2, h3, h4, h5, h6 {
  line-height: 1.15; font-weight: 800;
  color: var(--purple-xdark); letter-spacing: -0.02em;
}

.container {
  width: 100%; max-width: var(--max-width);
  margin-inline: auto; padding-inline: 1.25rem;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; gap: 0.4em;
  padding: 0.65em 1.5em;
  border-radius: var(--radius);
  font-weight: 700; font-size: 0.9rem;
  cursor: pointer; transition: all var(--transition);
  border: 2px solid transparent;
  white-space: nowrap; text-decoration: none; line-height: 1.2;
}
.btn:active { transform: translateY(1px); }

.btn--primary  { background: var(--purple); color: var(--white); border-color: var(--purple); }
.btn--primary:hover { background: var(--purple-dark); border-color: var(--purple-dark); color: var(--white); }

.btn--outline  { background: transparent; color: var(--purple); border-color: var(--purple); }
.btn--outline:hover { background: var(--purple-glow); color: var(--purple-light); border-color: var(--purple-light); }

.btn--ghost    { background: transparent; color: var(--text-muted); border-color: var(--border-accent); }
.btn--ghost:hover { color: var(--purple); border-color: var(--purple); }

.btn--sm { padding: 0.4em 0.9em; font-size: 0.82rem; }
.btn--lg { padding: 0.8em 2em;   font-size: 1rem; }

/* Inverted buttons for dark sections */
.btn--inv-outline {
  background: transparent; color: var(--white);
  border-color: rgba(255,255,255,0.35);
}
.btn--inv-outline:hover {
  background: rgba(255,255,255,0.08); color: var(--white);
  border-color: rgba(255,255,255,0.7);
}

/* ============================================================
   TAGS / CHIPS
   ============================================================ */
.tag {
  display: inline-block; padding: 0.2em 0.7em;
  border-radius: 999px; font-size: 0.74rem; font-weight: 600;
  background: var(--surface-2); color: var(--text-muted);
  border: 1px solid var(--border);
}
.tag--type      { background: var(--purple-glow); color: var(--purple); border-color: var(--border-accent); }
.tag--confirmed { background: var(--green-bg);    color: var(--green);  border-color: var(--green-border); }

.back-link { display: inline-block; color: var(--text-muted); font-size: 0.9rem; margin-bottom: 2rem; }
.back-link:hover { color: var(--purple); }

/* ============================================================
   THEME TOGGLE BUTTON
   ============================================================ */
.theme-toggle {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  border: 1.5px solid var(--border-accent);
  border-radius: var(--radius);
  background: var(--surface-2);
  cursor: pointer;
  font-size: 1rem; line-height: 1;
  transition: background var(--transition), border-color var(--transition), transform var(--transition);
  flex-shrink: 0;
}
.theme-toggle:hover { background: var(--surface-3); border-color: var(--purple); }
.theme-toggle:active { transform: scale(0.92); }

/* Show moon on dark, sun on light */
.theme-toggle__moon { display: block; }
.theme-toggle__sun  { display: none;  }
[data-theme="light"] .theme-toggle__moon { display: none;  }
[data-theme="light"] .theme-toggle__sun  { display: block; }

/* ============================================================
   NAVIGATION
   ============================================================ */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--nav-border);
  height: var(--nav-height);
  transition: background var(--transition), border-color var(--transition);
}

.nav {
  max-width: var(--max-width); margin-inline: auto;
  padding-inline: 1.25rem; height: 100%;
  display: flex; align-items: center;
  justify-content: space-between; gap: 1rem;
}

.nav__logo { display: flex; align-items: center; flex-shrink: 0; }
.nav__logo-img {
  height: 44px; width: auto;
  transition: filter var(--transition);
}
/* On dark mode: boost the desaturated logo so it reads on dark bg */
.nav__logo-img { filter: brightness(2.5) contrast(0.8); }
[data-theme="light"] .nav__logo-img { filter: none; }

.nav__menu { display: flex; align-items: center; list-style: none; gap: 0.15rem; }
.nav__link {
  display: block; padding: 0.45em 0.8em;
  border-radius: var(--radius);
  color: var(--text-muted); font-size: 0.88rem; font-weight: 600;
  transition: color var(--transition), background var(--transition);
}
.nav__link:hover, .nav__link--active { color: var(--purple); background: var(--purple-glow); }

.nav__item--cta { margin-left: 0.25rem; }

/* Controls wrapper (theme toggle + hamburger) */
.nav__controls {
  display: flex; align-items: center; gap: 0.5rem; flex-shrink: 0;
}

/* Mobile toggle */
.nav__toggle {
  display: none; flex-direction: column; justify-content: center;
  gap: 5px; width: 38px; height: 38px;
  background: none; border: 1.5px solid var(--border-accent);
  border-radius: var(--radius); cursor: pointer; padding: 7px;
}
.nav__toggle span { display: block; height: 2px; background: var(--purple); border-radius: 2px; }

@media (max-width: 820px) {
  .nav__toggle { display: flex; }
  .nav__menu {
    display: none; position: absolute; top: var(--nav-height); left: 0; right: 0;
    background: var(--nav-bg); border-bottom: 2px solid var(--purple);
    backdrop-filter: blur(10px);
    flex-direction: column; align-items: stretch; padding: 1rem; gap: 0.25rem;
  }
  .nav__menu--open { display: flex; }
  .nav__link { padding: 0.7em 1em; }
  .nav__item--cta { margin-left: 0; margin-top: 0.5rem; }
  .nav__item--cta .btn { width: 100%; justify-content: center; }
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative; overflow: hidden;
  padding: 5.5rem 0 5rem;
  background: var(--bg);
  transition: background var(--transition);
}

.hero__scanlines {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: 0.5;
  transition: opacity var(--transition);
}

/* Radial fade over the grid */
.hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 80% 70% at 50% 50%, var(--bg) 30%, transparent 100%);
}

.hero__inner {
  position: relative; z-index: 1;
  display: flex; flex-direction: column;
  align-items: center; text-align: center; gap: 1.75rem;
}

.hero__eyebrow {
  display: inline-flex; align-items: center; gap: 0.5em;
  background: var(--purple-glow); border: 1.5px solid var(--border-accent);
  border-radius: 999px; padding: 0.3em 1.1em;
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em;
  color: var(--purple); text-transform: uppercase;
}
.hero__eyebrow-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--purple); animation: pulse 2.2s infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.2; } }

.hero__mark {
  width: 90px; height: auto;
  /* The PNG is the full vibrant purple mark — works on both themes */
  transition: filter var(--transition);
}
/* On light mode: darken slightly so it reads on near-white bg */
[data-theme="light"] .hero__mark { filter: brightness(0.88) saturate(1.1); }

.hero__title {
  display: flex; flex-direction: column; align-items: center; gap: 0; line-height: 1;
}
.hero__title-top {
  font-family: var(--font-condensed);
  font-size: clamp(1.2rem, 4vw, 2rem);
  font-weight: 400; letter-spacing: 0.38em;
  text-transform: uppercase; color: var(--text-muted);
}
.hero__title-bottom {
  font-family: var(--font-condensed);
  font-size: clamp(3.5rem, 12vw, 7.5rem);
  font-weight: 900; letter-spacing: -0.02em;
  text-transform: uppercase; color: var(--purple-xdark); line-height: 0.9;
}
.hero__title-bottom em { font-style: normal; color: var(--purple); }

.hero__tagline {
  font-size: clamp(0.95rem, 2.5vw, 1.1rem);
  color: var(--text-muted); font-style: italic; max-width: 440px;
}
.hero__sub {
  max-width: 560px; color: var(--text-muted);
  font-size: 0.98rem; line-height: 1.75;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; justify-content: center; }

/* ============================================================
   SECTIONS
   ============================================================ */
.section { padding: 5rem 0; transition: background var(--transition); }

.section--alt {
  background: var(--surface);
  border-block: 1px solid var(--border);
}

/* Always-dark sections — never change with theme */
.section--dark {
  background: var(--cta-bg);
  border-block: none;
}
.section--dark .section__title,
.section--dark h3          { color: var(--white); }
.section--dark p, .section--dark li { color: #a8a4cc; }

.section__title { font-size: clamp(1.5rem, 3.5vw, 2.1rem); margin-bottom: 0.5rem; }
.section__sub   { color: var(--text-muted); margin-bottom: 2.5rem; font-size: 0.95rem; }
.section--dark .section__sub { color: #a8a4cc; }
.section__cta   { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; margin-top: 2.5rem; }

.section__title-accent {
  display: block; width: 44px; height: 4px;
  background: var(--purple); border-radius: 2px; margin-bottom: 1.25rem;
}

/* ============================================================
   WHAT WE DO CARDS
   ============================================================ */
.what-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 1.25rem;
}
.what-card {
  background: var(--surface-2); border: 1.5px solid var(--border);
  border-radius: var(--radius-lg); padding: 1.5rem;
  transition: border-color var(--transition), box-shadow var(--transition),
              transform var(--transition), background var(--transition);
}
.what-card:hover {
  border-color: var(--purple); box-shadow: var(--shadow-purple);
  transform: translateY(-2px);
}
.what-card__icon { font-size: 1.8rem; margin-bottom: 0.75rem; display: block; }
.what-card h3 { font-size: 1rem; margin-bottom: 0.5rem; }
.what-card p  { font-size: 0.88rem; color: var(--text-muted); line-height: 1.65; }

/* ============================================================
   TEAM CLASSES (Blue / Purple / Red)
   ============================================================ */
.classes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}
.class-card {
  background: var(--surface-2); border: 1.5px solid var(--border);
  border-radius: var(--radius-lg); padding: 1.75rem;
  display: flex; flex-direction: column; gap: 0.75rem;
  transition: transform var(--transition), box-shadow var(--transition),
              background var(--transition), border-color var(--transition);
}
.class-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

/* Top accent — team colours */
.class-card--blue   { border-top: 4px solid #3B82F6; }
.class-card--purple { border-top: 4px solid var(--purple); }
.class-card--red    { border-top: 4px solid #EF4444; }

.class-card__hat   { font-size: 2rem; }
.class-card__name  { font-size: 1.3rem; }
.class-card__sub   { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-faint); margin-top: -0.4rem; }
.class-card__rules {
  list-style: none; display: flex; flex-direction: column; gap: 0.35rem;
  border-top: 1px solid var(--border); padding-top: 0.75rem;
}
.class-card__rules li { font-size: 0.87rem; color: var(--text-muted); padding-left: 1.1em; position: relative; }
.class-card__rules li::before { content: '›'; position: absolute; left: 0; color: var(--purple); font-weight: 700; }
.class-card__who { font-size: 0.83rem; color: var(--text-faint); font-style: italic; margin-top: auto; padding-top: 0.5rem; border-top: 1px solid var(--border); }

/* ============================================================
   MODES (Conference Village vs BotBash)
   ============================================================ */
.modes-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
@media (max-width: 680px) { .modes-grid { grid-template-columns: 1fr; } }

.mode-card {
  background: var(--surface-2); border: 1.5px solid var(--border);
  border-radius: var(--radius-lg); padding: 1.75rem;
  display: flex; flex-direction: column; gap: 0.75rem;
  transition: background var(--transition), border-color var(--transition);
}
.mode-card--highlight { border-color: var(--purple); box-shadow: var(--shadow-purple); }
.mode-card h3 { font-size: 1.1rem; }
.mode-card p  { font-size: 0.9rem; color: var(--text-muted); flex: 1; line-height: 1.7; }

/* ============================================================
   EVENTS
   ============================================================ */
.events-list { display: flex; flex-direction: column; gap: 1rem; }
.events-list--full { max-width: 780px; }

.event-card {
  background: var(--surface-2); border: 1.5px solid var(--border);
  border-left: 4px solid var(--purple);
  border-radius: var(--radius-lg); padding: 1.25rem 1.5rem;
  display: flex; flex-direction: column; gap: 0.4rem;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
}
.event-card:hover { box-shadow: var(--shadow-purple); transform: translateX(3px); }

.event-card__meta    { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 0.15rem; }
.event-card__name    { font-size: 1.15rem; }
.event-card__name a  { color: var(--purple-xdark); }
.event-card__name a:hover { color: var(--purple); }
.event-card__detail  { font-size: 0.88rem; color: var(--text-muted); }

.empty-state { color: var(--text-muted); font-size: 0.95rem; }
.empty-state a { color: var(--purple); }

/* ============================================================
   TEAMS
   ============================================================ */
.teams-list { display: flex; flex-direction: column; gap: 1rem; }
.team-entry {
  background: var(--surface-2); border: 1.5px solid var(--border);
  border-radius: var(--radius-lg); padding: 1.25rem 1.5rem;
  display: flex; flex-direction: column; gap: 0.5rem;
  transition: background var(--transition);
}
.team-entry__name a { color: var(--purple-xdark); }
.team-entry__name a:hover { color: var(--purple); }
.team-entry__desc { font-size: 0.9rem; color: var(--text-muted); }

/* ============================================================
   GALLERY
   ============================================================ */
.gallery {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 0.5rem;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

/* Wide image spans full left column, both rows */
.gallery__item--wide {
  grid-row: 1 / 3;
}

/* Full-width banner strip — spans all columns */
.gallery__item--banner {
  grid-column: 1 / -1;
  min-height: 220px;
  max-height: 320px;
}

/* All items */
.gallery__item {
  position: relative;
  overflow: hidden;
  display: block;
  background: var(--surface-3);
  cursor: zoom-in;
  /* minimum height so short-ratio images don't collapse */
  min-height: 200px;
}

.gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease, filter 0.35s ease;
}

/* Caption overlay */
.gallery__caption {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 0.6rem 0.9rem;
  background: linear-gradient(transparent, rgba(14,12,26,0.88));
  color: #e2deff;
  font-size: 0.78rem;
  font-weight: 600;
  transform: translateY(100%);
  transition: transform 0.25s ease;
}

.gallery__item:hover img       { transform: scale(1.04); filter: brightness(0.85); }
.gallery__item:hover .gallery__caption { transform: translateY(0); }

/* On light mode — darken the caption bg slightly less */
[data-theme="light"] .gallery__caption {
  background: linear-gradient(transparent, rgba(20,16,48,0.82));
}

/* Responsive: stack to 2-col then 1-col on small screens */
@media (max-width: 860px) {
  .gallery {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }
  .gallery__item--wide   { grid-row: auto; grid-column: 1 / 3; }
  .gallery__item--banner { grid-column: 1 / 3; }
}
@media (max-width: 480px) {
  .gallery { grid-template-columns: 1fr; }
  .gallery__item--wide   { grid-column: auto; }
  .gallery__item--banner { grid-column: auto; max-height: none; }
  .gallery__caption { transform: translateY(0); } /* always show on touch */
}

/* ============================================================
   ILLUSTRATION BREAK
   ============================================================ */
.section--illus {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.illus-break {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.illus-break__text h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  margin-bottom: 1rem;
}

.illus-break__text p {
  color: var(--text-muted);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.illus-break__image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-lg);
  /* Subtle lift */
  filter: drop-shadow(0 8px 32px rgba(102,85,181,0.18));
}

@media (max-width: 768px) {
  .illus-break {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .illus-break__image { order: -1; }
}

/* ============================================================
   HISTORY / TIMELINE
   ============================================================ */
.history-strip { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
@media (max-width: 768px) { .history-strip { grid-template-columns: 1fr; gap: 2rem; } }
.history-strip__text h2 { margin-bottom: 1rem; }
.history-strip__text p  { color: var(--text-muted); margin-bottom: 1rem; font-size: 0.95rem; }

.timeline { display: flex; flex-direction: column; }
.timeline-item { display: flex; gap: 1.25rem; align-items: flex-start; padding: 1rem 0; border-bottom: 1px solid var(--border); }
.timeline-item:last-child { border-bottom: none; }
.timeline-item__year {
  font-size: 0.8rem; font-weight: 800;
  color: var(--white); background: var(--purple);
  padding: 0.2em 0.6em; border-radius: var(--radius);
  min-width: 44px; text-align: center; flex-shrink: 0; margin-top: 0.2rem;
}
.timeline-item p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }

/* ============================================================
   CTA SECTION — always dark
   ============================================================ */
.cta-section { background: var(--cta-bg); text-align: center; }
.cta-section__inner { display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.cta-section h2 { font-size: clamp(1.5rem, 4vw, 2.2rem); color: var(--white); }
.cta-section p  { color: #a8a4cc; }

/* ============================================================
   GENERIC PAGE
   ============================================================ */
.page { padding-block: 3rem 4rem; }
.page__header { margin-bottom: 2rem; border-bottom: 2px solid var(--border); padding-bottom: 1.5rem; }
.page__title { font-size: clamp(1.8rem, 5vw, 2.8rem); }
.page__description { color: var(--text-muted); margin-top: 0.5rem; font-size: 1.05rem; }

/* ============================================================
   PROSE
   ============================================================ */
.prose { color: var(--text); }
.prose h2 { font-size: 1.35rem; border-bottom: 1px solid var(--border); padding-bottom: 0.4rem; margin-top: 2.25rem; margin-bottom: 0.75rem; }
.prose h3 { font-size: 1.05rem; color: var(--purple); margin-top: 1.75rem; margin-bottom: 0.6rem; }
.prose p  { margin-bottom: 1rem; color: var(--text-muted); line-height: 1.75; }
.prose strong { color: var(--purple-xdark); }
.prose a  { color: var(--purple); text-decoration: underline; text-underline-offset: 3px; }
.prose a:hover { color: var(--purple-light); }
.prose ul, .prose ol { padding-left: 1.5rem; margin-bottom: 1rem; }
.prose li { margin-bottom: 0.4rem; color: var(--text-muted); }
.prose code {
  font-size: 0.875em; background: var(--surface-3);
  padding: 0.15em 0.45em; border-radius: 4px;
  color: var(--purple-light); border: 1px solid var(--border);
}
.prose pre { background: var(--surface-3); border-radius: var(--radius); padding: 1rem 1.25rem; overflow-x: auto; margin-bottom: 1rem; }
.prose pre code { background: none; padding: 0; border: none; color: var(--text); }
.prose table { width: 100%; border-collapse: collapse; margin-bottom: 1.5rem; font-size: 0.9rem; }
.prose th { background: var(--surface-2); text-align: left; padding: 0.65rem 1rem; border-bottom: 2px solid var(--purple); color: var(--purple-xdark); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.06em; }
.prose td { padding: 0.65rem 1rem; border-bottom: 1px solid var(--border); color: var(--text-muted); }
.prose tr:hover td { background: var(--surface-2); }
.prose hr { border: none; border-top: 1px solid var(--border); margin: 2.5rem 0; }
.prose blockquote { border-left: 4px solid var(--purple); padding: 0.75rem 1.25rem; background: var(--purple-glow); margin: 1.5rem 0; border-radius: 0 var(--radius) var(--radius) 0; }
.prose blockquote p { color: var(--text); margin-bottom: 0; }
/* Inline page photos (used in content markdown) */
.page-photo,
.prose figure {
  margin: 1.5rem 0 2rem;
}
.page-photo img,
.prose figure img {
  width: 100%;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}
.page-photo figcaption,
.prose figure figcaption {
  font-size: 0.78rem;
  color: var(--text-faint);
  margin-top: 0.5rem;
  text-align: center;
  font-style: italic;
}

.page-list { list-style: none; display: flex; flex-direction: column; gap: 1rem; }
.page-list__link { font-size: 1.05rem; font-weight: 700; color: var(--purple); }
.page-list__link:hover { color: var(--purple-light); }
.page-list__desc { font-size: 0.9rem; color: var(--text-muted); }

/* ============================================================
   FOOTER — always dark, never changes with theme
   ============================================================ */
.site-footer { background: var(--footer-bg); padding: 3.5rem 0 2rem; margin-top: auto; color: var(--footer-text); }
.footer__inner { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 2rem 3rem; }
@media (max-width: 680px) { .footer__inner { grid-template-columns: 1fr; } }

.footer__logo-wrap { display: inline-flex; align-items: center; gap: 1rem; text-decoration: none; margin-bottom: 0.75rem; }
.footer__logo-mark { height: 52px; width: auto; filter: brightness(0) invert(1) opacity(0.85); }
.footer__logo-text { display: flex; flex-direction: column; gap: 0; font-family: var(--font-condensed); text-transform: uppercase; }
.footer__logo-top    { font-size: 0.72rem; letter-spacing: 0.3em; color: var(--footer-muted); font-weight: 400; }
.footer__logo-bottom { font-size: 1.25rem; letter-spacing: 0.04em; color: var(--white); font-weight: 900; line-height: 1; }
.footer__tagline { color: var(--footer-faint); font-size: 0.85rem; font-style: italic; margin-bottom: 0.35rem; }
.footer__copy    { color: var(--footer-faint); font-size: 0.78rem; }

.footer__nav-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--footer-faint); margin-bottom: 0.75rem; font-weight: 700; }
.footer__nav { display: flex; flex-direction: column; gap: 0.4rem; }
.footer__link { color: var(--footer-muted); font-size: 0.88rem; }
.footer__link:hover { color: var(--white); }
.footer__social { display: flex; flex-direction: column; gap: 0.5rem; }
.footer__social-link { display: flex; align-items: center; gap: 0.5em; color: var(--footer-muted); font-size: 0.88rem; }
.footer__social-link:hover { color: var(--white); }

/* ============================================================
   RESPONSIVE & A11Y
   ============================================================ */
@media (max-width: 480px) { .hero { padding: 3.5rem 0 3rem; } .section { padding: 3rem 0; } }
:focus-visible { outline: 2px solid var(--purple); outline-offset: 3px; }
.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; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .hero__eyebrow-dot { animation: none; }
  html { scroll-behavior: auto; }
}
