/*
Theme Name: Custom Auto Theme
Author: System
Version: 1.0
*/

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

html {scroll-behavior: smooth;}
html, body {overflow-x:hidden;}
a {display: inline-block; text-align: center;}

:root {
  --bg: #fafaf8;
  --bg-alt: #f0efeb;
  --text: #1e1e2c;
  --text-muted: #5a5a72;
  --accent: #2b6777;
  --accent-light: #c8d8e4;
  --accent-dark: #1a3c48;
  --border: #d4d2cc;
  --white: #ffffff;
  --serif: 'Crimson Pro', Georgia, serif;
  --sans: 'IBM Plex Sans', system-ui, sans-serif;
  --max-w: 920px;
  --radius: 3px;
}

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

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

/* ── HEADER ── */
.site-header {
  border-bottom: 1px solid var(--border);
  padding: 1rem 2rem;
  background: var(--white);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.site-logo {
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-dark);
  text-decoration: none;
  letter-spacing: -0.02em;
}
.site-logo:hover { color: var(--accent); }
.main-nav { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.main-nav a {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  transition: color 0.2s;
}
.main-nav a:hover { color: var(--accent); }

/* ── BREADCRUMBS ── */
.breadcrumbs {
  max-width: var(--max-w);
  margin: 1.5rem auto 0;
  padding: 0 2rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}
.breadcrumbs a {
  color: var(--text-muted);
  text-decoration: none;
  text-align: left;
}
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs span { margin: 0 0.4rem; }

/* ── MAIN CONTENT ── */
.page-wrapper {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 2rem;
}

/* ── ARTICLE ── */
.article-meta {
  display: flex;
  gap: 1.5rem;
  margin: 1rem 0 1.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.article-meta-item { display: flex; align-items: center; gap: 0.3rem; }

h1 {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
  line-height: 1.2;
  color: var(--accent-dark);
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}
h2 {
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--accent-dark);
  margin: 2.5rem 0 1rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--border);
}
h3 {
  font-family: var(--sans);
  font-size: 1.05rem;
  font-weight: 600;
  margin: 1.5rem 0 0.5rem;
  color: var(--text);
}

.article-body p { margin-bottom: 1.2rem; }
.article-body img {
  width: 100%;
  border-radius: var(--radius);
  margin: 1.5rem 0;
  border: 1px solid var(--border);
}

/* ── PULLQUOTE ── */
.pullquote {
  border-left: 3px solid var(--accent);
  padding: 1rem 1.5rem;
  margin: 2rem 0;
  background: var(--bg-alt);
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--accent-dark);
}
.pullquote cite {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.8rem;
  font-style: normal;
  color: var(--text-muted);
}

/* ── DATA GRID (no tables!) ── */
.data-grid {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin: 2rem 0;
  overflow: hidden;
}
.data-grid-header {
  background: var(--accent-dark);
  color: var(--white);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.8rem 1rem;
  text-align: left;
}
.data-grid-cell {
  background: var(--white);
  padding: 0.7rem 1rem;
  font-size: 0.9rem;
}
.data-grid-cell:nth-child(4n+3),
.data-grid-cell:nth-child(4n+4) {
  background: var(--bg-alt);
}
.data-grid-cell.label {
  font-weight: 600;
  color: var(--accent-dark);
}

/* ── SIDEBAR / INFO BOX ── */
.info-box {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin: 2rem 0;
}
.info-box h3 {
  font-family: var(--serif);
  color: var(--accent-dark);
  margin-top: 0;
  margin-bottom: 0.8rem;
  font-size: 1rem;
}
.info-box ul {
  list-style: none;
  padding: 0;
}
.info-box li {
  padding: 0.4rem 0;
  padding-left: 1.2rem;
  position: relative;
  font-size: 0.9rem;
}
.info-box li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--accent);
}

/* ── READ ALSO ── */
.read-also {
  margin: 2.5rem 0;
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}
.read-also h3 {
  font-family: var(--serif);
  margin-top: 0;
  margin-bottom: 1rem;
  color: var(--accent-dark);
  font-size: 1.1rem;
}
.read-also-list {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}
.read-also-item {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--bg-alt);
  text-decoration: none;
  color: var(--text);
  transition: color 0.2s;
  text-align: left;
}
.read-also-item:last-child { border-bottom: none; }
.read-also-item:hover { color: var(--accent); }
.read-also-num {
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
  min-width: 2rem;
}
.read-also-title { font-size: 0.95rem; }

