/* Tripii's landing tokens (softdev-engineering/tripii, apps/landing-web/src/styles/landing.css),
   aligned with the POS app's own Tripii restyle so the page and the screenshots match. */
@font-face {
  font-family: "Plus Jakarta Sans";
  font-weight: 400;
  font-display: swap;
  src: url(fonts/PlusJakartaSans-Regular.ttf) format("truetype");
}
@font-face {
  font-family: "Plus Jakarta Sans";
  font-weight: 700;
  font-display: swap;
  src: url(fonts/PlusJakartaSans-Bold.ttf) format("truetype");
}

:root {
  --paper: #faf8f3;
  --surface: #fff;
  --ink: #0f1020;
  --text: #33333e;
  --text-2: #55555f;
  --line: #e6e3dc;
  --line-strong: #d6d1c6;
  --primary: #cb0041;
  --primary-hover: #a00033;
  --primary-tint: #ffe9f0;
  --navy: #1a1a2e;
  --on-navy-2: #c9c9d6;
  --radius: 14px;
  --shadow: 0 24px 60px -28px rgba(15, 16, 32, 0.35);
  --shadow-sm: 0 10px 30px -18px rgba(15, 16, 32, 0.28);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --gutter: 16px;
  --maxw: 1120px;
  color-scheme: light;
  accent-color: var(--primary);
  scrollbar-color: #bdb6a8 var(--paper);
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font: 400 17px/1.6 "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

::selection { background: #ffcfde; color: var(--ink); }

h1, h2, h3 { margin: 0; color: var(--ink); font-weight: 700; text-wrap: balance; }
p { margin: 0; }
img { display: block; max-width: 100%; height: auto; }

a { color: var(--primary); text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { color: var(--primary-hover); }

:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; border-radius: 8px; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }

.skip {
  position: absolute; left: 8px; top: -60px; z-index: 10;
  padding: 10px 16px; border-radius: 10px; background: var(--ink); color: #fff; font-weight: 700;
}
.skip:focus { top: 8px; }
.skip:hover { color: #fff; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 20px; border-radius: 12px;
  font-weight: 700; font-size: 16px; text-decoration: none;
  transition: background-color 0.16s ease, border-color 0.16s ease, transform 0.16s var(--ease-out);
}
.btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); color: #fff; }
.btn-primary:active { transform: translateY(1px); }
.btn-ghost { border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); min-height: 44px; padding: 0 16px; font-size: 15px; }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn-ink { background: var(--ink); color: #fff; font-size: 17px; }
.btn-ink:hover { background: #000; color: #fff; }
.btn-lg { min-height: 58px; padding: 0 28px; font-size: 18px; border-radius: 13px; }

/* Header */
.top { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: inline-flex; align-items: baseline; gap: 6px; padding-block: 5px; color: var(--ink); text-decoration: none; }
.brand:hover { color: var(--ink); }
.brand-name { font-weight: 700; font-size: 21px; letter-spacing: -0.04em; }
.brand-by { font-size: 14px; color: var(--text-2); }

/* Hero. On phones the copy's children join the hero's own grid, so the picture can come before the demo link. */
.hero { padding-top: 20px; padding-bottom: 56px; display: grid; }
.hero-copy { display: contents; }
.hero h1 { font-size: 40px; line-height: 1.04; letter-spacing: -0.04em; }
.accent { color: var(--primary); }
.lead { margin-top: 16px; font-size: 19px; line-height: 1.5; color: var(--text-2); max-width: 30ch; }
.hero-copy .btn-primary { margin-top: 28px; width: 100%; }
.offer { margin-top: 12px; font-size: 15px; font-weight: 700; color: var(--ink); text-align: center; }
.needs { margin-top: 2px; font-size: 15px; color: var(--text-2); text-align: center; }
.demo { order: 2; margin-top: 20px; font-size: 15px; text-align: center; color: var(--text-2); }
.demo a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 700; color: var(--ink); }
.demo a:hover { color: var(--primary); }
.demo span { display: block; font-size: 14px; }

/* The demo: three real screenshots that fade into each other, with the matching step lit. */
.show { order: 1; margin: 32px 0 0; }
.laptop { padding: 7px; border-radius: 14px; background: var(--ink); box-shadow: var(--shadow); }
.screen { position: relative; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 5px; background: var(--paper); }
.frame { position: absolute; inset: 0; display: block; }
.frame img { width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.laptop-base { height: 10px; margin: 7px -14px -7px; border-radius: 0 0 12px 12px; background: #d9d4c9; }

.show figcaption { margin-top: 26px; display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 12px; }
.steps-live { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 16px; font-weight: 700; color: var(--ink); }
.steps-live li { display: flex; align-items: center; gap: 10px; }
.n {
  flex-shrink: 0; display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%;
  background: var(--primary-tint); color: var(--primary); font-size: 14px; font-weight: 700;
}

.pause {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px;
  border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface);
  color: var(--ink); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer;
}
.pause:hover { border-color: var(--ink); }
.pause[hidden] { display: none; }
.pause svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.pause .i-play { display: none; }
.pause[aria-pressed="true"] .i-pause { display: none; }
.pause[aria-pressed="true"] .i-play { display: block; fill: currentColor; }

@media (prefers-reduced-motion: no-preference) {
  .frame { opacity: 0; animation: frame 12s infinite; }
  .frame:nth-child(2) { animation-delay: 4s; }
  .frame:nth-child(3) { animation-delay: 8s; }
  /* The first frame sits under the others, so it can start opaque instead of fading in from blank. */
  .frame:first-child { opacity: 1; animation-name: frame-first; }

  .steps-live li { color: var(--text-2); animation: step 12s infinite; }
  .steps-live li:nth-child(2) { animation-delay: 4s; }
  .steps-live li:nth-child(3) { animation-delay: 8s; }
  .steps-live li .n { animation: step-n 12s infinite; animation-delay: inherit; }

  .show.paused .frame, .show.paused .steps-live li, .show.paused .n { animation-play-state: paused; }
}
@media (prefers-reduced-motion: reduce) {
  /* No motion: show Cobrar with the change, the moment a shopkeeper recognises at once. */
  .frame:not(:nth-child(2)) { display: none; }
  .pause { display: none; }
}

/* Each frame stays opaque until the next one has fully faded in (above it, or below it at the
   loop's wrap), so the page background never shows through a half-faded pair. */
@keyframes frame {
  0% { opacity: 0; transform: scale(1.015); }
  4% { opacity: 1; transform: scale(1); }
  38% { opacity: 1; }
  41% { opacity: 0; }
  100% { opacity: 0; }
}
@keyframes frame-first {
  0%, 38% { opacity: 1; }
  41%, 96% { opacity: 0; }
  100% { opacity: 1; }
}
@keyframes step {
  0%, 33% { color: var(--ink); }
  36%, 100% { color: var(--text-2); }
}
@keyframes step-n {
  0%, 33% { background: var(--primary); color: #fff; }
  36%, 100% { background: var(--primary-tint); color: var(--primary); }
}

/* Features: one real screen per thing the owner does. */
.features { padding: 64px 0; background: var(--surface); border-block: 1px solid var(--line); }
.features h2, .start h2, .faq h2 { font-size: 30px; line-height: 1.12; letter-spacing: -0.035em; }
.feature-list { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 56px; }
.feature { display: grid; gap: 18px; }
.feature h3 { font-size: 22px; letter-spacing: -0.02em; }
.feature p { margin-top: 4px; color: var(--text-2); }
.shot { border-radius: 10px; border: 1px solid var(--line); box-shadow: var(--shadow-sm); background: var(--paper); }
.phone { justify-self: center; width: min(240px, 70%); padding: 7px; border-radius: 30px; background: var(--ink); box-shadow: var(--shadow); }
.phone .shot { border: 0; border-radius: 24px; box-shadow: none; }

/* Start */
.start { padding-top: 64px; padding-bottom: 64px; }
.start-steps { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 14px; }
.start-steps li { display: flex; align-items: center; gap: 14px; font-size: 20px; font-weight: 700; color: var(--ink); }
.start-steps .n { width: 40px; height: 40px; font-size: 18px; background: var(--primary); color: #fff; }

/* Price */
.price {
  display: grid; gap: 28px; padding: 40px 24px; border-radius: 22px;
  background: var(--navy); color: #fff;
}
.price h2 { color: #fff; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; }
.amount { font-size: 64px; line-height: 1; letter-spacing: -0.05em; }
.per { font-size: 20px; color: var(--on-navy-2); }
.price-main { margin-top: 16px; font-size: 18px; }
.price-note { margin-top: 6px; font-size: 16px; color: var(--on-navy-2); }
.price .btn-primary { width: 100%; }

/* FAQ */
.faq { padding-top: 64px; padding-bottom: 56px; display: grid; gap: 16px; }
.faq-list details { border-top: 1px solid var(--line-strong); }
.faq-list details:last-of-type { border-bottom: 1px solid var(--line-strong); }
.faq-list summary {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 60px; font-size: 18px; font-weight: 700; color: var(--ink);
  cursor: pointer; list-style: none;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: ""; flex-shrink: 0; width: 14px; height: 14px;
  background: linear-gradient(var(--ink), var(--ink)) center / 100% 2px no-repeat,
              linear-gradient(var(--ink), var(--ink)) center / 2px 100% no-repeat;
  transition: transform 0.2s var(--ease-out);
}
.faq-list details[open] summary::after { transform: rotate(45deg); }
.faq-list details p { padding-bottom: 18px; color: var(--text-2); max-width: 62ch; }
.ask { margin-top: 32px; font-size: 18px; font-weight: 700; color: var(--ink); }
.faq-list .btn-ink { margin-top: 12px; width: 100%; }

/* Footer */
.foot { border-top: 1px solid var(--line); font-size: 15px; color: var(--text-2); }
.foot-in { padding-top: 24px; padding-bottom: 32px; display: grid; gap: 8px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 0 20px; }
.foot a { display: inline-flex; align-items: center; min-height: 44px; color: var(--text-2); font-weight: 700; }
.foot a:hover { color: var(--ink); }

/* Legal placeholders */
.legal { padding-top: 40px; padding-bottom: 96px; display: grid; gap: 20px; justify-items: start; }
.legal h1 { font-size: 36px; letter-spacing: -0.035em; }
.draft { padding: 14px 16px; border: 1px solid #e2c48a; border-radius: 10px; background: #fcefd6; color: #6e4700; font-weight: 700; }

/* Desktop */
@media (min-width: 960px) {
  :root { --gutter: 32px; }
  body { font-size: 18px; }
  .top { height: 76px; }
  .brand-name { font-size: 23px; }
  .brand-by { font-size: 15px; }

  .hero { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: center; gap: 64px; padding-top: 48px; padding-bottom: 104px; }
  .hero-copy { display: block; }
  .hero h1 { font-size: 60px; }
  .lead { font-size: 21px; margin-top: 22px; }
  .hero-copy .btn-primary { width: auto; margin-top: 36px; }
  .offer, .needs, .demo { text-align: left; font-size: 16px; }
  .demo { margin-top: 10px; }
  .show { margin: 0; }
  .laptop { padding: 10px; border-radius: 16px; }
  .screen { aspect-ratio: 16 / 9; }
  .laptop-base { height: 12px; margin: 10px -20px -10px; }

  .features { padding: 104px 0; }
  .features h2, .start h2, .faq h2 { font-size: 40px; }
  .feature-list { margin-top: 56px; gap: 96px; }
  .feature { grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); align-items: center; gap: 64px; }
  /* Even rows put the screenshot first; the wide column moves with it. */
  .feature:nth-child(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); }
  .feature:nth-child(even) .feature-text { order: 2; }
  .feature h3 { font-size: 28px; }
  .feature p { font-size: 19px; }
  .feature-phone .phone { justify-self: center; width: 260px; }

  .start { padding-top: 104px; padding-bottom: 104px; }
  .start-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin-top: 40px; }
  .start-steps li { font-size: 22px; }

  .price { grid-template-columns: 1fr auto; align-items: center; gap: 64px; padding: 64px; border-radius: 24px; }
  .amount { font-size: 88px; }
  .per { font-size: 24px; }
  .price-main { font-size: 19px; }
  .price-note { font-size: 17px; }
  .price .btn-primary { width: auto; }

  .faq { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 64px; padding-top: 104px; padding-bottom: 96px; }
  .faq-list summary { font-size: 20px; min-height: 64px; }
  .faq-list .btn-ink { width: auto; padding: 0 24px; }

  .foot-in { grid-template-columns: 1fr auto; align-items: center; padding-top: 28px; padding-bottom: 28px; }
}
