/* ============================================================
   NOTP - Shared Campaign / Game Page CSS (campaign-common.css)
   Loads after notp.css. All brand tokens inherited.

   This holds the layout & chrome shared by every full subpage
   built on the "campaign-page" body class — campaign pages
   (lagrangepoint.php, duskhome.php) AND one-shot game pages
   (games.php). Page-specific content (episode accordions,
   character grids, lightboxes, etc.) stays in that page's own
   stylesheet, e.g. duskhome.css.
   ============================================================ */

/* -- CAMPAIGN HEADER - faded logo watermark background ----- */

#campaign-header {
  position: relative;
  background: var(--black);
  border-bottom: 1px solid var(--border);
  overflow: visible; /* allow logo to bleed below into nav area */
  min-height: 180px;
  display: flex;
  align-items: center;
  z-index: 0;
}

/* Faded logo - large, anchored top-left, bleeds below the header */
#campaign-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 2.5rem; /* nudged away from edge */
  width: 420px;
  height: 420px;
  background-image: url('/img/notp-logo.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: left top;
  opacity: 0.38;
  pointer-events: none;
  z-index: 0;
}

.campaign-anchor-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
  font-family: var(--font-display);
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--border-hot);
  padding: 0.5rem 1.1rem;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.campaign-anchor-btn:hover {
  background: var(--gold);
  color: #000;
}

/* Nav sits above the bleeding logo */
#main-nav {
  position: relative;
  z-index: 10;
  background: transparent; /* transparent - buttons carry their own bg */
  border-bottom: 1px solid var(--border);
  backdrop-filter: none;
}

/* Individual nav buttons get the dark background */
#main-nav a {
  background: rgba(8, 8, 8, 0.88);
  border-right: 1px solid var(--border);
}

#main-nav a:first-child {
  border-left: 1px solid var(--border);
}

#main-nav a:hover {
  background: rgba(30, 30, 30, 0.96);
  color: #fff;
}

.campaign-header-inner {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem 2rem;
  display: flex;
  align-items: center;
}

/* Home link - sits over the faded logo area */
.header-logo-link {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-dim);
  font-family: var(--font-display);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: color 0.2s;
  /* Push link to the right so it clears the faded logo area */
  margin-left: 260px;
}

.header-logo-link:hover {
  color: var(--gold);
}

.header-logo-link::before {
  content: '←';
  font-size: 16px;
}

/* Real logo image variant - swap ::before for this when PNG confirmed */
.header-logo-img {
  height: 52px;
  width: auto;
  filter: drop-shadow(0 0 12px rgba(200,144,10,0.4));
  transition: filter 0.2s;
}

.header-logo-link:hover .header-logo-img {
  filter: drop-shadow(0 0 20px rgba(200,144,10,0.7));
}

/* Mobile: smaller watermark */
@media (max-width: 680px) {
  #campaign-header {
    min-height: 140px;
  }

  #campaign-header::before {
    width: 240px;
    height: 240px;
    opacity: 0.12;
  }

  .header-logo-link {
    margin-left: 120px;
  }
}

/* -- CAMPAIGN LAYOUT --------------------------------------- */

#campaign-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem 4rem;
}

.campaign-layout {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 4rem;
  align-items: start;
  padding-top: 3rem;
}

/* -- POSTER COLUMN ----------------------------------------- */

.campaign-poster-col {
  /* Sticky: poster stays in view as user scrolls right column */
  position: sticky;
  top: calc(56px + 1.5rem); /* nav height + breathing room */
}

.campaign-poster-wrap {
  width: 100%;
  border: 1px solid var(--border);
}

.campaign-poster-img {
  width: 100%;
  height: auto;
  display: block;
  /* Natural portrait ratio, zero cropping */
}

/* -- CONTENT COLUMN ---------------------------------------- */

.campaign-identity {
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2.5rem;
}

.campaign-identity .campaign-tag {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--border-hot);
  padding: 3px 10px;
  margin-bottom: 1rem;
}

