/* Bolillas web: the game's candy colours, cream panels and brown ink. */
:root {
  --ink: #5A3A22;
  --ink-soft: #8a6a50;
  --cream: #FFFBF1;
  --cream-shade: #F6EBD6;
  --border: #E8C99A;
  --sky: #2FA4F2;
  --sky-light: #7CCBFF;
  --sky-deep: #1F6FE0;
  --grass: #52B81C;
  --yellow: #F5A300;
  --cherry: #E5274A;
  --header: 68px;
  --radius: 26px;
  --shadow: 0 10px 24px rgba(90, 58, 34, .16);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header) + 16px); }
body {
  margin: 0;
  font: 17px/1.65 -apple-system, BlinkMacSystemFont, "SF Pro Rounded", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: #EAF6FF;
}
img { max-width: 100%; }
a { color: var(--sky-deep); font-weight: 600; text-underline-offset: 3px; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.01em; }

/* MARK: Header, always on top */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header);
  background: rgba(255, 251, 241, .82);
  -webkit-backdrop-filter: saturate(160%) blur(14px); backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid rgba(232, 201, 154, .7);
}
.header-inner {
  max-width: 1120px; height: 100%; margin: 0 auto; padding: 0 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: flex; align-items: center; }
.brand img { height: 44px; width: auto; display: block; filter: drop-shadow(0 2px 3px rgba(90, 58, 34, .25)); }
.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav a {
  text-decoration: none; color: var(--ink); font-size: 15px; padding: 8px 12px; border-radius: 999px;
  transition: background .15s ease;
}
.site-nav a:hover { background: var(--cream-shade); }
.site-nav a[aria-current="page"] { background: #FFE3A3; box-shadow: inset 0 0 0 2px var(--yellow); }
.site-nav .lang-link { margin-left: 8px; border: 2px solid var(--border); }
.menu-button {
  display: none; width: 44px; height: 44px; border-radius: 14px; border: 2px solid var(--border);
  background: var(--cream); color: var(--ink); cursor: pointer; align-items: center; justify-content: center;
}
.menu-button svg { width: 22px; height: 22px; }

/* MARK: Pages with text */
.page { max-width: 820px; margin: 36px auto 56px; padding: 0 16px; }
.page-card {
  background: var(--cream); border: 3px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 36px 40px;
}
.page-card h1 { font-size: 34px; margin: 0 0 6px; }
.page-card h2 { font-size: 22px; margin: 34px 0 8px; padding-top: 18px; border-top: 2px dashed var(--cream-shade); }
.page-card h3 { font-size: 18px; margin: 22px 0 4px; }
.updated { color: var(--ink-soft); font-size: 14px; margin: 0 0 20px; }
.lead { font-size: 19px; }
.card { background: var(--cream-shade); border-radius: 18px; padding: 16px 20px; margin: 14px 0; }
.card h3 { margin-top: 0; }
ul { padding-left: 22px; }
li { margin: 5px 0; }

/* MARK: Home */
.hero {
  position: relative; overflow: hidden;
  background: radial-gradient(1200px 500px at 70% 10%, rgba(255, 255, 255, .45), transparent 60%),
              linear-gradient(180deg, var(--sky-light) 0%, var(--sky-deep) 100%);
  color: #fff;
}
.hero-inner {
  position: relative; z-index: 1; max-width: 1120px; margin: 0 auto; padding: 64px 20px 88px;
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center;
}
.hero h1 { font-size: clamp(36px, 5.4vw, 60px); margin: 0 0 16px; text-shadow: 0 3px 0 rgba(13, 74, 158, .45); }
.hero p { font-size: clamp(18px, 2vw, 21px); margin: 0 0 26px; max-width: 34em; opacity: .96; }
.hero-logo { width: min(420px, 90%); margin-bottom: 18px; filter: drop-shadow(0 8px 12px rgba(13, 74, 158, .35)); }
.store-badge {
  display: inline-flex; align-items: center; gap: 10px; background: #111; color: #fff; text-decoration: none;
  border-radius: 14px; padding: 10px 18px; font-weight: 700; box-shadow: 0 6px 14px rgba(0, 0, 0, .25);
}
.store-badge small { display: block; font-weight: 500; font-size: 12px; opacity: .8; }
.store-badge svg { width: 26px; height: 26px; fill: #fff; }
.phone {
  justify-self: center; width: min(300px, 78vw); aspect-ratio: 9 / 16.5; border-radius: 44px; padding: 12px;
  background: #1b1b1f; box-shadow: 0 30px 60px rgba(13, 50, 110, .45), inset 0 0 0 2px #3a3a40;
  transform: rotate(4deg);
}
.phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 34px; display: block; }
.marble { position: absolute; width: 74px; height: 74px; animation: float 7s ease-in-out infinite; z-index: 0; opacity: .95; }
.marble.m1 { top: 9%; left: 4%; width: 64px; height: 64px; }
.marble.m2 { top: 70%; left: 42%; animation-delay: -2s; width: 52px; height: 52px; }
.marble.m3 { top: 14%; right: 6%; animation-delay: -4s; }
.marble.m4 { bottom: 8%; right: 30%; animation-delay: -1s; width: 46px; height: 46px; }
.marble.m5 { bottom: 12%; left: 8%; animation-delay: -3s; width: 58px; height: 58px; }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-16px) rotate(14deg); } }
.wave { position: absolute; left: 0; right: 0; bottom: -1px; height: 60px; z-index: 1; }

