/* ============================================
   ECHOES OF 1939 — wartime-archive.com
   Main Stylesheet
   AdSense-compliant educational history blog
   ============================================ */

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

:root {
  --ink:     #0a0806;
  --page:    #0e0b08;
  --card:    #181209;
  --card2:   #1e1610;
  --red:     #7a1515;
  --red2:    #a83030;
  --gold:    #b8960c;
  --gold2:   #d4a820;
  --muted:   #6a5c45;
  --text:    #d4c9b0;
  --dim:     #8a7a65;
  --faint:   #4a3c2a;
  --border:  #252018;
  --borderl: #3a2e1e;
}

/* BASE */
html { scroll-behavior: smooth; }
body {
  background: var(--page);
  color: var(--text);
  font-family: 'Source Sans 3', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }

/* ACCESSIBILITY */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); border: 0;
}
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* POLICY BAR */
.policy-bar {
  background: #0a0603;
  border-bottom: 1px solid var(--borderl);
  text-align: center;
  padding: 6px 1rem;
  font-size: 11px;
  color: var(--muted);
  line-height: 1.6;
}
.policy-bar a { color: var(--gold); }
.policy-bar a:hover { color: var(--gold2); }

/* NAV */
nav {
  background: var(--ink);
  border-bottom: 2px solid var(--red);
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 58px;
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-logo {
  font-family: 'UnifrakturMaguntia', cursive;
  font-size: 24px;
  color: #f0d9a0;
  letter-spacing: 1px;
  white-space: nowrap;
}
.nav-logo:hover { color: #fff8e0; }
.nav-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}
.nav-links a {
  color: var(--dim);
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  transition: color .2s;
}
.nav-links a:hover { color: var(--gold2); }
.nav-right { display: flex; align-items: center; }
.search-form { display: flex; }
.nav-search {
  background: #1a1409;
  border: 1px solid var(--borderl);
  border-right: none;
  color: var(--text);
  padding: 6px 10px;
  font-size: 12px;
  width: 150px;
  outline: none;
  transition: border-color .2s;
}
.nav-search:focus { border-color: var(--gold); }
.search-btn {
  background: var(--red);
  border: none;
  color: #f0d9a0;
  padding: 6px 12px;
  cursor: pointer;
  font-size: 13px;
}
.search-btn:hover { background: var(--red2); }

/* TICKER */
.editorial-bar {
  background: #12100a;
  border-bottom: 1px solid var(--borderl);
  padding: 7px 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  overflow: hidden;
}
.ed-label {
  background: var(--red);
  color: #f0d9a0;
  font-size: 9px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 3px 8px;
  white-space: nowrap;
  flex-shrink: 0;
}
.ed-text {
  font-size: 12px;
  color: var(--dim);
  white-space: nowrap;
  animation: ticker 40s linear infinite;
}
@keyframes ticker {
  0%   { transform: translateX(60%); }
  100% { transform: translateX(-100%); }
}

/* AD ZONES */
.ad-zone {
  background: var(--card);
  border: 1px dashed var(--borderl);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--faint);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.ad-zone.leader  { height: 90px; width: 100%; }
.ad-zone.rect    { height: 250px; width: 100%; margin-bottom: 1.5rem; }
.ad-zone.inline  { height: 60px; width: 100%; margin: 1.5rem 0; }

/* STATS BAR */
.stats-bar {
  background: var(--ink);
  border-bottom: 1px solid var(--borderl);
  display: flex;
  justify-content: center;
  gap: 3rem;
  padding: 1rem 2rem;
}
.stat { text-align: center; }
.stat-num {
  font-family: 'IM Fell English', serif;
  font-size: 24px;
  color: #f0d9a0;
  line-height: 1;
}
.stat-label {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 2px;
}

/* HERO */
.hero {
  background: var(--ink);
  border-bottom: 3px solid var(--red);
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 370px;
  min-height: 400px;
  max-width: 1200px;
  margin: 0 auto;
}
.hero-main {
  padding: 2.5rem;
  border-right: 1px solid var(--borderl);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.eyebrow {
  font-size: 10px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--red2);
  margin-bottom: .75rem;
  display: block;
}
.hero-title {
  font-family: 'IM Fell English', serif;
  font-size: 38px;
  color: #f0e8cc;
  line-height: 1.2;
  margin-bottom: 1rem;
}
.hero-excerpt {
  color: var(--dim);
  font-size: 14px;
  line-height: 1.75;
  margin-bottom: 1.25rem;
  max-width: 500px;
}
.hero-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 12px;
  color: var(--faint);
  border-top: 1px solid var(--border);
  padding-top: 1rem;
  flex-wrap: wrap;
}
.tag {
  display: inline-block;
  background: var(--red);
  color: #f0d9a0;
  font-size: 9px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 3px 7px;
}
.tag.edu { background: #2a4a1a; color: #a0c878; }
.read-btn {
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold2);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 7px 18px;
  display: inline-block;
  transition: background .2s, color .2s;
}
.read-btn:hover { background: var(--gold); color: #1a0e00; }

/* HERO SIDEBAR */
.hero-side { display: flex; flex-direction: column; }
.hero-side-item {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--borderl);
  display: block;
  transition: background .15s;
}
.hero-side-item:last-child { border-bottom: none; }
.hero-side-item:hover { background: var(--card); }
.side-num {
  font-family: 'IM Fell English', serif;
  font-size: 26px;
  color: var(--faint);
  line-height: 1;
  margin-bottom: 3px;
}
.side-title {
  font-size: 13px;
  color: #c4b89a;
  line-height: 1.4;
  margin-bottom: 3px;
}
.side-meta { font-size: 11px; color: var(--muted); }

