/* SheetVan marketing and legal pages. Loaded for the "site" variant. */

/* Legal pages: long-form reading */
.legal { padding: clamp(2.5rem, 6vw, 4.5rem) 0 4.5rem; }
.wrap--prose { max-width: 44rem; }
.legal h1 { margin-bottom: 1.75rem; }
.legal h2 { font-size: 1.3rem; margin: 2.25rem 0 0.6rem; letter-spacing: -0.02em; }
.legal ul { padding-left: 1.2rem; margin: 0 0 1rem; }
.legal li { margin: 0.35rem 0; }
.legal code { font-size: 0.9em; background: var(--surface-2); padding: 0.1em 0.4em; border-radius: 6px; }

/* Home: hero, centred on a soft lime tint with a faint dot pattern, Dashboard picture in a band underneath */
.hero {
  padding-top: clamp(3.5rem, 8vw, 6rem);
  background:
    radial-gradient(70% 60% at 50% 0%, var(--accent-tint) 0%, rgb(255 231 215 / 0) 70%),
    radial-gradient(circle, #d5d9de 1px, transparent 1.3px) 0 0 / 22px 22px,
    var(--bg);
}
.hero-copy { max-width: 48rem; text-align: center; }
.hero h1 { font-size: clamp(2.5rem, 6vw, 4.25rem); margin-bottom: 1.25rem; }
.hero-lede { font-size: clamp(1.05rem, 1.6vw, 1.2rem); color: var(--muted); max-width: 36rem; margin: 0 auto 2rem; }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.75rem; }
.hero-shot {
  margin-top: clamp(3rem, 7vw, 4.5rem);
  padding: clamp(1.5rem, 5vw, 3.5rem) 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background-color: var(--accent-soft);
  background-image: linear-gradient(var(--accent-line) 1px, transparent 1px), linear-gradient(90deg, var(--accent-line) 1px, transparent 1px);
  background-size: 28px 28px;
}

