/* Kochavit landing pages. Plan: design-system/DESIGN-PLAN.md */
:root {
  --ink: #172636;
  --ink-soft: #4b5b6b;
  --stone: #f2f3ef;
  --surface: #ffffff;
  --line: #d6dad3;
  --card: #fbe7a1;
  --card-line: #e2c66a;
  --stamp: #b8322a;
  --go: #0e7a4b;
  --go-hover: #0b6640;
  --star: #f4b400;
  --wa-bg: #efeae2;
  --wa-head: #008069;
  --error: #b42318;
  --r-card: 14px;
  --r-input: 10px;
  --font: "IBM Plex Sans Hebrew", "Segoe UI", Arial, sans-serif;
  --font-card: "Karantina", "IBM Plex Sans Hebrew", sans-serif;
}
body.dental {
  --ink: #14304a;
  --card: #dcefea;
  --card-line: #a9d6ca;
  --stamp: #1d7a73;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--stone);
  color: var(--ink);
  font: 400 18px/1.6 var(--font);
}
img, svg { display: block; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--go); outline-offset: 3px; border-radius: 4px; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

/* Header */
.top { padding: 22px 0; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 22px; text-decoration: none; }
.logo svg { width: 28px; height: 28px; }
.top-link { font-weight: 500; font-size: 16px; text-decoration: none; border-bottom: 2px solid currentColor; padding-bottom: 1px; }

/* Hero */
.hero { padding: 8px 0 72px; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 64px; align-items: start; }
h1 {
  font-size: clamp(34px, 4.6vw, 56px);
  line-height: 1.1;
  font-weight: 700;
  margin: 16px 0 16px;
  max-width: 15ch;
}
.lead { font-size: 19px; color: var(--ink-soft); margin: 0 0 24px; max-width: 34em; }

