@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&display=swap');

/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 17px;
  scroll-behavior: smooth;
  background: #000;
  color: #fff;
}

body {
  font-family: 'Space Grotesk', system-ui, -apple-system, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  background: #000;
  color: #fff;
  overflow-x: hidden;
}

/* ── Typography ── */
h1, h2, h3, h4 {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

h1 { font-size: clamp(2rem, 6vw, 5rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2.4rem); margin-bottom: 0.25em; }
h3 { font-size: clamp(1.1rem, 2vw, 1.5rem); }

p { margin-bottom: 1rem; }

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

a:hover { text-decoration: underline; }

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

time { font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.6; display: block; margin-bottom: 0.5rem; }

/* ── Layout: Site Wrapper ── */
.site-wrapper {
  display: grid;
  grid-template-columns: 240px 1fr;
  min-height: 100vh;
}

/* ── Aside Nav (Left Sidebar) ── */
.site-aside-nav {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  background: #000;
  border-right: 1px solid #222;
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  z-index: 100;
}

.site-aside-nav nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.site-aside-nav nav ul li a {
  display: block;
  padding: 0.65rem 0;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-bottom: 1px solid #1a1a1a;
  transition: color 0.15s, padding-left 0.15s;
}

.site-aside-nav nav ul li a:hover,
.site-aside-nav nav ul li a[aria-current="page"] {
  color: #fff;
  padding-left: 0.5rem;
  text-decoration: none;
  border-bottom-color: #fff;
}

.site-aside-nav nav ul li a[aria-current="page"] {
  border-bottom-color: #fff;
}

/* Search */
.search-wrap { margin-top: auto; }
.search-wrap form {
  display: flex;
  gap: 0;
  border: 1px solid #333;
}
.search-wrap input {
  flex: 1;
  background: transparent;
  border: none;
  color: #fff;
  font-family: inherit;
  font-size: 0.8rem;
  padding: 0.5rem 0.75rem;
  outline: none;
}
.search-wrap input::placeholder { opacity: 0.4; }
.search-wrap button {
  background: #fff;
  color: #000;
  border: none;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  min-height: 40px;
  transition: background 0.15s;
}
.search-wrap button:hover { background: #ddd; }

/* ── Page Body ── */
.page-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* ── Site Header (top bar in page-body) ── */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  border-bottom: 1px solid #222;
  position: sticky;
  top: 0;
  background: #000;
  z-index: 90;
  min-height: 56px;
}

.brand-link {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
}
.brand-text { color: #fff; }
.brand-logo { height: 32px; width: auto; }

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid #fff;
  color: #fff;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.5rem 1rem;
  cursor: pointer;
  min-height: 40px;
}

/* ── Main + Content Aside layout ── */
.page-body > main,
.page-body > aside.content-aside {
  /* stacked by default; on wide screens: side-by-side */
}

/* inner layout: main + aside side by side */
.page-body {
  display: grid;
  grid-template-rows: auto 1fr;
  grid-template-columns: 1fr;
}

.page-body > main {
  grid-column: 1;
  padding: 2rem;
  min-width: 0;
}

.page-body > aside.content-aside {
  border-top: 1px solid #222;
  padding: 2rem;
}

/* On larger screens put aside to the right inside page-body */
@media (min-width: 1100px) {
  .page-body {
    display: grid;
    grid-template-areas:
      "header header"
      "main aside";
    grid-template-columns: 1fr 260px;
    grid-template-rows: auto 1fr;
  }
  .site-header { grid-area: header; }
  .page-body > main { grid-area: main; padding: 2.5rem 3rem; }
  .page-body > aside.content-aside {
    grid-area: aside;
    border-top: none;
    border-left: 1px solid #222;
    padding: 2.5rem 1.5rem;
    position: sticky;
    top: 56px;
    max-height: calc(100vh - 56px);
    overflow-y: auto;
  }
}

/* ── Article / main > section > div ── */
main > section > div { margin-bottom: 3rem; }
main > section > div:last-child { margin-bottom: 0; }

/* ── Content Aside ── */
.content-aside h2 {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.25rem;
  font-weight: 700;
}

.content-aside .subtitle {
  font-size: 0.75rem;
  opacity: 0.5;
  margin-bottom: 1rem;
}

.aside-links {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.aside-link {
  display: block;
  padding: 0.6rem 0;
  border-bottom: 1px solid #1a1a1a;
  font-size: 0.82rem;
  text-decoration: none;
  transition: padding-left 0.15s;
}
.aside-link:hover { padding-left: 0.4rem; text-decoration: none; }
.aside-link strong {
  font-weight: 600;
  display: block;
}

/* ── Subtitle (h2 + p.subtitle pattern) ── */
.subtitle {
  font-size: 1rem;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  opacity: 0.65;
  margin-bottom: 1.5rem;
}

/* ── Eyebrow labels ── */
.channel-eyebrow,
.about-eyebrow,
.privacy-eyebrow,
.tag-eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border-left: 3px solid #fff;
  padding-left: 0.6rem;
  margin-bottom: 1rem;
  opacity: 0.8;
}

/* ── Prose ── */
.prose {
  max-width: 68ch;
  font-size: 1rem;
  line-height: 1.75;
}

.prose h2 { margin-top: 2rem; margin-bottom: 0.5rem; font-size: 1.3rem; }
.prose h3 { margin-top: 1.5rem; margin-bottom: 0.4rem; font-size: 1.1rem; }
.prose p { margin-bottom: 1rem; }
.prose ul, .prose ol { margin: 0.75rem 0 1rem 1.5rem; }
.prose li { margin-bottom: 0.4rem; }
.prose a { border-bottom: 1px solid #555; }
.prose a:hover { border-bottom-color: #fff; text-decoration: none; }

.prose blockquote {
  border-left: 4px solid #fff;
  margin: 2rem 0;
  padding: 1rem 1.5rem;
  background: #111;
  font-size: 1.15rem;
  font-style: italic;
}

/* Drop cap */
.drop-cap .prose > p:first-of-type::first-letter,
.drop-cap > p:first-of-type::first-letter {
  float: left;
  font-size: 4rem;
  line-height: 0.8;
  margin: 0.05em 0.15em 0 0;
  font-weight: 700;
  text-transform: uppercase;
}

/* ── Pub date ── */
.pub-date, .mod-date {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.55;
  margin-bottom: 0.75rem;
}

/* ── Breadcrumb ── */
.breadcrumb {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  opacity: 0.55;
  margin-bottom: 1.5rem;
}
.breadcrumb a { border-bottom: 1px solid #333; }
.breadcrumb a:hover { opacity: 1; text-decoration: none; border-bottom-color: #fff; }
.breadcrumb span[aria-hidden] { margin: 0 0.4rem; }

/* ── Tags ── */
.tag-list { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.tag-badge {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid #444;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  transition: background 0.15s, color 0.15s;
}
.tag-badge:hover { background: #fff; color: #000; text-decoration: none; }

/* ── Home Hero ── */
.home-hero-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  overflow: hidden;
  background: #000;
  margin: -2rem;
  margin-bottom: 3rem;
}

.hero-media {
  position: absolute;
  inset: 0;
}

.hero-media .hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5;
}

.hero-no-img {
  background: repeating-linear-gradient(
    45deg,
    #0a0a0a,
    #0a0a0a 2px,
    #000 2px,
    #000 20px
  );
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.9) 30%, rgba(0,0,0,0.2) 100%);
}

.hero-copy {
  position: relative;
  z-index: 2;
  text-align: right;
  max-width: 680px;
  padding: 3rem 2.5rem;
}

.hero-copy h1 {
  font-size: clamp(2.5rem, 8vw, 6rem);
  margin-bottom: 0.5rem;
}

.hero-copy .hero-desc {
  font-size: 1.1rem;
  opacity: 0.8;
  text-align: right;
}

/* ── Channel Grid ── */
.channel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1px;
  background: #222;
  border: 1px solid #222;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 1rem;
}

.channel-card {
  display: block;
  background: #000;
  padding: 1.5rem 1.25rem;
  text-decoration: none;
  transition: background 0.18s;
  border-radius: 0;
}
.channel-card:hover { background: #111; text-decoration: none; }
.channel-card strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 0.3rem;
}
.channel-card .card-sub {
  display: block;
  font-size: 0.78rem;
  opacity: 0.55;
}

/* ── Article List (home latest) ── */
.article-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.article-item {
  display: block;
  padding: 1rem 0;
  border-bottom: 1px solid #1a1a1a;
  text-decoration: none;
  transition: padding-left 0.15s;
}
.article-item:hover { padding-left: 0.5rem; text-decoration: none; }
.article-item strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}
.article-item .item-desc {
  display: block;
  font-size: 0.82rem;
  opacity: 0.55;
  margin-bottom: 0.2rem;
}
.article-item time { display: inline; font-size: 0.75rem; }

/* ── Child Grid (channel / tag pages) ── */
.child-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1px;
  background: #1a1a1a;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid #1a1a1a;
}

