/* ytag.org design system (2026-10-14)
   Trust-first, accessibility-first: large type, 56px tap targets, one accent (brand blue),
   radius scale = 14px interactive / 20px containers / full for chips. Light + dark via tokens. */

:root {
  /* White + the original ytag blue. Light only: the audience is older, keep it simple. */
  --bg: #ffffff;
  --bg-hero: #ffffff;
  --surface: #ffffff;
  --surface-2: #f2f6ff;
  --ink: #111830;
  --ink-2: #3d4560;
  --ink-3: #5c6378;
  --line: #d5dcec;
  --accent: #002dff;
  --accent-hover: #0024cc;
  --accent-ink: #ffffff;
  --accent-soft: #e8efff;
  --bubble: #006dff;
  --success: #0d7a55;
  --danger: #c0180c;
  --shadow: 0 2px 4px rgba(0, 45, 255, .06), 0 16px 36px -14px rgba(0, 45, 255, .28);
  --r-ctl: 14px;
  --r-box: 20px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  color-scheme: light;
}

/* 3-layer horizontal-scroll guard (portfolio rule) */
html, body {
  min-height: 100%;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  overscroll-behavior-x: none;
}
@supports (overflow-x: clip) { html, body { overflow-x: clip; } }

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'IBM Plex Sans Hebrew', 'Rubik', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  position: relative;
  /* no transform here: it would make the sticky CTA's position:fixed relative to <body> */
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
h1, h2, h3, h4, p { overflow-wrap: anywhere; margin: 0; }
a { color: var(--accent); }
img { max-width: 100%; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.ph { line-height: 1; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }

/* ---------- Header ---------- */
.site-head { height: 68px; display: flex; align-items: center; }
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand-logo { height: 44px; width: auto; display: block; }
.head-note { display: none; align-items: center; gap: 8px; font-size: 15px; color: var(--ink-2); font-weight: 500; }
.head-note .ph { color: var(--accent); font-size: 20px; }
@media (min-width: 768px) { .head-note { display: inline-flex; } .brand-logo { height: 50px; } }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(180deg, var(--bg-hero) 0%, var(--bg) 100%);
  padding: 8px 0 40px;
}
.hero-grid { display: grid; gap: 22px; align-items: start; }
.hero-copy h1 {
  font-size: clamp(30px, 7.4vw, 46px);
  line-height: 1.12;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.hero-copy h1 .hl { color: var(--accent); }
.hero-sub { margin-top: 12px; font-size: 18px; color: var(--ink-2); max-width: 34ch; }
.operator-line {
  margin-top: 16px;
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 15px; line-height: 1.5; color: var(--ink-2);
  max-width: 44ch;
}
.operator-line .ph { color: var(--success); font-size: 20px; flex-shrink: 0; margin-top: 1px; }
.operator-line strong { color: var(--ink); font-weight: 600; }
.hero-proof { display: none; }
@media (min-width: 960px) {
  .hero { padding: 32px 0 72px; }
  .hero-grid { grid-template-columns: 1.05fr 1fr; gap: 56px; }
  .hero-copy { padding-top: 36px; }
  .hero-sub { font-size: 20px; }
  .hero-proof { display: grid; gap: 14px; margin-top: 32px; padding: 0; list-style: none; }
  .hero-proof li { display: flex; align-items: center; gap: 12px; font-size: 17px; font-weight: 500; }
  .hero-proof .ph { width: 36px; height: 36px; border-radius: 50%; background: var(--surface); color: var(--accent); display: grid; place-items: center; font-size: 19px; box-shadow: var(--shadow); }
}

/* ---------- Form card (shared by / and /quiz/) ---------- */
.form-card {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  background: var(--surface);
  border: 3px solid var(--accent);
  border-radius: var(--r-box);
  box-shadow: var(--shadow);
  padding: 0 18px 18px;
  position: relative;
  text-align: right;
  overflow: hidden;
}
@media (min-width: 480px) { .form-card { padding: 0 26px 22px; } }
/* Blue header band so it is obvious where to fill in */
.form-card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 0 -18px 18px; padding: 16px 18px;
  background: var(--accent); color: var(--accent-ink);
}
@media (min-width: 480px) { .form-card-head { margin: 0 -26px 20px; padding: 18px 26px; } }
.form-card-title { font-size: 20px; font-weight: 700; line-height: 1.3; }
.form-card-time { display: inline-flex; align-items: center; gap: 6px; font-size: 15px; font-weight: 500; white-space: nowrap; opacity: .95; }