/* Form */
.signup { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: 22px 24px 20px; max-width: 520px; }
.signup .row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.signup h2 { font-size: 22px; margin: 0 0 4px; }
.signup .note { margin: 0 0 16px; color: var(--ink-soft); font-size: 16px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-weight: 500; font-size: 16px; margin-bottom: 6px; }
.field input {
  width: 100%;
  font: 400 18px/1.4 var(--font);
  color: var(--ink);
  padding: 12px 14px;
  border: 1.5px solid #b9c0b6;
  border-radius: var(--r-input);
  background: #fff;
  min-height: 50px;
}
.field input:hover { border-color: #8f988c; }
.field input:focus { outline: none; border-color: var(--go); box-shadow: 0 0 0 3px rgba(14, 122, 75, 0.2); }
.field input[aria-invalid="true"] { border-color: var(--error); }
.field .err { color: var(--error); font-size: 15px; margin: 6px 0 0; }
.field input[dir="ltr"] { text-align: right; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 100%; min-height: 54px; padding: 0 24px;
  border: 0; border-radius: var(--r-input);
  background: var(--go); color: #fff;
  font: 700 19px/1 var(--font);
  cursor: pointer; text-decoration: none;
  transition: background-color 180ms ease;
}
.btn:hover { background: var(--go-hover); }
.btn[disabled] { opacity: 0.7; cursor: progress; }
.fine { font-size: 14px; color: var(--ink-soft); margin: 14px 0 0; line-height: 1.5; }
.form-error { color: var(--error); font-size: 16px; margin: 12px 0 0; }
.done h2 { font-size: 24px; margin: 0 0 8px; }
.done p { margin: 0; color: var(--ink-soft); }

/* The scene: job card -> WhatsApp -> Google review */
.scene { position: relative; padding-top: 8px; }
.scene-caption { font-size: 14px; color: var(--ink-soft); margin: 14px 4px 0; }

.ticket {
  position: relative;
  background: var(--card);
  border: 1px solid var(--card-line);
  border-radius: 6px;
  padding: 16px 20px 18px;
  width: 78%;
  margin-inline-start: auto;
  transform: rotate(-2deg);
  box-shadow: 0 1px 0 var(--card-line);
}
.ticket::before { /* perforated top edge */
  content: "";
  position: absolute; inset: -6px 10px auto 10px; height: 12px;
  background: radial-gradient(circle at 6px 6px, var(--stone) 4px, transparent 4.5px) 0 0 / 16px 12px repeat-x;
}
.ticket-head { display: flex; justify-content: space-between; align-items: baseline; border-bottom: 1px dashed var(--card-line); padding-bottom: 6px; margin-bottom: 8px; }
.ticket-title { font-family: var(--font-card); font-size: 26px; line-height: 1; letter-spacing: 0.02em; }
.ticket-no { font-family: var(--font); font-weight: 700; font-size: 17px; line-height: 1; direction: ltr; color: rgba(23, 38, 54, 0.8); }
.ticket dl { display: grid; grid-template-columns: auto 1fr; gap: 2px 14px; margin: 0; font-size: 16px; }
.ticket dt { font-family: var(--font-card); font-size: 20px; line-height: 1.3; color: rgba(23, 38, 54, 0.75); }
.ticket dd { margin: 0; line-height: 1.5; }
.stamp {
  position: absolute; left: 18px; bottom: 14px;
  font-family: var(--font-card); font-size: 34px; line-height: 1; letter-spacing: 0.04em;
  color: var(--stamp); border: 3px solid var(--stamp); border-radius: 6px;
  padding: 4px 12px 2px; transform: rotate(-9deg); opacity: 0.88;
}
body.dental .ticket-title, body.dental .ticket-no, body.dental .ticket dt, body.dental .stamp { font-family: var(--font); font-weight: 700; }
body.dental .ticket-title { font-size: 19px; }
body.dental .ticket-no { font-size: 16px; }
body.dental .ticket dt { font-size: 15px; font-weight: 500; }
body.dental .stamp { font-size: 20px; border-width: 2px; }

.phone {
  position: relative;
  margin: -6px 0 0;
  width: 86%;
  border-radius: 22px;
  overflow: hidden;
  background: var(--wa-bg);
  border: 1px solid #d9d3c9;
}
.wa-head { display: flex; align-items: center; gap: 10px; background: var(--wa-head); color: #fff; padding: 12px 16px; }
.wa-avatar { width: 36px; height: 36px; border-radius: 50%; background: #dfe5e7; color: var(--wa-head); display: grid; place-items: center; font-weight: 700; font-size: 17px; flex: none; }
.wa-name { font-weight: 500; font-size: 16px; line-height: 1.2; }
.wa-sub { font-size: 13px; opacity: 0.85; }
.wa-body { padding: 16px 14px 48px; min-height: 230px; }
.wa-day { text-align: center; margin: 0 0 12px; }
.wa-day span { background: #fff; border-radius: 6px; font-size: 13px; padding: 3px 10px; color: #54656f; }
.bubble {
  position: relative;
  max-width: 88%;
  background: #fff;
  border-radius: 8px;
  border-start-start-radius: 0;
  padding: 8px 12px 20px;
  font-size: 16px;
  line-height: 1.5;
  color: #111b21;
  box-shadow: 0 1px 0.5px rgba(11, 20, 26, 0.13);
}
.bubble .time { position: absolute; left: 10px; bottom: 4px; font-size: 12px; color: #667781; }
.bubble a { color: #027eb5; text-decoration: none; direction: ltr; unicode-bidi: isolate; }
.bubble.out { background: #d9fdd3; margin-inline-start: auto; border-start-start-radius: 8px; border-start-end-radius: 0; margin-top: 8px; padding-bottom: 8px; }
.typing { display: inline-flex; gap: 4px; background: #fff; border-radius: 8px; padding: 12px 14px; }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: #8696a0; animation: blink 1.2s infinite ease-in-out; }
.typing i:nth-child(2) { animation-delay: 0.15s; }
.typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes blink { 0%, 80%, 100% { opacity: 0.3; } 40% { opacity: 1; } }

.review {
  position: relative;
  width: 74%;
  margin: -28px 0 0 auto;
  margin-inline-start: auto;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 14px 16px;
  font-family: Roboto, Arial, sans-serif;
  color: #202124;
}
.review-top { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.review-avatar { width: 32px; height: 32px; border-radius: 50%; background: #7b5ea7; color: #fff; display: grid; place-items: center; font-size: 15px; font-weight: 500; }
.review-name { font-size: 15px; font-weight: 500; line-height: 1.2; }
.review-meta { font-size: 13px; color: #70757a; }
.stars { display: flex; gap: 2px; margin-bottom: 4px; }
.stars svg { width: 16px; height: 16px; fill: var(--star); }
.review p { margin: 0; font-size: 15px; line-height: 1.5; }
.g-logo { position: absolute; left: 14px; top: 14px; width: 18px; height: 18px; }

/* Load sequence: one orchestrated moment, final state without motion */
.js .seq { opacity: 0; }
.js .play .seq-stamp { animation: stamp 380ms cubic-bezier(.2, .9, .3, 1.3) 500ms forwards; }
.js .play .seq-typing { animation: show 1ms 1100ms forwards, hide 1ms 2300ms forwards; }
.js .play .seq-msg { animation: rise 320ms ease-out 2300ms forwards; }
.js .play .seq-reply { animation: rise 320ms ease-out 3300ms forwards; }
.js .play .seq-review { animation: rise 420ms ease-out 4200ms forwards; }
@keyframes stamp { from { opacity: 0; transform: rotate(-9deg) scale(1.6); } to { opacity: 0.88; transform: rotate(-9deg) scale(1); } }
@keyframes show { to { opacity: 1; } }
@keyframes hide { to { opacity: 0; display: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.seq-typing.gone { display: none; }
@media (prefers-reduced-motion: reduce) {
  .js .seq { opacity: 1 !important; animation: none !important; }
  .js .seq-typing { display: none; }
  .stamp.seq { opacity: 0.88 !important; }
  .typing i { animation: none; }
}

/* Sections */
section.band { padding: 72px 0; border-top: 1px solid var(--line); }
section.band h2 { font-size: clamp(26px, 3vw, 34px); line-height: 1.2; margin: 0 0 12px; max-width: 22ch; }
section.band .intro { color: var(--ink-soft); margin: 0 0 36px; max-width: 40em; }

.day { list-style: none; margin: 0; padding: 0; max-width: 760px; }
.day li { display: grid; grid-template-columns: 84px 1fr; gap: 20px; padding: 0 0 28px; position: relative; }
.day li::before { content: ""; position: absolute; right: 99px; top: 12px; bottom: -4px; width: 2px; background: var(--line); }
.day li:last-child::before { display: none; }
.day time { font-weight: 700; font-size: 20px; direction: ltr; text-align: left; font-variant-numeric: tabular-nums; }
.day .dot { position: absolute; right: 94px; top: 9px; width: 12px; height: 12px; border-radius: 50%; background: var(--surface); border: 2px solid var(--ink); }
.day li:last-child .dot { background: var(--star); border-color: var(--star); }
.day h3 { font-size: 20px; margin: 0 0 4px; padding-right: 28px; }
.day p { margin: 0; color: var(--ink-soft); padding-right: 28px; max-width: 34em; }

.rules { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.rules h3 { font-size: 20px; margin: 0 0 14px; }
.rules ul { list-style: none; margin: 0; padding: 0; }
.rules li { display: flex; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.rules li svg { width: 22px; height: 22px; flex: none; margin-top: 3px; }
.rules .yes svg { stroke: var(--go); }
.rules .no svg { stroke: var(--error); }

.price { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: start; }
.price-amount { font-size: 22px; margin: 0 0 8px; }
.price-amount strong { font-size: 44px; line-height: 1; }
.price ul { margin: 0; padding: 0 20px 0 0; }
.price li { margin: 0 0 8px; }
.price .btn { max-width: 320px; margin-top: 12px; }

.faq details, .faq h2 { max-width: 760px; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 18px 0; font-weight: 500; font-size: 19px; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 24px; line-height: 1; color: var(--ink-soft); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0 0 20px; color: var(--ink-soft); max-width: 40em; }

footer { padding: 40px 0 56px; border-top: 1px solid var(--line); font-size: 15px; color: var(--ink-soft); }
footer .wrap { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }

/* Responsive */
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .scene { max-width: 460px; }
  .rules, .price { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 520px) {
  body { font-size: 17px; }
  .signup .row { grid-template-columns: 1fr; }
  .wrap { padding: 0 16px; }
  .lead { font-size: 18px; }
  .signup { padding: 20px 16px; }
  .ticket { width: 92%; }
  .phone { width: 100%; }
  .review { width: 88%; }
  .day li { grid-template-columns: 64px 1fr; gap: 14px; }
  .day li::before { right: 75px; }
  .day .dot { right: 70px; }
  section.band { padding: 56px 0; }
}
