/* Mis Compras website. Layout: text sections scroll on the left while one phone stays put on the right and
   swaps screens (wide screens); on phones each section shows its own screenshot. Colors follow the app. */

@font-face { font-family: "Nunito"; src: url("fonts/nunito-latin.woff2") format("woff2"); font-weight: 200 1000; font-display: swap; }
@font-face { font-family: "Atkinson Hyperlegible"; src: url("fonts/atkinson-400-latin.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Atkinson Hyperlegible"; src: url("fonts/atkinson-700-latin.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --bg: #FDF6EE;
  --surface: #FFFDF9;
  --ink: #2B211C;
  --muted: #6B5A50;
  --orange: #E8875A;
  --orange-ink: #B4532A;
  --green: #3E7D59;
  --line: #EADCCD;
  --chip: #F4E6D6;
  --band-bg: #2E6646;
  --band-fg: #FFFFFF;
  --band-soft: #E6F2EA;
  --band-card: rgba(255, 255, 255, .14);
  --display: "Nunito", "Segoe UI", system-ui, sans-serif;
  --body: "Atkinson Hyperlegible", "Segoe UI", system-ui, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1D1612; --surface: #271E19; --ink: #F6ECE2; --muted: #C3B0A3;
    --orange: #EE9468; --orange-ink: #F2A47C; --green: #6DB38A; --line: #3B2E27; --chip: #33271F;
    --band-bg: #163626; --band-fg: #F6ECE2; --band-soft: #D3E8DA; --band-card: rgba(255, 255, 255, .08);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.6 var(--body); }
img { max-width: 100%; height: auto; }
a { color: var(--orange-ink); }
:focus-visible { outline: 3px solid var(--green); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); line-height: 1.1; text-wrap: balance; margin: 0; }
.wrap { max-width: 68rem; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 8px; z-index: 20; background: var(--surface); padding: 8px 14px; border-radius: 8px; }

/* header */
header.top { position: sticky; top: 0; z-index: 5; background: var(--bg); border-bottom: 1px solid var(--line); }
header.top .wrap { display: flex; align-items: center; gap: 12px; padding-block: 10px; }
.brand { display: flex; align-items: center; gap: 10px; font: 900 1.25rem var(--display); color: var(--ink); text-decoration: none; margin-right: auto; min-height: 44px; }
.brand img { width: 40px; height: 40px; border-radius: 10px; }
.lang { display: flex; gap: 4px; border: 2px solid var(--line); border-radius: 999px; padding: 3px; }
.lang a { display: inline-flex; align-items: center; justify-content: center; min-width: 48px; min-height: 40px; border-radius: 999px; color: var(--muted); font: 800 .95rem var(--display); text-decoration: none; }
.lang a[aria-current="page"] { background: var(--orange); color: #2B211C; }

.badge { display: inline-block; line-height: 0; border-radius: 10px; }
.badge img { width: 200px; height: auto; }

/* hero */
.hero .wrap { display: grid; gap: 32px; padding-block: 48px 32px; align-items: center; }
@media (min-width: 860px) { .hero .wrap { grid-template-columns: 1.2fr 1fr; padding-block: 72px 48px; } }
.hero h1 { font-size: clamp(2.3rem, 6vw, 4rem); font-weight: 900; letter-spacing: -.01em; }
.hero .lead { font-size: 1.25rem; color: var(--muted); max-width: 34ch; margin: 18px 0 22px; }
.hero .phone { justify-self: center; }

.facts { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 24px 0 0; }
.facts li { display: flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: var(--chip); font-weight: 700; font-size: .98rem; }
.facts li::before { content: ""; width: 18px; height: 18px; border-radius: 50%; flex: none;
  background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/12px no-repeat; }

/* phone frame */
.phone { width: min(300px, 78vw); aspect-ratio: 1 / 2; max-width: 100%; border: 10px solid var(--ink); border-radius: 38px; overflow: hidden; background: var(--surface); box-shadow: 0 24px 50px -24px rgba(60, 30, 10, .45); position: relative; }
.phone img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; transition: opacity .45s ease; }
.showcase .phone img { opacity: 0; }
.showcase .phone img.on { opacity: 1; }

/* features */
.features .wrap { display: grid; padding-block: 24px 40px; }
@media (min-width: 860px) { .features .wrap { grid-template-columns: 1.2fr 1fr; gap: 32px; } }
.showcase { display: none; }
@media (min-width: 860px) {
  .showcase { display: block; position: sticky; top: 96px; align-self: start; justify-self: center; }
  .feature .phone { display: none; }
  .feature { min-height: 78vh; align-content: center; }
}
.feature { padding-block: 36px; border-top: 1px solid var(--line); display: grid; gap: 14px; }
.feature:first-child { border-top: 0; }
.kicker { font: 800 .85rem var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--orange-ink); }
.feature h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 900; }
.feature p { margin: 0; max-width: 40ch; color: var(--muted); font-size: 1.12rem; }
.feature .phone { justify-self: center; margin-top: 12px; }
.tag { display: inline-block; padding: 1px 10px; border-radius: 8px; background: var(--chip); color: var(--ink); font: 800 1rem var(--display); /* Nunito: Atkinson's slashed zero read as "5ØØg" */ }
.reveal { transition: opacity .5s ease, transform .5s ease; }
.js .reveal.pending { opacity: .35; transform: translateY(14px); }

/* privacy band */
.privacy { background: var(--band-bg); color: var(--band-fg); }
.privacy .wrap { padding-block: 56px; display: grid; gap: 20px; }
.privacy h2 { font-size: clamp(1.9rem, 4.5vw, 2.8rem); font-weight: 900; }
.privacy p { margin: 0; max-width: 52ch; font-size: 1.15rem; color: var(--band-soft); }
.privacy ul { list-style: none; padding: 0; margin: 4px 0 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); }
.privacy li { padding: 14px 16px; border-radius: 14px; background: var(--band-card); font-weight: 700; font-size: 1.1rem; }
.privacy li span { display: block; font-weight: 400; color: var(--band-soft); font-size: 1rem; }

/* closing call to action */
.cta .wrap { padding-block: 56px; display: grid; justify-items: center; gap: 18px; text-align: center; }
.cta .icon { width: 72px; height: 72px; border-radius: 18px; }
.cta h2 { font-size: clamp(1.8rem, 4vw, 2.4rem); font-weight: 900; }
.cta p { margin: 0; color: var(--muted); }

footer { border-top: 1px solid var(--line); color: var(--muted); font-size: .95rem; }
footer .wrap { padding-block: 20px 40px; display: flex; flex-wrap: wrap; gap: 4px 24px; justify-content: space-between; align-items: center; }
footer nav { display: flex; flex-wrap: wrap; gap: 4px 20px; align-items: center; }
footer a, footer .mail { display: inline-flex; align-items: center; min-height: 44px; }
footer .legal { flex-basis: 100%; font-size: .82rem; margin: 8px 0 0; }

/* language chooser (root page) */
.chooser { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 20px; text-align: center; padding: 24px 16px; }
.chooser img { width: 96px; height: 96px; border-radius: 24px; }
.chooser nav { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.chooser nav a { display: inline-flex; align-items: center; min-height: 48px; padding: 0 22px; border-radius: 999px; background: var(--orange); color: #2B211C; font: 800 1.1rem var(--display); text-decoration: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal.pending { opacity: 1; transform: none; }
}
