/* Algoriit — the two products: the home page's product section and the product pages.
   Built on site.css tokens: graphite ground, light "field" sections, orange accent, Unbounded heads. */

/* ---------- shared bits ---------- */
.p-eyebrow { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.9rem; font-size: var(--step-small); color: var(--muted); letter-spacing: 0.02em; }
.p-tag { display: inline-flex; align-items: center; gap: 0.45rem; height: 1.75rem; padding: 0 0.75rem; background: var(--accent); color: var(--accent-ink); font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.75rem; }
.p-tag-quiet { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px currentColor; }
.p-num { font-family: var(--font-display); font-weight: 700; letter-spacing: 0.04em; }
.p-arrow { display: inline-flex; align-items: center; gap: 0.5rem; font-weight: 500; text-decoration: none; }
.p-arrow svg { transition: transform var(--t-ui) var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .p-arrow:hover svg { transform: translateX(4px); } }

/* ---------- home: our products ---------- */
.products { padding-top: calc(var(--section) * 0.8); }
.products-head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gutter); align-items: end; margin-bottom: 3rem; }
.products-head p { font-size: var(--step-body); color: var(--muted); }
.flagship { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); background: var(--field); color: var(--field-ink); --ink: var(--field-ink); --muted: var(--field-muted); }
.flagship-text { padding: clamp(1.75rem, 4vw, 3.75rem); display: grid; grid-template-columns: minmax(0, 1fr); min-width: 0; align-content: start; gap: 1.5rem; }
.flagship-name { font-family: var(--font-display); font-size: clamp(2rem, 0.4rem + 3.6vw, 4.25rem); font-weight: 800; text-transform: uppercase; letter-spacing: -0.03em; line-height: 0.95; }
.flagship-name em { font-style: normal; color: var(--accent); }
.flagship-line { font-size: var(--step-lead); line-height: 1.3; max-width: 30ch; }
.flagship-flow { list-style: none; padding: 0; margin: 0.5rem 0 0; display: grid; gap: 0; border-top: 1px solid color-mix(in srgb, var(--field-ink) 16%, transparent); }
.flagship-flow li { display: grid; grid-template-columns: 2.25rem 1fr; gap: 0.75rem; padding: 0.8rem 0; border-bottom: 1px solid color-mix(in srgb, var(--field-ink) 16%, transparent); font-size: var(--step-body); }
.flagship-flow li span:first-child { font-family: var(--font-display); font-weight: 700; color: var(--accent-press); font-size: 0.85em; padding-top: 0.15em; }
.flagship-actions { display: flex; flex-wrap: wrap; gap: 1rem 1.75rem; align-items: center; margin-top: 0.5rem; }
.flagship .button-ink { background: var(--field-ink); color: var(--field); }
.flagship-media { position: relative; display: grid; min-height: 420px; }
.flagship-media img { position: absolute; inset: 0; height: 100%; object-position: 50% 45%; }
.flagship-media .ui-float { align-self: end; }
.flagship-media .ui-float { width: 260px; }
.second { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); gap: var(--gutter); margin-top: 10px; background: var(--surface); padding: clamp(1.5rem, 3vw, 2.75rem); align-items: center; }
.second-name { font-family: var(--font-display); font-size: clamp(1.75rem, 1rem + 2.6vw, 3rem); font-weight: 800; text-transform: uppercase; letter-spacing: -0.02em; line-height: 1; margin-top: 1rem; }
.second-text { min-width: 0; }
.second-text p { margin-top: 1rem; font-size: var(--step-body); }
.second-text .p-arrow { margin-top: 1.5rem; }
.second-proof { margin-top: 0.75rem; font-size: var(--step-small); color: var(--muted); }

/* ---------- product pages ---------- */
.p-hero .hero-title { white-space: normal; }
.p-hero .p-eyebrow { grid-column: 1 / -1; margin-bottom: -1rem; }
.p-hero-sub { font-size: var(--step-lead); line-height: 1.35; max-width: 30ch; }
.p-name em, .p-accent { font-style: normal; color: var(--accent); }

