/* Shared styles for the generated Deck pages (/decks/) and Learn Tarot video
   pages (/learn/). Palette + type match the main site and the Founder's Story
   pages (see template_supporting_page.html and story/story.css). Root-relative
   asset paths so the same file serves every subdirectory. */
:root {
  --bg-cream: #EFE6DF;
  --bg-cream-soft: #F5EEE8;
  --bg-card: #EBE0D6;
  --ink: #151413;
  --ink-soft: #4A4644;
  --ink-mute: #6C6966;
  --gold: #C9A26B;
  --gold-soft: rgba(201, 162, 107, 0.28);
  --border-subtle: rgba(21, 20, 19, 0.08);
  --content-width: 680px;
  --shell-width: 1100px;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Jost', system-ui, sans-serif;
  background: var(--bg-cream);
  color: var(--ink);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
img { max-width: 100%; display: block; }
.shell { max-width: var(--shell-width); margin: 0 auto; padding: 0 24px; }

/* Header */
header {
  padding: 20px 0;
  position: sticky; top: 0;
  background: rgba(239, 230, 223, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 100;
  border-bottom: 1px solid var(--border-subtle);
}
.header-inner { display: flex; justify-content: space-between; align-items: center; }
.logo {
  display: flex; align-items: center; gap: 12px;
  font-weight: 600; font-size: 19px; letter-spacing: 0.2px;
  color: var(--ink); text-decoration: none;
}
.logo img { height: 32px; width: auto; }
nav ul { display: flex; gap: 30px; list-style: none; }
nav a {
  color: var(--ink-mute); text-decoration: none;
  font-size: 15px; font-weight: 500; transition: color 0.2s;
  padding-bottom: 2px;
}
nav a:hover { color: var(--ink); }
nav a[aria-current="page"] { color: var(--ink); border-bottom: 1.5px solid var(--gold); }

/* Page body */
main.page { padding: 64px 0 96px; }
.page-header { max-width: var(--content-width); margin: 0 auto 48px; text-align: center; }
.eyebrow {
  color: var(--gold); font-size: 12px;
  letter-spacing: 0.22em; text-transform: uppercase;
  font-weight: 600; margin-bottom: 12px;
}
h1 {
  font-size: clamp(34px, 5vw, 48px);
  font-weight: 700; letter-spacing: -0.02em;
  line-height: 1.1; margin-bottom: 16px;
  color: var(--ink);
}
.lead { font-size: 19px; color: var(--ink-soft); line-height: 1.65; }
.back-link {
  display: inline-block; margin-bottom: 24px;
  color: var(--ink-mute); text-decoration: none; font-size: 14px; font-weight: 500;
}
.back-link:hover { color: var(--ink); }
.back-link::before { content: '\2190  '; color: var(--gold); }

.btn-primary {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--ink); color: var(--bg-cream-soft);
  padding: 15px 30px; border-radius: 999px; text-decoration: none;
  font-weight: 600; font-size: 16px;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 8px 24px rgba(21, 20, 19, 0.18);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(21, 20, 19, 0.24); }
.open-app { text-align: center; margin-bottom: 56px; }
.open-app .hint, .hint { display: block; font-size: 13px; color: var(--ink-mute); margin-top: 14px; line-height: 1.5; }

/* Vertical 9:16 player (shared with the Founder's Story pages) */
.player {
  height: min(68vh, 620px);
  aspect-ratio: 9 / 16;
  width: auto;
  max-width: 100%;
  margin: 0 auto;
  background: #000;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 14px 40px rgba(21, 20, 19, 0.18);
}
.player video, .player iframe { width: 100%; height: 100%; display: block; border: 0; object-fit: contain; background: #000; }
.player.placeholder {
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.7); font-size: 15px; text-align: center; padding: 24px;
}

/* Deck index grid */
.decks-grid {
  display: grid; grid-template-columns: repeat(5, 1fr);
  gap: 18px; margin-bottom: 64px;
}
a.deck { display: block; text-decoration: none; color: inherit; transition: transform 0.3s; }
a.deck:hover { transform: translateY(-6px); }
.deck-card {
  position: relative;
  aspect-ratio: 2/3; border-radius: 8px; overflow: hidden;
  box-shadow: 0 14px 36px rgba(21, 20, 19, 0.18), 0 0 0 1px rgba(201, 162, 107, 0.18);
  background: var(--bg-cream-soft);
}
.deck-card img { width: 100%; height: 100%; object-fit: cover; display: block; }
.video-badge {
  position: absolute; top: 10px; left: 10px;
  background: rgba(21, 20, 19, 0.78); color: var(--bg-cream-soft);
  font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; font-weight: 600;
  padding: 5px 9px; border-radius: 999px;
  display: inline-flex; align-items: center; gap: 6px;
}
.video-badge::before {
  content: ''; width: 0; height: 0;
  border-style: solid; border-width: 4px 0 4px 6px;
  border-color: transparent transparent transparent var(--gold);
}
.deck-meta { margin-top: 14px; text-align: center; }
.deck-name { font-weight: 600; font-size: 15px; letter-spacing: -0.005em; color: var(--ink); }
.deck-tag { font-size: 13px; color: var(--ink-mute); margin-top: 4px; font-style: italic; }
.deck-price { font-size: 12px; color: var(--gold); margin-top: 6px; letter-spacing: 0.05em; font-weight: 600; }

/* Deck detail page */
.deck-hero {
  display: grid; grid-template-columns: minmax(0, 420px) minmax(0, 1fr);
  grid-template-areas: "media head" "media details";
  grid-template-rows: auto 1fr;
  column-gap: 56px; row-gap: 0; align-items: start;
  max-width: 980px; margin: 0 auto;
}
.deck-hero .deck-head { grid-area: head; padding-top: 8px; }
.deck-hero .media { grid-area: media; }
.deck-hero .details { grid-area: details; }
.deck-hero .media { display: flex; justify-content: center; }
.deck-art {
  width: min(100%, 360px); aspect-ratio: 2/3; border-radius: 12px; overflow: hidden;
  box-shadow: 0 18px 44px rgba(21, 20, 19, 0.22), 0 0 0 1px rgba(201, 162, 107, 0.18);
  background: var(--bg-cream-soft);
}
.deck-art img { width: 100%; height: 100%; object-fit: cover; }
.deck-hero h1 { margin-bottom: 8px; }
.tagline { font-size: 21px; color: var(--ink-soft); font-style: italic; line-height: 1.45; margin-bottom: 20px; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.tag {
  font-size: 13px; font-weight: 500; color: var(--ink-soft);
  background: var(--bg-card); border: 1px solid var(--border-subtle);
  padding: 5px 12px; border-radius: 999px;
}
.tag.primary { font-weight: 600; color: var(--ink); }
.details p { font-size: 17px; color: var(--ink-soft); line-height: 1.7; margin-bottom: 18px; }
.price-row { font-size: 14px; color: var(--gold); letter-spacing: 0.06em; font-weight: 600; text-transform: uppercase; margin-bottom: 18px; }
.art-mini {
  display: flex; align-items: center; gap: 16px;
  margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--border-subtle);
}
.art-mini .thumb {
  width: 84px; aspect-ratio: 2/3; border-radius: 6px; overflow: hidden; flex-shrink: 0;
  box-shadow: 0 8px 20px rgba(21, 20, 19, 0.18), 0 0 0 1px rgba(201, 162, 107, 0.18);
}
.art-mini .thumb img { width: 100%; height: 100%; object-fit: cover; }
.art-mini .caption { font-size: 14px; color: var(--ink-mute); line-height: 1.5; }

/* "More decks" strip on detail pages */
.more-decks { max-width: 980px; margin: 72px auto 0; padding-top: 40px; border-top: 1px solid var(--border-subtle); }
.more-decks h2 { font-size: 22px; font-weight: 600; letter-spacing: -0.01em; margin-bottom: 20px; }
.more-decks .decks-grid { margin-bottom: 0; }

/* Learn pages: long-form article copy rendered from Markdown */
.content { max-width: var(--content-width); margin: 0 auto; font-size: 17px; line-height: 1.75; color: var(--ink); }
.content .page-header { margin: 0 0 32px; padding-bottom: 28px; border-bottom: 1px solid var(--border-subtle); text-align: left; max-width: none; }
.content .page-header h1 { margin-bottom: 0; }
.content h2 { font-size: 24px; font-weight: 600; letter-spacing: -0.012em; line-height: 1.25; margin: 48px 0 14px; scroll-margin-top: 96px; }
.content p { margin-bottom: 1.2em; color: var(--ink); }
.content p a { color: var(--ink); text-decoration: none; border-bottom: 1.5px solid var(--gold-soft); transition: border-color 0.2s; }
.content p a:hover { border-bottom-color: var(--gold); }
.content strong { font-weight: 600; }
.content ul { margin: 0 0 1.4em 1.4em; }
.content li { margin-bottom: 8px; padding-left: 4px; }
.content li::marker { color: var(--gold); }
.content p.cta { margin: 28px 0 8px; }
.content p.cta a.btn-primary { border-bottom: none; color: var(--bg-cream-soft); }
.content p.cta a.btn-primary:hover { color: var(--bg-cream-soft); }
.content .article-video { margin: 36px 0 40px; }
.content .back-link { margin-bottom: 20px; }

/* Learn index cards (match the Founder's Story grid) */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}
.video-card {
  display: flex; flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 24px;
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  min-height: 180px;
}
.video-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 28px rgba(21, 20, 19, 0.10);
  border-color: var(--gold-soft);
}
.video-card.coming { opacity: 0.6; pointer-events: none; }
.video-kicker {
  font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--gold); font-weight: 600; margin-bottom: 12px;
}
.video-title { font-size: 22px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.2; margin-bottom: 10px; }
.video-blurb { font-size: 15px; color: var(--ink-mute); line-height: 1.55; flex: 1; }
.video-cta { margin-top: 16px; font-size: 14px; font-weight: 600; color: var(--ink); }
.video-cta::after { content: ' \2192'; color: var(--gold); }
.video-card.coming .video-cta { color: var(--ink-mute); }
.video-card.coming .video-cta::after { content: ''; }

