/* Shared styles for generated pages: jornadas, escrutinio, estadísticas, shared quinielas and guides.
   The landing (index.html) keeps its own inline styles but uses the same palette. */
:root {
  --qd-red: #e3151a;
  --qd-red-dark: #b01216;
  --qd-red-soft: #fdeceb;
  --qd-black: #1c181a;
  --qd-ink: #121011;
  --qd-white: #ffffff;
  --qd-gray-50: #fbfaf9;
  --qd-gray-100: #f4f1ee;
  --qd-gray-200: #e8e3df;
  --qd-gray-300: #d6d0cb;
  --qd-gray-500: #5d6362;
  --qd-green: #15803d;
  --qd-green-bg: #e7f6ec;
  --qd-miss: #b42318;
  --qd-miss-bg: #fdecea;
  --qd-live: #c2410c;
  --font-sans: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --shadow-soft: 0 14px 36px rgba(28, 24, 26, 0.08);
  --shadow-strong: 0 26px 70px rgba(28, 24, 26, 0.2);
  --radius-xl: 30px;
  --radius-lg: 22px;
  --radius-md: 14px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--qd-black);
  background:
    radial-gradient(circle at top left, rgba(227, 21, 26, 0.12), transparent 22%),
    linear-gradient(180deg, #ffffff 0%, #f5f2ef 100%);
  line-height: 1.6;
  overflow-x: clip;
}
/* Same background blobs as the landing page. */
body::before, body::after { content: ""; position: fixed; border-radius: 50%; pointer-events: none; z-index: -1; }
body::before { left: -12vw; bottom: -18vw; width: 42vw; height: 42vw; background: radial-gradient(circle, rgba(227, 21, 26, 0.2), transparent 70%); }
body::after { right: -9vw; top: 10rem; width: 30vw; height: 30vw; background: radial-gradient(circle, rgba(28, 24, 26, 0.09), transparent 70%); }
a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
.wrap { width: min(1160px, calc(100% - 2rem)); margin: 0 auto; }
@media (max-width: 640px) { .wrap { width: calc(100% - 1rem); } }
.narrow { width: min(820px, calc(100% - 1.5rem)); margin: 0 auto; }

/* Header styles live in /assets/header.css (shared with the legal pages). */

