body {font-family: system-ui; color: #111; background: #fff;}
.site-title {font-family: 'ChomskyCustom', serif; font-size: 120px;}
@font-face {font-family: 'ChomskyCustom'; src: url('fonts/Chomsky.woff') format('woff');}
/* --- Centered title and navigation --- */

.site-header {
  border-bottom: 1px solid #e6e6e6;
  padding: 40px 0 30px;
  text-align: center;
}

.site-title {
  font-family: 'ChomskyCustom', serif;
  font-size: 120px;          /* Larger title */
  letter-spacing: 0.02em;
  margin: 0 auto 16px;       /* Adds space below title */
  display: block;
  white-space: nowrap;  
}

.main-nav {
  margin-top: 10px;
}

.main-nav a {
  display: inline-block;
  margin: 0 14px;
  text-decoration: none;
  color: #111;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.main-nav a:hover {
  text-decoration: underline;
}

/* --- Homepage Hero Section --- */

.hero {
  text-align: center;
  margin-top: 40px;
}

.issue-preview-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 42px;
  margin-bottom: 24px;
  color: #111;
  font-weight: 400;
}

.hero-image-link img {
  display: block;
  margin: 0 auto;
  max-width: 600px; /* adjust if you want a smaller/larger preview */
  height: auto;
  border: 1px solid #ddd;
}

/* --- Font updates below the image --- */
body, p, a, h2, h3, h4, h5, h6, button {
  font-family: 'JetBrains Mono', monospace;
}
/* --- Homepage Hero Section (Centered Image + Title) --- */

.hero {
  text-align: center;
  margin-top: 40px;
}

.issue-preview-title {
  font-family: 'ChomskyCustom', serif; /* use your masthead font */
  font-size: 36px;
  margin-bottom: 20px;
  color: #111;
  font-weight: normal;
}

.hero-image-link img {
  display: block;
  margin: 0 auto;
  max-width: 600px;
  height: auto;
  border: 1px solid #ddd;
}
.issue-preview-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 36px;
  text-align: center;
  margin-bottom: 20px;
  color: #111;
  font-weight: 400;
}
/* --- Responsive Design Tweaks --- */

/* Tablets and small laptops (≤ 900px) */
@media (max-width: 900px) {
  .site-title {
    font-size: 80px;
  }

  .issue-preview-title {
    font-size: 28px;
  }

  .hero-image {
    max-width: 90%;
  }
}

/* Mobile phones (≤ 600px) */
@media (max-width: 600px) {
  .site-title {
    font-size: 56px;
    line-height: 1.1;
  }

  .main-nav a {
    display: block;
    margin: 8px 0;
  }

  .issue-preview-title {
    font-size: 24px;
    margin-bottom: 12px;
  }

  .hero-image {
    max-width: 95%;
  }

  .hero-copy h2 {
    font-size: 16px;
    padding: 0 10px;
  }
}
/* --- Shared Page Styles --- */
.page-content {
  text-align: center;
  margin-top: 40px;
}

.page-title {
  font-family: 'ChomskyCustom', serif;
  font-size: 64px;
  margin-bottom: 20px;
  color: #111;
}

.subtitle {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 500;
  font-size: 28px;
  margin-bottom: 16px;
  color: #333;
}

.about-body,
.contact-body,
.issues-list a {
  font-family: 'JetBrains Mono', monospace;
  font-size: 18px;
  color: #111;
  line-height: 1.6;
}

.issues-list {
  list-style-type: disc;
  text-align: left;
  max-width: 600px;
  margin: 20px auto;
}

.issues-list a {
  text-decoration: none;
}

.issues-list a:hover {
  text-decoration: underline;
}
.about-body {
  max-width: 480px;           /* limits width roughly to the title width */
  margin: 0 auto;             /* centers the text block */
  text-align: left;           /* keeps paragraph alignment natural */
  font-family: 'JetBrains Mono', monospace;
  font-size: 18px;
  line-height: 1.6;
}

/* --- Dark Mode Styles --- */
@media (prefers-color-scheme: dark) {
  body {
    background: #111;
    color: #f2f2f2;
  }

  .site-header {
    border-bottom: 1px solid #444;
  }

  /* Menu links (About, Issues, Contact) */
  .main-nav a {
    color: #fff;
  }

  .main-nav a:hover {
    color: #9ecfff;
  }

  a {
    color: #9ecfff;
  }

  a:hover {
    color: #c0e4ff;
  }

  .site-footer {
    border-top: 1px solid #444;
    color: #bbb;
  }


  /* Headings and titles */
  .site-title {
    color: #fafafa;
  }

  .issue-preview-title,
  .page-title,
  .subtitle {
    color: #fff;
  }

  /* Body text across all pages */
  .about-body,
  .contact-body,
  .issues-list a,
  p {
    color: #f2f2f2;
  }

  /* Optional: bullet list color fix */
  .issues-list li {
    color: #f2f2f2;
  }
}
/* ============================
   ARTICLE PAGE LAYOUT & TYPO
   ============================ */

