/* Kaksho website. Editorial layout: serif headlines, hairline rules, left-aligned section headers, real screenshots
   in plain frames. Motion only where it explains something (the tour, the day, the language switch). */

:root {
  --paper: #fbfaf7;
  --white: #ffffff;
  --sand: #f3f1ec;
  --ink: #17162a;
  --body: #43425a;
  --muted: #7d7b90;
  --rule: #e4e1da;
  --rule-strong: #d3d0c7;
  --indigo: #3e3ab8;
  --night: #16152b;
  --night-rule: rgba(255, 255, 255, 0.12);
  --night-body: #c9c8dc;
  --night-muted: #8f8ea8;
  --serif: "Newsreader", "Noto Serif Devanagari", Georgia, serif;
  --sans: "Inter", "Noto Sans Devanagari", system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --frame-shadow: 0 1px 1px rgba(23, 22, 42, 0.04), 0 18px 40px -24px rgba(23, 22, 42, 0.28);
  /* Where the right-hand column of a section header starts (3 of 12 columns, plus the 32px gap). */
  --indent: calc((100% - 32px) * 0.25 + 32px);
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--body);
  font: 400 16.5px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1,
h2,
h3 {
  margin: 0;
  color: var(--ink);
  text-wrap: balance;
}
h1,
h2 {
  font-family: var(--serif);
  font-weight: 450;
  letter-spacing: -0.018em;
  font-optical-sizing: auto;
}
h3 {
  font: 600 17px/1.35 var(--sans);
  letter-spacing: -0.01em;
}
p {
  margin: 0;
  text-wrap: pretty;
}
a {
  color: var(--indigo);
  text-decoration: none;
}
img {
  display: block;
  max-width: 100%;
  height: auto;
}
ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}
button {
  font: inherit;
}
:focus-visible {
  outline: 2px solid var(--indigo);
  outline-offset: 3px;
  border-radius: 4px;
}
.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: 10px 16px;
  border-radius: 6px;
}
.skip:focus {
  top: 12px;
}
.wrap {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding-inline: 32px;
}
section {
  padding-block: 112px;
}
.white {
  background: var(--white);
  border-block: 1px solid var(--rule);
}