/* Learn watch page */
.watch-body { max-width: var(--content-width); margin: 0 auto; }
.watch-body .eyebrow, .watch-body h1 { text-align: center; }
.watch-body .player { margin-bottom: 16px; }
.watch-body .blurb {
  font-size: 18px; color: var(--ink-soft); line-height: 1.7;
  text-align: center; margin: 12px auto 0; max-width: 560px;
}
.watch-app { text-align: center; margin-top: 32px; }
.pager {
  display: flex; justify-content: space-between; gap: 16px;
  margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--border-subtle);
}
.pager a {
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px;
  border-bottom: 1.5px solid var(--gold-soft); padding-bottom: 2px;
}
.pager a:hover { border-bottom-color: var(--gold); }
.pager .spacer { flex: 1; }

/* Footer */
footer {
  padding: 48px 0 64px;
  border-top: 1px solid var(--border-subtle);
  color: var(--ink-mute); font-size: 14px;
  background: var(--bg-cream-soft);
  margin-top: 80px;
}
.footer-inner {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 24px;
}
.footer-brand { display: flex; align-items: center; gap: 10px; }
.footer-brand img { height: 24px; width: auto; opacity: 0.85; }
footer ul { display: flex; gap: 26px; list-style: none; flex-wrap: wrap; }
footer a { color: var(--ink-mute); text-decoration: none; transition: color 0.2s; }
footer a:hover { color: var(--ink); }

@media (max-width: 900px) {
  /* Phones: name and tagline first, then the video, then the details. */
  .deck-hero { grid-template-columns: 1fr; grid-template-areas: "head" "media" "details"; grid-template-rows: auto; row-gap: 28px; }
  .deck-hero .deck-head { text-align: center; padding-top: 0; }
  .deck-hero .details { text-align: center; }
  .player { height: min(60vh, 560px); }
  .deck-hero .tags { justify-content: center; }
  .art-mini { justify-content: center; text-align: left; }
}
@media (max-width: 768px) {
  main.page { padding: 48px 0 80px; }
  .content { font-size: 16px; }
  .content h2 { font-size: 22px; margin-top: 40px; }
  .decks-grid { grid-template-columns: repeat(2, 1fr); }
  nav ul { gap: 16px; font-size: 14px; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  footer ul { gap: 14px; }
}
@media (max-width: 600px) {
  .nav-secondary { display: none; }
}
@media (max-width: 480px) {
  header { padding: 16px 0; }
  .shell { padding: 0 20px; }
  .logo span { font-size: 17px; }
  .logo img { height: 28px; }
  nav ul { gap: 14px; }
}