.section { max-width: 1120px; margin: 0 auto; padding: 64px 20px; }
.section h2 { font-size: clamp(28px, 3.4vw, 38px); text-align: center; margin: 0 0 10px; }
.section .sub { text-align: center; color: var(--ink-soft); margin: 0 auto 36px; max-width: 40em; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.mode {
  background: var(--cream); border: 3px solid var(--border); border-radius: var(--radius); padding: 24px;
  box-shadow: var(--shadow); text-align: center; transition: transform .2s ease, box-shadow .2s ease;
}
.mode:hover { transform: translateY(-4px); box-shadow: 0 16px 30px rgba(90, 58, 34, .2); }
.mode img { height: 84px; width: auto; margin-bottom: 8px; }
.mode h3 { font-size: 21px; margin: 4px 0 6px; }
.mode p { margin: 0; color: var(--ink-soft); font-size: 16px; }
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.feature { display: flex; gap: 14px; align-items: flex-start; background: #fff; border-radius: 20px; padding: 18px; border: 2px solid #D8ECFB; }
.feature img { width: 46px; height: 46px; flex: none; }
.feature h3 { margin: 0 0 4px; font-size: 18px; }
.feature p { margin: 0; font-size: 15px; color: var(--ink-soft); }
.band { background: var(--cream); border-top: 3px solid var(--border); border-bottom: 3px solid var(--border); }
.links { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.links a {
  display: block; text-decoration: none; color: var(--ink); background: #fff; border: 2px solid var(--border);
  border-radius: 18px; padding: 16px 18px; font-size: 17px;
}
.links a span { display: block; color: var(--ink-soft); font-weight: 400; font-size: 14px; }
.links a:hover { border-color: var(--yellow); }

/* MARK: Footer */
.site-footer { background: #0D4A9E; color: #DCEBFF; font-size: 14px; }
.footer-inner {
  max-width: 1120px; margin: 0 auto; padding: 28px 20px; display: flex; flex-wrap: wrap; gap: 12px 28px;
  align-items: center; justify-content: space-between;
}
.footer-inner nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.site-footer a { color: #fff; font-weight: 600; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }

/* MARK: Phones and tablets */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; padding: 40px 20px 80px; }
  .hero p { margin-left: auto; margin-right: auto; }
  .phone { transform: none; width: min(260px, 70vw); }
  .marble.m2, .marble.m4 { display: none; }
}
@media (max-width: 760px) {
  .menu-button { display: inline-flex; }
  .site-nav {
    position: absolute; top: var(--header); left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 2px;
    padding: 10px 16px 16px; background: var(--cream); border-bottom: 3px solid var(--border);
    box-shadow: 0 14px 24px rgba(90, 58, 34, .18);
    transform: translateY(-8px); opacity: 0; visibility: hidden; transition: opacity .18s ease, transform .18s ease, visibility .18s;
  }
  .site-nav.open { transform: none; opacity: 1; visibility: visible; }
  .site-nav a { padding: 12px 14px; font-size: 17px; }
  .site-nav .lang-link { margin: 6px 0 0; text-align: center; }
  .page { margin: 20px auto 40px; padding: 0 12px; }
  .page-card { padding: 24px 20px; border-radius: 22px; }
  .page-card h1 { font-size: 27px; }
  .section { padding: 48px 16px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .marble { animation: none; }
  .mode, .site-nav { transition: none; }
}