/* Small uppercase label, no ornament. */
.label {
  font: 500 12.5px/1.2 var(--sans);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Section header: label on the left, headline and intro on the right, over a hairline. */
.sh {
  display: grid;
  grid-template-columns: 3fr 9fr;
  gap: 32px;
  padding-top: 22px;
  border-top: 1px solid var(--rule-strong);
}
.sh .label {
  display: flex;
  gap: 14px;
}
.sh .label b {
  font-weight: 500;
  color: var(--ink);
}
.sh h2 {
  font-size: clamp(34px, 4.2vw, 54px);
  line-height: 1.06;
  max-width: 17em;
}
.sh .lede {
  margin-top: 20px;
  font-size: 18.5px;
  line-height: 1.6;
  max-width: 40em;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 46px;
  padding: 0 20px;
  border-radius: 8px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  font: 500 15.5px/1 var(--sans);
  cursor: pointer;
  white-space: nowrap;
  transition:
    background 0.2s,
    border-color 0.2s;
}
.btn:hover {
  background: var(--indigo);
  border-color: var(--indigo);
}
.btn.line {
  background: transparent;
  color: var(--ink);
  border-color: var(--rule-strong);
}
.btn.line:hover {
  background: var(--white);
  border-color: var(--ink);
}
.btn.sm {
  height: 38px;
  padding: 0 14px;
  font-size: 14.5px;
}
.more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font: 500 15.5px/1 var(--sans);
  color: var(--ink);
}
.more::after {
  content: "→";
  transition: transform 0.2s var(--ease);
}
.more:hover::after {
  transform: translateX(3px);
}
.ico {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 250, 247, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}
.site-header.scrolled {
  border-bottom-color: var(--rule);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  height: 64px;
  gap: 28px;
}
.brand img {
  height: 25px;
  width: auto;
}
.nav {
  display: flex;
  gap: 26px;
  margin-left: auto;
}
.nav a {
  color: var(--body);
  font: 450 14.5px/1 var(--sans);
  transition: color 0.2s;
}
.nav a:hover {
  color: var(--ink);
}
.menu-btn {
  display: none;
  margin-left: auto;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid var(--rule-strong);
  background: transparent;
  color: var(--ink);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* ---------- Hero ---------- */
.hero {
  padding-block: 88px 0;
}
.hero-grid {
  display: grid;
  grid-template-columns: 7fr 5fr;
  gap: 64px;
  align-items: end;
}
.hero h1 {
  font-size: clamp(44px, 6.4vw, 84px);
  line-height: 1;
  letter-spacing: -0.028em;
  margin-top: 22px;
}
.hero h1 em {
  color: var(--indigo);
}
.hero-side p {
  font-size: 18px;
  line-height: 1.6;
}
.hero-ctas {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  margin-top: 30px;
}
.hero-shot {
  margin-top: 72px;
}
.frame {
  background: var(--white);
  border: 1px solid var(--rule-strong);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--frame-shadow);
}
.frame .bar {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 14px;
  border-bottom: 1px solid var(--rule);
  background: #f7f6f2;
}
.frame .bar i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--rule-strong);
}
.frame .bar span {
  margin-left: 12px;
  font: 450 12px/1 var(--sans);
  color: var(--muted);
}
.frame img {
  width: 100%;
}
/* A dialog captured on its own: trim the edge, where the dimmed page behind it shows at the corners. */
.frame.dlg img {
  width: calc(100% + 8px);
  max-width: none;
  margin: -4px;
}
.surfaces {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 48px;
  border-top: 1px solid var(--rule-strong);
}
.surfaces li {
  padding: 20px 24px 0 0;
}
.surfaces li + li {
  padding-left: 24px;
  border-left: 1px solid var(--rule);
}
.surfaces p {
  margin-top: 6px;
  font-size: 15px;
  color: var(--muted);
  line-height: 1.55;
}

.phone {
  width: 270px;
  max-width: 100%;
  padding: 8px;
  border-radius: 38px;
  background: #1b1a2e;
  box-shadow: 0 30px 50px -30px rgba(23, 22, 42, 0.55);
  flex: none;
}
.phone .scr {
  position: relative;
  border-radius: 30px;
  overflow: hidden;
  background: #fff;
  aspect-ratio: 585 / 1300;
}
.phone .scr img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}
/* Phone-size web pages (teacher portal) have no status bar: a white strip stands in. */
.phone .scr img.web {
  top: 22px;
  height: calc(100% - 22px);
}
figure {
  margin: 0;
}
figcaption {
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
}
figcaption b {
  color: var(--ink);
  font-weight: 500;
}

/* Hairline lists, used for features beside pictures. */
.list {
  margin-top: 32px;
  border-top: 1px solid var(--rule);
}
.list li {
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
  font-size: 16px;
  line-height: 1.55;
}
.list b {
  color: var(--ink);
  font-weight: 600;
}

/* ---------- Before / after ---------- */
.compare {
  margin-top: 56px;
  margin-left: var(--indent);
}
.compare .row {
  display: grid;
  grid-template-columns: 170px 1fr 1.25fr;
  gap: 24px;
  padding: 16px 0;
  border-bottom: 1px solid var(--rule);
  font-size: 16px;
  line-height: 1.5;
}
.compare .row.th {
  padding-top: 0;
}
.compare .row.th div {
  font: 500 12.5px/1.2 var(--sans);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
}
.compare .k {
  color: var(--ink);
  font-weight: 600;
}
.compare .old {
  color: var(--muted);
}
.compare .new {
  color: var(--ink);
}