/* ── SUBSCRIBE ── */
.subscribe-section {
  margin: 2.5rem 0;
  padding: 2rem;
  background: var(--accent-dark);
  color: var(--white);
  border-radius: var(--radius);
  text-align: center;
}
.subscribe-section h3 {
  font-family: var(--serif);
  color: var(--white);
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
}
.subscribe-section p {
  font-size: 0.9rem;
  opacity: 0.85;
  margin-bottom: 1.2rem;
}
.subscribe-form {
  display: flex;
  gap: 0.5rem;
  max-width: 420px;
  margin: 0 auto;
  flex-wrap: wrap;
  justify-content: center;
}
.subscribe-form input[type="email"] {
  flex: 1;
  min-width: 200px;
  padding: 0.7rem 1rem;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.1);
  color: var(--white);
  font-family: var(--sans);
  font-size: 0.9rem;
}
.subscribe-form input::placeholder { color: rgba(255,255,255,0.5); }
.subscribe-form button {
  padding: 0.7rem 1.5rem;
  background: var(--white);
  color: var(--accent-dark);
  border: none;
  border-radius: var(--radius);
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.2s;
}
.subscribe-form button:hover { background: var(--accent-light); }

/* ── FOOTER ── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem;
  margin-top: 3rem;
  background: var(--white);
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  text-align: center;
}
.footer-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin: 1rem 0;
  flex-wrap: wrap;
}
.footer-links a {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-decoration: none;
}
.footer-links a:hover { color: var(--accent); }
.footer-copy {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.8rem;
}
.footer-disclaimer {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.8rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.5;
  opacity: 0.75;
}

/* ── COOKIE MODAL ── */
.cookie-modal {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  max-width: 360px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  z-index: 999;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  font-size: 0.85rem;
  animation: slideUp 0.4s ease;
}
@keyframes slideUp {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.cookie-modal p { margin-bottom: 1rem; color: var(--text-muted); }
.cookie-modal-btns { display: flex; gap: 0.5rem; }
.cookie-modal-btns button {
  flex: 1;
  padding: 0.5rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--sans);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--bg);
  color: var(--text);
}
.cookie-modal-btns .accept-btn {
  background: var(--accent-dark);
  color: var(--white);
  border-color: var(--accent-dark);
}
.cookie-modal-btns .accept-btn:hover { background: var(--accent); }
.cookie-modal-btns .decline-btn:hover { background: var(--bg-alt); }
.cookie-hidden { display: none; }

/* ── HERO / HOME ── */
.hero-section {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
}
.hero-tag {
  display: inline-block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  border: 1px solid var(--accent);
  padding: 0.2rem 0.7rem;
  border-radius: var(--radius);
  margin-bottom: 1rem;
}

/* ── SUCCESS ── */
.success-page {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 2rem;
}
.success-page h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: 1rem;
}
.success-page p {
  color: var(--text-muted);
  margin-bottom: 2rem;
  font-size: 1.1rem;
}
.btn-primary {
  display: inline-block;
  padding: 0.8rem 2rem;
  background: var(--accent-dark);
  color: var(--white);
  text-decoration: none;
  border-radius: var(--radius);
  font-weight: 600;
  transition: background 0.2s;
}
.btn-primary:hover { background: var(--accent); }

/* ── 404 ── */
.page-404 {
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 2rem;
}
.page-404 .error-code {
  font-family: var(--serif);
  font-size: clamp(5rem, 15vw, 10rem);
  font-weight: 700;
  color: var(--accent-light);
  line-height: 1;
}
.page-404 h1 {
  font-size: 1.4rem;
  margin: 1rem 0;
}
.page-404 p {
  color: var(--text-muted);
  margin-bottom: 2rem;
}

/* ── POLICY PAGES ── */
.policy-body h1 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
}
.policy-body h2 {
  font-size: 1.2rem;
  margin-top: 2rem;
}
.policy-body p, .policy-body li {
  font-size: 0.9rem;
  color: var(--text-muted);
}
.policy-body ul {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}
.policy-body li { margin-bottom: 0.3rem; }

/* ── CARDS (home article listing) ── */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}
.article-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  background: var(--white);
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.article-card:hover {
  border-color: var(--accent);
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.article-card-tag {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 0.5rem;
}
.article-card h3 {
  font-family: var(--serif);
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
  line-height: 1.3;
}
.article-card p {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: left;
}

/* ── NUMBER HIGHLIGHTS ── */
.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}
.stat-item {
  text-align: center;
  padding: 1.2rem;
  background: var(--bg-alt);
  border-radius: var(--radius);
}
.stat-num {
  font-family: var(--serif);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}
.stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  .site-header { padding: 0.8rem 1rem; }
  .header-inner { flex-direction: column; align-items: flex-start; }
  .main-nav { gap: 1rem; }
  .page-wrapper { padding: 1.5rem 1rem; }
  .breadcrumbs { padding: 0 1rem; }
  .data-grid { grid-template-columns: 1fr; }
  .data-grid-cell.label { background: var(--bg-alt); }
  .cookie-modal { left: 1rem; right: 1rem; max-width: none; bottom: 1rem; }
  .subscribe-section { padding: 1.5rem; }
}
