/* Nizam. Direction: the split stage. Rokkitt + Cairo / Literata + Readex Pro. Slate, sage, blush, olive. */
:root {
  --bg: #a6b3bc;
  --surface: #b2bdc5;
  --paper: #e6dcd2;
  --ink: #1c1c1c;
  --muted: #38424a;
  --accent: #2c3620;
  --accent-ink: #e3e2da;
  --field-1: #a6b3bc;
  --field-2: #b7c8be;
  --field-3: #d6c4b8;
  --field-4: #2c3620;
  --field-4-ink: #e3e2da;

  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.0625rem, 1rem + 0.2vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.5vw, 1.5rem);
  --step-head: clamp(2.1rem, 1.35rem + 2.3vw, 3.4rem);
  --step-display: clamp(2.75rem, 0.8rem + 4.1vw, 4.75rem);

  --margin: 12px;
  --pad: clamp(24px, 3vw, 42px);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --display: 'Rokkitt', 'Cairo', 'Arial Narrow', Impact, sans-serif;
  --text: 'Literata', 'Readex Pro', Georgia, 'Times New Roman', serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--accent);
  color: var(--ink);
  font-family: var(--text);
  font-size: var(--step-body);
  line-height: 1.65;
  text-align: right;
  text-wrap: pretty;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
::selection { background: var(--accent); color: var(--accent-ink); }

h1, h2, h3, .display, .wordmark, .plan-name, .plan-price, .foot-menu {
  font-family: var(--display);
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.12;
  text-wrap: balance;
}

/* ---------- the split ---------- */
.split {
  display: grid;
  grid-template-columns: 55fr 45fr;
  gap: var(--margin);
  padding: var(--margin);
  align-items: start;
}

/* the fixed half */
.stage {
  position: sticky;
  top: var(--margin);
  height: calc(100svh - 2 * var(--margin));
  background: var(--bg);
  overflow: hidden;
}
.stage-canvas { position: absolute; inset: 0 0 270px 0; direction: ltr; }
.stage-canvas canvas { display: block; }
.spots { position: absolute; inset: 0 0 270px 0; pointer-events: none; direction: ltr; }
.spot {
  position: absolute;
  left: 0; right: auto; top: 0;
  width: 44px; height: 44px;
  margin: -22px 0 0 -22px;
  padding: 0;
  border: 0;
  background: transparent;
  pointer-events: auto;
}
.spot::before {
  content: '';
  position: absolute;
  inset: 18px;
  background: var(--accent);
  opacity: 0.42;
  transition: transform 0.25s var(--ease), background-color 0.25s, opacity 0.25s;
}
.spot:hover::before { transform: scale(2); opacity: 1; }
.spot[aria-pressed='true']::before { background: var(--ink); transform: scale(2.4); opacity: 1; }
.spot[hidden] { display: none; }

.stage-fallback { display: none; position: absolute; inset: 24px; font-size: var(--step-body); }
.no-webgl .stage-fallback { display: block; }

.stage-panel {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 270px;
  padding: 16px 28px 20px;
  display: grid;
  grid-template-rows: 1fr auto auto;
  gap: 12px;
  background: var(--surface);
}
.stage-info { font-size: var(--step-body); line-height: 1.45; color: var(--ink); overflow: hidden; }
[data-info][data-mode='before'] .stage-line:nth-of-type(3) { display: none; }
[data-info][data-mode='after'] .stage-line:nth-of-type(2) { display: none; }
.moments { display: flex; gap: 8px; flex-wrap: wrap; }
.moments button { min-height: 44px; padding: 0 18px; border: 0; background: var(--field-3); color: var(--ink); font-size: var(--step-body); transition: background-color 0.2s, color 0.2s, transform 0.15s var(--ease); font-variant-numeric: tabular-nums; direction: ltr; }
.moments button:hover { background: var(--ink); color: var(--accent-ink); }
.moments button[aria-pressed='true'] { background: var(--accent); color: var(--accent-ink); }
.moments button:active { transform: translateY(2px); }
.stage-name { font-family: var(--display); font-weight: 800; font-size: var(--step-lead); line-height: 1.2; margin-bottom: 6px; }
.stage-line { max-width: 56ch; }
.stage-controls { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }

