/* Alpine Summit Analytics - site styles.
   Design language follows the sales deck: paper / forest panel / ochre / terracotta / peach, serif headings.
   Edit the variables below to retune the whole site. */
:root {
  --paper: #f6f1e8;
  --sand: #efe8da;
  --beige: #e4ddd0;
  --ink: #1c2321;
  --muted: #5d625e;
  --rule: #d9d1c2;
  --accent: #b5532f;        /* terracotta */
  --accent-dark: #974325;
  --ochre: #d9a441;
  --panel: #16241f;         /* forest */
  --ptext: #ece6d8;
  --peach: #f6b48f;
  --wrap: 1120px;
  --radius: 14px;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 4.75rem; }
body { margin: 0; font-family: var(--sans); font-size: 1.0625rem; line-height: 1.6; color: var(--ink); background: var(--paper); overflow-x: hidden; overflow-wrap: break-word; }
img, svg { max-width: 100%; }
img { display: block; height: auto; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; line-height: 1.12; margin: 0; }
p { margin: 0 0 1rem; }
a { color: var(--accent); }
ul, ol { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.chapter--dark :focus-visible, .feature :focus-visible { outline-color: var(--ochre); }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding-left: 1.5rem; padding-right: 1.5rem; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(246, 241, 232, 0.97); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--rule); }
.header-inner { max-width: var(--wrap); margin: 0 auto; padding: 0.6rem 1.5rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { text-decoration: none; color: var(--ink); display: inline-block; padding: 0.15rem 0; }
.wordmark { display: flex; flex-direction: column; line-height: 1.1; }
.asa {
  font-family: var(--serif); font-size: 1.45rem; font-weight: 700; letter-spacing: 0.06em;
  color: #d0505a;
  background: linear-gradient(to top, #1b2a5c 0%, #b83a6b 38%, #dc5a4a 68%, #f09a3a 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.fullname { margin-top: 0.15rem; font-size: 0.62rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
nav { display: flex; align-items: center; gap: 0.25rem 1.6rem; }
.nav-link { color: var(--ink); text-decoration: none; font-size: 0.8rem; letter-spacing: 0.12em; text-transform: uppercase; font-weight: 600; padding: 0.7rem 0; }
.nav-link:hover { color: var(--accent); }
.nav-cta { display: inline-flex; align-items: center; min-height: 44px; padding: 0 1.15rem; background: var(--accent); color: #fff; text-decoration: none; font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase; font-weight: 700; border-radius: 4px; }
.nav-cta:hover { background: var(--accent-dark); }
.nav-cta { transition: opacity 0.25s ease, visibility 0.25s; }
.site-header.cta-off .nav-cta { opacity: 0; visibility: hidden; }

/* ---------- Shared type + buttons ---------- */
.eyebrow { margin: 0 0 0.9rem; font-family: var(--sans); font-size: 0.78rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0.8rem 1.6rem; background: var(--accent); color: #fff; text-decoration: none; font-family: var(--sans); font-size: 0.85rem; letter-spacing: 0.1em; text-transform: uppercase; font-weight: 700; border: 0; border-radius: 4px; cursor: pointer; }
.button:hover { background: var(--accent-dark); }
.button:disabled { opacity: 0.6; cursor: wait; }
.button.on-dark { background: var(--ochre); color: var(--panel); }
.button.on-dark:hover { background: var(--ptext); }
.text-link { display: inline-flex; align-items: center; min-height: 48px; color: var(--ink); font-size: 0.85rem; letter-spacing: 0.1em; text-transform: uppercase; font-weight: 700; }
.text-link:hover { color: var(--accent); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--rule); }
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: url("images/denali-contours.svg") center 40% / cover no-repeat; opacity: 0.5;
  -webkit-mask-image: radial-gradient(ellipse 58% 62% at 27% 50%, rgba(0,0,0,0.04) 0%, rgba(0,0,0,0.04) 55%, #000 100%);
  mask-image: radial-gradient(ellipse 58% 62% at 27% 50%, rgba(0,0,0,0.04) 0%, rgba(0,0,0,0.04) 55%, #000 100%);
}
.hero-text { position: relative; padding-top: clamp(3.5rem, 9vw, 7rem); padding-bottom: clamp(3.75rem, 9.5vw, 7.5rem); }
.hero h1 { font-size: clamp(2.2rem, 6vw, 4.1rem); margin: 0 0 1.4rem; max-width: 15em; }
.hero h1 em { color: var(--accent); }
.subhead { font-size: clamp(1.05rem, 2vw, 1.2rem); color: var(--muted); margin: 0 0 2rem; max-width: 32rem; }
.hero-links { display: flex; align-items: center; flex-wrap: wrap; gap: 0.5rem 1.75rem; margin: 0; }

/* ---------- Chapters (one per deck slide) ---------- */
.chapter { padding: clamp(3.5rem, 8vw, 6.5rem) 0; }
.chapter--paper { background: var(--paper); }
.chapter--sand { background: var(--sand); }
.chapter--tight { padding-top: 0; }
.chapter--dark { background: var(--panel); color: var(--ptext); }
.chapter-head { margin-bottom: clamp(1.75rem, 4vw, 3rem); }
.chapter-head h2 { font-size: clamp(2rem, 5.2vw, 3.4rem); max-width: 22ch; }
.ico { width: 3rem; height: 3rem; flex: none; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }

/* Slide 4: old methods + better way */
.old-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 2.4vw, 1.75rem); margin-bottom: clamp(1rem, 2.4vw, 1.75rem); }
.old-card { background: #fff; border: 2px solid var(--rule); border-radius: var(--radius); overflow: hidden; }
.old-card img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.old-card p { margin: 0; padding: 1.1rem 1.4rem 1.4rem; font-family: var(--serif); font-size: clamp(1.25rem, 2.3vw, 1.65rem); line-height: 1.2; }
.better { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 1.25rem clamp(1.5rem, 4vw, 3.5rem); background: var(--panel); color: var(--ptext); border-radius: var(--radius); padding: clamp(1.5rem, 3.4vw, 2.25rem) clamp(1.5rem, 4vw, 3.25rem); }
.better-lead { margin: 0; font-family: var(--serif); font-size: clamp(1.9rem, 3.4vw, 2.7rem); line-height: 1.05; color: #fff; }
.better-items { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem 1.5rem; }
.better-items li { display: flex; align-items: center; gap: 1rem; line-height: 1.25; font-size: clamp(1rem, 1.7vw, 1.2rem); }
.better-items .ico { color: var(--ochre); width: clamp(2.6rem, 4vw, 3.4rem); height: clamp(2.6rem, 4vw, 3.4rem); }

/* Slide 5: before / after */
.ba { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 4vw, 3rem); }
.ba-col { border-radius: var(--radius); overflow: hidden; }
.ba-before { background: var(--beige); }
.ba-after { background: var(--panel); color: var(--ptext); }
.ba-img { position: relative; }
.ba-img img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.ba-img .pill { position: absolute; top: 14px; left: 14px; }
.ba-col ul { padding: 0.5rem clamp(1.25rem, 3vw, 2.25rem) 1rem; }
.ba-col li { position: relative; padding: 0.95rem 0 0.95rem 2.1rem; font-family: var(--serif); font-size: clamp(1.1rem, 1.9vw, 1.4rem); line-height: 1.2; border-bottom: 1px solid rgba(0, 0, 0, 0.12); }
.ba-after li { border-bottom-color: rgba(255, 255, 255, 0.15); }
.ba-col li:last-child { border-bottom: 0; }
.ba-col li::before { content: ""; position: absolute; left: 0; top: 1.15rem; width: 0.95rem; height: 0.95rem; border-radius: 50%; background: #a39a88; }
.ba-after li::before { background: var(--ochre); }
.ba-arrow { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 3; width: 3.6rem; height: 3.6rem; border-radius: 50%; background: var(--accent); border: 5px solid var(--sand); display: flex; align-items: center; justify-content: center; }
.ba-arrow svg { width: 1.5rem; height: 1.5rem; fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

.pill { display: inline-block; padding: 0.35rem 1rem; border-radius: 99px; background: var(--ochre); color: var(--panel); font-family: var(--sans); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; line-height: 1.3; }
.pill-dark { background: var(--ink); color: #fff; }

/* Slide 6: six ways */
.six { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 2.4vw, 1.75rem); }
.card { background: #fff; border: 2px solid var(--rule); border-top: 8px solid var(--peach); border-radius: var(--radius); padding: clamp(1.4rem, 3vw, 2.25rem); }
.ib { display: flex; align-items: center; justify-content: center; width: 4.4rem; height: 4.4rem; border-radius: 50%; background: var(--panel); color: var(--ochre); margin-bottom: 1.3rem; }
.ib .ico { width: 2.3rem; height: 2.3rem; }
.card h3 { font-size: clamp(1.4rem, 2.5vw, 1.8rem); margin-bottom: 0.5rem; }
.card p { margin: 0; color: var(--muted); font-size: 1rem; line-height: 1.45; }
.inline-cta { margin: 2.25rem 0 0; text-align: center; font-family: var(--serif); font-size: clamp(1.15rem, 2.2vw, 1.4rem); }
.inline-cta a { font-weight: 700; white-space: nowrap; }

/* Slide 10: charts */
.vz-pair { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1rem, 2.4vw, 1.75rem); align-items: stretch; }
.vz { margin: 0; display: flex; flex-direction: column; background: #fff; border: 2px solid var(--rule); border-radius: var(--radius); overflow: hidden; }
.vz-better { border-color: var(--accent); }
.vz-body { position: relative; padding: 1.4rem clamp(1.1rem, 2.4vw, 1.75rem) 1.4rem; flex: 1; display: flex; flex-direction: column; }
.vz-body > .pill { position: absolute; top: 1rem; right: 1rem; }
.vz-heading { margin: 0 6.2rem 1rem 0; font-family: var(--sans); font-weight: 700; font-size: 0.95rem; color: #444; line-height: 1.35; }
.vz-heading--story { font-family: var(--serif); font-weight: 400; font-size: clamp(1.25rem, 2.1vw, 1.55rem); color: var(--ink); line-height: 1.2; }
.vz-common svg { width: 100%; height: auto; margin: auto 0; border-radius: 4px; }
.vz-cap { padding: 0.95rem clamp(1.1rem, 2.4vw, 1.75rem); font-size: 0.95rem; font-weight: 600; margin: 0; }
.vz-cap--light { background: var(--beige); color: var(--ink); }
.vz-cap--dark { background: var(--panel); color: #fff; }
.bars { margin: 0 0 0.75rem; }
.bars li { display: grid; grid-template-columns: minmax(6.5rem, 10.5rem) 1fr 2.5rem; align-items: center; gap: 0.7rem; margin: 0.4rem 0; font-size: 0.9rem; color: var(--muted); }
.bar-label { text-align: right; line-height: 1.2; }
.bar-track { display: block; height: 1.15rem; }
.bar { display: block; height: 100%; background: #b9c4bd; border-radius: 3px; transform-origin: left center; }
.bar-val { font-variant-numeric: tabular-nums; }
.bars li.hl { color: var(--ink); font-weight: 700; }
.bars li.hl .bar { background: var(--accent); }
.vz-note { margin: auto 0 0; font-size: 0.82rem; color: var(--muted); }
.under { margin: clamp(1.75rem, 4vw, 2.75rem) 0 0; text-align: center; font-family: var(--serif); font-size: clamp(1.25rem, 2.8vw, 1.9rem); line-height: 1.25; }

/* Selected work */
.feature { display: grid; grid-template-columns: 1.05fr 1fr; background: var(--panel); color: var(--ptext); border-radius: var(--radius); overflow: hidden; }
.feature-media img { width: 100%; height: 100%; min-height: 260px; object-fit: cover; }
.feature-text { padding: clamp(1.6rem, 4vw, 3rem); align-self: center; }
.feature .eyebrow { color: var(--ochre); }
.feature h3 { font-size: clamp(1.9rem, 3.6vw, 2.7rem); color: #fff; margin-bottom: 1rem; }
.feature p { color: #d3cdbd; }
.feature .feature-fine { font-size: 0.92rem; color: #b8b2a2; }
.feature .button { margin-top: 0.25rem; }
.feature .feature-fine { margin-top: 1.5rem; }

/* About */
.about { display: grid; grid-template-columns: 1fr 1.3fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: start; }
.lede { margin: 0; font-family: var(--serif); font-size: clamp(1.4rem, 2.8vw, 2rem); line-height: 1.3; }
.about p { max-width: 38rem; }

/* Next step + contact (deck slide 14) */
.next-step { position: relative; overflow: hidden; padding: clamp(3rem, 6vw, 5rem) 0; }
.next-bg { position: absolute; inset: 0; pointer-events: none; }
.next-bg::before { content: ""; position: absolute; inset: 0; background: url("images/contours-light.svg") left center / auto 135% no-repeat; opacity: 0.2; }
.next-grid { position: relative; display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.next-copy .eyebrow { color: var(--ochre); }
.next-copy h2 { font-size: clamp(2.3rem, 6vw, 4.5rem); line-height: 1.04; color: #fff; margin-bottom: 1.25rem; }
.next-lead { font-size: 1.1rem; max-width: 30rem; color: var(--ptext); }
.next-rows { margin-top: 1.75rem; font-family: var(--serif); color: #f1e4c4; }
.next-rows p { margin: 0 0 0.4rem; }
.contact-name { font-family: var(--sans); font-size: 0.78rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ochre); font-weight: 700; margin-bottom: 0.7rem !important; }
.next-rows a { color: #f1e4c4; font-size: clamp(1.1rem, 2.4vw, 1.5rem); text-underline-offset: 0.2em; }
.next-rows a:hover { color: #fff; }

.form-card { background: var(--paper); color: var(--ink); border-radius: var(--radius); padding: clamp(1.4rem, 3.2vw, 2.4rem); box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35); }
.form-card h3 { font-size: 1.6rem; margin-bottom: 1rem; }
.field { margin-bottom: 0.85rem; }
.field label { display: block; margin-bottom: 0.35rem; font-size: 0.74rem; letter-spacing: 0.13em; text-transform: uppercase; font-weight: 700; }
.opt { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--muted); }
.field input, .field textarea { width: 100%; padding: 0.85rem 0.95rem; font: inherit; font-size: 1rem; color: var(--ink); background: #fff; border: 1px solid #cfc6b4; border-radius: 6px; }
.field textarea { resize: vertical; min-height: 7.5rem; }
.field input:focus, .field textarea:focus { outline: 3px solid var(--accent); outline-offset: 0; border-color: var(--accent); }
.hp { position: absolute; left: -9999px; width: 0; height: 0; opacity: 0; }
.submit { width: 100%; min-height: 54px; margin-top: 0.25rem; }
.form-status { min-height: 1.5rem; margin: 0.75rem 0 0; color: var(--muted); font-size: 0.95rem; }
.form-success h3 { margin-bottom: 0.75rem; }
.form-success:focus { outline: none; }
.form-success .button { background: var(--accent); }
[hidden] { display: none !important; }

/* Footer */
.site-footer { background: #0f1a16; color: #9aa39d; font-size: 0.85rem; padding: 1.75rem 0 2rem; }
.site-footer p { margin: 0 0 0.3rem; }

/* ---------- Scroll reveal (progressive enhancement) ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(20px); transition: opacity 0.7s ease, transform 0.7s ease; }
.js [data-reveal].in { opacity: 1; transform: none; }
.old-card:nth-child(2), .card:nth-child(2n) { transition-delay: 0.08s; }
.old-card:nth-child(3), .card:nth-child(3n) { transition-delay: 0.16s; }
.js .vz-better .bar { transform: scaleX(0); transition: transform 0.9s cubic-bezier(.2, .7, .2, 1); }
.js .vz-better.in .bar { transform: scaleX(1); }
.bars li:nth-child(2) .bar { transition-delay: 0.08s; } .bars li:nth-child(3) .bar { transition-delay: 0.16s; } .bars li:nth-child(4) .bar { transition-delay: 0.24s; } .bars li:nth-child(5) .bar { transition-delay: 0.32s; }
.bars li:nth-child(6) .bar { transition-delay: 0.4s; } .bars li:nth-child(7) .bar { transition-delay: 0.48s; } .bars li:nth-child(8) .bar { transition-delay: 0.56s; } .bars li:nth-child(9) .bar { transition-delay: 0.64s; } .bars li:nth-child(10) .bar { transition-delay: 0.72s; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal], .js .vz-better .bar { opacity: 1; transform: none; transition: none; }
}

/* ---------- Tablet ---------- */
@media (max-width: 960px) {
  .six { grid-template-columns: repeat(2, 1fr); }
  .vz-pair { grid-template-columns: 1fr; }
  .better { grid-template-columns: 1fr; }
  .feature { grid-template-columns: 1fr; }
  .feature-media img { aspect-ratio: 16 / 9; min-height: 0; height: auto; }
  .about { grid-template-columns: 1fr; }
  .next-grid { grid-template-columns: 1fr; }
}

/* ---------- Stack side-by-side layouts ---------- */
@media (max-width: 760px) {
  .old-cards { grid-template-columns: 1fr; }
  .old-card { display: grid; grid-template-columns: 42% 1fr; align-items: center; }
  .old-card img { height: 100%; aspect-ratio: auto; min-height: 7.5rem; }
  .old-card p { padding: 0.9rem 1.1rem; font-size: 1.2rem; }
  .better-items { grid-template-columns: 1fr; }
  .ba { grid-template-columns: 1fr; gap: 0; }
  .ba-arrow { position: relative; left: auto; top: auto; transform: rotate(90deg); margin: -1.8rem auto; width: 3.4rem; height: 3.4rem; }
}

/* ---------- Phone ---------- */
@media (max-width: 640px) {
  body { font-size: 1rem; }
  .chapter { padding: 3rem 0; }
  .chapter-head { margin-bottom: 1.5rem; }
  .chapter--tight { padding-top: 0; }
  .feature .button { width: 100%; }
  .wrap, .header-inner { padding-left: 1.1rem; padding-right: 1.1rem; }
  .nav-link { display: none; }
  .asa { font-size: 1.3rem; }
  .hero-links { flex-direction: column; align-items: stretch; gap: 0.25rem; }
  .hero-links .button { width: 100%; }
  .hero-links .text-link { justify-content: center; }
  .six { grid-template-columns: 1fr; }
  .card { display: grid; grid-template-columns: auto 1fr; column-gap: 1.1rem; align-items: center; padding: 1.1rem 1.2rem 1.2rem; border-top-width: 6px; }
  .ib { grid-row: 1 / span 2; width: 3.6rem; height: 3.6rem; margin-bottom: 0; }
  .ib .ico { width: 1.9rem; height: 1.9rem; }
  .card h3 { font-size: 1.3rem; margin-bottom: 0.2rem; align-self: end; }
  .card p { align-self: start; font-size: 0.95rem; }
  .bars li { grid-template-columns: 6.6rem 1fr 2.3rem; gap: 0.45rem; font-size: 0.8rem; }
  .bar-label { text-align: left; }
  .vz-heading { margin-right: 0; padding-top: 2rem; }
  .vz-body { padding: 1.1rem 1rem; }
  .next-rows a { font-size: 1.05rem; overflow-wrap: anywhere; }
  .form-card { padding: 1.25rem 1.1rem 1.4rem; }
  .inline-cta a { white-space: normal; }
}
@media (max-width: 360px) {
  .wrap, .header-inner { padding-left: 0.9rem; padding-right: 0.9rem; }
  .nav-cta { padding: 0 0.8rem; font-size: 0.72rem; }
  .asa { font-size: 1.15rem; }
}