.campaign-title {
  font-family: var(--font-display);
  font-size: clamp(36px, 5vw, 60px);
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.01em;
  line-height: 1;
  margin-bottom: 0.6rem;
}

.campaign-subtitle {
  font-size: 18px;
  color: var(--text-muted);
  font-style: italic;
}

/* -- SECTIONS ---------------------------------------------- */

.campaign-section {
  margin-bottom: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--border);
}

.campaign-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.campaign-section-title {
  font-family: var(--font-display);
  font-size: clamp(18px, 3vw, 26px);
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

/* -- LORE -------------------------------------------------- */

.campaign-lore p {
  font-size: 17px;
  line-height: 1.85;
  color: var(--text);
  margin-bottom: 1.1rem;
}

.campaign-lore p:last-child { margin-bottom: 0; }

/* -- CAMPAIGN PRIMER - intro callout box --------------------- */

.campaign-primer {
  border-left: 3px solid var(--gold);
  background: rgba(200, 144, 10, 0.05);
  padding: 1.25rem 1.5rem;
  margin-bottom: 2.5rem;
}

.campaign-primer p {
  font-size: 18px;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: 0.85rem;
  font-style: italic;
}

.campaign-primer p:last-child {
  margin-bottom: 0;
}

/* -- QUICK FACTS --------------------------------------------- */

.quick-facts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
}

.quick-fact {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  padding: 1rem 1.25rem;
}

.quick-fact-label {
  display: block;
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.35rem;
}

.quick-fact-value {
  display: block;
  font-size: 17px;
  color: #fff;
  font-weight: 600;
}

/* -- DOWNLOADS ------------------------------------------------ */

.download-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.download-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  text-decoration: none;
  transition: background 0.2s;
}

.download-item:hover { background: #1a1a1a; }

.download-icon {
  font-size: 22px;
  color: var(--gold);
  flex-shrink: 0;
}

.download-info {
  display: flex;
  flex-direction: column;
}

.download-name {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  color: #fff;
}

.download-item:hover .download-name { color: var(--gold); }

.download-meta {
  font-size: 13px;
  color: var(--text-muted);
}

/* -- RESPONSIVE ------------------------------------------------ */

@media (max-width: 960px) {
  .campaign-layout {
    grid-template-columns: 260px 1fr;
    gap: 2.5rem;
  }
}

@media (max-width: 768px) {
  #campaign-main {
    padding: 0 1.5rem 3rem;
  }

  .campaign-layout {
    grid-template-columns: 220px 1fr;
    gap: 1.75rem;
  }

  .campaign-title {
    font-size: clamp(28px, 6vw, 44px);
  }

  /* Nav buttons tighten up */
  #main-nav a {
    font-size: 13px;
    padding: 0.85rem 1rem;
    letter-spacing: 0.08em;
  }
}

@media (max-width: 680px) {
  /* Header watermark smaller */
  #campaign-header {
    min-height: 120px;
  }

  #campaign-header::before {
    width: 200px;
    height: 200px;
    opacity: 0.2;
    left: 1rem;
  }

  .header-logo-link {
    margin-left: 100px;
    font-size: 11px;
  }

  #campaign-main {
    padding: 0 1rem 2.5rem;
  }

  /* Stack poster above content */
  .campaign-layout {
    grid-template-columns: 1fr;
    gap: 1.75rem;
    padding-top: 1.5rem;
  }

  .campaign-poster-col {
    position: static;
  }

  .campaign-poster-wrap {
    max-width: 280px;
    margin: 0 auto;
  }

  .campaign-title {
    font-size: clamp(28px, 8vw, 42px);
  }

  .campaign-subtitle {
    font-size: 16px;
  }

  .campaign-section {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
  }

  .campaign-lore p {
    font-size: 16px;
  }
}

/* -- Very small phones (380px) ------------------------------ */
@media (max-width: 380px) {
  #main-nav a {
    font-size: 11px;
    padding: 0.75rem 0.6rem;
    letter-spacing: 0.05em;
  }

  .campaign-title {
    font-size: clamp(24px, 9vw, 36px);
  }
}
