:root {
  --page-safe-top: env(safe-area-inset-top, 0px);
  --page-safe-right: env(safe-area-inset-right, 0px);
  --page-safe-bottom: env(safe-area-inset-bottom, 0px);
  --page-safe-left: env(safe-area-inset-left, 0px);
  color-scheme: light dark;
  --bg: #f7f7f5;
  --fg: #202022;
  --muted: #626268;
  --line: #d6d6d8;
  --soft: #e8e8e8;
  --button: #242426;
  --button-fg: #fff;
  --focus: #0063ca;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #141415;
  --fg: #f1f1f3;
  --muted: #a4a4ac;
  --line: #37373b;
  --soft: #28282b;
  --button: #f1f1f3;
  --button-fg: #19191b;
  --focus: #84baff;
}
:root[data-theme="light"] {
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root[data-theme="system"] {
    --bg: #141415;
    --fg: #f1f1f3;
    --muted: #a4a4ac;
    --line: #37373b;
    --soft: #28282b;
    --button: #f1f1f3;
    --button-fg: #19191b;
    --focus: #84baff;
  }
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
}
body {
  margin: 0;
  /* Cover mode fills the display; keep landing controls inside its safe area.
     Fixed demo/dialog surfaces apply their own viewport insets. */
  padding: var(--page-safe-top) var(--page-safe-right) var(--page-safe-bottom) var(--page-safe-left);
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}
button,
select,
input {
  font: inherit;
}
button,
a,
select,
input {
  touch-action: manipulation;
}
button,
a {
  color: inherit;
}
a {
  text-decoration: none;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: default;
}
button,
select {
  border: 0;
  background: none;
}
a:focus-visible,
button:focus-visible,
select:focus-visible,
summary:focus-visible,
input:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 5px;
}
a[aria-disabled="true"] {
  pointer-events: none;
  opacity: 0.5;
}
button:hover,
.text-link:hover {
  opacity: 0.75;
}
.sr-only,
.skip {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip:focus {
  width: auto;
  height: auto;
  margin: 12px;
  padding: 8px;
  clip-path: none;
  background: var(--bg);
  z-index: 2;
}
.site-header {
  max-width: 1104px;
  margin: auto;
  padding: 28px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.brand {
  font-weight: 700;
  font-size: 21px;
  letter-spacing: -0.6px;
}
.brand span {
  font-size: 13px;
  font-weight: 400;
  color: var(--muted);
  margin-left: 10px;
  letter-spacing: 0;
}
.preferences {
  display: flex;
  gap: 8px;
}
.preferences select {
  max-width: 105px;
  font-size: 13px;
  color: var(--muted);
  min-height: 44px;
  padding: 6px;
  cursor: pointer;
}
.intro {
  text-align: center;
  margin: 40px auto 36px;
  padding: 0 24px;
  max-width: 800px;
}
.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 0 0 12px;
}
h1 {
  white-space: pre-line;
  font-size: clamp(36px, 5.8vw, 68px);
  line-height: 1.13;
  letter-spacing: -0.055em;
  font-weight: 650;
  margin: 0;
  text-wrap: balance;
}
.subtitle {
  font-size: 18px;
  color: var(--muted);
  margin: 20px 0 26px;
  text-wrap: balance;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 26px;
}
.primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  background: var(--button);
  color: var(--button-fg);
  border-radius: 9px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
}
.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 5px;
}
.demo {
  max-width: 744px;
  padding: 0 12px;
  margin: 0 auto;
}
.demo-note {
  text-align: center;
  font-size: 11px;
  color: var(--muted);
  margin: 12px 0 0;
}
.download {
  max-width: 800px;
  margin: 100px auto 0;
  padding-top: 40px;
  border-top: 1px solid var(--line);
}
.download-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.download-heading .eyebrow {
  margin-bottom: 8px;
}
h2 {
  font-size: 30px;
  line-height: 1.2;
  letter-spacing: -0.035em;
  font-weight: 600;
  margin: 0;
}
.requirements,
.small {
  font-size: 12px;
  color: var(--muted);
  margin: 12px 0;
}
.download-status {
  font-size: 13px;
  color: var(--muted);
  margin: 8px 0;
}
.download-status:empty {
  display: none;
}
.pricing {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 13px;
  margin-top: 28px;
}
.pricing strong {
  font-size: 23px;
  letter-spacing: -0.03em;
  font-weight: 600;
  margin-right: 8px;
}
.limits {
  margin-bottom: 28px;
}
.details-list {
  border-top: 1px solid var(--line);
}
details {
  border-bottom: 1px solid var(--line);
}
summary {
  cursor: pointer;
  list-style: none;
  font-size: 13px;
  padding: 17px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
summary::-webkit-details-marker {
  display: none;
}
summary::after {
  content: "+";
  font-size: 18px;
  color: var(--muted);
}
details[open] summary::after {
  content: "−";
}
.detail-body {
  font-size: 13px;
  color: var(--muted);
  padding: 0 0 24px;
  max-width: 690px;
}
.detail-body p {
  margin: 0 0 16px;
}
.detail-body pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 11px;
  line-height: 1.8;
  padding: 16px;
  background: var(--soft);
  border-radius: 6px;
  color: var(--fg);
}
.detail-body code {
  font-size: 11px;
  overflow-wrap: anywhere;
  display: block;
  margin-bottom: 16px;
}
.detail-body button {
  min-width: 44px;
  min-height: 44px;
  color: var(--fg);
  text-decoration: underline;
  font-size: 13px;
  padding: 4px 0;
}
footer {
  max-width: 1104px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin: 80px auto 0;
  padding: 24px 32px 36px;
  font-size: 11px;
  color: var(--muted);
}
@media (max-width: 850px) {
  .download {
    margin: 70px 24px 0;
  }
  .demo {
    margin: 0 12px;
    padding: 0;
  }
  .app-surface img {
    filter: drop-shadow(0 10px 16px #00000010);
  }
}
@media (max-width: 540px) {
  .site-header {
    padding: 20px;
  }
  .brand span {
    display: none;
  }
  .preferences {
    gap: 0;
  }
  .preferences select {
    max-width: 94px;
    font-size: 16px;
  }
  .intro {
    margin: 44px auto 32px;
    padding: 0 22px;
  }
  .subtitle {
    font-size: 16px;
  }
  .hero-actions {
    gap: 12px 20px;
  }
  .demo-note {
    font-size: 10px;
    margin-top: 8px;
  }
  .download-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 20px;
  }
  .download-heading .primary {
    width: 100%;
    white-space: normal;
    text-align: center;
  }
  h2 {
    font-size: 28px;
  }
  .pricing {
    flex-direction: column;
    gap: 6px;
  }
  .requirements,
  .small {
    font-size: 12px;
  }
  footer {
    padding: 24px;
    flex-direction: column;
    gap: 4px;
    margin-top: 40px;
  }
}
@media (max-width: 380px) {
  .site-header {
    flex-wrap: wrap;
    gap: 8px;
    padding: 16px 20px;
  }
  .preferences {
    margin-left: auto;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation: none !important;
    transition: none !important;
  }
}