/* ---------- Product tour ---------- */
.tour {
  margin-top: 56px;
}
.tour-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--rule-strong);
}
.tour-tab {
  position: relative;
  text-align: left;
  border: 0;
  background: none;
  padding: 18px 24px 22px 0;
  cursor: pointer;
  color: var(--muted);
}
.tour-tab + .tour-tab {
  padding-left: 24px;
}
.tour-tab h3 {
  color: var(--muted);
  transition: color 0.25s;
}
.tour-tab p {
  margin-top: 6px;
  font-size: 14.5px;
  line-height: 1.5;
}
.tour-tab:hover h3,
.tour-tab[aria-selected="true"] h3 {
  color: var(--ink);
}
.tour-tab[aria-selected="true"] p {
  color: var(--body);
}
/* The progress line runs along the top rule of the active tab. */
.tour-tab .progress {
  position: absolute;
  top: -1px;
  left: 0;
  right: 0;
  height: 2px;
  overflow: hidden;
}
.tour-tab + .tour-tab .progress {
  left: 24px;
}
.tour-tab .progress i {
  display: block;
  height: 100%;
  background: var(--ink);
  transform-origin: left;
  transform: scaleX(0);
}
.tour-tab[aria-selected="true"] .progress i {
  transform: scaleX(var(--p, 1));
}
.tour-stage {
  position: relative;
  margin-top: 8px;
  aspect-ratio: 16 / 10.4;
  border-radius: 14px;
  background: var(--sand);
  overflow: hidden;
}
.tour-panel {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  padding: 40px 56px;
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.5s var(--ease),
    transform 0.6s var(--ease);
  pointer-events: none;
}
.tour-panel.on {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
.tour-panel .frame {
  width: 100%;
}
.tour-panel .phone {
  width: min(240px, 34%);
}

/* ---------- A day at your institute ---------- */
.day-grid {
  display: grid;
  grid-template-columns: 3fr 4fr 5fr;
  gap: 32px;
  margin-top: 24px;
}
.clock {
  grid-column: 1;
  grid-row: 1;
  position: sticky;
  top: 140px;
  align-self: start;
  margin-top: 120px;
  font: 400 64px/1 var(--serif);
  color: var(--ink);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums lining-nums;
}
.clock .t {
  display: inline-block;
}
.clock .t.flip {
  animation: rise 0.5s var(--ease);
}
.clock small {
  display: block;
  margin-top: 12px;
  font: 500 12.5px/1.2 var(--sans);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
}
@keyframes rise {
  from {
    transform: translateY(40%);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
.day-visual {
  grid-column: 2;
  grid-row: 1;
  position: sticky;
  top: 80px;
  align-self: start;
  height: calc(100vh - 100px);
  max-height: 780px;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.day-visual .phone {
  width: 280px;
}
.day-visual .scr img {
  opacity: 0;
  transition: opacity 0.55s var(--ease);
}
.day-visual .scr img.on {
  opacity: 1;
}
.day-steps {
  grid-column: 3;
  grid-row: 1;
  padding-block: 14vh 20vh;
}
.day-step {
  min-height: 56vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  opacity: 0.3;
  transition: opacity 0.45s var(--ease);
}
.day-step.on {
  opacity: 1;
}
.day-step .when {
  font: 500 12.5px/1 var(--sans);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
}
.day-step h3 {
  font: 450 30px/1.15 var(--serif);
  letter-spacing: -0.015em;
  margin-top: 14px;
}
.day-step p {
  margin-top: 14px;
  font-size: 17px;
  max-width: 34em;
}
.day-step .note {
  margin-top: 14px;
  font: 500 14px/1.4 var(--sans);
  color: var(--indigo);
}
.day-step .step-shot {
  display: none;
}

/* ---------- Copy beside pictures ---------- */
.spot {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 72px;
  align-items: start;
  margin-top: 56px;
}
.spot.flip {
  grid-template-columns: 7fr 5fr;
}
.spot.flip > .copy {
  order: 2;
}
.spot .copy > p {
  font-size: 17.5px;
}

/* ---------- Focus Mode ---------- */
.night {
  background: var(--night);
  color: var(--night-body);
}
.night h2,
.night h3 {
  color: #fff;
}
.night .sh {
  border-top-color: var(--night-rule);
}
.night .label {
  color: var(--night-muted);
}
.night .sh .label b {
  color: #fff;
}
.night .lede {
  color: var(--night-body);
}
.focus-phones {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 72px;
}
.focus-phones figure {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.focus-phones .phone {
  width: 260px;
  background: #0c0b1a;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}
.night figcaption {
  color: var(--night-muted);
  text-align: center;
}
.night figcaption b {
  color: #fff;
}
.cols4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 80px;
  border-top: 1px solid var(--night-rule);
}
.cols4 > div {
  padding: 22px 24px 0 0;
}
.cols4 > div + div {
  padding-left: 24px;
  border-left: 1px solid var(--night-rule);
}
.cols4 p {
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--night-muted);
}

/* ---------- Tests ---------- */
.nta-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  margin-top: 24px;
  font-size: 14px;
  color: var(--muted);
}
.nta-legend span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.nta {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  font: 600 10.5px/1 var(--sans);
  font-style: normal;
  color: #fff;
  flex: none;
}
.nta.ans {
  background: #2e9e44;
  clip-path: polygon(50% 0, 100% 32%, 100% 100%, 0 100%, 0 32%);
}
.nta.not {
  background: #d4462c;
  clip-path: polygon(0 0, 100% 0, 100% 68%, 50% 100%, 0 68%);
}
.nta.rev {
  background: #6b3fb4;
  border-radius: 50%;
}
.nta.nv {
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--rule-strong);
  border-radius: 3px;
}
.results-row {
  display: grid;
  grid-template-columns: 7fr 5fr;
  gap: 72px;
  align-items: center;
  margin-top: 96px;
}
.results-row figure:last-child {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ---------- Parents ---------- */
.lang-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}
.seg {
  display: inline-flex;
  border: 1px solid var(--rule-strong);
  border-radius: 8px;
  padding: 3px;
  background: var(--white);
}
.seg button {
  border: 0;
  background: transparent;
  padding: 7px 16px;
  border-radius: 6px;
  font: 500 14.5px/1 var(--sans);
  color: var(--muted);
  cursor: pointer;
  transition:
    background 0.25s,
    color 0.25s;
}
.seg button[aria-pressed="true"] {
  background: var(--ink);
  color: #fff;
}
.lang-stage .scr img {
  transition: opacity 0.5s var(--ease);
}
.lang-stage .scr img.hidden {
  opacity: 0;
}

/* ---------- Fees ---------- */
.fees-pics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: start;
}
.fees-pics .stack {
  display: grid;
  gap: 24px;
}

/* ---------- Teachers ---------- */
.teach-pics {
  display: grid;
  grid-template-columns: 8fr 4fr;
  gap: 40px;
  align-items: end;
  margin-top: 56px;
}
.teach-pics .phone {
  width: 100%;
  max-width: 260px;
}

/* ---------- Everything else ---------- */
.modules {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 48px;
  row-gap: 48px;
  margin-top: 64px;
}
.module {
  border-top: 1px solid var(--rule-strong);
  padding-top: 18px;
}
.module ul {
  margin-top: 12px;
}
.module li {
  font-size: 15.5px;
  line-height: 1.5;
  padding: 7px 0;
  border-bottom: 1px solid var(--rule);
}

/* ---------- Who builds it ---------- */
.team-text {
  margin-left: var(--indent);
  margin-top: 32px;
  font: 400 clamp(24px, 2.6vw, 34px) / 1.35 var(--serif);
  color: var(--ink);
  letter-spacing: -0.01em;
  max-width: 26em;
}
.team-text em {
  color: var(--indigo);
}

/* ---------- Going live ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 48px;
  row-gap: 40px;
  margin-top: 56px;
  margin-left: var(--indent);
}
.step {
  border-top: 1px solid var(--rule-strong);
  padding-top: 16px;
}
.step .n {
  font: 400 30px/1 var(--serif);
  color: var(--indigo);
}
.step h3 {
  margin-top: 14px;
}
.step p {
  margin-top: 6px;
  font-size: 15.5px;
  line-height: 1.55;
}

/* ---------- FAQ ---------- */
.faq {
  margin-top: 40px;
  margin-left: var(--indent);
  border-top: 1px solid var(--rule);
}
.faq details {
  border-bottom: 1px solid var(--rule);
}
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 0;
  font: 500 17.5px/1.4 var(--sans);
  color: var(--ink);
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary .pm {
  flex: none;
  width: 14px;
  height: 14px;
  position: relative;
}
.faq summary .pm::before,
.faq summary .pm::after {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 14px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.3s var(--ease);
}
.faq summary .pm::after {
  transform: rotate(90deg);
}
.faq details[open] summary .pm::after {
  transform: rotate(0deg);
}
.faq .a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s var(--ease);
}
.faq details[open] .a {
  grid-template-rows: 1fr;
}
.faq .a > div {
  overflow: hidden;
}
.faq .a p {
  padding: 0 48px 24px 0;
  font-size: 16.5px;
}