/* Wrapper for the individual article page */
.article-container {
  max-width: 800px;
  margin: 80px auto 40px;
  padding: 0 1rem;
}

/* Title centered */
#article-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

/* Date & byline centered under title */
.article-meta {
  text-align: center;
  font-size: 0.95rem;
  margin: 0;
}

/* Add a little space below the meta block */
.article-meta + .article-meta {
  margin-bottom: 1.5rem;
}

/* Body text left-aligned */
.article-body,
#article-content {
  text-align: left;
  line-height: 1.6;
  font-size: 1rem;
}

/* Main article image: centered and scaled down */
.article-image {
  display: block;
  margin: 1.5rem auto 0.5rem;
  max-width: 60%;   /* 60% of the container width */
  height: auto;     /* keep aspect ratio */
}

/* Caption under the image */
.article-caption {
  text-align: center;
  margin: 0 0 1.5rem;
  font-style: italic;
  font-size: 0.9rem;
  color: #444;
}

/* ============================
   RESPONSIVE TWEAKS
   ============================ */
@media (max-width: 768px) {
  .article-container {
    margin-top: 60px;
  }

  .article-image {
    max-width: 90%;  /* let images breathe on mobile */
  }

  .article-body,
  #article-content {
    font-size: 1.05rem;
  }
}

/* -------------------------
   ARTICLES PAGE: INDEX
   ------------------------- */

/* Basic layout for the list */
#articles-list {
  list-style: none;
  margin: 2rem 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.article-card {
  margin: 0; /* spacing handled by gap */
}

/* Whole card is clickable */
.article-card-link {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
  text-decoration: none;
  color: inherit;
  transition:
    box-shadow 0.15s ease,
    transform 0.15s ease,
    border-color 0.15s ease;
}

/* Hover/focus: looks obviously tappable/clickable */
.article-card-link:hover,
.article-card-link:focus-visible {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
  border-color: rgba(0, 0, 0, 0.3);
}

.article-card-link:focus-visible {
  outline: 2px solid #000;
  outline-offset: 3px;
}

/* Text inside card */
.article-subline {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.7;
  margin-bottom: 0.35rem;
}

.article-title {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0;
  text-decoration: underline;
  text-underline-offset: 0.12em;
}

