/* ============================================================
   PodMelody marketing site — shared styles
   "Editorial" design language: warm paper + deep ink + one moss
   accent. Flat surfaces, 1px hairline borders, never drop shadows
   (the sticky-header blur is the one intentional exception).
   ============================================================ */

:root {
  /* Surfaces & ink */
  --bg:          #F7F4EE;   /* warm paper — page background */
  --ink:         #1F1C12;   /* warm near-black — primary text */
  --ink-2:       #565043;   /* secondary text */
  --ink-3:       #8A836F;   /* tertiary text / meta */
  --surface:     #F1ECE1;   /* slightly raised paper (bands, cards) */
  --elevated:    #ECE4D6;   /* a touch further raised */
  --hair:        rgba(31, 28, 18, 0.12);  /* 1px hairline */
  --hair-2:      rgba(31, 28, 18, 0.20);  /* stronger hairline */
  --subtle-fill: rgba(31, 28, 18, 0.10);  /* inactive track/fill */

  /* Accent — moss (the single accent; swap here for another) */
  --accent:      #5F7137;
  --accent-deep: #4C5B2C;
  --on-accent:   #F7F4EE;

  /* Category "plate" tints (pale cards behind the accent art) */
  --plate-news: #D8DEE0;
  --plate-feel: #E7DAC7;
  --plate-ent:  #E2D9E8;
  --plate-sci:  #D8E1D9;

  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans:  'Outfit', system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-deep); }
img { display: block; max-width: 100%; }

/* One keyboard-focus ring for the whole site. Without it the only visible
   focus is the mobile menu button, which makes tabbing through the nav and
   the FAQ disclosures a guessing game. :focus-visible so a mouse click on a
   link or a summary doesn't leave a ring behind. */
a:focus-visible,
button:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

.shell { max-width: 1180px; margin: 0 auto; padding: 0 40px; width: 100%; }

/* ── View fade-in ─────────────────────────────────────────── */
@keyframes pmfade {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}
.pm-view { animation: pmfade 0.4s cubic-bezier(0.16, 1, 0.3, 1); }
main { flex: 1; }

/* The fade-in and the smooth anchor scrolling in the guide are both motion the
   OS setting asks us to drop. Anchors still jump to the right place — they just
   arrive instantly. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .pm-view { animation: none; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ── Header ───────────────────────────────────────────────── */
.pm-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(247, 244, 238, 0.86);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--hair);
}
.pm-header-inner {
  max-width: 1180px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 40px;
}
.pm-wordmark {
  font-family: var(--font-serif); font-weight: 600;
  font-size: 23px; color: var(--ink); line-height: 1;
}
/* "Pod" upright ink, "Melody" italic in the accent — the house emphasis rule
   applied to the wordmark itself. Shared by the header wordmark and the
   footer mark (.fmark), so both stay in step from one place. */
.pm-wordmark .pod,
.pm-footer .fmark .pod    { font-style: normal; }
.pm-wordmark .melody,
.pm-footer .fmark .melody { font-style: italic; color: var(--accent); }
.pm-wordmark:hover { color: var(--ink); }
.pm-wordmark:hover .melody { color: var(--accent); }
.pm-nav { display: flex; align-items: center; gap: 26px; }
.pm-nav-link {
  font-family: var(--font-sans); font-weight: 500; font-size: 11.5px;
  letter-spacing: 0.09em; text-transform: uppercase; color: var(--ink-2);
  padding: 4px 0; border-bottom: 1px solid transparent;
}
.pm-nav-link:hover { color: var(--ink); }
.pm-nav-link.on { color: var(--ink); border-bottom-color: var(--accent); }

.pm-mobile-menu { display: none; position: relative; }
.pm-mobile-menu summary {
  display: inline-flex; align-items: center; gap: 8px;
  list-style: none; cursor: pointer;
  font-size: 11.5px; font-weight: 600; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--ink);
  padding: 9px 12px; border: 1px solid var(--hair-2); border-radius: 8px;
}
.pm-mobile-menu summary::-webkit-details-marker { display: none; }
.pm-mobile-menu summary::after { content: "+"; color: var(--accent); font-size: 15px; line-height: 0.8; }
.pm-mobile-menu[open] summary::after { content: "−"; }
.pm-mobile-menu summary:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 3px;
}
.pm-mobile-panel {
  position: absolute; top: calc(100% + 10px); right: 0;
  display: flex; flex-direction: column; gap: 2px;
  min-width: 224px; padding: 10px;
  background: var(--bg); border: 1px solid var(--hair-2); border-radius: 12px;
}
.pm-mobile-panel a {
  padding: 10px 11px; border-radius: 7px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.07em;
  text-transform: uppercase; color: var(--ink-2);
}
.pm-mobile-panel a:hover,
.pm-mobile-panel a.on { background: var(--surface); color: var(--ink); }