.progress-track { height: 6px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px; overflow: hidden; margin: 0 0 20px; }
.progress-fill { height: 100%; width: 0%; background: var(--accent); border-radius: 999px; transition: width .35s var(--ease); }

.form-step { display: none; }
.form-step.active-step { display: block; }
.form-step.conditional-step:not(.active-step) { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .form-step.active-step { animation: step-in .32s var(--ease); }
  @keyframes step-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
}

/* Chat bubble: the persona asks each question */
.chat-bubble { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 18px; }
.chat-bubble .avatar {
  width: 48px; height: 48px; border-radius: 50%; flex-shrink: 0; object-fit: cover;
  border: 2px solid var(--surface); box-shadow: 0 0 0 2px var(--accent);
}
.chat-bubble .message {
  background: var(--bubble);
  color: #ffffff;
  border-radius: 4px 18px 18px 18px;
  padding: 13px 16px;
  font-size: 18px;
  line-height: 1.5;
  font-weight: 500;
  max-width: 100%;
}
.bubble-hint { display: block; margin-top: 6px; font-size: 15px; font-weight: 400; color: #ffffff; opacity: .92; }

/* Inputs */
.form-card input[type="text"],
.form-card input[type="tel"],
.form-card input[type="email"],
.form-card input[type="number"] {
  width: 100%;
  min-height: 56px;
  padding: 12px 16px;
  font: inherit;
  font-size: 18px;
  color: var(--ink);
  background: var(--surface);
  border: 2px solid #b9c4de;
  border-radius: var(--r-ctl);
  margin: 0 0 14px;
  text-align: right;
  direction: rtl;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.form-card input::placeholder { color: var(--ink-3); }
.form-card input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }

/* Buttons */
.form-card button,
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%;
  min-height: 56px;
  padding: 12px 20px;
  font: inherit;
  font-size: 18px;
  font-weight: 700;
  color: var(--accent-ink);
  background: var(--accent);
  border: 0;
  border-radius: var(--r-ctl);
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .2s var(--ease), transform .12s var(--ease), box-shadow .2s var(--ease);
}
.form-card button:hover, .btn:hover { background: var(--accent-hover); }
.form-card button:active, .btn:active { transform: scale(.985); }
.form-card button:focus-visible, .btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.form-card button:disabled,
.form-card button[disabled] { background: var(--surface-2); color: var(--ink-3); border: 1px solid var(--line); cursor: not-allowed; transform: none; }

.button-row { display: grid; grid-template-columns: 1fr 2fr; gap: 10px; margin-top: 6px; }
.form-card .prev-btn { background: var(--surface); color: var(--ink); border: 1.5px solid var(--line); }
.form-card .prev-btn:hover { background: var(--surface-2); }

/* Quiz: multiple-choice answers */
.form-card .answer-btn {
  justify-content: flex-start;
  text-align: right;
  white-space: normal;
  margin: 0 0 10px;
  min-height: 56px;
  font-weight: 500;
  color: var(--ink);
  background: var(--surface);
  border: 1.5px solid var(--line);
}
.form-card .answer-btn:hover { background: var(--accent-soft); border-color: var(--accent); }
.form-card .answer-btn.selected { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

/* Quiz: back link */
.form-card .back-btn {
  width: auto; min-height: 40px; padding: 6px 10px; margin: -6px -8px 12px 0;
  font-size: 15px; font-weight: 600;
  background: transparent; color: var(--accent);
}
.form-card .back-btn:hover { background: var(--accent-soft); }
.back-btn .arrow { font-size: 18px; line-height: 1; }

/* Age slider */
.form-card input[type="range"]#age {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 8px; margin: 18px 0 16px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px; cursor: pointer;
}
#age::-webkit-slider-thumb { -webkit-appearance: none; width: 32px; height: 32px; border-radius: 50%; background: var(--accent); border: 4px solid var(--surface); box-shadow: 0 2px 8px rgba(17, 24, 48, .25); }
#age::-moz-range-thumb { width: 26px; height: 26px; border-radius: 50%; background: var(--accent); border: 4px solid var(--surface); box-shadow: 0 2px 8px rgba(17, 24, 48, .25); }
#ageDisplayWrapper { display: flex; align-items: center; justify-content: center; gap: 10px; font-size: 18px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.form-card #ageDisplayInput { width: 96px; min-height: 52px; margin: 0; text-align: center; font-size: 24px; font-weight: 700; color: var(--accent); }
.age-note { text-align: center; font-size: 14px; color: var(--ink-3); margin: 0 0 14px; }