.article-link-hint {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Thumbnail for index cards */
.article-thumb-wrapper {
  width: 100%;
  max-height: 220px;
  overflow: hidden;
  border-radius: 0.75rem;
}

.article-thumb {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.article-text {
  display: flex;
  flex-direction: column;
}

/* Desktop: only cards with thumbnails become side-by-side */
@media (min-width: 768px) {
  .article-card.has-thumb .article-card-link {
    flex-direction: row;
    align-items: stretch;
  }

  .article-card.has-thumb .article-thumb-wrapper {
    flex: 0 0 220px;
    max-height: none;
  }

  .article-card.has-thumb .article-text {
    flex: 1;
  }
}

/* Optional: page heading on articles.html */
.page-title {
  margin-top: 1.5rem;
  margin-bottom: 0.25rem;
}

.page-subtitle {
  margin-top: 0;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  opacity: 0.75;
}

/* -------------------------
   SINGLE ARTICLE PAGE
   ------------------------- */

.article-page-title {
  margin-top: 1.5rem;
  margin-bottom: 0.25rem;
  font-size: 1.5rem;
}

.article-page-subline {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.7;
  margin-bottom: 1rem;
}

.article-page-thumb-wrapper {
  margin: 1rem 0;
}

.article-page-thumb {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  display: block;
}

.article-page-caption {
  font-size: 0.8rem;
  margin-top: 0.35rem;
  opacity: 0.8;
}

.article-page-body p {
  margin: 0 0 1rem;
  line-height: 1.5;
}

/* -------------------------
   DEFAULT (Light Mode)
   ------------------------- */
.article-card-link {
  background: #ffffff;
  color: #111111; /* dark text */
  border: 1px solid rgba(0, 0, 0, 0.12);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.article-title {
  color: #000000;
}

.article-subline,
.article-link-hint {
  color: #444444;
}

/* Hover/focus (light mode) */
.article-card-link:hover,
.article-card-link:focus-visible {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  border-color: rgba(0, 0, 0, 0.3);
}

/* -------------------------
   DARK MODE OVERRIDES
   ------------------------- */
@media (prefers-color-scheme: dark) {
  .article-card-link {
    background: #1b1b1b;          /* dark card */
    color: #f2f2f2;               /* light text */
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
  }

  .article-title {
    color: #ffffff;
  }

  .article-subline,
  .article-link-hint {
    color: #cccccc;               /* readable gray */
    opacity: 1;
  }

  /* Hover/focus (dark mode) */
  .article-card-link:hover,
  .article-card-link:focus-visible {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
    border-color: rgba(255, 255, 255, 0.4);
  }
}

/* Single article layout fix */
.article-page {
  max-width: 700px;     /* optional, adjust or remove if you have your own width */
  margin: 1.5rem auto 3rem;
  text-align: left;
}

.article-page-title,
.article-page-subline,
.article-page-body {
  text-align: left;
}

/* Make sure paragraphs are left aligned too */
.article-page-body p {
  text-align: left;
}

/* Restore uncropped full image on article pages */
.article-page-thumb-wrapper {
  margin: 1rem 0;
}

.article-page-thumb {
  width: 100%;
  height: auto;      /* keep aspect ratio */
  display: block;
  max-height: none;  /* remove previous cap */
  object-fit: contain;  /* or simply remove this line */
}

/* -------------------------
   ARTICLES INDEX — CARD LAYOUT
   ------------------------- */

/* List spacing */
#articles-list {
  list-style: none;
  margin: 1.5rem 0 2.5rem;
  padding: 0 1rem; /* adds breathing room on mobile */
}

/* Card container */
.article-card {
  margin: 0 0 1.25rem 0;
}

/* Full card is a link */
.article-card-link {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(0, 0, 0, 0.15);
  text-decoration: none;
  color: inherit;
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
  transition:
    box-shadow 0.15s ease,
    transform 0.15s ease,
    border-color 0.15s ease;
}

/* Hover (light mode) */
.article-card-link:hover,
.article-card-link:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  border-color: rgba(0, 0, 0, 0.3);
}

/* Light-mode text */
.article-title {
  color: #000;
}
.article-subline,
.article-link-hint {
  color: #444;
  opacity: 1;
}

/* -------------------------
   THUMBNAIL LETTERBOXING
   ------------------------- */

/* Uniform thumbnail box — change aspect-ratio here if desired */
.article-thumb-wrapper {
  width: 100%;
  aspect-ratio: 1 / 1;   /* square thumbnail */
  background: #000;      /* solid black bars */
  border-radius: 0.75rem;
  overflow: hidden;
}

/* Image fits inside box; black bars auto-added */
.article-thumb {
  width: 100%;
  height: 100%;
  object-fit: contain;   /* NO cropping */
  background: #000;      /* ensures bars are black */
  display: block;
}

/* Text container */
.article-text {
  display: flex;
  flex-direction: column;
}

/* Typography */
.article-subline {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.35rem;
}

.article-title {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0;
  text-decoration: underline;
  text-underline-offset: 0.12em;
}

.article-link-hint {
  margin-top: 0.5rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* -------------------------
   DARK MODE
   ------------------------- */

@media (prefers-color-scheme: dark) {
  .article-card-link {
    background: #1b1b1b;
    color: #f2f2f2;
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
  }

  .article-title {
    color: #fff;
  }

  .article-subline,
  .article-link-hint {
    color: #ccc;
  }

  .article-thumb-wrapper,
  .article-thumb {
    background: #000;  /* still black for letterboxing */
  }

  .article-card-link:hover,
  .article-card-link:focus-visible {
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
  }
}

/* -------------------------
   DESKTOP ENHANCEMENT
   Only apply side-by-side layout when there's a thumbnail
   ------------------------- */

@media (min-width: 768px) {
  #articles-list {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 1.5rem;
  }

  .article-card.has-thumb .article-card-link {
    flex-direction: row;
    align-items: stretch;
  }

  .article-card.has-thumb .article-thumb-wrapper {
    flex: 0 0 220px;
    aspect-ratio: 1 / 1;  /* keep square */
  }

  .article-card.has-thumb .article-text {
    flex: 1;
  }
}

/* -------------------------
   DESKTOP: restore old thumbnail style
   (Leave mobile letterboxing as-is)
   ------------------------- */
@media (min-width: 768px) {
  /* Remove letterboxing constraints */
  .article-card.has-thumb .article-thumb-wrapper {
    aspect-ratio: auto;   /* not fixed */
    max-height: none;
    height: auto;
    background: none;     /* remove black box behind image */
    flex: 0 0 220px;       /* old desktop width */
    border-radius: 0.75rem;
    overflow: hidden;
  }

  /* Restore the original cropped look */
  .article-card.has-thumb .article-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;     /* crop to fit container */
    background: none;      /* no letterbox bars */
  }
}