/* SECTION RULE */
.section-rule {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem 2rem 0;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}
.rule-line { flex: 1; height: 1px; background: var(--borderl); }
.rule-label {
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--red2);
  white-space: nowrap;
}
.rule-ornament { color: var(--gold); font-size: 14px; }

/* MAIN GRID */
.main-grid {
  display: grid;
  grid-template-columns: 1fr 290px;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 3rem;
}
.main-content {
  padding: 1.5rem 2rem 0;
  border-right: 1px solid var(--border);
}

/* DISCLAIMER */
.disclaimer {
  background: #101a0a;
  border: 1px solid #2a4a1a;
  border-left: 3px solid #4a7a2a;
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
  font-size: 12px;
  color: #7a9a5a;
  line-height: 1.6;
}
.disclaimer strong {
  color: #a0c878;
  display: block;
  margin-bottom: .25rem;
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* ARTICLES */
.articles { display: flex; flex-direction: column; }
.article-card {
  border-bottom: 1px solid var(--border);
  padding: 1.5rem 0;
}
.article-card.featured {
  background: var(--card);
  border: 1px solid var(--borderl);
  border-left: 4px solid var(--red);
  padding: 1.5rem;
  margin-bottom: .5rem;
}
.article-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: .5rem;
  flex-wrap: wrap;
}
.article-top time {
  font-size: 11px;
  color: var(--faint);
}
.article-title {
  font-family: 'IM Fell English', serif;
  font-size: 20px;
  color: #e8d9b8;
  line-height: 1.3;
  margin-bottom: .45rem;
}
.article-title a { transition: color .2s; }
.article-title a:hover { color: var(--gold2); }
.article-excerpt {
  font-size: 13px;
  color: var(--dim);
  line-height: 1.7;
  margin-bottom: .75rem;
}
.article-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: var(--faint);
}
.article-footer a {
  color: var(--gold);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.article-footer a:hover { color: var(--gold2); }

/* PAGINATION */
.pagination {
  display: flex;
  gap: 4px;
  padding: 1.5rem 0 0;
  align-items: center;
}
.page-btn {
  background: var(--card);
  border: 1px solid var(--borderl);
  color: var(--dim);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  transition: all .15s;
}
a.page-btn:hover, .page-btn.active {
  background: var(--red);
  border-color: var(--red);
  color: #f0d9a0;
}

/* SIDEBAR */
.sidebar { padding: 1.5rem 1.25rem 0; }
.widget { margin-bottom: 1.75rem; }
.widget-head {
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold);
  border-bottom: 1px solid var(--borderl);
  padding-bottom: 7px;
  margin-bottom: .85rem;
}

/* PULLQUOTE */
.pullquote {
  background: var(--card);
  border-left: 3px solid var(--gold);
  padding: 1.25rem;
  margin-bottom: 1.75rem;
}
.pullquote p {
  font-family: 'IM Fell English', serif;
  font-style: italic;
  font-size: 15px;
  color: #d4c9a0;
  line-height: 1.65;
  margin-bottom: .45rem;
}
.pullquote cite { font-size: 11px; color: var(--muted); letter-spacing: 1px; }