/* Errors + notes */
.error-msg { display: block; color: var(--danger); font-size: 15px; margin: -6px 0 12px; }
.callback-note {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 16px; line-height: 1.5;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-ctl);
  padding: 12px 14px; margin: 2px 0 14px;
}
.callback-note .ph { color: var(--accent); font-size: 22px; flex-shrink: 0; }
/* Consent: one big tappable box. Older audience, so it tells people what to do next. */
.consent-guide {
  display: none; align-items: center; gap: 8px;
  margin: 2px 0 8px; font-size: 17px; font-weight: 700; color: var(--accent);
}
.consent-guide.show { display: flex; }
.consent-guide .ph { font-size: 22px; }
@media (prefers-reduced-motion: no-preference) {
  .consent-guide.show .ph { animation: guide-bob 1.2s ease-in-out infinite; }
  @keyframes guide-bob { 50% { transform: translateY(4px); } }
}
.consent-box {
  display: flex; align-items: flex-start; gap: 14px;
  margin: 0 0 12px; padding: 14px 14px;
  background: var(--surface-2); border: 2px solid #b9c4de; border-radius: var(--r-ctl);
  font-size: 15px; line-height: 1.5; color: var(--ink-2); cursor: pointer;
  transition: border-color .2s var(--ease), background-color .2s var(--ease), box-shadow .2s var(--ease);
}
.consent-box input[type="checkbox"] {
  width: 32px; height: 32px; margin: 0; flex-shrink: 0; cursor: pointer; accent-color: var(--success);
}
.consent-copy { display: grid; gap: 2px; }
.consent-cta { font-size: 18px; color: var(--ink); }
.consent-box.attention { border-color: var(--accent); border-width: 3px; padding: 13px; box-shadow: 0 0 0 5px var(--accent-soft); }
.consent-box.attention .consent-cta { color: var(--accent); }
.consent-box.is-checked { border-color: var(--success); background: #ecf8f2; box-shadow: none; }
.consent-box.is-checked .consent-cta { color: var(--success); }
@media (prefers-reduced-motion: no-preference) {
  .consent-box.nudge { animation: nudge .5s var(--ease); }
  @keyframes nudge { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
}
.form-secure-note { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 16px 0 0; font-size: 14px; color: var(--ink-3); }

/* ---------- Trust band ---------- */
.trust { padding: 8px 0 8px; }
.trust-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.trust-list li {
  display: flex; flex-direction: column; gap: 6px;
  padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-box);
}
.trust-list .ph { font-size: 26px; color: var(--accent); }
.trust-list strong { font-size: 17px; line-height: 1.3; }
.trust-list span { font-size: 14px; color: var(--ink-3); line-height: 1.4; }
@media (min-width: 960px) {
  .trust-list { grid-template-columns: repeat(4, 1fr); gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-box); }
  .trust-list li { background: none; border: 0; border-radius: 0; padding: 24px; }
  .trust-list li + li { border-inline-start: 1px solid var(--line); }
}

/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section h2 { font-size: clamp(26px, 5.4vw, 36px); line-height: 1.2; font-weight: 700; letter-spacing: -0.01em; }
.section-lead { margin-top: 10px; font-size: 18px; color: var(--ink-2); max-width: 52ch; }
@media (min-width: 960px) { .section { padding: 88px 0; } }