/* ---------- Demo ---------- */
.demo-grid {
  display: grid;
  grid-template-columns: 4fr 5fr;
  gap: 48px;
  margin-top: 40px;
  margin-left: var(--indent);
}
.demo-grid .intro p {
  font-size: 17px;
}
.contacts {
  margin-top: 28px;
  border-top: 1px solid var(--rule);
}
.contacts a {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
  color: var(--ink);
  font: 500 16px/1.3 var(--sans);
}
.contacts a span {
  font: 400 13.5px/1.3 var(--sans);
  color: var(--muted);
}
.contacts a:hover {
  color: var(--indigo);
}
.form {
  background: var(--white);
  border: 1px solid var(--rule-strong);
  border-radius: 12px;
  padding: 28px;
}
.form h3 {
  font: 450 24px/1.2 var(--serif);
}
.fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 20px;
}
.field {
  display: grid;
  gap: 6px;
}
.field.full {
  grid-column: 1 / -1;
}
.field label {
  font: 500 13.5px/1.2 var(--sans);
  color: var(--ink);
}
.field input,
.field select {
  width: 100%;
  height: 44px;
  border-radius: 8px;
  border: 1px solid var(--rule-strong);
  background: var(--white);
  padding: 0 12px;
  font: 400 16px var(--sans);
  color: var(--ink);
  transition: border-color 0.2s;
}
.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--ink);
}
.field input[aria-invalid="true"] {
  border-color: #c0392b;
}
.form-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 20px;
}
.form-actions .btn {
  width: 100%;
  padding: 0 12px;
}
.form .err {
  margin-top: 10px;
  min-height: 1em;
  font-size: 14px;
  color: #c0392b;
}
.form .fine {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--rule);
  padding-block: 48px 36px;
  font-size: 14.5px;
}
.foot-grid {
  display: grid;
  grid-template-columns: 3fr 3fr 3fr 3fr;
  gap: 32px;
}
.foot-grid ul {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}
.foot-grid a {
  color: var(--body);
}
.foot-grid a:hover {
  color: var(--ink);
}
.foot-grid .about p {
  margin-top: 14px;
  color: var(--muted);
  max-width: 28ch;
}
.legal {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13.5px;
}