.mode { display: flex; gap: 8px; }
.cell {
  min-height: 48px;
  padding: 0 24px;
  border: 0;
  background: var(--field-1);
  color: var(--ink);
  font-size: var(--step-body);
  transition: background-color 0.2s, color 0.2s, transform 0.15s var(--ease);
}
.mode .cell { background: var(--field-3); }
.cell[aria-pressed='true'] { background: var(--accent); color: var(--accent-ink); }
.cell:hover { background: var(--ink); color: var(--accent-ink); }
.cell:active { transform: translateY(2px); }

.tabs { display: flex; gap: 20px; }
.tabs button {
  border: 0; background: none; padding: 12px 0;
  font-size: var(--step-body);
  color: var(--muted);
}
.tabs button[aria-pressed='true'] { color: var(--ink); font-weight: 600; }
.tabs button:hover { color: var(--ink); }

/* the reading half */
.col { background: var(--paper); min-width: 0; }
.pad { padding: 0 var(--pad); }
.col > section { position: relative; }

.hero { min-height: calc(100svh - 2 * var(--margin)); display: flex; flex-direction: column; }
.bars { display: flex; height: 56px; flex: 0 0 56px; overflow: hidden; }
.bars span { flex: 0 0 28px; background: var(--ink); transition: background-color 0.5s, transform 0.5s var(--ease); }
.bars span:nth-child(even) { background: var(--paper); }
.bars span:nth-child(even) { transform: scaleY(1); }
.after .bars span:nth-child(3n) { background: var(--accent); }
.hero-body { padding: 24px var(--pad) 48px; flex: 1; display: flex; flex-direction: column; gap: 24px; }
.nav { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: clamp(24px, 6vh, 72px); }
.wordmark { font-size: var(--step-lead); text-decoration: none; display: inline-flex; align-items: center; gap: 10px; }
.mark { height: 30px; width: auto; flex: none; object-fit: contain; }
.nav nav { display: flex; gap: 20px; flex-wrap: wrap; font-size: var(--step-body); }
.nav nav a { text-decoration: none; padding: 8px 0; }
.nav nav a:hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; }

.display { font-size: var(--step-display); }
.lead { font-size: var(--step-lead); line-height: 1.45; max-width: 36ch; }
.body { max-width: 48ch; }
.actions { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; margin-top: 8px; }
.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 56px; padding: 0 36px;
  background: var(--accent); color: var(--accent-ink);
  text-decoration: none; font-size: var(--step-body);
  transition: background-color 0.2s, transform 0.15s var(--ease);
}
.button:hover { background: var(--ink); }
.button:active { transform: translateY(2px); }
.link { text-underline-offset: 6px; text-decoration-thickness: 2px; }
.link:hover { text-decoration-thickness: 4px; }

h2 { font-size: var(--step-head); margin-bottom: 20px; }

/* a day */
.day { padding: clamp(80px, 12vh, 160px) 0 0; }
.day .pad { margin-bottom: 48px; }
.moment { min-height: 68svh; padding: var(--pad); display: flex; flex-direction: column; gap: 16px; justify-content: center; cursor: pointer; }
.moment:nth-child(1) { background: var(--field-2); }
.moment:nth-child(2) { background: transparent; }
.moment:nth-child(3) { background: var(--field-1); }
.moment:nth-child(4) { background: transparent; }
.moment:nth-child(5) { background: var(--field-4); color: var(--field-4-ink); }
.m-time { font-family: var(--display); font-weight: 800; font-size: var(--step-display); line-height: 1; font-variant-numeric: tabular-nums; direction: ltr; align-self: flex-start; }
.moment h3 { font-size: var(--step-head); }
.moment p { max-width: 44ch; }
.moment .count { display: block; margin-top: 4px; font-size: var(--step-small); font-weight: 600; }