/* The header keeps a compact text CTA; Apple's official badge is reserved for
   the primary download action so the page does not repeat or restyle it. */
.pm-nav-link.pm-download-link {
  background: var(--ink); border: 1px solid var(--ink); border-radius: 7px;
  color: var(--bg); padding: 8px 13px;
}
.pm-nav-link.pm-download-link:hover {
  background: var(--accent-deep); border-color: var(--accent-deep); color: var(--bg);
}
.pm-mobile-panel .pm-download-link {
  background: var(--ink); color: var(--bg); margin-top: 6px; text-align: center;
}
.pm-mobile-panel .pm-download-link:hover { background: var(--accent-deep); color: var(--bg); }
.app-store-badge {
  display: inline-flex; flex: none; line-height: 0;
  transition: opacity 160ms ease;
}
.app-store-badge:hover { opacity: 0.82; }
.app-store-badge img {
  display: block; width: 172px; height: auto;
}

/* ── Typographic components ───────────────────────────────── */
.eyebrow {
  font-family: var(--font-sans); font-weight: 600; font-size: 11px;
  letter-spacing: 0.09em; text-transform: uppercase; color: var(--accent);
  margin: 0;
}
.accent-title {
  font-family: var(--font-serif); font-weight: 500; color: var(--ink);
  line-height: 1.04; letter-spacing: -0.01em; margin: 0;
}
.accent-title .tail { font-style: italic; color: var(--accent); font-weight: 400; }
.pull-quote {
  font-family: var(--font-serif); font-style: italic; font-size: 25px;
  line-height: 1.3; color: var(--ink); margin: 0;
}
.lead {
  font-family: var(--font-sans); font-weight: 300; font-size: 16px;
  line-height: 1.6; color: var(--ink-2); margin: 0;
}

/* ── Buttons ──────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-sans); font-weight: 500; font-size: 13px;
  letter-spacing: 0.01em; border-radius: 8px; padding: 10px 18px;
  cursor: pointer; border: 1px solid transparent; transition: color 0.2s, background 0.2s;
  background: var(--accent); color: var(--on-accent);
}
.btn:hover { background: var(--accent-deep); color: var(--on-accent); }
.btn.outline { background: transparent; color: var(--ink); border-color: var(--hair-2); }
.btn.outline:hover { background: transparent; color: var(--accent-deep); border-color: var(--accent); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--hair); }
.btn.ghost:hover { background: transparent; color: var(--accent-deep); border-color: var(--accent); }
.btn.full { width: 100%; }
.btn.lg { padding: 11px 22px; font-size: 13.5px; }
.btn.pending { cursor: default; }
.btn.pending:hover { background: var(--accent); color: var(--on-accent); }
.btn.outline.pending:hover {
  background: transparent; color: var(--ink); border-color: var(--hair-2);
}

.badge {
  display: inline-flex; align-items: center; font-family: var(--font-sans);
  font-weight: 600; font-size: 10px; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--on-accent); background: var(--accent); border-radius: 20px; padding: 3px 9px;
}

.text-link {
  font-family: var(--font-sans); font-size: 13px; font-weight: 600;
  letter-spacing: 0.04em; color: var(--accent);
}
.text-link:hover { color: var(--accent-deep); }

/* ── SlipPlate (square art on a ~6° tilted tinted card) ───── */
.plate {
  width: var(--s, 48px); height: var(--s, 48px); flex: none;
  background: var(--tint, var(--plate-news)); border-radius: 5px;
  transform: rotate(var(--angle, -6deg));
  display: grid; place-items: center;
}
.plate::after {
  content: ""; display: block; width: 62%; height: 62%;
  border-radius: 3px; background: var(--accent);
}

/* ── Queue rows (Up next list) ────────────────────────────── */
.queue-row {
  display: flex; align-items: center; gap: 16px; padding: 13px 0;
  border-top: 1px solid var(--hair);
}
.queue-row .meta { flex: 1; min-width: 0; }
.queue-row .title { font-family: var(--font-serif); font-size: 17px; color: var(--ink); }
.queue-row .title em { font-style: italic; color: var(--accent); }
.queue-row .sub { font-size: 12px; color: var(--ink-3); }
.queue-row .dur {
  font-size: 12.5px; color: var(--ink-2); font-variant-numeric: tabular-nums;
}

