:root {
  --bg: #f7f3fc;
  --surface: #ffffff;
  --ink: #22123c;
  --muted: #5d4d73;
  --primary: #4213b3;
  --wash: #eee5ff;
  --line: #e1d6f2;
  --night: #230a58;
  --ivory: #faf7e8;
  --mint: #62f1b6;
  --mint-wash: #daf8eb;
  --forest: #14634f;
  --radius: 20px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
a { color: var(--primary); text-underline-offset: 3px; }
a:hover { color: var(--night); }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 10;
  background: var(--night); color: var(--ivory); padding: 10px 16px; border-radius: 10px;
}
.skip:focus { top: 12px; }

.wrap { width: min(100% - 40px, 920px); margin-inline: auto; }

header.site {
  background: var(--night);
  color: var(--ivory);
}
header.site .wrap {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 12px 16px; padding-block: 24px;
}
.brand { display: inline-flex; align-items: center; gap: 22px; text-decoration: none; color: var(--ivory); font-family: ui-rounded, "SF Pro Rounded", "Arial Rounded MT Bold", "Hiragino Maru Gothic ProN", Nunito, "Varela Round", "Segoe UI", system-ui, sans-serif; font-weight: 800; font-size: 56px; line-height: 1; letter-spacing: 3px; -webkit-text-stroke: 2.5px currentColor; paint-order: stroke fill; stroke-linejoin: round; stroke-linecap: round; }
.brand img { width: 108px; height: 108px; border-radius: 34px; display: block; box-shadow: 0 6px 20px rgba(0,0,0,.35); }
.brand span span { color: var(--mint); }
nav.main { display: flex; flex-wrap: wrap; gap: 4px 12px; }
nav.main a { color: var(--ivory); text-decoration: none; font-weight: 600; font-size: 15px; padding: 6px 2px; border-bottom: 2px solid transparent; }
nav.main a:hover, nav.main a[aria-current="page"] { border-bottom-color: var(--mint); color: #fff; }
header.site :focus-visible { outline-color: var(--mint); }

main { padding-block: 48px 64px; }

.hero { background: var(--night); color: var(--ivory); }
.hero .wrap { padding-block: 56px 64px; }
.hero h1 { color: var(--ivory); font-size: clamp(34px, 6vw, 54px); line-height: 1.08; letter-spacing: -1.4px; margin: 0 0 18px; max-width: 18ch; text-wrap: balance; }
.hero h1 em { font-style: normal; color: var(--mint); }
.hero p { font-size: 19px; max-width: 56ch; margin: 0 0 24px; color: #e6d9ff; }
.app-store-badge { display: inline-block; vertical-align: middle; }
.app-store-badge img { display: block; width: auto; height: 48px; }
.app-store-badge:focus-visible { outline-color: var(--mint); }

h1 { font-size: clamp(30px, 5vw, 40px); line-height: 1.15; letter-spacing: -0.9px; margin: 0 0 8px; }
h2 { font-size: 24px; line-height: 1.25; letter-spacing: -0.4px; margin: 40px 0 10px; }
h3 { font-size: 18px; margin: 24px 0 6px; }
p, ul, ol { margin: 0 0 14px; }
li { margin-bottom: 6px; }
.lead { font-size: 19px; color: var(--muted); max-width: 62ch; }
.updated { color: var(--muted); font-size: 15px; margin-bottom: 28px; }

.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); margin-block: 24px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.card h2, .card h3 { margin-top: 0; }
.card.mint { background: var(--mint-wash); border-color: #bfe9d6; }
.price { font-size: 30px; font-weight: 800; letter-spacing: -0.8px; margin: 4px 0; }
.price small { font-size: 16px; font-weight: 600; color: var(--muted); letter-spacing: 0; }

.notice { background: var(--wash); border: 1px solid var(--line); border-radius: 14px; padding: 14px 18px; margin-block: 18px; }

table { border-collapse: collapse; width: 100%; margin-block: 14px 20px; background: var(--surface); border-radius: 14px; overflow: hidden; font-size: 16px; }
th, td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--line); }
th { background: var(--wash); font-weight: 700; }
tr:last-child td { border-bottom: 0; }
.table-scroll { overflow-x: auto; }

details { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 4px 18px; margin-bottom: 10px; }
summary { cursor: pointer; font-weight: 700; padding: 12px 0; }
details[open] summary { margin-bottom: 4px; }

.btn { display: inline-block; background: var(--primary); color: #fff; text-decoration: none; font-weight: 700; padding: 12px 22px; border-radius: 14px; }
.btn:hover { background: var(--night); color: #fff; }

footer.site { background: var(--night); color: #e6d9ff; padding-block: 32px; font-size: 15px; }
footer.site .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; }
footer.site a { color: var(--ivory); }
footer.site :focus-visible { outline-color: var(--mint); }
footer.site ul { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 20px; }
footer.site li { margin: 0; }

@media (max-width: 640px) {
  .table-scroll { overflow: visible; }
  table, tbody, tr, th, td { display: block; width: 100%; }
  thead { position: absolute; left: -9999px; }
  tr { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; margin-bottom: 12px; overflow: hidden; }
  th[scope="row"] { background: var(--wash); border-bottom: 1px solid var(--line); }
  td { border-bottom: 0; padding-top: 8px; padding-bottom: 8px; }
  td::before { content: attr(data-label); display: block; font-weight: 700; font-size: 14px; color: var(--muted); }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media print { header.site, footer.site, .skip { display: none; } body { background: #fff; } }

@media (max-width: 520px) {
  .brand { font-size: 42px; letter-spacing: 2px; gap: 14px; -webkit-text-stroke-width: 2px; }
  .brand img { width: 84px; height: 84px; border-radius: 26px; }
}

/* Marca destacada en la portada y el pie */
.hero .wrap.hero-grid { display: flex; flex-wrap: wrap-reverse; align-items: center; justify-content: space-between; gap: 32px 48px; }
.hero-copy { flex: 1 1 360px; min-width: 0; }
.hero-mark { flex: 0 0 auto; width: clamp(190px, 32vw, 340px); height: auto; aspect-ratio: 1; border-radius: 28%; display: block; margin-inline: auto; box-shadow: 0 18px 50px rgba(0,0,0,.45); }
.foot-brand { display: inline-flex; align-items: center; gap: 14px; color: var(--ivory); font-family: ui-rounded, "SF Pro Rounded", "Arial Rounded MT Bold", "Hiragino Maru Gothic ProN", Nunito, "Varela Round", "Segoe UI", system-ui, sans-serif; font-weight: 800; font-size: 30px; letter-spacing: 2px; -webkit-text-stroke: 1.5px currentColor; paint-order: stroke fill; stroke-linejoin: round; stroke-linecap: round; text-decoration: none; }
.foot-brand img { width: 64px; height: 64px; border-radius: 20px; display: block; }
.foot-brand span span { color: var(--mint); }
.foot-mail { margin: 10px 0 0; }

/* Selector de idioma (es/en) y enlace de la insignia */
nav.main a.lang { border: 1.5px solid rgba(250, 247, 232, .45); border-radius: 999px; padding: 4px 10px; }
nav.main a.lang:hover { border-color: var(--mint); }