/* Two aligned views, an original native app PNG, and one draggable seam. */
.comparison-section {
  max-width: 800px;
  margin: 78px auto 0;
}
.comparison-section h2 {
  font-size: 26px;
  text-align: center;
  margin: 0 0 24px;
}
.comparison-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted);
  margin: 0 4px 12px;
}
.comparison {
  position: relative;
  aspect-ratio: 8/5;
  overflow: hidden;
  border-radius: 12px;
  background: #e4e4e5;
  touch-action: pan-y;
  cursor: ew-resize;
  user-select: none;
  -webkit-user-select: none;
}
.comparison:focus-within {
  outline: 3px solid var(--focus);
  outline-offset: 5px;
}
.comparison-scene,
.comparison-before {
  position: absolute;
  inset: 0;
}
.comparison-before {
  clip-path: inset(0 calc(100% - var(--reveal)) 0 0);
  pointer-events: none;
}
.comparison-before img {
  position: absolute;
  left: 9%;
  top: 7%;
  width: 62%;
  height: auto;
  display: block;
  filter: drop-shadow(0 8px 12px #00000024);
}
.sample-question {
  position: absolute;
  inset: 12% 7% 10%;
  background: #fafafa;
  color: #242426;
  border-radius: 8px;
  padding: 6% 7%;
  font-size: clamp(11px, 1.5vw, 16px);
}
.sample-eyebrow {
  font-size: 0.72em;
  color: #626268;
}
.sample-question h3 {
  font-size: 1.5em;
  font-weight: 600;
  margin: 16px 0 10px;
  letter-spacing: -0.03em;
}
.sample-question p {
  margin: 0 0 22px;
  color: #626268;
}
.sample-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 0.88em;
  font-variant-numeric: tabular-nums;
}
.comparison-seam {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--reveal);
  width: 2px;
  transform: translateX(-1px);
  background: #242426;
  pointer-events: none;
}
.comparison-seam span {
  position: absolute;
  left: 1px;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #242426;
  color: white;
  box-shadow: 0 2px 8px #0003;
}
@media (prefers-color-scheme: dark) {
  :root[data-theme="system"] .comparison {
    background: #303033;
  }
}
:root[data-theme="dark"] .comparison {
  background: #303033;
}
@media (max-width: 850px) {
  .comparison-section {
    margin: 60px 24px 0;
  }
}
@media (max-width: 540px) {
  .comparison-section h2 {
    font-size: 23px;
  }
  .sample-question h3 {
    margin: 8px 0;
  }
  .sample-question p {
    margin-bottom: 12px;
  }
  .sample-options {
    gap: 8px;
  }
  .comparison-seam span {
    width: 44px;
    height: 44px;
  }
  .comparison-section .demo-note {
    font-size: 10px;
  }
}
/* Keep the source question below the app's answer card in the sample scene. */
.sample-question h3 {
  margin-top: 48px;
}
@media (max-width: 540px) {
  .comparison {
    aspect-ratio: 8/6;
  }
  .sample-question {
    padding: 4% 7%;
  }
  .sample-question h3 {
    font-size: 1.2em;
    margin-top: 24px;
  }
}