/* TIMELINE */
.tl-item {
  display: flex;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
}
.tl-item:last-child { border-bottom: none; }
.tl-year {
  font-family: 'IM Fell English', serif;
  font-size: 20px;
  color: var(--red2);
  min-width: 40px;
  line-height: 1.1;
}
.tl-text { font-size: 12px; color: var(--dim); line-height: 1.5; }
.tl-text strong { color: var(--text); }

/* CATEGORIES */
.cat-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  color: var(--dim);
  transition: color .15s;
}
.cat-item:last-child { border-bottom: none; }
.cat-item:hover .cat-name { color: var(--gold2); }
.cat-badge {
  background: var(--card2);
  border: 1px solid var(--borderl);
  color: var(--faint);
  font-size: 11px;
  padding: 1px 6px;
}

/* TAG CLOUD */
.tag-cloud { display: flex; flex-wrap: wrap; gap: 5px; }
.tag-pill {
  background: var(--card2);
  border: 1px solid var(--borderl);
  color: var(--dim);
  font-size: 11px;
  padding: 3px 9px;
  display: inline-block;
  transition: all .15s;
}
.tag-pill:hover {
  background: var(--red);
  border-color: var(--red);
  color: #f0d9a0;
}

/* NEWSLETTER */
.newsletter {
  background: var(--card);
  border: 1px solid var(--borderl);
  border-top: 3px solid var(--gold);
  padding: 1.25rem;
  text-align: center;
  margin-bottom: 1.75rem;
}
.newsletter h3 {
  font-family: 'IM Fell English', serif;
  font-size: 17px;
  color: #f0d9a0;
  margin-bottom: .35rem;
}
.newsletter p { font-size: 12px; color: var(--dim); margin-bottom: .85rem; }
.nl-row { display: flex; }
.nl-row input {
  flex: 1;
  background: #1a1409;
  border: 1px solid var(--borderl);
  border-right: none;
  color: var(--text);
  padding: 7px 9px;
  font-size: 12px;
  outline: none;
}
.nl-row button {
  background: var(--gold);
  border: none;
  color: #1a0e00;
  padding: 7px 12px;
  cursor: pointer;
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-weight: 600;
}
.nl-row button:hover { background: var(--gold2); }

/* ARTICLE FULL PAGE */
.article-full { max-width: 760px; padding: 2rem 0; }
.article-full-header { margin-bottom: 1.5rem; }
.article-full-title {
  font-family: 'IM Fell English', serif;
  font-size: 34px;
  color: #f0e8cc;
  line-height: 1.2;
  margin: .75rem 0;
}
.article-byline {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 1px;
  border-bottom: 1px solid var(--borderl);
  padding-bottom: .85rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}
.article-body {
  font-family: 'IM Fell English', serif;
  font-size: 17px;
  line-height: 1.85;
  color: #c0b498;
}
.article-body p { margin-bottom: 1.1rem; }
.article-body h2 {
  font-size: 24px;
  color: #f0e8cc;
  margin: 2rem 0 .65rem;
  font-weight: 400;
}
.article-body h3 {
  font-size: 20px;
  color: #f0e8cc;
  margin: 1.75rem 0 .65rem;
  font-weight: 400;
}
.article-blockquote {
  border-left: 3px solid var(--gold);
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  background: var(--card);
}
.article-blockquote p {
  font-style: italic;
  color: #d4c9a0;
  margin: 0;
  font-size: 16px;
}

/* BACK BTN */
.back-btn {
  background: transparent;
  border: 1px solid var(--borderl);
  color: var(--dim);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 6px 16px;
  cursor: pointer;
  display: inline-block;
  margin-bottom: 1.25rem;
  transition: all .15s;
}
.back-btn:hover { border-color: var(--red); color: var(--red2); }

/* SHARE ROW */
.share-row {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--borderl);
}
.share-label {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
}