/* ---------- Motion ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 0.7s var(--ease),
    transform 0.8s var(--ease);
  transition-delay: calc(var(--i, 0) * 80ms);
}
.js .reveal.in {
  opacity: 1;
  transform: none;
}
/* The hero screenshot is uncovered from the top, like a window opening. */
.js .hero-shot .frame {
  clip-path: inset(0 0 100% 0 round 12px);
  transition: clip-path 1.3s var(--ease) 0.35s;
}
.js .hero.ready .hero-shot .frame {
  clip-path: inset(0 0 0 0 round 12px);
}
.js .hero .fade {
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.8s var(--ease),
    transform 0.8s var(--ease);
  transition-delay: calc(var(--i, 0) * 100ms);
}
.js .hero.ready .fade {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
  .js .reveal,
  .js .hero .fade {
    opacity: 1 !important;
    transform: none !important;
  }
  .js .hero-shot .frame {
    clip-path: none !important;
  }
}

/* ---------- Smaller screens ---------- */
@media (max-width: 1080px) {
  .nav {
    gap: 18px;
  }
  .tour-tab p {
    display: none;
  }
  .cols4 {
    grid-template-columns: 1fr 1fr;
  }
  .cols4 > div:nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }
  .cols4 > div:nth-child(n + 3) {
    padding-top: 28px;
  }
  .day-grid {
    grid-template-columns: 2fr 4fr 5fr;
  }
  .clock {
    font-size: 48px;
  }
}
@media (max-width: 900px) {
  .wrap {
    padding-inline: 20px;
  }
  section {
    padding-block: 80px;
  }
  .nav {
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    padding: 4px 20px 16px;
    background: var(--paper);
    border-bottom: 1px solid var(--rule);
    display: none;
  }
  .nav.open {
    display: flex;
  }
  .nav a {
    padding: 14px 0;
    font-size: 16px;
    border-bottom: 1px solid var(--rule);
  }
  .menu-btn {
    display: inline-flex;
  }
  .site-header .btn {
    display: none;
  }
  .sh {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .hero {
    padding-top: 56px;
  }
  .hero-grid,
  .spot,
  .spot.flip,
  .results-row,
  .teach-pics {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .spot.flip > .copy {
    order: 0;
  }
  .hero-shot {
    margin-top: 48px;
  }
  .surfaces {
    grid-template-columns: 1fr 1fr;
  }
  .surfaces li:nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }
  .surfaces li:nth-child(n + 3) {
    padding-top: 20px;
  }
  .compare,
  .steps,
  .faq,
  .team-text {
    margin-left: 0;
  }
  .day-grid {
    display: block;
  }
  .day-visual,
  .clock {
    display: none;
  }
  .day-steps {
    padding-block: 8px 0;
  }
  .day-step {
    min-height: 0;
    opacity: 1;
    padding-block: 28px;
    border-bottom: 1px solid var(--rule);
  }
  .day-step .step-shot {
    display: block;
    margin-top: 24px;
    width: 220px;
  }
  .focus-phones {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .modules {
    grid-template-columns: 1fr 1fr;
  }
  .steps {
    grid-template-columns: 1fr 1fr;
  }
  .demo-grid {
    grid-template-columns: 1fr;
    margin-left: 0;
  }
  .foot-grid {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 640px) {
  .wrap {
    padding-inline: 16px;
  }
  body {
    font-size: 16px;
  }
  .hero h1 {
    font-size: 44px;
  }
  .hero-shot .frame .bar {
    height: 24px;
  }
  .hero-shot .frame .bar span {
    display: none;
  }
  .surfaces {
    grid-template-columns: 1fr;
  }
  .surfaces li,
  .surfaces li + li {
    padding: 16px 0;
    border-left: 0;
    border-bottom: 1px solid var(--rule);
  }
  .compare .row,
  .compare .row.th {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .compare .row.th {
    display: none;
  }
  .compare .old::before {
    content: "Today: ";
  }
  .compare .new::before {
    content: "With Kaksho: ";
    font-weight: 600;
  }
  .tour-tabs {
    grid-template-columns: 1fr 1fr;
  }
  .tour-tab,
  .tour-tab + .tour-tab {
    padding: 14px 12px 14px 0;
  }
  .tour-tab + .tour-tab .progress {
    left: 0;
  }
  .tour-tab h3 {
    font-size: 15px;
  }
  .tour-stage {
    aspect-ratio: 1 / 1.1;
  }
  .tour-panel {
    padding: 16px;
    gap: 16px;
  }
  .tour-panel .phone {
    width: 46%;
  }
  .cols4,
  .modules,
  .steps,
  .fees-pics,
  .fields,
  .form-actions,
  .foot-grid {
    grid-template-columns: 1fr;
  }
  .cols4 > div,
  .cols4 > div + div {
    padding: 20px 0;
    border-left: 0;
    border-bottom: 1px solid var(--night-rule);
  }
  .form {
    padding: 22px 18px;
  }
  .faq .a p {
    padding-right: 0;
  }
}

/* ---------- Phones: readable screenshots, swipeable rows, bigger tap targets ---------- */
.mbar,
.swipe-hint {
  display: none;
}
.more {
  padding-block: 12px;
}
.seg button {
  padding: 13px 18px;
}
@media (max-width: 900px) {
  .brand {
    padding-block: 8px;
  }
  .foot-grid ul {
    gap: 0;
  }
  .foot-grid ul a {
    display: inline-block;
    padding-block: 9px;
  }
  /* Rows of cards you swipe through, instead of one very long column. */
  [data-carousel] {
    display: flex !important;
    gap: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    margin-inline: -20px;
    padding: 4px 20px 8px;
    scroll-padding-inline: 20px;
  }
  [data-carousel]::-webkit-scrollbar {
    display: none;
  }
  [data-carousel] > * {
    flex: 0 0 82%;
    scroll-snap-align: start;
  }
  .day-steps {
    padding-block: 4px 8px;
    margin-top: 28px;
  }
  .day-step {
    padding: 22px 20px 24px;
    border: 1px solid var(--rule);
    border-radius: 14px;
    background: var(--white);
    justify-content: flex-start;
  }
  .day-step h3 {
    font-size: 25px;
  }
  .day-step p {
    font-size: 15.5px;
  }
  .day-step .step-shot {
    width: 200px;
    margin: 22px auto 0;
  }
  .focus-phones {
    margin-top: 48px;
  }
  .focus-phones > figure {
    flex-basis: 72%;
  }
  .focus-phones .phone {
    width: 100%;
  }
  .swipe-hint {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
    font: 500 13px/1.3 var(--sans);
    color: var(--muted);
  }
  .swipe-hint b {
    font-weight: 500;
    color: var(--ink);
    font-variant-numeric: tabular-nums;
  }
  .night .swipe-hint {
    color: var(--night-muted);
  }
  .night .swipe-hint b {
    color: #fff;
  }
  .teach-pics .phone {
    margin-inline: auto;
  }
  /* The demo bar along the bottom, once the hero's own buttons have scrolled away. */
  .mbar {
    display: flex;
    gap: 10px;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
    background: rgba(251, 250, 247, 0.96);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--rule);
    transform: translateY(110%);
    transition: transform 0.35s var(--ease);
  }
  .mbar.show {
    transform: none;
  }
  .mbar .btn {
    flex: 1;
    height: 48px;
  }
  .mbar .wa {
    flex: 0 0 48px;
    padding: 0;
  }
  .site-footer {
    padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px));
  }
}
@media (max-width: 640px) {
  section {
    padding-block: 64px;
  }
  .sh h2 {
    font-size: 31px;
  }
  .sh .lede {
    font-size: 17px;
  }
  .spot,
  .tour,
  .modules,
  .steps,
  .demo-grid {
    margin-top: 32px;
  }
  .results-row {
    margin-top: 56px;
  }
  .teach-pics {
    margin-top: 32px;
  }
  .focus-phones,
  .cols4 {
    margin-top: 40px;
  }
  /* Computer screenshots: shown large enough to read, swiped sideways inside their frame. */
  .frame.wide .shot {
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }
  .frame.wide .shot::-webkit-scrollbar {
    display: none;
  }
  .frame.wide .shot img {
    width: var(--zoom-w, 760px);
    max-width: none;
  }
  /* The tour shows one screen at a time at its natural height. */
  .tour-stage {
    aspect-ratio: auto;
    background: none;
    border-radius: 0;
    overflow: visible;
    margin-top: 14px;
  }
  .tour-panel {
    position: static;
    display: none;
    padding: 0;
    opacity: 1;
    transform: none;
  }
  .tour-panel.on {
    display: flex;
  }
  .tour-panel:not(#tp-3) {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  #tp-3 {
    padding: 20px 12px;
    border-radius: 14px;
    background: var(--sand);
  }
  .tour-tab h3 {
    font-size: 15px;
  }
  [data-carousel] {
    margin-inline: -16px;
    padding-inline: 16px;
    scroll-padding-inline: 16px;
  }
}
/* Grid and flex children may shrink below their content (the wide screenshots scroll inside their frame instead). */
.hero-grid > *,
.spot > *,
.results-row > *,
.teach-pics > *,
.demo-grid > *,
.fees-pics > *,
.sh > *,
.tour-panel > *,
figure {
  min-width: 0;
}