/* How it works: vertical timeline beside a sticky title */
.steps-grid { display: grid; gap: 28px; }
@media (min-width: 960px) {
  .steps-grid { grid-template-columns: 1fr 1.3fr; gap: 64px; }
  .steps-grid > div:first-child { position: sticky; top: 32px; align-self: start; }
}
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline li { position: relative; display: grid; grid-template-columns: 48px 1fr; gap: 16px; padding-bottom: 28px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li:not(:last-child)::before {
  content: ""; position: absolute; top: 52px; bottom: 4px; inset-inline-start: 23px; width: 2px; background: var(--line);
}
.timeline .num {
  width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: 19px;
}
.timeline li:last-child .num { background: var(--accent); color: var(--accent-ink); }
.timeline h3 { font-size: 20px; line-height: 1.3; font-weight: 700; padding-top: 10px; }
.timeline p { margin-top: 4px; color: var(--ink-2); }

/* Who it's for: tinted panel with 2x2 tiles */
.who { background: var(--surface); border-block: 1px solid var(--line); }
.who-grid { display: grid; gap: 12px; margin-top: 28px; }
@media (min-width: 640px) { .who-grid { grid-template-columns: 1fr 1fr; } }
.who-grid div { display: flex; align-items: center; gap: 14px; padding: 18px; border-radius: var(--r-box); background: var(--surface-2); border: 1px solid var(--line); font-size: 18px; font-weight: 500; line-height: 1.4; }
.who-grid .ph { font-size: 28px; color: var(--accent); flex-shrink: 0; }

/* FAQ */
.faq { max-width: 760px; }
.faq-list { margin-top: 24px; display: grid; gap: 10px; }
.faq-list details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-box); }
.faq-list summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 20px; min-height: 60px; font-size: 18px; font-weight: 600;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary .ph { color: var(--accent); font-size: 20px; flex-shrink: 0; transition: transform .25s var(--ease); }
.faq-list details[open] summary .ph { transform: rotate(45deg); }
.faq-list details p { padding: 0 20px 18px; color: var(--ink-2); }
.faq-list summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: var(--r-box); }

/* Final CTA */
.final-cta { padding: 0 0 64px; }
.final-cta .box {
  background: var(--accent); color: var(--accent-ink); border-radius: var(--r-box);
  padding: 32px 22px; display: grid; gap: 18px; text-align: center; justify-items: center;
}
.final-cta h2 { font-size: clamp(24px, 5vw, 32px); line-height: 1.25; font-weight: 700; }
.final-cta p { opacity: .9; font-size: 17px; }
.final-cta .btn { width: auto; min-width: 240px; background: #ffffff; color: var(--accent); }
.final-cta .btn:hover { background: var(--accent-soft); }

/* Sticky mobile CTA, shown only while the form is off-screen */
.sticky-cta {
  position: fixed; inset-inline: 0; bottom: 0; z-index: 40;
  /* inline-end gap leaves room for the accessibility widget button (bottom-left) */
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  padding-inline-end: 84px;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  transform: translateY(110%); transition: transform .3s var(--ease);
}
.sticky-cta.show { transform: none; }
@media (min-width: 960px) { .sticky-cta { display: none; } }

/* ---------- Footer ---------- */
.site-foot { padding: 24px 16px 96px; text-align: center; font-size: 14px; color: var(--ink-3); }
.site-foot a { color: var(--ink-2); }
@media (min-width: 960px) { .site-foot { padding-bottom: 32px; } }

/* ---------- Thanks page ---------- */
.thanks-main { padding: 16px 0 24px; }
.thanks-card { max-width: 560px; margin: 0 auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-box); box-shadow: var(--shadow); padding: 32px 22px; }
.thanks-card .success-icon { width: 64px; height: 64px; border-radius: 50%; background: var(--success); color: #fff; display: grid; place-items: center; font-size: 34px; margin: 0 auto 16px; }
.thanks-title { font-size: clamp(26px, 6vw, 34px); line-height: 1.2; font-weight: 700; text-align: center; }
.thanks-sub { margin-top: 10px; text-align: center; color: var(--ink-2); font-size: 18px; }
.thanks-card h2 { font-size: 24px; margin: 32px 0 18px; }

/* Per-section defensive overflow guard (portfolio rule) */
.site-head, .hero, .trust, .section, .final-cta, .site-foot, .thanks-main { overflow-x: clip; max-width: 100%; }

/* Quiz loading overlay */
.loading-overlay { position: fixed; inset: 0; z-index: 90; display: none; align-items: center; justify-content: center; background: color-mix(in srgb, var(--bg) 75%, transparent); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); }
.loading-overlay.show { display: flex; }
.spinner { width: 44px; height: 44px; border: 4px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* Transparency notice (Google gov-documents policy): calm, readable, not alarming */
.notice-sec { padding-top: 0; }
.notice-box {
  display: flex; gap: 14px; align-items: flex-start;
  max-width: 760px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-box);
  padding: 20px;
}
.notice-box > .ph { font-size: 28px; color: var(--accent); flex-shrink: 0; margin-top: 2px; }
.notice-box h2 { font-size: 22px; margin-bottom: 8px; }
.notice-box p { color: var(--ink-2); font-size: 17px; }
.notice-box p + p { margin-top: 8px; }
