/* ============================================
   Housing Politics Lab — Stylesheet
   ============================================ */

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

:root {
  --color-navy: #1a2744;
  --color-blue: #2c5282;
  --color-accent: #c53030;
  --color-text: #2d3748;
  --color-text-light: #718096;
  --color-bg: #ffffff;
  --color-bg-warm: #faf9f7;
  --color-border: #e2e8f0;
  --font-serif: 'Source Serif 4', 'Georgia', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --max-width: 1100px;
}

html { font-size: 17px; scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--color-blue); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--color-accent); }

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

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  color: var(--color-navy);
  line-height: 1.3;
  font-weight: 700;
}

h1 { font-size: 2.4rem; margin-bottom: 0.5rem; }
h2 { font-size: 1.8rem; margin-bottom: 1rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.5rem; }

p { margin-bottom: 1rem; }

/* --- Layout --- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

section {
  padding: 3rem 0;
}

/* --- Header --- */
.site-header {
  background: var(--color-navy);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header .logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #fff;
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  text-decoration: none;
}

.site-header .logo img {
  width: 32px;
  height: 32px;
}

.site-header .logo:hover { color: #cbd5e0; }

nav ul {
  list-style: none;
  display: flex;
  gap: 2rem;
}

nav a {
  color: #cbd5e0;
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  text-decoration: none;
  transition: color 0.2s;
}

nav a:hover, nav a.active { color: #fff; }

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.25rem;
}

/* --- Hero --- */
.hero {
  position: relative;
  background: var(--color-navy);
  color: #fff;
  padding: 4.5rem 0;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../assets/images/dc_zoning_map_1924.png') center/cover;
  opacity: 0.15;
}

.hero .container { position: relative; z-index: 1; }

.hero h1 {
  color: #fff;
  font-size: 3rem;
  margin-bottom: 0.75rem;
}

.hero .subtitle {
  font-size: 1.2rem;
  color: #cbd5e0;
  margin-bottom: 1.5rem;
  font-family: var(--font-serif);
  font-style: italic;
}

.hero .lead {
  font-size: 1.1rem;
  line-height: 1.8;
  max-width: 700px;
  color: #e2e8f0;
}

/* --- Section Headings --- */
.section-heading {
  text-align: center;
  margin-bottom: 1.75rem;
}

.section-heading h2 { margin-bottom: 0.5rem; }

.section-heading p {
  color: var(--color-text-light);
  max-width: 600px;
  margin: 0 auto;
}

.section-heading .rule {
  width: 60px;
  height: 3px;
  background: var(--color-accent);
  margin: 1rem auto 0;
  border: none;
}

/* --- Two Column Layout --- */
.two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
}

.two-column .column {
  min-width: 0;
}

.two-column .column:first-child {
  border-right: 2px solid var(--color-blue);
  padding-right: 2.5rem;
}

.two-column .column:last-child {
  padding-left: 0;
}

.two-column .column .card {
  margin-bottom: 1rem;
  width: 100%;
}

.two-column .column .card:last-child {
  margin-bottom: 0;
}

/* --- Cards Grid --- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
}

.card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  padding: 2rem;
  transition: box-shadow 0.2s, transform 0.2s;
}

.card:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  transform: translateY(-2px);
}

.card h3 { margin-bottom: 0.5rem; }

.card p {
  color: var(--color-text-light);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* Compact card variant */
.card.card-compact {
  padding: 1.25rem 1.5rem;
  display: block;
  text-decoration: none;
  color: inherit;
}

.card.card-compact h3 {
  font-size: 1.05rem;
  margin-bottom: 0.35rem;
}

.card.card-compact p {
  font-size: 0.9rem;
  margin-bottom: 0;
}

.card.card-compact:hover h3 { color: var(--color-accent); }

.card-label {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-blue);
  background: #e8edf6;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  margin-right: 0.4rem;
  vertical-align: middle;
}

/* --- Press Section --- */
.press-logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 3rem;
}

.press-logos a {
  display: block;
  opacity: 0.5;
  transition: opacity 0.2s;
  flex-shrink: 0;
}

.press-logos a:hover { opacity: 1; }

.press-section {
  padding: 2rem 0;
  background: #edf0f7;
}

.press-section .section-heading { margin-bottom: 1.25rem; }

.press-logos img {
  height: 24px;
  width: auto;
  object-fit: contain;
  filter: grayscale(100%);
  transition: filter 0.2s;
}

.press-logos a:hover img { filter: none; }

/* --- Content Page --- */
.page-header {
  background: var(--color-navy);
  color: #fff;
  padding: 3rem 0;
}

.page-header h1 { color: #fff; font-size: 2.2rem; }
.page-header .subtitle { color: #cbd5e0; font-family: var(--font-serif); font-style: italic; }

.page-content {
  padding: 3rem 0;
  max-width: 760px;
  margin: 0 auto;
}

.page-content h2 { margin-top: 2rem; }
.page-content ul, .page-content ol { margin: 0 0 1rem 1.5rem; }
.page-content li { margin-bottom: 0.5rem; }

/* --- Background variants --- */
.bg-warm { background: var(--color-bg-warm); }
.bg-navy-tint { background: #edf0f7; }

/* --- Footer --- */
.site-footer {
  background: var(--color-navy);
  color: #a0aec0;
  padding: 2.5rem 0;
  font-size: 0.9rem;
  text-align: center;
}

.site-footer a { color: #cbd5e0; }
.site-footer a:hover { color: #fff; }

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

/* --- Utility --- */
.btn {
  display: inline-block;
  padding: 0.6rem 1.5rem;
  border-radius: 4px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
}

.btn-primary {
  background: var(--color-blue);
  color: #fff;
}

.btn-primary:hover {
  background: var(--color-navy);
  color: #fff;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  html { font-size: 16px; }

  .hero { padding: 4rem 0; }
  .hero h1 { font-size: 2.2rem; }

  section { padding: 2.5rem 0; }

  .card-grid { grid-template-columns: 1fr; }
  .two-column { grid-template-columns: 1fr; }

  .menu-toggle { display: block; }

  nav ul {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-navy);
    padding: 1rem 2rem;
    gap: 0.75rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  }

  nav ul.open { display: flex; }

  .footer-content {
    flex-direction: column;
    text-align: center;
  }

  .press-logos { gap: 2rem; }
  .press-logos img { height: 20px; }
}