/* ── App screenshots ──────────────────────────────────────── */
/* A real screen capture in a minimal device bezel. The bezel is a plain ink
   border rather than a rendered phone chrome — the house rule is flat surfaces
   and hairlines, and a photoreal handset would be the loudest object on the
   page. Captions carry the explanation so the shot itself never has to be
   squinted at.

   Sizing rule: never render a capture wider than half its pixel width, so it
   stays sharp on a 2× display. Callers set `--shot-w` accordingly. */
.pm-shot { display: flex; flex-direction: column; gap: 14px; margin: 0; }
.pm-shot .frame {
  width: 100%; max-width: var(--shot-w, 320px); overflow: hidden;
  background: var(--ink); border: 8px solid var(--ink); border-radius: 30px;
}
/* height:auto so a capture can carry intrinsic width/height attributes — those
   reserve the right box before the image loads, but without this the attribute
   height wins over the scaled width and the frame stretches to the full 1956px. */
.pm-shot .frame img { width: 100%; height: auto; display: block; }
.pm-shot figcaption {
  font-family: var(--font-sans); font-weight: 300; font-size: 13px;
  line-height: 1.55; color: var(--ink-2); max-width: var(--shot-w, 320px);
}
.pm-shot figcaption strong {
  font-family: var(--font-serif); font-weight: 600; font-style: italic;
  font-size: 15px; color: var(--ink);
}
/* Landscape captures (iPad, CarPlay) — squarer corners, wider ceiling. */
.pm-shot.wide { --shot-w: 100%; }
.pm-shot.wide .frame { border-radius: 18px; border-width: 10px; }

/* ── Footer ───────────────────────────────────────────────── */
.pm-footer { background: var(--surface); border-top: 1px solid var(--hair); }
.pm-footer-inner {
  max-width: 1180px; margin: 0 auto; padding: 48px 44px;
  display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px;
}
.pm-footer .fmark {
  font-family: var(--font-serif); font-weight: 600;
  font-size: 22px; color: var(--ink);
}
.pm-footer p { font-size: 13px; line-height: 1.6; color: var(--ink-2); max-width: 300px; margin: 0; }
.pm-footer .note { font-size: 12px; color: var(--ink-3); }
.pm-footer .col { display: flex; flex-direction: column; gap: 9px; }
.pm-footer .col-head {
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase;
  font-weight: 600; color: var(--ink-3); margin-bottom: 2px;
}
.pm-footer .col a { font-size: 13px; color: var(--ink-2); }
.pm-footer .col a:hover { color: var(--accent); }
.pm-footer .col a.studio { color: var(--accent); }
.pm-subbar { border-top: 1px solid var(--hair); }
.pm-subbar-inner {
  max-width: 1180px; margin: 0 auto; padding: 16px 44px;
  display: flex; justify-content: space-between; gap: 12px 28px;
  font-size: 11.5px; color: var(--ink-3);
}
/* Support/privacy sit with the copyright rather than in a footer column: they
   are the two links a visitor arrives at the site *looking* for (the App Store
   listing points at support), so they get a fixed home on every page. Muted to
   the subbar's own ink — accent green here would outrank the nav above it. */
.pm-subbar-inner .legal { text-align: right; }
.pm-subbar-inner a { color: var(--ink-3); border-bottom: 1px solid var(--hair-2); }
.pm-subbar-inner a:hover { color: var(--accent); border-bottom-color: var(--accent); }
.pm-credit {
  max-width: 1180px; margin: 0 auto; padding: 0 44px 14px;
  font-size: 9.5px; line-height: 1.45; color: var(--ink-3);
}

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 820px) {
  .shell { padding: 0 22px; }
  .pm-header-inner { padding: 14px 22px; }
  .pm-nav { display: none; }
  .pm-mobile-menu { display: block; }
  .pm-footer-inner { grid-template-columns: 1fr; gap: 28px; padding: 40px 22px; }
  .pm-subbar-inner { flex-direction: column; gap: 6px; padding: 16px 22px; }
  /* Stacked, the subbar is a single left-hand column — the desktop right-edge
     alignment would leave the two lines ragged against each other. */
  .pm-subbar-inner .legal { text-align: left; }
  .pm-credit { padding: 0 22px 14px; }
}