/* ABOUT / STATIC PAGES */
.static-page { max-width: 760px; padding: 2.5rem 2rem; }
.static-page h1 {
  font-family: 'IM Fell English', serif;
  font-size: 32px;
  color: #f0e8cc;
  margin-bottom: 1.25rem;
}
.static-page h2 {
  font-family: 'IM Fell English', serif;
  font-size: 22px;
  color: #d4c9a0;
  margin: 2rem 0 .65rem;
  font-weight: 400;
}
.static-page p {
  font-size: 14px;
  color: var(--dim);
  line-height: 1.8;
  margin-bottom: 1rem;
}
.static-page ul {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}
.static-page li {
  font-size: 14px;
  color: var(--dim);
  line-height: 1.75;
  margin-bottom: .35rem;
}
.policy-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 1rem 0 1.5rem;
}
.policy-card {
  background: var(--card);
  border: 1px solid var(--borderl);
  padding: 1rem;
}
.policy-card h3 {
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: .5rem;
}
.policy-card p {
  font-size: 12px;
  color: var(--dim);
  line-height: 1.6;
  margin: 0;
}

/* FOOTER */
footer {
  background: var(--ink);
  border-top: 3px solid var(--red);
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  padding: 2.5rem 2rem 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
}
.footer-brand .logo {
  font-family: 'UnifrakturMaguntia', cursive;
  font-size: 26px;
  color: #f0d9a0;
  margin-bottom: .4rem;
}
.footer-brand p { font-size: 12px; color: var(--muted); line-height: 1.6; }
.footer-col h4 {
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: .65rem;
}
.footer-col ul { list-style: none; }
.footer-col li { padding: 3px 0; }
.footer-col a { font-size: 12px; color: var(--dim); transition: color .15s; }
.footer-col a:hover { color: var(--text); }
.soc-row { display: flex; gap: 8px; margin-top: .85rem; }
.soc {
  width: 28px; height: 28px;
  border: 1px solid var(--borderl);
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; color: var(--dim);
  transition: all .15s;
}
.soc:hover { border-color: var(--red); color: var(--red2); }
.footer-legal {
  border-top: 1px solid var(--borderl);
  padding: 1rem 2rem;
  font-size: 11px;
  color: var(--faint);
  line-height: 1.7;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
}
.footer-bottom {
  border-top: 1px solid var(--borderl);
  padding: .75rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 10px;
  color: var(--faint);
  max-width: 1200px;
  margin: 0 auto;
}

/* RESPONSIVE */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-side { display: none; }
  .main-grid { grid-template-columns: 1fr; }
  .sidebar { border-top: 1px solid var(--border); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav-links { display: none; }
  .policy-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .hero-title { font-size: 26px; }
  .footer-grid { grid-template-columns: 1fr; }
  .stats-bar { gap: 1.5rem; flex-wrap: wrap; }
}

/* ============================================
   COOKIE BANNER
   ============================================ */
#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #0a0806;
  border-top: 2px solid var(--red);
  z-index: 9999;
  transition: transform 0.4s, opacity 0.4s;
}
.cookie-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: .85rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}
.cookie-text {
  font-size: 12px;
  color: var(--dim);
  line-height: 1.6;
  flex: 1;
}
.cookie-text strong {
  color: #f0d9a0;
  margin-right: .5rem;
}
.cookie-text a { color: var(--gold); }
.cookie-text a:hover { color: var(--gold2); }
.cookie-btns {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}
.cookie-accept {
  background: var(--red);
  border: none;
  color: #f0d9a0;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 8px 20px;
  cursor: pointer;
  transition: background .2s;
}
.cookie-accept:hover { background: var(--red2); }
.cookie-manage {
  font-size: 11px;
  color: var(--dim);
  letter-spacing: 1px;
  text-transform: uppercase;
  border-bottom: 1px solid var(--borderl);
}
.cookie-manage:hover { color: var(--gold); border-color: var(--gold); }

/* ============================================
   MOBILE MENU TOGGLE
   ============================================ */
#mobileMenuBtn {
  display: none;
  background: transparent;
  border: 1px solid var(--borderl);
  color: var(--dim);
  font-size: 18px;
  width: 36px;
  height: 36px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

@media (max-width: 900px) {
  #mobileMenuBtn { display: flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: 58px;
    left: 0;
    right: 0;
    background: var(--ink);
    border-bottom: 2px solid var(--red);
    flex-direction: column;
    padding: 1rem 2rem;
    gap: .75rem;
    z-index: 200;
  }
  .nav-links.mobile-open { display: flex; }
  .nav-links a {
    font-size: 13px;
    padding: .35rem 0;
    border-bottom: 1px solid var(--border);
  }
  .cookie-inner { flex-direction: column; gap: 1rem; }
}