/* devices */
.devices { padding: clamp(80px, 12vh, 160px) 0 0; }
.rows { margin-top: 48px; }
.rows button {
  display: block; width: 100%; text-align: right;
  border: 0; background: transparent;
  padding: 24px var(--pad);
  transition: background-color 0.2s, transform 0.2s var(--ease);
}
.rows button:hover { background: var(--field-2); }
.rows button[aria-pressed='true'], .rows button.on { background: var(--accent); color: var(--accent-ink); }
.rname { display: block; font-family: var(--display); font-weight: 800; font-size: var(--step-lead); line-height: 1.2; margin-bottom: 10px; }
.rline { display: block; max-width: 48ch; font-size: var(--step-body); }
.rline + .rline { margin-top: 6px; }
.plate { margin: 12px 0 0; padding: 0 var(--pad) 12px; display: grid; gap: 10px; }
.plate img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.plate figcaption { font-size: var(--step-small); color: var(--muted); }
.devices { padding-bottom: 80px; }

/* packages: three fields in the column */
.packages { padding-top: clamp(40px, 8vh, 96px); }
.packages .pad { margin-bottom: 48px; }
.plan {
  min-height: 82svh;
  padding: var(--pad);
  display: grid;
  grid-template-rows: auto auto auto 1fr auto auto;
  gap: 20px;
}
.plan-1 { background: var(--field-2); }
.plan-2 { background: transparent; min-height: 92svh; }
.plan-3 { background: var(--field-4); color: var(--field-4-ink); }
.plan-name { font-size: var(--step-head); }
.plan-for { font-size: var(--step-lead); line-height: 1.4; max-width: 32ch; }
.plan-has { max-width: 42ch; }
.plan-price { display: flex; align-items: baseline; gap: 12px; align-self: end; font-size: var(--step-display); font-variant-numeric: tabular-nums; }
.plan-price .cur { font-size: var(--step-body); letter-spacing: 0; }
.plan .button { justify-self: start; }
.plan-3 .button { background: var(--field-4-ink); color: var(--accent); }
.plan-3 .button:hover { background: var(--field-3); }
.plan.is-current { outline: 0; }

/* process: the slip */
.process { padding: clamp(80px, 12vh, 160px) 0; background: var(--field-1); }
.process-head { margin-bottom: 48px; }
.slip {
  width: min(480px, calc(100% - 2 * var(--pad)));
  margin: 0 var(--pad) 0 auto;
  padding: 32px 28px 56px;
  background: var(--paper);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 14px), 96% 100%, 92% calc(100% - 14px), 88% 100%, 84% calc(100% - 14px), 80% 100%, 76% calc(100% - 14px), 72% 100%, 68% calc(100% - 14px), 64% 100%, 60% calc(100% - 14px), 56% 100%, 52% calc(100% - 14px), 48% 100%, 44% calc(100% - 14px), 40% 100%, 36% calc(100% - 14px), 32% 100%, 28% calc(100% - 14px), 24% 100%, 20% calc(100% - 14px), 16% 100%, 12% calc(100% - 14px), 8% 100%, 4% calc(100% - 14px), 0 100%);
  font-size: var(--step-body);
  font-variant-numeric: tabular-nums;
}
.slip h3 { font-size: var(--step-lead); margin: 28px 0 10px; }
.slip h3:first-child { margin-top: 0; }
.slip li { display: flex; align-items: baseline; gap: 8px; padding: 5px 0; }
.slip li i { flex: 1; align-self: flex-end; margin-bottom: 7px; height: 4px; min-width: 16px; background-image: none; border-bottom: 4px dotted var(--muted); }
.slip li span:last-child { white-space: nowrap; }
.slip-end { margin: 32px -28px 0; padding: 12px 28px; background: var(--ink); color: var(--accent-ink); font-weight: 600; }