/* The app icon already has its own rounded, transparent corners. */
img[src*="qd-logo"] { border-radius: 0 !important; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem;
  min-height: 2.8rem; padding: 0.6rem 1.15rem;
  border-radius: 999px; border: 1px solid transparent;
  font: inherit; font-weight: 800; font-size: 0.92rem; text-decoration: none; cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: linear-gradient(135deg, var(--qd-red), var(--qd-red-dark)); color: #fff; box-shadow: 0 12px 26px rgba(176, 18, 22, 0.26); }
.btn-dark { background: var(--qd-black); color: #fff; }
.btn-light { background: #fff; color: var(--qd-black); border-color: var(--qd-gray-200); box-shadow: 0 6px 16px rgba(28, 24, 26, 0.05); }
.btn-ghost { background: rgba(255, 255, 255, 0.1); color: #fff; border-color: rgba(255, 255, 255, 0.22); }
.btn-sm { min-height: 2.35rem; padding: 0.42rem 0.9rem; font-size: 0.85rem; }
.btn svg { width: 1.1rem; height: 1.1rem; fill: currentColor; flex: none; }
a:focus-visible, .btn:focus-visible, summary:focus-visible { outline: 2px solid var(--qd-red); outline-offset: 3px; }

/* ---------- Page hero ---------- */
main { padding: 0.6rem 0 2.5rem; }
.page-hero {
  position: relative; overflow: hidden; isolation: isolate;
  margin: 0.4rem 0 1.6rem;
  padding: clamp(1.25rem, 3.5vw, 2.3rem);
  border-radius: var(--radius-xl);
  color: #fff;
  background: linear-gradient(150deg, #121011 0%, #1c181a 55%, #5d0c10 100%);
  box-shadow: var(--shadow-strong);
}
.page-hero::before {
  content: ""; position: absolute; z-index: -1; right: -120px; top: -150px;
  width: 380px; height: 380px; border-radius: 50%;
  background: radial-gradient(circle, rgba(227, 21, 26, 0.55), transparent 68%);
}
.page-hero::after {
  content: ""; position: absolute; z-index: -1; inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.9), transparent 85%);
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.9), transparent 85%);
}
.page-hero .breadcrumbs { color: rgba(255, 255, 255, 0.62); margin: 0 0 0.9rem; }
.page-hero h1 { color: #fff; margin: 0.75rem 0 0.6rem; max-width: 22ch; }
.page-hero .lead { color: rgba(255, 255, 255, 0.76); margin-bottom: 0; }
.page-hero .kicker { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.16); color: rgba(255, 255, 255, 0.82); }
.page-hero .chips { margin: 0.9rem 0 0; }
.page-hero .chip { background: rgba(255, 255, 255, 0.1); color: #fff; border: 1px solid rgba(255, 255, 255, 0.12); }
.page-hero .chip-live { background: rgba(232, 89, 12, 0.22); color: #ffd8bf; border-color: rgba(232, 89, 12, 0.4); }
.page-hero .chip-done { background: rgba(21, 128, 61, 0.25); color: #c6f1d4; border-color: rgba(21, 128, 61, 0.45); }
.page-hero .chip-wait { background: rgba(99, 102, 241, 0.22); color: #dfe0ff; border-color: rgba(99, 102, 241, 0.4); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1.2rem; }
.hero-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 0.6rem; margin-top: 1.2rem; }
.hero-stats div { padding: 0.75rem 0.9rem; border-radius: var(--radius-md); background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.1); }
.hero-stats strong { display: block; font-size: 1.35rem; line-height: 1.15; letter-spacing: -0.02em; }
.hero-stats span { display: block; line-height: 1.35; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.06em; color: rgba(255, 255, 255, 0.65); font-weight: 700; }
@media (max-width: 560px) {
  .hero-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-stats strong { font-size: 1.12rem; }
  .hero-stats span { font-size: 0.68rem; }
}

.breadcrumbs { font-size: 0.8rem; color: var(--qd-gray-500); }
.breadcrumbs a { text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }
.kicker {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.35rem 0.75rem; border-radius: 999px;
  background: #fff; border: 1px solid var(--qd-gray-200);
  color: var(--qd-gray-500); font-size: 0.72rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase;
}
.kicker::before { content: ""; width: 0.48rem; height: 0.48rem; border-radius: 50%; background: var(--qd-red); box-shadow: 0 0 0 4px rgba(227, 21, 26, 0.18); }
.kicker.live::before { animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.25; } }

h1 { font-size: clamp(1.85rem, 5.6vw, 3.1rem); line-height: 1.02; letter-spacing: -0.045em; margin: 0.7rem 0 0.6rem; }
h1 span, h2 span { color: var(--qd-red); }
.page-hero h1 span { color: #ff5a5f; }
h2 { font-size: clamp(1.35rem, 3.6vw, 1.85rem); line-height: 1.12; letter-spacing: -0.035em; margin: 2.2rem 0 0.8rem; scroll-margin-top: 5.5rem; }
h3 { font-size: 1.06rem; margin: 1.4rem 0 0.4rem; letter-spacing: -0.01em; }
.lead { color: var(--qd-gray-500); font-size: 1.04rem; max-width: 48rem; margin: 0 0 1rem; }
.muted { color: var(--qd-gray-500); }
.small { font-size: 0.84rem; }
.section-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 0.6rem; margin: 2.2rem 0 0.8rem; }
.section-head h2 { margin: 0; }

.card {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(155, 162, 158, 0.2);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  padding: 1.1rem;
}
.card-flush { padding: 0.35rem; }

/* Chips */
.chips { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: 0.4rem 0 1rem; }
.chip { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.32rem 0.7rem; border-radius: 999px; font-size: 0.8rem; font-weight: 700; background: var(--qd-gray-100); color: var(--qd-black); }
.chip-live { background: #fff1e6; color: #a2410a; }
.chip-live::before { content: ""; width: 0.45rem; height: 0.45rem; border-radius: 50%; background: var(--qd-live); animation: pulse 1.4s ease-in-out infinite; }
.chip-done { background: var(--qd-green-bg); color: var(--qd-green); }
.chip-wait { background: #eef2ff; color: #3730a3; }

/* ---------- Fixtures (scoreboard rows) ---------- */
.fixtures { list-style: none; margin: 0; padding: 0; }
.fx {
  display: grid; grid-template-columns: 2.3rem minmax(0, 1fr) auto 3.1rem; align-items: center; gap: 0.2rem 0.75rem;
  padding: 0.7rem 0.75rem; border-radius: var(--radius-md);
}
.fx { border-bottom: 1px solid var(--qd-gray-100); }
.fx:last-child { border-bottom: 0; }
.fx:hover { background: var(--qd-gray-50); }
.fx-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.1rem; height: 2.1rem; border-radius: 0.7rem;
  background: var(--qd-gray-100); color: var(--qd-gray-500); font-weight: 800; font-size: 0.86rem;
}
.fx.pleno { background: linear-gradient(90deg, var(--qd-red-soft), rgba(253, 236, 235, 0)); }
.fx.pleno .fx-num { background: var(--qd-red); color: #fff; font-size: 0.72rem; }
.fx-teams { min-width: 0; }
.fx-team { display: flex; align-items: center; justify-content: space-between; gap: 0.6rem; font-weight: 700; line-height: 1.35; max-width: 22rem; }
.fx-team span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fx-team b { font-variant-numeric: tabular-nums; min-width: 1.2rem; text-align: right; font-size: 1.02rem; }
.fx-team.win span { font-weight: 800; }
.fx-team.lose { color: var(--qd-gray-500); }
.fx-meta { display: flex; flex-wrap: wrap; gap: 0.15rem 0.6rem; margin-top: 0.25rem; font-size: 0.75rem; color: var(--qd-gray-500); }
.fx-meta .live { color: var(--qd-live); font-weight: 800; }
.fx-meta .done { color: var(--qd-green); font-weight: 700; }
.fx-time { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; font-size: 0.95rem; white-space: nowrap; }
.fx-time small { display: block; font-size: 0.68rem; color: var(--qd-gray-500); text-transform: uppercase; letter-spacing: 0.04em; font-weight: 700; }
.fx-sign { display: flex; justify-content: center; }
.sign {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 2.2rem; height: 2.2rem; padding: 0 0.4rem; border-radius: 0.7rem;
  font-weight: 800; background: var(--qd-black); color: #fff; font-size: 0.95rem;
  box-shadow: 0 6px 14px rgba(28, 24, 26, 0.16);
}
.sign.s1 { background: var(--qd-red); }
.sign.sX { background: #4b5563; }
.sign.s2 { background: var(--qd-black); }
.sign.provisional { background: #fff; color: var(--qd-black); border: 2px dashed var(--qd-gray-300); box-shadow: none; }
.sign.empty { background: transparent; box-shadow: none; color: var(--qd-gray-300); border: 2px solid var(--qd-gray-200); }
.bets { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.35rem; margin-top: 0.4rem; max-width: 18rem; font-size: 0.68rem; color: var(--qd-gray-500); font-weight: 700; }
.bets b { display: block; height: 0.3rem; border-radius: 3px; background: var(--qd-gray-200); position: relative; overflow: hidden; margin-bottom: 0.15rem; }
.bets b i { position: absolute; inset: 0 auto 0 0; background: var(--qd-red); opacity: 0.8; border-radius: 3px; }
@media (min-width: 900px) {
  .fixtures.cols { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: repeat(8, auto); grid-auto-flow: column; column-gap: 0.6rem; }
  .fixtures.cols .fx:nth-child(8) { border-bottom: 0; }
}
@media (max-width: 560px) {
  .fx { grid-template-columns: 2rem minmax(0, 1fr) auto 2.5rem; gap: 0.2rem 0.55rem; padding: 0.65rem 0.4rem; }
  .fx-num { width: 1.9rem; height: 1.9rem; font-size: 0.8rem; }
  .sign { min-width: 2rem; height: 2rem; font-size: 0.9rem; }
}

/* Combination */
.combo { display: grid; grid-template-columns: repeat(auto-fill, minmax(2.6rem, 1fr)); gap: 0.4rem; }
.combo div { text-align: center; }
.combo small { display: block; font-size: 0.66rem; color: var(--qd-gray-500); font-weight: 700; margin-bottom: 0.2rem; }
.combo .sign { width: 100%; }
.combo .pleno-cell { grid-column: span 2; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.data { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.data th, .data td { padding: 0.6rem 0.6rem; text-align: left; border-top: 1px solid var(--qd-gray-100); white-space: nowrap; }
.data thead th { border-top: 0; font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--qd-gray-500); }
.data td.num, .data th.num { text-align: right; font-variant-numeric: tabular-nums; }
.data tr.hl td { background: var(--qd-red-soft); font-weight: 800; }
.data a { font-weight: 700; text-decoration: none; }
.data a:hover { color: var(--qd-red); }
.data .muted { font-weight: 500; }

/* Prize highlight */
.prize-top { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 0.7rem; margin-bottom: 0.9rem; }
.prize-top div { padding: 0.9rem 1rem; border-radius: var(--radius-md); background: var(--qd-gray-50); border: 1px solid var(--qd-gray-200); }
.prize-top div.main { background: linear-gradient(135deg, var(--qd-red), var(--qd-red-dark)); color: #fff; border: 0; }
.prize-top strong { display: block; font-size: 1.45rem; letter-spacing: -0.03em; line-height: 1.15; }
.prize-top span { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700; opacity: 0.8; }

/* ---------- Layout helpers ---------- */
.two-col { display: grid; gap: 1rem; }
@media (min-width: 860px) { .two-col { grid-template-columns: 1fr 1fr; } }

/* ---------- CTA ---------- */
.cta {
  position: relative; overflow: hidden; isolation: isolate;
  margin: 2rem 0; padding: clamp(1.25rem, 3vw, 2rem);
  border-radius: var(--radius-xl); color: #fff;
  background: linear-gradient(150deg, #121011 0%, #1c181a 58%, #5d0c10 100%);
  box-shadow: var(--shadow-strong);
  display: grid; gap: 1rem; align-items: center;
}
.cta::after { content: ""; position: absolute; z-index: -1; right: -90px; top: -110px; width: 300px; height: 300px; border-radius: 50%; background: radial-gradient(circle, rgba(227, 21, 26, 0.5), transparent 70%); }
.cta h2 { margin: 0 0 0.5rem; color: #fff; }
.cta h2 span { color: #ff5a5f; }
.cta p { margin: 0 0 1rem; color: rgba(255, 255, 255, 0.78); max-width: 40rem; }
.cta ul { list-style: none; margin: 0 0 1.1rem; padding: 0; display: grid; gap: 0.4rem; color: rgba(255, 255, 255, 0.88); }
.cta li::before { content: "✓"; display: inline-flex; align-items: center; justify-content: center; width: 1.3rem; height: 1.3rem; margin-right: 0.55rem; border-radius: 50%; background: rgba(227, 21, 26, 0.9); font-size: 0.72rem; font-weight: 800; }
.cta-phone { display: none; }
@media (min-width: 860px) {
  .cta.with-phone { grid-template-columns: 1fr 210px; }
  .cta-phone { display: block; width: 210px; margin: -1rem 0 -3.5rem; transform: rotate(6deg); filter: drop-shadow(0 24px 40px rgba(0, 0, 0, 0.45)); }
}
.cta-inline {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.8rem;
  margin: 1.2rem 0; padding: 0.85rem 0.9rem 0.85rem 1.1rem;
  border-radius: var(--radius-lg); background: #fff; border: 1px solid var(--qd-gray-200); box-shadow: var(--shadow-soft);
}
.cta-inline p { margin: 0; font-weight: 800; display: flex; align-items: center; gap: 0.6rem; }
.cta-inline p img { width: 2.1rem; height: 2.1rem; border-radius: 0.6rem; flex: none; }

.stores { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.store {
  display: inline-flex; align-items: center; gap: 0.6rem;
  min-width: 10.5rem; padding: 0.55rem 1rem;
  border-radius: var(--radius-md); text-decoration: none;
  background: #fff; color: var(--qd-black); border: 1px solid var(--qd-gray-200);
  transition: transform 0.15s;
}
.store:hover { transform: translateY(-1px); }
.store svg { width: 1.45rem; height: 1.45rem; fill: currentColor; flex: none; }
.store small { display: block; font-size: 0.64rem; letter-spacing: 0.07em; text-transform: uppercase; }
.store strong { display: block; font-size: 1.02rem; line-height: 1.1; }
.store.dark { background: var(--qd-black); color: #fff; border-color: rgba(255, 255, 255, 0.18); }

/* ---------- Tiles ---------- */
.grid { display: grid; gap: 0.75rem; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.tile {
  position: relative; display: block; text-decoration: none;
  padding: 1rem 1.1rem; border-radius: var(--radius-lg);
  background: #fff; border: 1px solid var(--qd-gray-200); box-shadow: 0 6px 16px rgba(28, 24, 26, 0.05);
  transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.tile:hover { transform: translateY(-2px); border-color: rgba(227, 21, 26, 0.5); box-shadow: 0 14px 28px rgba(28, 24, 26, 0.09); }
.tile strong { display: block; font-size: 1.02rem; letter-spacing: -0.01em; }
.tile span { display: block; margin-top: 0.2rem; font-size: 0.84rem; color: var(--qd-gray-500); line-height: 1.45; }
.tile em { position: absolute; top: 0.9rem; right: 1rem; font-style: normal; font-size: 0.7rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--qd-gray-500); }
.tile em.live { color: var(--qd-live); }
.tile em.done { color: var(--qd-green); }
.tile .tile-icon, .tile-icon { display: inline-flex; margin-top: 0; line-height: 1; align-items: center; justify-content: center; width: 2.4rem; height: 2.4rem; border-radius: 0.8rem; background: var(--qd-red-soft); color: var(--qd-red-dark); font-weight: 800; margin-bottom: 0.6rem; font-size: 0.92rem; }
.pager { display: flex; justify-content: space-between; gap: 0.75rem; margin-top: 1.6rem; flex-wrap: wrap; }

/* ---------- Shared quiniela picks ---------- */
.picks { display: inline-flex; gap: 0.22rem; }
.pick { display: inline-flex; align-items: center; justify-content: center; width: 1.9rem; height: 1.9rem; border-radius: 0.55rem; font-weight: 800; font-size: 0.85rem; border: 1px solid var(--qd-gray-200); color: #b9bebc; background: #fff; }
.pick.on { background: var(--qd-black); color: #fff; border-color: var(--qd-black); }
.pick.on.hit { background: var(--qd-green); border-color: var(--qd-green); }
.pick.on.miss { background: var(--qd-miss); border-color: var(--qd-miss); }
.pick.wide { width: auto; padding: 0 0.6rem; }
.fx.row-hit { background: var(--qd-green-bg); }
.fx.row-miss { background: var(--qd-miss-bg); }
.fx.share { grid-template-columns: 2.3rem minmax(0, 1fr) auto auto; }
@media (max-width: 560px) { .fx.share { grid-template-columns: 2rem minmax(0, 1fr) auto auto; } .fx.share .fx-time { display: none; } }

/* ---------- Article (guides) ---------- */
.article-layout { display: grid; gap: 1.5rem; }
@media (min-width: 980px) { .article-layout { grid-template-columns: minmax(0, 1fr) 260px; align-items: start; } .toc { position: sticky; top: 5.5rem; } }
.article { font-size: 1.02rem; min-width: 0; }
.article .table-wrap { margin: 0.8rem 0 1.2rem; border-radius: var(--radius-md); box-shadow: var(--shadow-soft); }
.article .table-wrap table { margin: 0; box-shadow: none; }
@media (max-width: 560px) {
  .article table { font-size: 0.84rem; }
  .article th, .article td { padding: 0.5rem 0.5rem; }
  .article th { font-size: 0.66rem; letter-spacing: 0.02em; }
  .article td:last-child { white-space: nowrap; }
}
.article p, .article li { color: #2c2729; }
.article ul, .article ol { padding-left: 1.2rem; }
.article li { margin: 0.3rem 0; }
.article li::marker { color: var(--qd-red); font-weight: 800; }
.article table { width: 100%; border-collapse: collapse; margin: 0.8rem 0 1.2rem; font-size: 0.93rem; background: #fff; border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-soft); }
.article th, .article td { padding: 0.62rem 0.75rem; border-bottom: 1px solid var(--qd-gray-100); text-align: left; }
.article th { background: var(--qd-black); color: #fff; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.05em; }
.article tbody tr:nth-child(even) td { background: var(--qd-gray-50); }
.article h2 { padding-top: 0.2rem; }
.article h2::before { content: ""; display: block; width: 2.4rem; height: 4px; border-radius: 2px; background: var(--qd-red); margin-bottom: 0.7rem; }
.note { padding: 0.9rem 1.1rem; border-left: 4px solid var(--qd-red); background: #fff; border-radius: 0 var(--radius-md) var(--radius-md) 0; margin: 1.1rem 0; box-shadow: var(--shadow-soft); }
.toc { padding: 1rem 1.1rem; border-radius: var(--radius-lg); background: #fff; border: 1px solid var(--qd-gray-200); box-shadow: var(--shadow-soft); font-size: 0.9rem; }
.toc strong { display: block; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--qd-gray-500); margin-bottom: 0.5rem; }
.toc ol { margin: 0; padding-left: 1.1rem; }
.toc li { margin: 0.32rem 0; }
.toc a { text-decoration: none; font-weight: 600; }
.toc a:hover { color: var(--qd-red); }
.toc .btn { width: 100%; margin-top: 0.9rem; }
details.faq { background: #fff; border: 1px solid var(--qd-gray-200); border-radius: var(--radius-md); margin: 0.5rem 0; transition: border-color 0.15s; }
details.faq[open] { border-color: rgba(227, 21, 26, 0.4); }
details.faq summary { cursor: pointer; padding: 0.85rem 1rem; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
details.faq summary::after { content: "+"; color: var(--qd-red); font-weight: 800; font-size: 1.2rem; line-height: 1; }
details.faq[open] summary::after { content: "–"; }
details.faq summary::-webkit-details-marker { display: none; }
details.faq p { margin: 0; padding: 0 1rem 0.95rem; color: var(--qd-gray-500); }

/* ---------- Footer ---------- */
.footer { padding: 1rem 0 2rem; }
.footer-box { padding: 1.4rem; border-radius: var(--radius-xl); background: var(--qd-ink); color: rgba(255, 255, 255, 0.82); }
.footer-cols { display: grid; gap: 1.2rem; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.footer-cols strong { display: block; color: #fff; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 0.55rem; }
.footer-cols a { display: block; text-decoration: none; font-size: 0.88rem; padding: 0.18rem 0; color: rgba(255, 255, 255, 0.75); }
.footer-cols a:hover { color: #fff; }
.footer-brand { display: flex; align-items: center; gap: 0.6rem; color: #fff; font-weight: 800; margin-bottom: 0.6rem; }
.footer-brand img { width: 2.2rem; height: 2.2rem; border-radius: 0.65rem; }
.footer-legal { margin: 1.2rem 0 0; padding-top: 1rem; border-top: 1px solid rgba(255, 255, 255, 0.1); font-size: 0.8rem; color: rgba(255, 255, 255, 0.55); }

/* ---------- Sticky download bar (mobile) ---------- */
.sticky-cta { display: none; }
@media (max-width: 860px) {
  body.has-sticky { padding-bottom: 4.8rem; }
  .sticky-cta {
    display: flex; align-items: center; gap: 0.7rem;
    position: fixed; left: 0.5rem; right: 0.5rem; bottom: max(0.5rem, env(safe-area-inset-bottom));
    z-index: 40; padding: 0.55rem 0.55rem 0.55rem 0.7rem;
    border-radius: 20px; background: rgba(18, 16, 17, 0.96); color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
  }
  .sticky-cta img { width: 2.3rem; height: 2.3rem; border-radius: 0.65rem; flex: none; }
  .sticky-cta p { margin: 0; flex: 1; font-size: 0.8rem; line-height: 1.25; color: rgba(255, 255, 255, 0.75); }
  .sticky-cta p strong { display: block; font-size: 0.9rem; color: #fff; }
  .sticky-cta .btn { min-height: 2.4rem; padding: 0.45rem 0.9rem; flex: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
