/* Folio Organised — Subscriptions page (Stage 1, public, static).
   Page-scoped styles only. Reuses :root tokens already defined in style.css (--ink, --paper,
   --accent, --accent-dark, --muted, --line, --font-sans) plus the global `h1, h2 { font-family:
   Georgia... }` base rule — this file defines no new colour/typography tokens, and touches no
   existing selector in style.css. All class names below are unique to this page.

   Visual language (Revision 2): matches the existing Sign In screen's own design exactly —
   .auth-stage-bg/.auth-stage-scrim (full-bleed photo + diagonal scrim) and .auth-stage-box
   (white, 18px-radius, 0 20px 60px shadow, 32px/28px padding card) in style.css — rather than a
   conventional hero-banner-then-plain-page layout. The photo stays fixed behind the whole page
   (position:fixed, not just a short hero band) so it's visible in the gaps around every panel as
   the page scrolls normally underneath it; this is the same position:fixed technique #authOverlay
   and .auth-stage already use elsewhere in this app, just applied to a page-length background
   instead of a single modal. */

.sub-body { background: var(--ink); color: var(--ink); margin: 0; }

/* ---------- Fixed full-screen photograph + scrim ---------- */
.sub-bg { position: fixed; inset: 0; z-index: 0; }
.sub-bg-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 42%; display: block; }
.sub-bg-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(20, 17, 14, 0.62) 0%, rgba(20, 17, 14, 0.5) 55%, rgba(20, 17, 14, 0.36) 100%);
  pointer-events: none;
}

/* Everything else sits in its own stacking context above the fixed photo, and scrolls normally
   with the document — the photo never traps or intercepts scroll, it simply doesn't move. */
.sub-content { position: relative; z-index: 1; padding: 48px 20px 64px; }

/* ---------- Shared "card over photo" panel treatment — mirrors .auth-stage-box exactly ---------- */
.sub-panel {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(20, 17, 14, 0.4);
  padding: 32px 28px;
  box-sizing: border-box;
}
@media (max-width: 480px) {
  .sub-panel { padding: 24px 20px; }
}

/* ---------- Brand panel (logo / title / motto / disclaimer / sign in) ---------- */
.sub-brand-panel {
  max-width: 420px;
  margin: 0 auto 28px;
  text-align: center;
}
.sub-brand-logo { width: 48px; height: 48px; margin-bottom: 10px; }
/* No font-family override — inherits the same global `h1, h2 { font-family: Georgia... }` rule
   .auth-title (also a plain <h2>) relies on, so this reads as pixel-identical brand typography. */
.sub-brand-title { font-size: 1.4rem; margin: 0 0 4px; }
.sub-brand-motto {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 18px;
}
.sub-disclaimer {
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--accent-dark);
  background: var(--paper-alt);
  border-radius: var(--radius);
  padding: 10px 14px;
  margin: 0 0 16px;
}
.sub-brand-signin {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: underline;
}
.sub-brand-signin:hover { color: var(--accent-dark); }
.sub-brand-signin:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Plans intro ---------- */
.sub-plans-intro { max-width: 640px; margin: 0 auto 28px; text-align: center; }
/* Matches .welcome-headline ("Welcome to Folio Organised") in style.css: same font-family
   (--welcome-sans), weight and letter-spacing — sized down for its smaller role on this page
   rather than reusing the Welcome page's own large hero size. */
.sub-plans-intro h2 {
  font-family: var(--welcome-sans, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
  font-size: 1.3rem;
  margin: 0 0 8px;
  color: #fff;
}
.sub-plans-intro p { font-family: var(--font-sans); font-size: 0.92rem; color: rgba(255, 255, 255, 0.85); margin: 0; }

/* ---------- Plan panels ---------- */
.sub-plans-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  max-width: 1120px;
  margin: 0 auto;
  align-items: start;
}

.sub-plan-card { display: flex; flex-direction: column; }

/* Studio — recommended: a restrained accent border is the only distinguishing mark, no fill
   colour or ribbon graphic, consistent with the rest of the app's quiet visual language. */
.sub-plan-recommended { border: 1.5px solid var(--accent); }
.sub-plan-recommended-label {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin: 0 0 10px;
}

.sub-plan-name { font-size: 1.2rem; margin: 0 0 6px; }
.sub-plan-price {
  font-family: var(--font-sans);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-dark);
  margin: 0 0 18px;
}
.sub-plan-price span { font-size: 0.82rem; font-weight: 500; color: var(--muted); }

.sub-plan-section-label {
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 14px 0 8px;
}
.sub-plan-section-label:first-of-type { margin-top: 0; }

.sub-plan-list { list-style: none; margin: 0; padding: 0; }
.sub-plan-list li {
  font-family: var(--font-sans);
  font-size: 0.86rem;
  line-height: 1.5;
  color: var(--ink);
  padding: 4px 0;
}
.sub-plan-list.sub-plan-excluded li { color: var(--muted); font-size: 0.82rem; }

.sub-plan-tag {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-left: 6px;
}

/* ---------- Closing panel ---------- */
.sub-closing-panel { max-width: 420px; margin: 28px auto 0; text-align: center; }
.sub-closing-panel p { font-family: var(--font-sans); font-size: 0.9rem; color: var(--ink); margin: 0 0 14px; }
.sub-closing-signin {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  color: #fff;
  background: var(--ink);
  border-radius: var(--radius);
  padding: 10px 24px;
  text-decoration: none;
}
.sub-closing-signin:hover { background: #37322c; }
.sub-closing-signin:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sub-closing-note { font-family: var(--font-sans); font-size: 0.78rem; color: var(--muted); margin: 14px 0 0 !important; }
.sub-closing-motto {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 16px 0 0 !important;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .sub-plans-grid { grid-template-columns: 1fr; max-width: 420px; }
  /* Starter/Studio/Professional stays the HTML source order (correct reading order and desktop
     column order) — only the single-column mobile stack reorders Studio to the top, visually
     only, via CSS order rather than duplicating markup. */
  .sub-plan-recommended { order: -1; }
}

@media (max-width: 640px) {
  .sub-content { padding: 32px 16px 48px; }
  .sub-plans-intro h2 { font-size: 1.15rem; }
}