/* products: breaks the split */
.products { background: var(--field-1); padding: clamp(80px, 12vh, 160px) var(--margin); display: grid; grid-template-columns: 4fr 8fr; gap: var(--pad); }
.products-head { padding-inline-start: var(--pad); }
.products-head h2 { margin-bottom: 24px; }
.products-body { padding-inline-end: var(--pad); min-width: 0; }
.ptabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.ptabs button { min-height: 48px; padding: 0 22px; border: 0; background: var(--field-3); color: var(--ink); font-size: var(--step-body); transition: background-color 0.2s, color 0.2s, transform 0.15s var(--ease); }
.ptabs button:hover { background: var(--ink); color: var(--accent-ink); }
.ptabs button[aria-pressed='true'] { background: var(--accent); color: var(--accent-ink); }
.ptabs button:active { transform: translateY(2px); }
.ptable { width: 100%; border-collapse: collapse; font-size: var(--step-body); line-height: 1.5; }
.ptable[hidden] { display: none; }
.ptable thead th { text-align: right; font-weight: 600; padding: 0 12px 12px; font-size: var(--step-small); }
.ptable th, .ptable td { padding: 14px 12px; vertical-align: top; text-align: right; }
.ptable tbody tr:nth-child(odd) { background: var(--field-2); }
.ptable tbody tr:nth-child(even) { background: var(--surface); }
.ptable tbody th { font-weight: 600; width: 32%; }
.ptable .num { text-align: left; white-space: nowrap; font-variant-numeric: tabular-nums; direction: ltr; }
.products .products-note { grid-column: 2; padding-inline-end: var(--pad); margin-top: 0; max-width: none; }

/* questions: breaks the split */
.faq { background: var(--field-3); padding: clamp(80px, 12vh, 160px) var(--margin); display: grid; grid-template-columns: 4fr 8fr; gap: var(--pad); }
.faq h2 { margin: 0 0 32px; padding-inline-start: var(--pad); }
.faq-clip { margin: 0 var(--pad) 0 0; display: grid; gap: 10px; max-width: 420px; }
.faq-clip video { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; background: var(--field-2); }
.faq-clip figcaption { font-size: var(--step-small); }
.faq-text { columns: 2; column-gap: 56px; padding-inline-end: var(--pad); font-size: var(--step-body); line-height: 1.6; }
.faq-text p { break-inside: avoid; margin-bottom: 20px; }
.faq-text strong { font-weight: 600; }