/* the product panels: a chat on the left, what the system does on the right */
.w2-sheet { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; padding: 16px; background: var(--u-sheet); border: 1px solid var(--u-border); border-top: 0; border-radius: 0 0 12px 12px; min-height: 470px; } /* taste-skill-ignore: inside a data-ui fragment */
.chat { background: #efeae2; border-radius: 10px; padding: 12px; display: flex; flex-direction: column; gap: 8px; align-content: start; }
.chat-head { display: flex; align-items: center; gap: 10px; padding: 2px 2px 8px; border-bottom: 1px solid #ddd6cc; margin-bottom: 2px; }
.chat-av { width: 30px; height: 30px; border-radius: 50%; background: #1f8a4c; color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 12px; flex: none; }
.chat-head strong { display: block; font-size: 13px; }
.chat-head span { font-size: 11px; color: var(--u-muted); }
.bubble { max-width: 88%; padding: 8px 10px; border-radius: 10px; font-size: 13px; line-height: 1.4; background: #fff; box-shadow: 0 1px 1px rgba(0,0,0,0.08); align-self: flex-start; } /* taste-skill-ignore: inside a data-ui fragment */
.bubble.out { align-self: flex-end; background: #d9fdd3; }
.bubble .who { display: block; font-size: 11px; font-weight: 600; color: #1f6f8b; margin-bottom: 2px; }
.bubble .meta { display: block; text-align: right; font-size: 10px; color: var(--u-muted); margin-top: 3px; }
.bubble .bt { display: block; margin-top: 7px; padding-top: 7px; border-top: 1px solid #eceef0; text-align: center; color: #1f6f8b; font-weight: 600; }
.bubble ul { list-style: none; padding: 0; margin: 4px 0 0; }
.bubble li { display: flex; justify-content: space-between; gap: 10px; }
.bubble .total { font-weight: 600; border-top: 1px solid #eceef0; margin-top: 4px; padding-top: 4px; }
.react { align-self: flex-start; margin-top: -6px; margin-left: 8px; background: #fff; border-radius: 10px; padding: 1px 6px; font-size: 12px; box-shadow: 0 1px 2px rgba(0,0,0,0.12); } /* taste-skill-ignore: inside a data-ui fragment */
.bubble.is-pending, .react.is-pending { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .bubble, .react { animation: pop-in 280ms var(--ease-out); }
}
@keyframes pop-in { from { opacity: 0; transform: translateY(6px) scale(0.98); } }
.w2-right { display: grid; gap: 10px; align-content: start; }
.ticket { background: var(--u-raised); border-radius: 10px; padding: 12px 14px; border-left: 3px solid var(--u-accent); transition: opacity 320ms var(--ease-out), transform 420ms var(--ease-out); }
.ticket.is-pending { opacity: 0.3; transform: translateY(6px); }
.ticket-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 4px; }
.ticket-top strong { font-size: 13px; }
.ticket p { font-size: 13px; max-width: none; }
.ticket .ui-line { color: var(--u-muted); margin-top: 2px; }
.ticket-mid { border-left-color: #d97706; }
.state { display: inline-flex; gap: 6px; align-items: center; margin-top: 8px; font-size: 12px; color: var(--u-muted); }
.state.is-pending { display: none; }
.pill-hot { background: #ffe3d9; color: #8a2408; }
.sum { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 6px; }
.sum div { background: #fff; border-radius: 8px; padding: 6px 8px; }
.sum span { display: block; font-size: 11px; color: var(--u-muted); }
.sum strong { font-size: 18px; letter-spacing: -0.01em; }

/* problem */
.p-problem { padding-block: calc(var(--section) * 0.6); }
.p-problem-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: calc(var(--gutter) * 2); align-items: start; }
.pains { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gutter); }
.pains li { border-top: 2px solid var(--field-ink); padding-top: 1rem; font-size: var(--step-body); }
.pains strong { display: block; font-size: var(--step-lead); line-height: 1.2; margin-bottom: 0.5rem; letter-spacing: -0.01em; }

/* how it works */
.p-how { padding-block: var(--section) calc(var(--section) * 0.6); }
.p-how-head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gutter); align-items: end; margin-bottom: 3.5rem; }
.p-how-head p { color: var(--muted); }
.how { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(var(--cols, 5), minmax(0, 1fr)); gap: 10px; counter-reset: how; }
.how li { background: var(--surface); padding: 1.5rem 1.25rem 1.75rem; display: grid; align-content: start; gap: 0.75rem; min-height: 260px; }
.how li::before { counter-increment: how; content: "0" counter(how); font-family: var(--font-display); font-weight: 700; color: var(--accent); font-size: 1.25rem; }
.how h3 { font-size: var(--step-lead); line-height: 1.15; letter-spacing: -0.01em; }
.how p { font-size: var(--step-small); line-height: 1.5; color: var(--muted); }

/* features */
.p-features { padding-bottom: calc(var(--section) * 0.7); }
.feat { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); }
.feat li { padding: 1.5rem var(--gutter) 1.75rem 0; border-bottom: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); }
.feat h3 { font-size: var(--step-body); font-weight: 600; margin-bottom: 0.4rem; }
.feat p { font-size: var(--step-small); color: var(--muted); }

/* who it's for */
.p-who { padding-block: calc(var(--section) * 0.7); }
.p-who-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gutter); margin-top: 3rem; }
.p-who-main { grid-column: span 7; }
.p-who-side { grid-column: span 5; display: grid; gap: var(--gutter); align-content: start; }
.p-who-main .crop { aspect-ratio: 4 / 3; }
.p-who .fig figcaption { font-size: var(--step-body); color: var(--field-muted); margin-top: 1rem; }
.p-who .fig figcaption strong { color: var(--field-ink); }
.p-who-side .crop { aspect-ratio: 16 / 10; }
.who-card { background: #fff; padding: 1.5rem; }
.who-card h3 { font-size: var(--step-lead); line-height: 1.2; margin-bottom: 0.5rem; }
.who-card .p-tag { margin-bottom: 1rem; }

/* works with */
.p-with { padding-block: calc(var(--section) * 0.6); }
.with { list-style: none; padding: 0; margin: 2.5rem 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.with li { background: var(--surface); padding: 1.25rem; min-height: 150px; display: grid; align-content: space-between; gap: 1rem; }
.with strong { font-size: var(--step-lead); font-weight: 600; letter-spacing: -0.01em; }
.with span { font-size: var(--step-small); color: var(--muted); }

/* proof */
.p-proof { background: var(--stone); color: var(--stone-ink); --ink: var(--stone-ink); --muted: var(--stone-muted); padding-block: calc(var(--section) * 0.6); }
.quotes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); margin-top: 3rem; }
.quotes figure { margin: 0; background: #fff; padding: 1.75rem; display: grid; align-content: space-between; gap: 1.5rem; }
.quotes blockquote { margin: 0; font-size: var(--step-lead); line-height: 1.3; letter-spacing: -0.01em; }
.quotes figcaption { font-size: var(--step-small); color: var(--stone-muted); }

/* contact variant on product pages */
.p-contact-alt { display: flex; flex-wrap: wrap; gap: 1rem 1.75rem; align-items: center; margin-top: 1.5rem; }

/* how it works: few words, large type, one line each */
.p-how { padding-block: calc(var(--section) * 0.6) calc(var(--section) * 0.55); }
.p-how-head { margin-bottom: 2.5rem; }
.bigsteps { list-style: none; padding: 0; margin: 0; border-top: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); }
.bigsteps li { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 5fr) minmax(0, 5fr); gap: var(--gutter); align-items: baseline; padding: clamp(1.25rem, 2.4vw, 2rem) 0; border-bottom: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); }
.bs-n { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.5rem, 1rem + 2vw, 2.75rem); line-height: 1; color: var(--accent); }
.bigsteps h3 { font-size: clamp(1.375rem, 1rem + 1.4vw, 2.25rem); line-height: 1.1; letter-spacing: -0.015em; font-weight: 600; }
.bigsteps p { font-size: var(--step-lead); line-height: 1.35; color: var(--muted); }
.included { margin-top: 2.75rem; display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 10fr); gap: var(--gutter); align-items: start; }
.included h3 { font-size: var(--step-small); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); padding-top: 0.6rem; }
.chips { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0.6rem; }
.chips li { padding: 0.5rem 0.95rem; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 24%, transparent); font-size: var(--step-body); }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .flagship { grid-template-columns: 1fr; }
  .flagship-media { min-height: 320px; }
  .how { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feat { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .with { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .products-head, .p-how-head, .p-problem-grid { grid-template-columns: 1fr; row-gap: 1.25rem; }
  .second { grid-template-columns: 1fr; }
  .p-who-main, .p-who-side { grid-column: 1 / -1; }
  .quotes { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .bigsteps li { grid-template-columns: 3.5rem minmax(0, 1fr); row-gap: 0.4rem; }
  .bigsteps li p { grid-column: 2; }
  .included { grid-template-columns: 1fr; gap: 1rem; }
}
@media (max-width: 640px) {
  .w2-sheet { grid-template-columns: 1fr; padding: 12px; min-height: 0; }
  /* retention demo: flag + campaign above the chat, outcome below it, so it reads in story order */
  .w2-story { display: flex; flex-direction: column; gap: 10px; }
  .w2-story .w2-right { display: contents; }
  .w2-story .w2-right > [data-seq="1"] { order: -2; }
  .w2-story .w2-right > [data-seq="2"] { order: -1; }
  .pains { grid-template-columns: 1fr; }
  .how, .feat, .with { grid-template-columns: 1fr; }
  .how li { min-height: 0; }
  .flagship-media .ui-float { width: calc(100% - 28px); }
  .second-name { font-size: clamp(1.5rem, 0.6rem + 4.4vw, 2rem); }
  .p-hero .p-eyebrow { margin-bottom: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .ticket { transition: none; }
}

/* ---------- Whats2Sale: what quiet regulars cost (calculator) ---------- */
.p-cost { background: var(--green); color: var(--green-ink); --muted: var(--green-muted); padding-block: calc(var(--section) * 0.55); }
.p-cost-grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); gap: calc(var(--gutter) * 2); align-items: center; }
.p-cost-text > p { color: var(--green-muted); max-width: 44ch; margin-top: 1rem; }
.cost-form { margin-top: 2rem; display: grid; gap: 0.25rem; }
.cost-ctl { display: grid; grid-template-columns: 1fr auto; column-gap: 1rem; align-items: baseline; padding: 0.9rem 0 0.4rem; border-top: 1px solid color-mix(in srgb, var(--green-ink) 18%, transparent); }
.cost-ctl output { font-weight: 600; font-variant-numeric: tabular-nums; }
.cost-ctl input[type="range"] { grid-column: 1 / -1; width: 100%; margin: 0.6rem 0 0.2rem; accent-color: var(--accent); min-height: 28px; }
.p-cost-out { background: var(--green-deep); padding: clamp(1.5rem, 3vw, 2.75rem); }
.cost-label { font-size: var(--step-small); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--green-muted); }
.cost-big { font-family: var(--font-display); font-weight: 800; font-size: clamp(2.25rem, 1rem + 4.6vw, 4.75rem); line-height: 1; letter-spacing: -0.03em; color: var(--accent); margin: 0.75rem 0 1.25rem; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.cost-cur { font-size: 0.4em; letter-spacing: 0; vertical-align: 0.9em; }
.cost-month, .cost-back { font-size: var(--step-lead); line-height: 1.35; }
.cost-back { margin: 1rem 0 1.75rem; color: var(--green-muted); }
.cost-back strong, .cost-month strong { color: var(--green-ink); white-space: nowrap; }
.cost-note { margin-top: 1.25rem; font-size: var(--step-small); color: var(--green-muted); }

/* ---------- Whats2Sale: WhatsApp alone vs Whats2Sale ---------- */
.p-compare { background: var(--stone); color: var(--stone-ink); --muted: var(--stone-muted); padding-block: calc(var(--section) * 0.55); }
.p-compare .head { margin-bottom: 2.5rem; max-width: 18ch; }
.cmp-row { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 4fr) minmax(0, 5fr); gap: var(--gutter); padding: 1.1rem 0; border-top: 1px solid color-mix(in srgb, var(--stone-ink) 22%, transparent); align-items: baseline; }
.cmp-row strong { font-size: var(--step-lead); line-height: 1.2; letter-spacing: -0.01em; }
.cmp-row span:nth-child(2) { color: var(--stone-muted); }
.cmp-row span:nth-child(3) { font-weight: 500; padding-left: 1.1rem; border-left: 3px solid var(--accent); }
.cmp-headrow { border-top: 0; padding-bottom: 0.5rem; font-size: var(--step-small); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; }
.cmp-headrow span:nth-child(2) { text-decoration: none; }
.cmp-headrow span:nth-child(3) { border-left: 0; padding-left: 1.1rem; }
@media (max-width: 900px) {
  .p-cost-grid { grid-template-columns: 1fr; }
  .cmp-headrow { display: none; }
  .cmp-row { grid-template-columns: 1fr; gap: 0.35rem; }
  .cmp-row span:nth-child(2)::before { content: "Today: "; font-weight: 600; }
}