/* Context is outside the original native app image. No explanatory outer card. */

/* Comparison scene: one shared scene under the clipped native app image. */
.comparison-section { max-width: 960px; }
.coding-scene { position:absolute; inset:0; background:#f6f7f9; color:#252a31; font: 14px/1.5 -apple-system,BlinkMacSystemFont,sans-serif; }
.coding-bar { height:46px; padding:12px 20px; background:#fff; border-bottom:1px solid #dce0e5; display:flex; justify-content:space-between; }
.coding-bar span,.coding-label { color:#606b78; font-size:12px; }
.coding-columns { display:grid; grid-template-columns: 1fr 1fr; height:calc(100% - 46px); }
.coding-problem,.coding-editor { padding:24px; min-width:0; }
.coding-problem { overflow:hidden; border-right:1px solid #dce0e5; background:#fff; }
.coding-problem h3 { font-size:22px; margin:6px 0 12px; }
.coding-problem p { margin:8px 0 18px; }
.coding-scene pre { white-space:pre-wrap; font:12px/1.6 ui-monospace,monospace; }
.coding-problem pre { padding:10px; background:#f3f5f7; border-radius:5px; }
.coding-editor { padding:0; background:#f8f9fb; }
.coding-tab { padding:12px 18px; border-bottom:1px solid #dce0e5; font:12px ui-monospace,monospace; }
.coding-editor > pre { padding:8px 18px; min-height:135px; }
.coding-editor pre span { color:#8793a1; margin-right:14px; }
.coding-cases { border-top:1px solid #dce0e5; padding:14px 18px; font-size:12px; }
.coding-cases p { margin:8px 0; }
.comparison-before img { left:15%; top:8%; width:56%; }
@media(max-width:850px) {
  .comparison { aspect-ratio: auto; }
  .comparison-scene, .coding-scene { position: relative; }
  .coding-columns { height:auto; grid-template-columns: 1fr; grid-template-rows: auto auto; }
  .comparison-before img { left:2%; top:8%; width:min(96%, 460px); }
}
@media(max-width:540px) {
  .coding-scene { font-size:13px; }
  .coding-problem { padding:14px; border:0; border-bottom:1px solid #dce0e5; }
  .coding-problem h3 { font-size:18px; margin:2px 0 5px; }
  .coding-problem p { margin:4px 0 8px; }
  .coding-problem pre { margin:4px 0; padding:5px; }
  .coding-editor > pre { min-height:70px; margin:0; padding:5px 14px; }
  .coding-tab,.coding-cases { padding:6px 14px; }
  .coding-cases p { margin:3px 0; }
}