/* contact */
.contact { background: var(--field-2); min-height: 80svh; padding: 48px var(--margin) clamp(64px, 10vh, 120px); overflow: hidden; }
.strip { overflow: hidden; padding: 0 var(--pad); }
.strip-track { display: flex; gap: 8px; width: 100%; }
.strip-track img { height: 150px; flex: 1 1 0; min-width: 0; object-fit: cover; transition: transform 6s var(--ease); }
.contact:hover .strip-track img:nth-child(odd) { transform: scale(1.04); }
.contact-head { margin: 72px var(--pad) 40px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; align-items: end; }
.contact h2 { margin: 0; }
.contact-head .body { grid-column: 2 / span 2; padding-inline-start: 8px; }
.bar { margin: 0 var(--pad); display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.bar .cell { min-height: 96px; font-size: var(--step-body); background: var(--field-3); }
.bar .field { display: block; padding: 0; }
.bar .field input { width: 100%; height: 96px; border: 0; background: transparent; text-align: center; font-size: var(--step-body); }
.bar .field input::placeholder { color: var(--muted); opacity: 1; }
.bar .field:focus-within { background: var(--paper); }
.bar .field input:focus-visible { outline: none; }
.bar .submit { background: var(--accent); color: var(--accent-ink); }
.bar .submit:hover { background: var(--ink); }
.small { grid-column: 1 / span 2; font-size: var(--step-small); margin-top: 8px; max-width: 60ch; }

/* footer */
.foot { display: grid; grid-template-columns: 6fr 6fr; min-height: 100svh; background: var(--field-4); color: var(--field-4-ink); }
.foot-photo { position: relative; overflow: hidden; }
.foot-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; transition: transform 8s var(--ease); }
.foot-photo:hover img { transform: scale(1.04); }
.foot-body { padding: 40px 8vw 32px var(--pad); display: flex; flex-direction: column; gap: 48px; }
.foot .wordmark { align-self: flex-start; }
.foot-menu { font-size: var(--step-head); display: grid; gap: 20px; line-height: 1.1; }
.foot-menu a { text-decoration: none; display: inline-block; transition: transform 0.25s var(--ease), color 0.2s; }
.foot-menu:hover a { color: #9aa58c; }
.foot-menu a:hover { color: var(--field-4-ink); transform: translateX(-12px); }
.foot-info { display: flex; gap: 48px; flex-wrap: wrap; font-size: var(--step-small); line-height: 1.5; }
.foot-info p { max-width: 28ch; }
.legal { margin-top: auto; font-size: var(--step-small); line-height: 1.5; max-width: 62ch; color: #c4cab8; }

/* entrance: staggered rise, once, never hidden without script */
.js [data-in] { opacity: 0; transform: translateY(24px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); transition-delay: calc(var(--i, 0) * 70ms); }
.js [data-in].in { opacity: 1; transform: none; }

/* phone: the apartment is pinned behind the text, then released as the text covers it */
@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; gap: 0; padding: 0 var(--margin) var(--margin); }
  .stage { top: 0; height: 58svh; z-index: 0; }
  .stage-canvas, .spots { inset: 0 0 198px 0; }
  .spot { width: 36px; height: 36px; margin: -18px 0 0 -18px; }
  .spot::before { inset: 14px; }
  .stage-panel { height: 198px; padding: 10px 14px 10px; gap: 6px; }
  .moments { gap: 6px; flex-wrap: nowrap; }
  .moments button { min-height: 38px; padding: 0 10px; font-size: 0.9375rem; flex: 1 1 0; }
  .moment { min-height: 56svh; }
  .stage-name { font-size: var(--step-body); margin-bottom: 3px; }
  .stage-info { font-size: var(--step-small); line-height: 1.35; }
  .stage-controls { gap: 8px; flex-wrap: nowrap; }
  .cell { min-height: 38px; padding: 0 10px; font-size: 0.875rem; }
  .tabs { gap: 10px; }
  .tabs button { font-size: 0.875rem; padding: 6px 0; }
  .col { position: relative; z-index: 1; margin-top: 0; }
  .hero { min-height: 0; }
  .nav { margin-bottom: 8px; flex-wrap: wrap; row-gap: 4px; }
  .nav nav { gap: 4px 12px; font-size: var(--step-small); line-height: 1.25; flex-basis: 100%; }
  .nav nav a { padding: 2px 0; }
  .bars { height: 28px; flex-basis: 28px; }
  .hero-body { padding: 12px 20px 36px; gap: 14px; }
  .display { max-width: none; }
  .plan { min-height: 70svh; }
  .slip { width: calc(100% - 2 * var(--pad)); max-width: 620px; }
  .products { grid-template-columns: 1fr; padding: 80px var(--margin); }
  .products-head, .products-body, .products .products-note { padding: 0 var(--pad); grid-column: 1; }
  .faq { grid-template-columns: 1fr; padding: 80px var(--margin); }
  .faq-clip { margin: 0 var(--pad); }
  .faq-text { columns: 1; padding: 0 var(--pad); }
  .contact-head { grid-template-columns: 1fr; gap: 16px; }
  .contact-head .body { grid-column: 1; padding: 0; }
  .bar { grid-template-columns: 1fr; }
  .bar .cell, .bar .field input { min-height: 60px; height: 60px; }
  .small { grid-column: 1; }
  .strip-track img { height: 110px; }
  .foot { grid-template-columns: 1fr; }
  .foot-photo { height: 50svh; }
  .foot-body { padding: 32px var(--pad) 32px; gap: 32px; }
  .foot-menu { font-size: 8vw; gap: 20px; }
}

@media (max-width: 600px) {
  .strip-track img:nth-child(n+5) { display: none; }
  .ptable thead { display: none; }
  .ptable, .ptable tbody { display: block; width: 100%; }
  .ptable tr { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 12px 14px; }
  .ptable tbody th { width: auto; padding: 0; }
  .ptable td { padding: 0; grid-column: 1 / -1; }
  .ptable td.num { grid-column: 2; grid-row: 1; text-align: left; font-weight: 600; padding: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .strip-track { animation: none; }
  .js [data-in] { opacity: 1; transform: none; transition: none; }
  * { transition-duration: 0.01ms !important; }
}