.child-card {
  display: block;
  background: #000;
  padding: 1.5rem 1.25rem;
  text-decoration: none;
  transition: background 0.18s;
}
.child-card:hover { background: #0d0d0d; text-decoration: none; }
.child-card strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.child-card .card-sub {
  display: block;
  font-size: 0.8rem;
  opacity: 0.55;
  margin-bottom: 0.3rem;
}
.child-card time { display: block; font-size: 0.75rem; }

.child-thumb-wrap { margin-bottom: 0.75rem; }
.child-thumb { width: 100%; height: 120px; object-fit: cover; border-radius: 2px; }

/* ── Article Hero ── */
.article-hero-figure {
  margin-bottom: 2rem;
  border-radius: 4px;
  overflow: hidden;
}
.article-hero-img { width: 100%; max-height: 480px; object-fit: cover; }

/* ── Article Meta ── */
.article-meta {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

/* ── Continue links ── */
.continue-links {
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* ── Contact Section ── */
.contact-info {
  max-width: 50ch;
  font-size: 0.95rem;
  opacity: 0.8;
}

/* ── Footer ── */
footer {
  background: #000;
  border-top: 1px solid #222;
  padding: 1.5rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

footer p {
  margin: 0;
  font-size: 0.8rem;
}

footer small {
  font-size: 0.78rem;
  opacity: 0.55;
  letter-spacing: 0.04em;
}

footer small a {
  border-bottom: 1px solid #333;
  margin: 0 0.3rem;
}
footer small a:hover { opacity: 1; border-bottom-color: #fff; text-decoration: none; }

/* ── Animations ── */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.55s ease, transform 0.55s ease;
  }
  .reveal.visible {
    opacity: 1;
    transform: none;
  }

  .stagger-list .reveal:nth-child(1) { transition-delay: 0.05s; }
  .stagger-list .reveal:nth-child(2) { transition-delay: 0.12s; }
  .stagger-list .reveal:nth-child(3) { transition-delay: 0.19s; }
  .stagger-list .reveal:nth-child(4) { transition-delay: 0.26s; }
  .stagger-list .reveal:nth-child(5) { transition-delay: 0.33s; }
  .stagger-list .reveal:nth-child(6) { transition-delay: 0.40s; }

  .channel-card,
  .child-card,
  .article-item,
  .aside-link {
    transition-property: background, padding-left, color;
    transition-duration: 0.18s;
    transition-timing-function: ease;
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* ── Responsive: tablet ── */
@media (max-width: 1099px) {
  .site-wrapper {
    grid-template-columns: 1fr;
  }

  .site-aside-nav {
    position: fixed;
    left: -260px;
    top: 0;
    width: 260px;
    height: 100vh;
    border-right: 1px solid #333;
    transition: left 0.3s ease;
    z-index: 200;
  }

  .site-aside-nav.open { left: 0; }

  .nav-toggle { display: flex; align-items: center; }

  .page-body {
    grid-template-areas: none;
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr auto;
  }

  .site-header { grid-area: unset; }
  .page-body > main { grid-area: unset; padding: 1.5rem 1.25rem; }
  .page-body > aside.content-aside {
    grid-area: unset;
    position: static;
    max-height: none;
    padding: 1.5rem 1.25rem;
  }

  .home-hero-section { margin: -1.5rem; margin-bottom: 2.5rem; }
}

/* ── Responsive: mobile ── */
@media (max-width: 600px) {
  h1 { font-size: clamp(1.8rem, 9vw, 3rem); }
  h2 { font-size: clamp(1.1rem, 5vw, 1.6rem); }

  .page-body > main { padding: 1rem; }
  .page-body > aside.content-aside { padding: 1rem; }

  .hero-copy { padding: 1.5rem 1rem; }
  .hero-copy h1 { font-size: clamp(2rem, 10vw, 3.5rem); }

  .channel-grid { grid-template-columns: 1fr 1fr; }
  .child-grid { grid-template-columns: 1fr; }

  .site-header { padding: 0.75rem 1rem; }

  footer { padding: 1rem; }

  .prose { max-width: 100%; }

  .search-wrap input,
  .search-wrap button { font-size: 16px; }

  .site-aside-nav nav ul li a { min-height: 44px; display: flex; align-items: center; }
}

/* ── Overlay for mobile nav ── */
.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 199;
}
.nav-overlay.active { display: block; }