/* Dashboard picture: a light-only copy of the v2 Dashboard tab (src/pages/dashboard-preview.ts). */
.sheet-preview { margin: 0 auto; max-width: 56rem; min-width: 0; }
.sheet {
  --s-canvas: #f4f5f7; --s-card: #ffffff; --s-line: #e3e5e8; --s-text: #111827; --s-muted: #6b7280;
  --s-accent: #f26a1b; --s-green: #15803d; --s-red: #b42318; --s-sheets: #188038;
  background: var(--s-canvas); color: var(--s-text);
  border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow);
  overflow: hidden;
  font: 400 12.5px/1.35 var(--font);
  font-variant-numeric: tabular-nums;
}
.sheet-bar { display: flex; align-items: center; gap: 0.5rem; padding: 0.6rem 1rem; border-bottom: 1px solid var(--s-line); background: #f8f9fa; font-size: 13px; }
.sheet-icon { width: 14px; height: 18px; border-radius: 2px; background: var(--s-sheets); box-shadow: inset 0 0 0 3px #ffffff33; }
.sv-body { padding: 0 0 1rem; }
.sv-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.85rem 1.1rem; background: var(--s-card); border-bottom: 1px solid var(--s-line); }
.sv-name { margin: 0; font-weight: 700; font-size: 17px; letter-spacing: -0.01em; }
.sv-status { margin: 0.1rem 0 0; color: var(--s-green); font-size: 11.5px; }
.sv-refresh { flex: none; padding: 0.45rem 0.9rem; border-radius: 4px; background: var(--s-accent); font-weight: 700; font-size: 12px; }
.sv-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.65rem; padding: 0.9rem 1.1rem 0; }
.sv-kpi { background: var(--s-card); border: 1px solid var(--s-line); padding: 0.6rem 0.7rem; min-width: 0; }
.sv-kpi-label { display: block; color: var(--s-muted); font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sv-kpi-value { display: block; margin: 0.15rem 0 0.2rem; font-size: 19px; font-weight: 700; letter-spacing: -0.02em; white-space: nowrap; }
.sv-kpi-detail { display: flex; align-items: center; justify-content: space-between; gap: 0.4rem; min-height: 28px; color: var(--s-muted); font-size: 11px; }
.sv-up { color: var(--s-green); font-weight: 600; }
.sv-down { color: var(--s-red); font-weight: 600; }
.sv-red { color: var(--s-red); }
.sv-spark { width: 52%; max-width: 96px; height: 28px; }
.sv-spark rect { fill: var(--s-accent); }
.sv-spark--line polyline { fill: none; stroke: var(--s-accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 0; vector-effect: non-scaling-stroke; }
.sv-row-2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.65rem; padding: 0.65rem 1.1rem 0; }
.sv-card { background: var(--s-card); border: 1px solid var(--s-line); padding: 0.65rem 0.8rem; min-width: 0; }
.sv-card--wide { margin: 0.65rem 1.1rem 0; }
.sv-card-title { margin: 0 0 0.45rem; font-weight: 700; font-size: 12.5px; }
.sv-chart { display: block; width: 100%; height: 110px; }
.sv-chart rect { fill: var(--s-accent); transform-box: fill-box; transform-origin: 50% 100%; }
.sv-chart-labels { display: flex; justify-content: space-between; color: var(--s-muted); font-size: 10.5px; margin-top: 0.2rem; }
.sv-stats { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.3rem 1rem; margin-top: 0.45rem; padding-top: 0.45rem; border-top: 1px solid var(--s-line); color: var(--s-muted); font-size: 11px; }
.sv-stats b { color: var(--s-text); }
.sv-table { width: 100%; border-collapse: collapse; }
.sv-table th { text-align: left; color: var(--s-muted); font-weight: 700; font-size: 10.5px; padding: 0.2rem 0.3rem; border-bottom: 1px solid var(--s-line); }
.sv-table td { padding: 0.32rem 0.3rem; border-bottom: 1px solid var(--s-canvas); white-space: nowrap; }
.sv-table tr:last-child td { border-bottom: 0; }
.sv-table td:nth-child(n+2), .sv-table th:nth-child(n+2) { text-align: right; }
.sv-table--bars td:first-child { width: 42%; }
.sv-bar-cell { width: 38%; }
.sv-bar { display: block; width: 100%; height: 8px; }
.sv-bar rect { fill: var(--s-accent); transform-box: fill-box; transform-origin: 0 50%; }
.sheet-tabs { display: flex; gap: 0.25rem; padding: 0.35rem 0.6rem; border-top: 1px solid var(--s-line); background: #f1f3f4; overflow: hidden; white-space: nowrap; font-size: 12px; color: var(--s-muted); }
.sheet-tabs span { padding: 0.2rem 0.6rem; border-radius: 4px; }
.sheet-tabs .is-active { background: #ffffff; color: var(--s-sheets); font-weight: 700; box-shadow: 0 1px 2px #0000001a; }

/*
 * Dashboard picture, played when it scrolls into view (/js/reveal.js): KPI numbers count up, their details fade in,
 * the revenue bars grow, then the table rows and client bars follow. Without JS or with reduced motion it shows finished.
 */
.sheet-preview.is-armed .sv-fade, .sheet-preview.is-armed .sv-row { opacity: 0; }
.sheet-preview.is-armed .sv-chart rect { transform: scaleY(0); }
.sheet-preview.is-armed .sv-bar rect { transform: scaleX(0); }
.sheet-preview.is-armed .sv-spark--line polyline { stroke-dashoffset: 1; }
.sheet-preview.is-in .sv-fade, .sheet-preview.is-in .sv-row { opacity: 1; transition: opacity 0.4s ease; }
.sheet-preview.is-in .sv-chart rect { transform: none; transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.sheet-preview.is-in .sv-bar rect { transform: none; transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1); }
.sheet-preview.is-in .sv-spark--line polyline { stroke-dashoffset: 0; transition: stroke-dashoffset 1.2s cubic-bezier(0.65, 0, 0.35, 1) 0.6s; }
.sheet-preview.is-in .sv-d2 { transition-delay: 0.35s; }
.sheet-preview.is-in .sv-d3 { transition-delay: 0.45s; }
.sheet-preview.is-in .sv-d4 { transition-delay: 0.55s; }
.sheet-preview.is-in .sv-d5 { transition-delay: 0.65s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(1) { transition-delay: 0.6s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(2) { transition-delay: 0.65s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(3) { transition-delay: 0.7s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(4) { transition-delay: 0.75s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(5) { transition-delay: 0.8s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(6) { transition-delay: 0.85s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(7) { transition-delay: 0.9s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(8) { transition-delay: 0.95s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(9) { transition-delay: 1s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(10) { transition-delay: 1.05s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(11) { transition-delay: 1.1s; }
.sheet-preview.is-in .sv-chart rect:nth-of-type(12) { transition-delay: 1.15s; }
.sheet-preview.is-in .sv-row:nth-child(1) { transition-delay: 1.1s; }
.sheet-preview.is-in .sv-row:nth-child(2) { transition-delay: 1.2s; }
.sheet-preview.is-in .sv-row:nth-child(3) { transition-delay: 1.3s; }
.sheet-preview.is-in .sv-row:nth-child(4) { transition-delay: 1.4s; }
.sheet-preview.is-in .sv-row:nth-child(1) .sv-bar rect { transition-delay: 1.3s; }
.sheet-preview.is-in .sv-row:nth-child(2) .sv-bar rect { transition-delay: 1.4s; }
.sheet-preview.is-in .sv-row:nth-child(3) .sv-bar rect { transition-delay: 1.5s; }
.sheet-preview.is-in .sv-row:nth-child(4) .sv-bar rect { transition-delay: 1.6s; }

/* Shared section rhythm */
.steps, .uses, .pricing, .faq { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.h2-quiet { color: var(--faint); }

/* Home: steps */
.step-list { list-style: none; counter-reset: step; margin: 2.25rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; }
.step-list li { counter-increment: step; position: relative; padding-top: 3.25rem; }
.step-list li::before {
  content: counter(step);
  position: absolute; top: 0; left: 0;
  width: 2.1rem; height: 2.1rem; display: grid; place-items: center;
  border-radius: 999px; background: var(--accent); color: var(--on-accent);
  font: 700 0.95rem/1 var(--font);
}
.step-list li:not(:last-child)::after {
  content: ""; position: absolute; top: 1.05rem; left: 2.9rem; right: -1rem; height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-line));
  transform-origin: left center;
}
.step-list p { color: var(--muted); margin: 0; max-width: 32ch; }

/*
 * How it works, played in order when it scrolls into view. /js/reveal.js adds "is-armed" (start state) and then
 * "is-in". Without JS or with reduced motion neither class is set, so everything simply shows.
 * Sequence: step 1, line 1 draws, step 2, line 2 draws, step 3.
 */
.steps.is-armed .step-list li { opacity: 0; transform: translateY(14px); }
.steps.is-armed .step-list li::before { background: var(--surface-2); color: var(--faint); transform: scale(0.8); }
.steps.is-armed .step-list li::after { transform: scaleX(0); }
.steps.is-in .step-list li { opacity: 1; transform: none; transition: opacity 0.5s ease, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.steps.is-in .step-list li::before { background: var(--accent); color: var(--on-accent); transform: none; transition: background-color 0.3s ease, color 0.3s ease, transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1); }
.steps.is-in .step-list li::after { transform: none; transition: transform 0.6s cubic-bezier(0.65, 0, 0.35, 1); }
.steps.is-in .step-list li:nth-child(1)::after { transition-delay: 0.3s; }
.steps.is-in .step-list li:nth-child(2), .steps.is-in .step-list li:nth-child(2)::before { transition-delay: 0.7s; }
.steps.is-in .step-list li:nth-child(2)::after { transition-delay: 1s; }
.steps.is-in .step-list li:nth-child(3), .steps.is-in .step-list li:nth-child(3)::before { transition-delay: 1.4s; }

/* Hover lift on the reporting panels (pointer devices only) */
@media (hover: hover) {
  .use { transition: transform 0.2s ease, box-shadow 0.2s ease; }
  .use:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
}

/* Home: uses. 5 neutral panels on a 6-column grid: 4+2, 3+3, then 6 full width. */
.uses { border-top: 1px solid var(--line); }
.uses h2 { max-width: 46rem; }
.use-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1rem; margin-top: 2.25rem; }
.use { grid-column: span 2; background: var(--surface-2); border-radius: var(--radius-panel); padding: 1.75rem; }
.use p { color: var(--muted); margin: 0; max-width: 46ch; }
.use-grid > .use:nth-child(1) { grid-column: span 4; }
.use-grid > .use:nth-child(2) { grid-column: span 2; }
.use-grid > .use:nth-child(3), .use-grid > .use:nth-child(4) { grid-column: span 3; }
.use-grid > .use:nth-child(5) { grid-column: span 6; }
.use--accent { background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent-line); }
.use--accent p { color: var(--text); }
.use--ink { background: var(--ink); color: #f3f4f5; }
.use--ink h3 { color: var(--accent); }
.use--ink p { color: #c3c7cc; }

/* Home: pricing */
.pricing { border-top: 1px solid var(--line); }
.pricing-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(1.5rem, 5vw, 4rem); align-items: start; }
.pricing-note { color: var(--muted); font-size: 1.1rem; max-width: 30rem; }
.price-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel); box-shadow: var(--shadow); padding: clamp(1.5rem, 4vw, 2.25rem); }
.price { margin: 0 0 0.75rem; font-size: 1.05rem; color: var(--muted); }
.price strong { font: 700 3rem/1 var(--font); color: var(--text); margin-right: 0.35rem; letter-spacing: -0.04em; }
.price-points { margin: 1rem 0 1.5rem; padding: 0; list-style: none; }
.price-points li { padding-left: 1.6rem; position: relative; margin: 0.45rem 0; }
.price-points li::before { content: ""; position: absolute; left: 0.2rem; top: 0.45em; width: 0.7rem; height: 0.4rem; border-left: 2px solid var(--text); border-bottom: 2px solid var(--text); transform: rotate(-45deg); }

/* Home: FAQ */
.faq { border-top: 1px solid var(--line); }
.faq h2 { margin-bottom: 1.25rem; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 1.1rem 2.5rem 1.1rem 0; position: relative; font-weight: 600; font-size: 1.06rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0.25rem; top: 50%; transform: translateY(-50%); font: 400 1.5rem/1 var(--font); color: var(--muted); }
.faq details[open] summary::after { content: "\2212"; }
.faq details p { color: var(--muted); margin: 0 0 1.2rem; max-width: 60ch; }

/* Home: closing call to action */
.closing { padding: 0 0 clamp(3.5rem, 8vw, 6rem); }
.closing-inner {
  display: flex; flex-direction: column; align-items: center; gap: 1.25rem; text-align: center;
  border-radius: var(--radius-panel);
  padding: clamp(2.25rem, 6vw, 3.75rem) clamp(1.5rem, 5vw, 3rem);
  background:
    radial-gradient(circle, rgb(18 20 23 / 0.08) 1px, transparent 1.3px) 0 0 / 22px 22px,
    var(--accent-soft);
  box-shadow: inset 0 0 0 1px var(--accent-line);
}
.closing-inner h2 { margin: 0; max-width: 24ch; }

/* Phones and small tablets: every multi-column block stacks */
@media (max-width: 860px) {
  .pricing-grid { grid-template-columns: minmax(0, 1fr); }
  .step-list { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  .step-list li { padding: 0 0 0 3.25rem; }
  .step-list li:not(:last-child)::after { top: 2.5rem; bottom: -1.3rem; left: 1rem; right: auto; width: 2px; height: auto; background: linear-gradient(180deg, var(--accent), var(--accent-line)); transform-origin: top center; }
  .steps.is-armed .step-list li::after { transform: scaleY(0); }
  .steps.is-in .step-list li::after { transform: none; }
  .use-grid { grid-template-columns: minmax(0, 1fr); }
  .use-grid > .use:nth-child(n) { grid-column: auto; }
}
@media (max-width: 640px) {
  .sv-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sv-row-2 { grid-template-columns: minmax(0, 1fr); }
  .sv-head { padding: 0.7rem 0.8rem; }
  .sv-kpis, .sv-row-2 { padding-left: 0.8rem; padding-right: 0.8rem; }
  .sv-card--wide { margin-left: 0.8rem; margin-right: 0.8rem; }
  .sv-table--bars .sv-bar-cell { display: none; }
}
