/* Poppins, served from this site (no request to Google Fonts). Latin and Latin Extended, weights 400, 500, 600. */
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/poppins-400-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/poppins-400-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/poppins-500-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/poppins-500-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/poppins-600-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/poppins-600-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ==========================================================================
   Mikukito — site styles
   ========================================================================== */

:root {
  --bg: #f8f8f6;
  --surface: #ffffff;
  --ink: #1d1d1f;
  --muted: #45474c;
  --line: #e6e6e2;
  --banner: #020414;   /* one navy for every dark band on the site (hero, Contact, app pages) */
  --badge-ring: transparent; /* light cards: the filled navy circle needs no ring */
  --banner-ink: #ffffff;
  --accent: #0b766d;
  --accent-hover: #095e57;
  --accent-ink: #ffffff;
  --danger: #b42318;
  --danger-bg: #fef3f2;
  --success-bg: #ecf8f6;
  --shadow: 0 6px 24px rgba(20, 20, 20, .08);
  --radius: 18px;
  --max: 1120px;
  --gutter: clamp(16px, 4vw, 32px);
  --section: clamp(48px, 8vw, 96px);
  color-scheme: light;
}

/* Dark theme: opt-in via the header toggle (saved per visitor) */
:root[data-theme="dark"] {
    /* Dark mode is one dark colour: the site's deep navy (#020414) for the page and every band, the same as the
       light-mode hero. Cards and the Work with us band sit a hair lighter (#0b1027) so content still groups, and
       thin divider lines separate the bands. Text: ink 18.2:1 on the page, muted 10.8:1, teal 7.9:1; on cards
       ink 16.8:1, muted 9.9:1, teal 7.3:1. */
    --bg: #020414;
    --surface: #0b1027;
    --ink: #f2f2f0;
    --muted: #b8bccb;
    --line: #262e4f;
    --banner: #020414;
    --accent: #2bb3a6;
    --accent-hover: #3fc9bc;
    --accent-ink: #062a27;
    --danger: #ff9b8f;
    --danger-bg: #3a1d2a;
    --success-bg: #10303a;
    --shadow: 0 6px 24px rgba(0, 0, 0, .55);
    color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 24px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: 3px; }
a:hover { color: var(--accent); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { line-height: 1.3; margin: 0; text-wrap: balance; }
p { margin: 0 0 .75em; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.skip-link {
  position: absolute; left: 12px; top: -48px; z-index: 100;
  background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: 8px;
}
.skip-link:focus { top: 12px; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* Header ------------------------------------------------------------------ */
.site-header { position: relative; z-index: 20; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 84px; }
.logo { font-weight: 500; font-size: 1.3rem; letter-spacing: .06em; text-decoration: none; }
.logo:hover { color: inherit; }

.nav-toggle {
  display: none; align-items: center; justify-content: center;
  width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--surface); color: var(--ink); cursor: pointer;
}
.nav-toggle svg { width: 22px; }

.nav-list { list-style: none; display: flex; gap: 8px; margin: 0; padding: 0; font-size: .9rem; }
.nav-list > li { position: relative; }
.nav-list a { display: block; padding: 8px 10px; text-decoration: none; border-radius: 8px; }
.nav-list a[aria-current="page"] { color: var(--accent); font-weight: 500; }
.subnav {
  list-style: none; margin: 0; padding: 6px; min-width: 160px;
  position: absolute; top: 100%; left: 0;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(4px); transition: .15s ease;
}
.has-sub:hover .subnav, .has-sub:focus-within .subnav { opacity: 1; visibility: visible; transform: none; }
.subnav a:hover { background: var(--bg); }

@media (max-width: 720px) {
  .js .nav-toggle { display: inline-flex; }
  .js .site-nav {
    display: none; position: absolute; top: 76px; right: var(--gutter); left: var(--gutter);
    background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); padding: 8px;
  }
  .js .site-nav.open { display: block; }
  .js .nav-list { flex-direction: column; gap: 0; font-size: 1rem; }
  .js .nav-list a { padding: 12px 14px; }
  .js .subnav { position: static; opacity: 1; visibility: visible; transform: none; border: 0; box-shadow: none; padding: 0 0 0 14px; background: none; }
  .nav-list { flex-wrap: wrap; justify-content: flex-end; }
}

/* Footer ------------------------------------------------------------------ */
.site-footer { margin-top: var(--section); border-top: 1px solid var(--line); }
.site-footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; padding-block: 28px; }
.footer-links { display: flex; gap: 20px; list-style: none; margin: 0; padding: 0; font-size: .9rem; }
.copyright { width: 100%; color: var(--muted); font-size: .8rem; margin: 0; }

/* Shared ------------------------------------------------------------------ */
.section { padding-block: var(--section) 0; }
.section-title { font-weight: 500; font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2rem); margin-bottom: 12px; }
.section-head { text-align: center; margin-bottom: 36px; }
.lead { color: var(--muted); max-width: 68ch; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px;
  padding: 10px 24px; border-radius: 12px; border: 0;
  background: var(--accent); color: var(--accent-ink);
  font: inherit; font-weight: 600; font-size: .9rem; text-decoration: none; cursor: pointer;
  transition: background .2s, transform .2s;
}
.btn:hover { background: var(--accent-hover); color: var(--accent-ink); transform: translateY(-1px); }

.appstore {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px;
  padding: 6px 16px 6px 12px; border-radius: 10px;
  background: #000; color: #fff; text-decoration: none; line-height: 1.1;
  border: 1px solid #000; transition: transform .2s;
}
:root[data-theme="dark"] .appstore { border-color: #8e8e93; }
.appstore:hover { color: #fff; transform: translateY(-1px); }
.appstore svg { width: 22px; fill: currentColor; }
.appstore small { display: block; font-size: .62rem; letter-spacing: .02em; }
.appstore b { font-size: 1.15rem; font-weight: 500; }

/* Home: banner ------------------------------------------------------------ */
.banner { background: var(--banner); color: var(--banner-ink); text-align: center; padding: clamp(40px, 7vw, 72px) var(--gutter); }
.banner h1 { font-weight: 400; font-size: clamp(1.8rem, 1.3rem + 2.4vw, 3rem); }
.banner p { opacity: .85; margin: 8px 0 18px; }
.banner a { font-weight: 600; font-size: .95rem; }
.banner a:hover { color: #8ee6dc; }

/* Home: app cards --------------------------------------------------------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 24px; }
.card {
  display: flex; flex-direction: column; padding: clamp(20px, 3vw, 32px);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
  transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 14px 36px rgba(20, 20, 20, .12); }
.card-head { display: flex; gap: 18px; align-items: center; }
.card-head img { width: 84px; flex: none; }
.card h3 { font-size: 1.5rem; font-weight: 600; }
.card-head p { margin: 4px 0 0; color: var(--muted); font-size: .9rem; }
.card ul { margin: 20px 0 24px; padding-left: 20px; font-size: .92rem; }
.card li + li { margin-top: 6px; }
.card-actions { margin-top: auto; display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; }

/* App pages --------------------------------------------------------------- */
.app-hero { text-align: center; padding-top: clamp(16px, 4vw, 40px); }
.app-hero img { width: clamp(96px, 14vw, 128px); margin: 0 auto 12px; }
.app-hero h1 { font-size: clamp(1.7rem, 1.4rem + 1vw, 2.2rem); font-weight: 600; }
.app-hero p { font-size: clamp(1.1rem, 1rem + .5vw, 1.35rem); font-weight: 500; margin: 2px 0 0; }

.split { display: grid; grid-template-columns: 1.2fr 1fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.split h2 { font-size: clamp(1.4rem, 1.2rem + .8vw, 1.8rem); font-weight: 500; margin-bottom: 14px; }
.split .lead { margin-bottom: 24px; }

.love-title { display: flex; align-items: center; gap: 10px; }
.love-title svg { width: 28px; flex: none; }
.features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 36px 56px; margin: 32px 0 0; padding: 0; list-style: none; }
.feature { display: flex; gap: 20px; align-items: flex-start; }
.feature-icon {
  flex: none; width: 64px; height: 64px; display: grid; place-items: center;
  font-size: 2.2rem; line-height: 1; border-radius: 18px; background: var(--surface); border: 1px solid var(--line);
}
.feature h3 { font-size: 1.05rem; font-weight: 600; margin-bottom: 4px; }
.feature p { margin: 0; color: var(--muted); font-size: .92rem; }

.checklist { list-style: none; padding: 0; margin: 0 0 16px; }
.checklist li { display: flex; gap: 10px; align-items: center; padding: 3px 0; }
.checklist svg { width: 20px; flex: none; color: var(--accent); }

/* Phone mockups ----------------------------------------------------------- */
.phones { display: flex; justify-content: center; align-items: flex-start; padding-block: 12px 24px; }
.phone {
  /* Matches the app's own mockups: black outline, grey ring, black bezel, top notch */
  position: relative; flex: none; width: clamp(170px, 20vw, 220px); aspect-ratio: 9 / 19.5;
  padding: 5px; border: 6px solid #666; border-radius: 42px; background: #030303;
  box-shadow: 0 0 0 2px #000, 0 24px 48px rgba(0, 0, 0, .22);
}
.phone::before {
  content: ""; position: absolute; z-index: 2; top: 5px; left: 50%; transform: translateX(-50%);
  width: 38%; height: 20px; border-radius: 0 0 14px 14px; background: #030303;
}
.screen {
  position: relative; height: 100%; overflow: hidden; border-radius: 31px;
  padding: 40px 12px 14px; font-size: .62rem; line-height: 1.4; color: #1d1d1f; background: #fff;
}
.phone--back { transform: rotate(9deg) translateY(28px); margin-left: -36px; }
.phone--angled-a { transform: rotate(-14deg); }
.phone--angled-b { transform: rotate(-14deg) translateY(56px); margin-left: -28px; }

.screen--explorito { background: #fdeeee; }
.screen-bar { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.pill { background: #fff; border-radius: 99px; padding: 1px 8px; font-weight: 500; }
.lesson { background: #16213a; color: #fff; border-radius: 14px; padding: 10px; text-align: center; margin-top: 14px; width: 74%; }
.lesson span { display: block; font-size: 2rem; line-height: 1.2; }
.lesson--right { margin-left: auto; }
.rocket { font-size: 2.2rem; margin-top: 12px; }
.screen--hero { display: grid; place-items: center; font-size: 4rem; }
.screen--dark { background: #16213a; }

.board { position: relative; height: 62%; margin-top: 10px; }
.tile { position: absolute; width: 24%; aspect-ratio: 1; border-radius: 5px; background: #1aa39a; }
.tile--empty { background: transparent; border: 1.5px solid #1aa39a; }
.tray { display: flex; justify-content: space-around; margin-top: 8px; }
.tray span { width: 22px; height: 22px; border-radius: 4px; background: #1aa39a; }
.tray .is-active { background: #9b5de5; outline: 2px solid #f15bb5; outline-offset: 2px; }
.score-ring { width: 72%; aspect-ratio: 1; margin: 14px auto; border: 3px solid #9b5de5; border-radius: 50%; display: grid; place-items: center; text-align: center; }
.score-ring b { font-size: 1.1rem; }
.screen-btn { margin-top: 18px; padding: 9px; border-radius: 12px; background: #1aa39a; color: #fff; text-align: center; font-weight: 600; }

/* Client services ---------------------------------------------------------- */
.eyebrow { display: block; margin-bottom: 8px; color: var(--accent); font-size: .8rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.text-links { display: flex; flex-wrap: wrap; gap: 12px 28px; margin-top: 20px; font-weight: 600; font-size: .95rem; }
.text-links a { color: var(--accent); }
.text-links a:hover { color: var(--accent-hover); }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(24px, 4vw, 44px); }





.mini-services { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 20px; margin-top: 28px; }
.mini-services > div { padding: 22px 24px; background: var(--bg); border: 1px solid var(--line); border-radius: 14px; }
.mini-services h3 { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; font-size: 1.1rem; font-weight: 600; }
.mini-services h3 span { font-size: 1.5rem; }
.mini-services ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: .92rem; line-height: 1.6; }
.mini-services li + li { margin-top: 4px; }
.contact-form-wrap { max-width: 760px; margin-inline: auto; }

.contact-strip { margin-top: var(--section); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; padding: 20px 24px; }
.contact-strip p { margin: 0; }

/* Contact form ------------------------------------------------------------ */

.form { display: grid; gap: 22px; }
.form fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.form legend, .form label, .field-label { display: block; padding: 0; margin-bottom: 6px; font-weight: 500; font-size: .95rem; }
.optional { color: var(--muted); font-weight: 400; font-size: .85rem; }
.hint { display: block; margin: -2px 0 8px; color: var(--muted); font-size: .85rem; }
.form-note { margin: 0; color: var(--muted); font-size: .85rem; }

.form input[type="text"], .form input[type="email"], .form input[type="url"], .form select, .form textarea {
  width: 100%; min-height: 48px; padding: 11px 14px; border: 1.5px solid var(--line); border-radius: 12px;
  background: var(--surface); color: var(--ink); font: inherit; font-size: 1rem; transition: border-color .15s, box-shadow .15s;
}
.form textarea { min-height: 180px; resize: vertical; line-height: 1.6; }
.form select { appearance: none; padding-right: 40px; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: calc(100% - 20px) 21px, calc(100% - 15px) 21px; background-size: 5px 5px; background-repeat: no-repeat; }
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
.form [aria-invalid="true"] { border-color: var(--danger) !important; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: 16px; }
.field-row label { font-weight: 400; font-size: .9rem; }


.check-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 6px 20px; }
.check-list label { display: flex; gap: 10px; align-items: flex-start; margin: 0; padding: 6px 0; font-weight: 400; font-size: .95rem; cursor: pointer; }
.check-list input { margin: 4px 0 0; width: 18px; height: 18px; flex: none; accent-color: var(--accent); }

.error-msg { margin: 6px 0 0; color: var(--danger); font-size: .85rem; font-weight: 500; }
.error-msg::before { content: "⚠ "; }
.form-alert { padding: 16px 18px; border-radius: 12px; border: 1.5px solid var(--danger); background: var(--danger-bg); font-size: .92rem; }
.form-alert:focus { outline: none; }
.form-alert p { margin: 0 0 6px; font-weight: 600; }
.form-alert ul { margin: 0; padding-left: 20px; }
.form-alert a { color: var(--danger); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.btn[disabled] { opacity: .7; cursor: progress; transform: none; }
.spinner { width: 16px; height: 16px; margin-right: 10px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.form-success { padding: clamp(24px, 4vw, 40px); border-radius: var(--radius); background: var(--success-bg); border: 1.5px solid var(--accent); }
.form-success h2 { font-weight: 500; font-size: 1.4rem; margin-bottom: 8px; }
.form-success h2:focus { outline: none; }
.js [data-show][hidden], [hidden] { display: none !important; }

/* Legal / 404 ------------------------------------------------------------- */
.prose { max-width: 72ch; }
.prose h1 { font-weight: 500; font-size: clamp(1.8rem, 1.5rem + 1vw, 2.4rem); margin-bottom: 8px; }
.prose h2 { font-weight: 600; font-size: 1.2rem; margin: 32px 0 8px; }
.prose p, .prose li { color: var(--muted); }
.notfound { text-align: center; padding-block: clamp(64px, 12vw, 140px); }
.notfound h1 { font-size: clamp(3rem, 2rem + 6vw, 6rem); font-weight: 600; }

/* Responsive -------------------------------------------------------------- */
@media (max-width: 860px) {
  .split, .features { grid-template-columns: 1fr; }
  .split > .phones { order: -1; }
  .split--text-first > .phones { order: 0; }
}
@media (max-width: 420px) {
  .phone--back, .phone--angled-b { display: none; }
  .phone--angled-a { transform: none; }
  .card-head { flex-direction: column; align-items: flex-start; }
}

/* Ticked lists inside the client-projects cards */
.mini-services .checklist { margin: 0; padding: 0; }
.mini-services .checklist li { align-items: flex-start; padding: 4px 0; color: var(--muted); font-size: .92rem; line-height: 1.55; }
.mini-services .checklist svg { width: 16px; margin-top: 4px; color: var(--accent); opacity: .75; }

/* Privacy policy */
.prose h3 { font-weight: 600; font-size: 1rem; margin: 22px 0 6px; }
.prose ul { padding-left: 22px; margin: 0 0 12px; }
.prose li { margin: 6px 0; }
.prose li ul { margin: 6px 0 0; }
.prose a { color: var(--accent); }
.prose strong { color: var(--ink); }
.policy-meta { margin-bottom: 24px; }
.policy-contact { font-style: normal; color: var(--muted); line-height: 1.8; }

/* Explorito demo lesson (mirrors the app's own look) ----------------------- */

.phone--demo { width: clamp(270px, 28vw, 320px); }
.exd {
  --exd-bg: #fcefef; --exd-navy: #16213a; --exd-pink: #ffc2c2; --exd-heart: #e8476b;
  --exd-green: #3fbf8f; --exd-red: #ff5a4e;
  position: relative; display: flex; flex-direction: column; padding: 44px 16px 18px;
  background: var(--exd-bg); color: var(--exd-navy);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif; font-size: 14px; line-height: 1.35;
}
:where(.exd) button { font: inherit; color: inherit; cursor: pointer; }
.exd :focus-visible { outline: 3px solid var(--exd-heart); outline-offset: 2px; }
.exd-main { display: flex; flex-direction: column; height: 100%; transition: filter .2s; }
.exd-main.is-dimmed { filter: blur(2px) brightness(.93); }
.exd-top { display: flex; align-items: center; gap: 8px; }
.exd-hearts { display: flex; align-items: center; gap: 3px; font-weight: 700; font-size: 1rem; }
.exd-hearts svg { width: 20px; fill: var(--exd-heart); }
.exd-progress { flex: 1; height: 10px; border-radius: 99px; background: var(--exd-pink); overflow: hidden; }
.exd-progress span { display: block; height: 100%; border-radius: 99px; background: linear-gradient(#f06a8a, var(--exd-heart)); transition: width .3s; }
.exd-icon { display: grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; background: none; }
.exd-icon svg { width: 18px; }
.exd-instr { margin: 10px 0 4px; font-size: .9rem; }
.exd-prompt { margin: 0; text-align: center; font-weight: 700; font-size: 1.35rem; }
.exd-prompt:focus { outline: none; }
.exd-art { flex: 1; min-height: 0; display: grid; place-items: center; padding: 6px 0; }
.exd-art img { max-height: 100%; max-width: 78%; object-fit: contain; }
.exd-options { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.exd-option {
  min-height: 46px; padding: 6px; border: 2px solid var(--exd-navy); border-radius: 12px; background: var(--exd-bg);
  box-shadow: 0 3px 0 var(--exd-navy); font-weight: 700; font-size: .98rem; transition: transform .1s, box-shadow .1s;
}
.exd-option:active:not(:disabled) { transform: translateY(3px); box-shadow: none; }
.exd-option:disabled { cursor: default; opacity: .55; }
.exd-option.is-right { opacity: 1; border-color: var(--exd-green); box-shadow: 0 3px 0 var(--exd-green); }
.exd-option.is-wrong { opacity: 1; border-color: var(--exd-red); box-shadow: 0 3px 0 var(--exd-red); }
.exd-sheet { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px 16px 20px; border-radius: 14px 14px 0 0; background: var(--exd-navy); color: #fff; animation: exd-up .25s ease-out; }
@keyframes exd-up { from { transform: translateY(100%); } }
.exd-result { margin: 0; font-size: 1.45rem; font-weight: 700; }
.exd-result.is-right { color: var(--exd-green); }
.exd-result.is-wrong { color: var(--exd-red); }
.exd-meaning { margin: 2px 0 14px; font-size: .9rem; }
.exd-btn { display: block; width: 100%; min-height: 44px; margin-top: 8px; padding: 10px; border: 0; border-radius: 12px; font-weight: 700; font-size: 1rem; text-align: center; text-decoration: none; }
.exd-btn--light { background: var(--exd-bg); color: var(--exd-navy) !important; box-shadow: 0 3px 0 var(--exd-pink); }
.exd-btn--pink { background: var(--exd-pink); color: var(--exd-navy) !important; box-shadow: 0 3px 0 #f2a5a5; }
.exd-btn--primary { background: var(--exd-navy); color: #fff !important; }
.exd-btn--ghost { background: transparent; color: var(--exd-navy) !important; border: 2px solid var(--exd-navy); }
.exd-start { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 6px; }
.exd-start img { margin-bottom: 8px; }
.exd-kicker { margin: 0; color: var(--exd-heart); font-weight: 700; font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; }
.exd-title { margin: 0; font-size: 1.4rem; font-weight: 700; }
.exd-title:focus { outline: none; }
.exd-start p { margin: 0 0 10px; }
.exd-stars { font-size: 2.4rem; letter-spacing: 4px; color: #e7d3d3; }
.exd-stars .on { color: #f6b93b; }
.exd-tip { position: absolute; inset: 0; display: flex; flex-direction: column; padding: 44px 18px 20px; background: var(--exd-navy); color: #fff; }
.exd-tip-head { display: flex; align-items: flex-end; gap: 8px; }
.exd-tip-head h3 { margin: 0; font-size: 1.15rem; }
.exd-tip-head h3:focus { outline: none; }
.exd-tip-body { flex: 1; overflow: auto; margin: 14px 0; font-size: .86rem; }
.exd-tip-body p { margin: 0 0 8px; }
.exd-instr--lg { font-size: 1rem; margin: 12px 0 14px; }
.exd-instr--lg:focus { outline: none; }
.exd-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; }
.exd-card {
  position: relative; min-height: 64px; padding: 8px 10px; border: 2.5px solid var(--exd-navy); border-radius: 14px;
  background: var(--exd-bg); font-weight: 700; font-size: .92rem; line-height: 1.2; transition: background .2s, border-color .2s;
}
.exd-card.is-selected { border: 2.5px dashed #f4c14e; }
.exd-card.is-matched { border-color: transparent; background: #5fae8e; cursor: default; }
.exd-card.is-latest { background: #b3d5c7; }
.exd-card.is-wrong { border-color: var(--exd-red); animation: exd-shake .3s; }
.exd-card:disabled { color: var(--exd-navy); }
.exd-check { position: absolute; top: 5px; right: 5px; width: 20px; color: var(--exd-navy); }
@keyframes exd-shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }
@media (prefers-reduced-motion: reduce) { .exd-card.is-wrong { animation: none; } }
@media (prefers-reduced-motion: reduce) { .exd-sheet { animation: none; } .exd-main, .exd-progress span { transition: none; } }

.phone--demo { width: clamp(260px, min(28vw, calc((100svh - 120px) * .46)), 320px); }

/* Explorito demo: learning-path start screen */
.exd-path { position: absolute; inset: 0; padding: 40px 12px 0; overflow: hidden; }
.exd-path-top { display: flex; gap: 6px; align-items: stretch; }
.exd-chip {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  min-width: 42px; padding: 6px 6px 5px; border-radius: 12px; background: #fff; box-shadow: 0 3px 0 var(--exd-pink);
  font-size: .8rem; line-height: 1.1;
}
.exd-chip b { font-size: .85rem; }
.exd-chip--heart svg { width: 16px; fill: var(--exd-heart); }
.exd-chip--lang { margin-left: auto; padding: 0 12px; font-weight: 700; font-size: .95rem; }
.exd-planet { position: absolute; display: block; width: 48%; }
.exd-planet img { display: block; width: 100%; }
.exd-planet--fund { top: 13%; right: 3%; }
.exd-planet--intro {
  top: 44%; left: 3%; padding: 0; border: 0; background: none; border-radius: 16px;
  filter: drop-shadow(0 0 0 rgba(232, 71, 107, 0)); animation: exd-glow 1.8s ease-in-out infinite;
  transition: transform .15s;
}
.exd-planet--intro:hover { transform: scale(1.03); }
.exd-planet--intro:active { transform: scale(.98); }
@keyframes exd-glow {
  0%, 100% { filter: drop-shadow(0 0 0 rgba(232, 71, 107, 0)); }
  50% { filter: drop-shadow(0 0 10px rgba(232, 71, 107, .85)); }
}
.exd-hint {
  position: absolute; top: 52%; right: 4%; width: 40%; margin: 0; padding: 8px 10px;
  background: var(--exd-heart); color: #fff; border-radius: 12px; font-size: .74rem; line-height: 1.3; text-align: center;
  box-shadow: 0 4px 12px rgba(232, 71, 107, .35); animation: exd-bob 1.8s ease-in-out infinite;
}
.exd-hint::before {
  content: ""; position: absolute; left: -6px; top: 50%; margin-top: -6px;
  border: 6px solid transparent; border-left: 0; border-right-color: var(--exd-heart);
}
@keyframes exd-bob { 50% { transform: translateX(-5px); } }
.exd-path-bottom { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; }
@media (prefers-reduced-motion: reduce) {
  .exd-planet--intro { animation: none; filter: drop-shadow(0 0 8px rgba(232, 71, 107, .8)); }
  .exd-hint { animation: none; }
}

.exd-intro-stars {
  position: absolute; left: 0; right: 0; top: 84.3%; transform: translateY(-50%);
  display: flex; justify-content: center; gap: 7%; font-size: 1.2rem; line-height: 1; pointer-events: none;
}
.exd-intro-stars span { color: transparent; -webkit-text-stroke: 1.5px #fff; }
.exd-intro-stars .on { color: #fbbf24; -webkit-text-stroke: 0; }
.exd-intro-stars .pop { animation: exd-pop .5s cubic-bezier(.3, 1.6, .5, 1) both; }
@keyframes exd-pop { from { transform: scale(0); opacity: 0; } 70% { transform: scale(1.35); } to { transform: scale(1); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .exd-intro-stars .pop { animation: none; } }
.exd-chip img { height: 17px; width: auto; }
.pro-shot { width: 100%; max-width: 520px; height: auto; margin-inline: auto; }

/* Puzzlies demo (mirrors the app's own look) -------------------------------- */
.phone--demo { container-type: inline-size; }
.pzd {
  --pzd-bg: #050a2d; --pzd-card: #15143b; --pzd-line: #2e2852; --pzd-pink: #f7c8f2; --pzd-gold: #f2b61e;
  --pzd-cyan: #3ff3ee; --pzd-purple: #a95cf3; --pzd-t: 60px;
  position: relative; padding: 30px 10px 12px; background: var(--pzd-bg); color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif; font-size: 11.5px; line-height: 1.25;
  user-select: none; -webkit-user-select: none;
}
@supports (width: 1cqw) { .pzd { --pzd-t: clamp(46px, 21cqw, 64px); } }
:where(.pzd) button { font: inherit; color: inherit; cursor: pointer; }
.pzd :focus-visible { outline: 3px solid var(--pzd-cyan); outline-offset: 2px; }
.pzd-home, .pzd-game, .pzd-over { height: 100%; display: flex; flex-direction: column; }

/* home */
.pzd-home-top { display: flex; gap: 7px; align-items: flex-start; margin-top: 8px; }
.pzd-chip {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  width: 22%; aspect-ratio: 1 / 1.13; border: 1px solid var(--pzd-line); border-radius: 14px; background: var(--pzd-card);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 5px 12px rgba(0, 0, 0, .4);
}
.pzd-chip img { height: 34%; width: auto; }
.pzd-chip b { font-size: .92rem; font-weight: 800; }
.pzd-gear { margin-left: auto; width: 9%; }
.pzd-home-mid { flex: 1; display: flex; align-items: center; padding-top: 8%; }
.pzd-scores { width: 100%; border: 1px solid #3a2f5c; border-radius: 16px; background: #13123a; padding: 4px 7px 6px; }
.pzd-row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; text-align: center; padding: 7px 4px; font-size: .92rem; font-weight: 400; }
.pzd-row--head { color: #fff; padding-top: 8px; padding-bottom: 6px; }
.pzd-row.is-best { margin: 2px 0 4px; padding: 10px 4px; background: #241f4b; border: 2px solid #4a3b78; border-bottom-color: #1a173a; border-radius: 13px; }
.pzd-best { padding: 1px 9px; border-radius: 99px; background: linear-gradient(#f9d35a, var(--pzd-gold)); color: #12102e; font-size: .8rem; font-weight: 700; }
.pzd-hint {
  position: relative; align-self: center; margin: 8px 0 9px; padding: 6px 12px; border-radius: 12px;
  background: var(--pzd-purple); font-size: .76rem; text-align: center; animation: pzd-bob 1.8s ease-in-out infinite;
}
.pzd-hint::after { content: ""; position: absolute; left: 50%; bottom: -6px; margin-left: -6px; border: 6px solid transparent; border-bottom: 0; border-top-color: var(--pzd-purple); }
@keyframes pzd-bob { 50% { transform: translateY(-4px); } }
.pzd-btn { display: grid; place-items: center; width: 100%; min-height: 46px; padding: 8px; border: 0; border-radius: 99px; font-weight: 700; font-size: 1.1rem; text-align: center; text-decoration: none; color: #fff !important; }
.pzd-btn--primary { min-height: 46px; font-size: 1.05rem; background: linear-gradient(#c88afa, #a74ef0 55%, #a046ec); box-shadow: inset 0 3px 2px rgba(255, 255, 255, .25), 0 0 18px rgba(167, 78, 240, .5); }
.pzd-new { animation: pzd-glow 1.8s ease-in-out infinite; }
@keyframes pzd-glow { 50% { box-shadow: inset 0 3px 2px rgba(255, 255, 255, .25), 0 0 30px rgba(178, 92, 246, .95); } }
.pzd-btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.pzd-btn--purple, .pzd-btn--cyan { min-height: 42px; background: #050a2d; font-size: .86rem; }
.pzd-btn--purple { border: 2px solid #a95cf3; box-shadow: inset 0 0 14px rgba(169, 92, 243, .55); }
.pzd-btn--cyan { border: 2px solid #5ff1e9; box-shadow: inset 0 0 14px rgba(95, 241, 233, .45); }

/* level: HUD */
.pzd-hud { position: relative; display: flex; justify-content: space-between; align-items: stretch; margin-top: 22px; }
.pzd-card {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  height: 52px; border: 1px solid var(--pzd-line); border-radius: 13px; background: var(--pzd-card);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05), 0 4px 10px rgba(0, 0, 0, .4);
}
.pzd-card:nth-child(1) { width: 15%; }
.pzd-card:nth-child(2) { width: 24%; }
.pzd-card:nth-child(3) { width: 21%; }
.pzd-card b { font-size: 1rem; font-weight: 800; }
.pzd-card:nth-child(1) b { font-weight: 500; }
.pzd-card--obj img { width: 34%; max-width: 24px; }
.pzd-obj { font-size: .85rem; }
.pzd-obj svg { width: 16px; color: #9a9cc6; }
.pzd-card--obj.is-done img { opacity: .4; }
.pzd-pill { position: absolute; top: -7px; left: 50%; transform: translateX(-50%); padding: 1px 6px; border-radius: 99px; background: var(--pzd-pink); color: #1a1240; font-size: .54rem; letter-spacing: .03em; text-transform: uppercase; white-space: nowrap; }
.pzd-pill--gold { background: var(--pzd-gold); }
.pzd-pause { position: absolute; right: 2px; top: -27px; width: 15px; padding: 0; border: 0; background: none; }
.pzd-pause img { width: 100%; }

/* level: board */
.pzd-board { display: grid; gap: calc(var(--pzd-t) * .12); justify-content: center; align-content: center; flex: 1; margin-top: 6px; }
.pzd-cell { position: relative; width: var(--pzd-t); height: var(--pzd-t); padding: 0; }
.pzd-slot { border: 1px solid rgba(63, 243, 238, .4); border-radius: 13px; background: #060a24; box-shadow: 0 0 6px rgba(63, 243, 238, .28), inset 0 0 4px rgba(63, 243, 238, .12); }
.pzd-slot.is-hint { animation: pzd-hintpulse 1s ease-in-out 3; }
@keyframes pzd-hintpulse { 50% { box-shadow: 0 0 22px rgba(246, 193, 30, .95); border-color: var(--pzd-gold); } }
.pzd-tile {
  position: relative; display: grid; place-items: center; width: var(--pzd-t); height: var(--pzd-t); border-radius: 13px;
  background: linear-gradient(160deg, #2fdde0 0%, #48fbf3 45%, #39efec 100%);
  box-shadow: inset 0 0 0 1.5px #86fbf6, inset 0 0 0 4px #2ed6d8, inset 0 0 0 5.5px #9dfcf8, 0 0 6px rgba(63, 243, 238, .35);
}
.pzd-tile img { width: 64%; height: 64%; border-radius: 50%; box-shadow: 0 0 0 2px #3ce2e2; }
.pzd-pegs { position: absolute; display: flex; gap: 2.5px; }
.pzd-pegs i { display: block; background: #eeeafc; border: 1px solid #5f5c80; border-radius: 2px; }
.pzd-pegs--top, .pzd-pegs--bottom { left: 50%; transform: translateX(-50%); }
.pzd-pegs--top { top: -7px; } .pzd-pegs--bottom { bottom: -7px; }
.pzd-pegs--top i, .pzd-pegs--bottom i { width: 3px; height: 9px; }
.pzd-pegs--left, .pzd-pegs--right { top: 50%; transform: translateY(-50%); flex-direction: column; }
.pzd-pegs--left { left: -7px; } .pzd-pegs--right { right: -7px; }
.pzd-pegs--left i, .pzd-pegs--right i { width: 9px; height: 3px; }
.pzd-tile.is-spark .pzd-pegs i { animation: pzd-spark .55s ease-out 2; }
@keyframes pzd-spark { 40% { background: #fff; border-color: #fff; box-shadow: 0 0 6px #fff, 0 0 12px #bff; } }
.pzd-board.is-shine .pzd-tile { overflow: hidden; }
.pzd-board.is-shine .pzd-tile::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, .75) 45%, rgba(255, 255, 255, .15) 52%, transparent 60%);
  background-size: 300% 100%; animation: pzd-shine .9s ease-out forwards;
}
.pzd-board.is-shine .pzd-tile .pzd-pegs { display: none; }
@keyframes pzd-shine { from { background-position: 100% 0; } to { background-position: -50% 0; } }

/* level: tray */
.pzd-tray { display: flex; gap: 6px; overflow-x: auto; margin: 4px -10px 6px; padding: 10px 10px; scrollbar-width: none; }
.pzd-tray::-webkit-scrollbar { display: none; }
.pzd-tray-item { flex: none; padding: calc(var(--pzd-t) * .2); border: 2px solid transparent; border-radius: 4px; background: none; touch-action: pan-x; }
.pzd-tray-item.is-selected { border-color: #a24bf0; box-shadow: 0 0 10px rgba(162, 75, 240, .55), inset 0 0 8px rgba(162, 75, 240, .25); }
.pzd-tray-item.is-ghost .pzd-tile { opacity: .35; filter: saturate(.5) brightness(.55); }
.pzd-floating { z-index: 60; pointer-events: none; margin: 0; filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .5)); }

/* level: footer */
.pzd-foot { display: flex; align-items: flex-end; gap: 6px; }
.pzd-score { position: relative; display: flex; flex-direction: column; width: 20%; min-width: 64px; padding: 11px 8px 7px; border: 1.5px solid var(--pzd-gold); border-radius: 13px; }
.pzd-score-n { font-size: 1rem; font-weight: 800; }
.pzd-lvl { font-size: .9rem; font-weight: 300; }
.pzd-lvl b { font-weight: 800; margin-left: 1px; }
.pzd-bar { display: block; height: 3px; margin-top: 4px; border-radius: 2px; background: #3b3550; overflow: hidden; }
.pzd-bar i { display: block; height: 100%; background: var(--pzd-gold); transition: width .6s ease; }
.pzd-score.is-streak::after {
  content: ""; position: absolute; right: -8px; bottom: -6px; width: 26px; height: 34px; border-right: 3px solid #ff4fd8; border-radius: 0 0 20px 0;
  filter: drop-shadow(0 0 4px #ff4fd8); opacity: 0; animation: pzd-streak .8s ease-out;
}
@keyframes pzd-streak { 0% { opacity: 0; transform: translate(14px, -30px) rotate(-30deg); } 40% { opacity: 1; } 100% { opacity: 0; transform: none; } }
.pzd-chip--sm { width: 17%; aspect-ratio: 1 / .85; margin-left: auto; padding: 4px; gap: 2px; }
.pzd-chip--sm + .pzd-chip--sm { margin-left: 0; width: 15%; }
.pzd-chip--sm img { height: 38%; }
.pzd-chip--sm b { font-size: .9rem; }

/* round over */
.pzd-close { align-self: flex-end; width: 22px; height: 22px; margin-top: 4px; padding: 0; border: 0; background: none; color: #fff; }
.pzd-over h3 { margin: 6px 0 26px; text-align: center; font-size: 1.35rem; font-weight: 800; }
.pzd-over h3:focus { outline: none; }
.pzd-ring {
  position: relative; align-self: center; width: 58%; aspect-ratio: 1; margin-bottom: 18%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
}
.pzd-ring-svg { position: absolute; inset: -4%; width: 108%; height: 108%; overflow: visible; filter: drop-shadow(0 0 6px rgba(160, 160, 255, .55)); }
.pzd-ring span { position: relative; font-size: .9rem; }
.pzd-final { position: relative; font-size: 2.15rem; font-weight: 800; }
.pzd-newbest { position: absolute; top: -9%; z-index: 1; padding: 2px 14px; border-radius: 99px; background: linear-gradient(#f9d35a, var(--pzd-gold)); color: #12102e; font-size: .85rem; font-weight: 800; text-transform: uppercase; }
.pzd-over .pzd-scores { margin-bottom: auto; }
.pzd-over .pzd-btn--primary { margin-top: 12px; }
.pzd-burst { position: absolute; inset: 0; pointer-events: none; }
.pzd-burst i {
  position: absolute; left: 50%; top: 50%; width: 2px; height: 13px; border-radius: 2px; background: #c86bf5; box-shadow: 0 0 5px #e07bff;
  transform: rotate(var(--a)) translateY(0); opacity: 0; animation: pzd-burst 1.1s ease-out forwards;
}
.pzd-burst i:nth-child(3n) { background: #ff6fb5; }
@keyframes pzd-burst { 15% { opacity: 1; } 100% { opacity: 0; transform: rotate(var(--a)) translateY(calc(var(--d) * -1.6)); } }
@media (prefers-reduced-motion: reduce) {
  .pzd-hint, .pzd-new, .pzd-slot.is-hint, .pzd-tile.is-spark .pzd-pegs i, .pzd-board.is-shine .pzd-tile::after, .pzd-score.is-streak::after { animation: none !important; }
}
/* Puzzlies demo: transitions and effects from the app recordings */
.pzd-game { position: relative; }
.pzd-time.is-low { color: #ff4d6d; }
.pzd-dim { display: none; }
.pzd-game .pzd-hud, .pzd-game .pzd-foot { transition: opacity .25s, filter .25s; }
.pzd-slot.is-dim { background: #1c0c32; border-color: rgba(255, 80, 210, .25); box-shadow: none; transition: background .25s; }
.pzd-slot.is-electric { background: #46153f; border-color: transparent; border-radius: 4px; box-shadow: 0 0 5px rgba(255, 70, 210, .3); }
.pzd-zap { position: absolute; inset: -3px; width: calc(100% + 6px); height: calc(100% + 6px); overflow: visible; }
.pzd-zap path { fill: none; stroke: #ffe1f8; stroke-width: 1.1; stroke-linejoin: round; filter: drop-shadow(0 0 1.5px #ff4fd8); }
.pzd-zap path + path { stroke: #ff5fd8; stroke-width: .8; opacity: .75; }
.pzd-leaving, .pzd-sheet { position: absolute; inset: 0; z-index: 20; padding: 30px 10px 12px; background: var(--pzd-bg); }
.pzd-leaving { pointer-events: none; }
.pzd-sheet { z-index: 25; display: flex; flex-direction: column; }
.pzd-sheet .pzd-over { flex: 1; }
.pzd-spark { position: absolute; inset: -4%; pointer-events: none; opacity: 0; }
.pzd-spark::before, .pzd-spark::after { content: ""; position: absolute; right: 0; top: 50%; }
.pzd-spark::before {
  width: 34px; height: 34px; margin: -17px -15px 0 0; border-radius: 50%;
  background: repeating-conic-gradient(#ffe45c 0 4deg, transparent 4deg 22deg);
  -webkit-mask: radial-gradient(circle, transparent 0 3px, #000 4px 15px, transparent 17px); mask: radial-gradient(circle, transparent 0 3px, #000 4px 15px, transparent 17px);
  filter: drop-shadow(0 0 3px #ffd84a);
}
.pzd-spark::after { width: 8px; height: 8px; margin: -4px -2px 0 0; border-radius: 50%; background: #fff; box-shadow: 0 0 6px 2px #ffe45c; }
.pzd-orbit { opacity: 0; filter: blur(.6px); }
.pzd-sheet.is-done .pzd-orbit { opacity: .85; animation: pzd-orbit 2.6s linear infinite; }
@keyframes pzd-orbit { to { stroke-dashoffset: -100; } }
.pzd-ring .pzd-burst { position: absolute; inset: auto; width: 0; height: 0; }
.pzd-burst i { left: 0; top: 0; }
@keyframes pzd-burst { 0% { opacity: 0; transform: rotate(var(--a)) translateY(-4px); } 15% { opacity: 1; } 100% { opacity: 0; transform: rotate(var(--a)) translateY(calc(var(--d) * -1)); } }
@media (prefers-reduced-motion: reduce) { .pzd-sheet.is-done .pzd-orbit { animation: none; opacity: 0; } }

/* Two-phone composition of real app screens (same frame as the demo phones) */
.shot-pair { position: relative; display: flex; justify-content: center; align-items: center; padding: 40px 0 64px; isolation: isolate; }
.shot-pair::before {
  content: ""; position: absolute; z-index: -1; inset: 8% 4%; border-radius: 50%;
  background: radial-gradient(closest-side at 38% 45%, rgba(169, 92, 243, .32), transparent 75%),
              radial-gradient(closest-side at 64% 60%, rgba(63, 243, 238, .24), transparent 75%);
  filter: blur(18px);
}
.shot-pair .phone { width: clamp(170px, 21vw, 240px); }
.shot-pair__back { transform: rotate(-6deg) translate(0, 30px); z-index: 1; }
.shot-pair__front { transform: rotate(5deg) translate(0, -16px); margin-left: -4%; z-index: 2; box-shadow: 0 0 0 2px #000, -18px 28px 50px rgba(0, 0, 0, .35); }
.screen--shot { padding: 0; background: #050a2d; }
.screen--shot img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center top; }
@media (max-width: 420px) { .shot-pair .phone { width: 44vw; } .shot-pair__front { margin-left: -8%; } }

/* Puzzlies: measured layout of the app's home and Round Over screens (828 x 1792 reference) */
.pzd { container-type: inline-size; }
.pzd-home, .pzd-sheet .pzd-over { position: absolute; inset: 0; display: block; }
.pzd-sheet { padding: 0; }
.pzd-home .pzd-home-top { position: absolute; left: 3.9%; right: 3.9%; top: 6.6%; height: 7.4%; margin: 0; display: block; }
.pzd-home .pzd-chip { position: absolute; top: 0; height: 100%; width: 19.6%; aspect-ratio: auto; border-radius: 3.6cqw; gap: .6cqw; }
.pzd-home .pzd-chip:nth-child(1) { left: 0; } .pzd-home .pzd-chip:nth-child(2) { left: 22.4%; }
.pzd-home .pzd-chip img { height: 5.6cqw; }
.pzd-home .pzd-chip b { font-size: 3.7cqw; }
.pzd-home .pzd-gear { position: absolute; right: 0; top: 1.4cqw; width: 5.7cqw; margin: 0; }
.pzd-home-mid { position: absolute; left: 3.9%; right: 3.9%; top: 42.1%; height: 21.4%; padding: 0; display: block; }
.pzd-sheet .pzd-scores { position: absolute; left: 3.9%; right: 3.9%; top: 52.8%; height: 21.4%; margin: 0; }
.pzd-scores { position: relative; height: 100%; padding: 0; border-radius: 4.4cqw; }
.pzd-row { position: absolute; left: 4.2%; right: 4.2%; display: block; height: 14%; padding: 0; font-size: 3.9cqw; transform: translateY(-50%); }
.pzd-row > * { position: absolute; top: 50%; transform: translate(-50%, -50%); white-space: nowrap; }
.pzd-row > :nth-child(1) { left: 25%; } .pzd-row > :nth-child(2) { left: 50%; } .pzd-row > :nth-child(3) { left: 75%; }
.pzd-row--head { top: 13%; padding: 0; }
.pzd-row.is-best { top: 40.7%; height: 27.4%; margin: 0; padding: 0; border-radius: 3.6cqw; }
.pzd-row:nth-child(3) { top: 67.8%; } .pzd-row:nth-child(4) { top: 86.9%; }
.pzd-best { padding: .3cqw 2.4cqw; font-size: 3.7cqw; }
.pzd-home .pzd-new { position: absolute; left: 3.9%; right: 3.9%; width: auto; top: 87.3%; height: 7.1%; min-height: 0; font-size: 4.7cqw; animation: none; }
.pzd-sheet .pzd-close { position: absolute; left: 91.2%; top: 5.7%; width: 4.4cqw; height: 4.4cqw; margin: 0; }
.pzd-sheet .pzd-over h3 { position: absolute; left: 0; right: 0; top: 11.7%; margin: 0; transform: translateY(-50%); font-size: 6.9cqw; }
.pzd-sheet .pzd-ring { position: absolute; left: 22.1%; width: 55.8%; top: calc(34.6% - 27.9cqw); aspect-ratio: 1; margin: 0; display: block; }
.pzd-sheet .pzd-ring-svg { inset: 0; width: 100%; height: 100%; }
.pzd-sheet .pzd-spark { inset: 0; }
.pzd-sheet .pzd-newbest { position: absolute; left: 50%; top: 21.3%; transform: translate(-50%, -50%); padding: .9cqw 4.2cqw; font-size: 4cqw; z-index: 2; }
.pzd-ro-level, .pzd-final, .pzd-ro-your { position: absolute; left: 0; right: 0; text-align: center; transform: translateY(-50%); }
.pzd-ro-level { top: 27.9%; font-size: 4.4cqw; }
.pzd-sheet .pzd-final { top: 33.3%; font-size: 10.6cqw; }
.pzd-ro-your { top: 38.6%; font-size: 4.1cqw; }
.pzd-sheet .pzd-over .pzd-btn--primary { position: absolute; left: 3.9%; right: 3.9%; width: auto; top: 80.7%; height: 7.1%; min-height: 0; margin: 0; font-size: 4.7cqw; }
.pzd-sheet .pzd-btn-row { position: absolute; left: 3.9%; right: 3.9%; top: 89.5%; height: 6.75%; margin: 0; gap: 2.9cqw; }
.pzd-sheet .pzd-btn-row .pzd-btn { height: 100%; min-height: 0; font-size: 4.1cqw; }
.pzd-sheet { overflow: hidden; }
.pzd-over > .pzd-burst { position: absolute; width: 0; height: 0; z-index: 1; pointer-events: none; }
.pzd-over > .pzd-burst i { position: absolute; left: 0; top: 0; width: .5cqw; height: 4.4cqw; margin-left: -.25cqw; border-radius: 1cqw; box-shadow: 0 0 1.2cqw currentColor; opacity: 0;
  transform: rotate(var(--a)) translateY(-2cqw); animation: pzd-fw 1.3s cubic-bezier(.15,.7,.3,1) forwards; }
@keyframes pzd-fw { 0% { opacity: 0; transform: rotate(var(--a)) translateY(-2cqw) scaleY(.4); } 12% { opacity: 1; } 70% { opacity: .9; }
  100% { opacity: 0; transform: rotate(var(--a)) translateY(calc(var(--d) * -1)) scaleY(.7); } }

/* Smooth tile selection: a single frame glides to the chosen tile, which eases up */
.pzd-tray { position: relative; }
.pzd-tray-item, .pzd-tray-item.is-selected { border-color: transparent; box-shadow: none; }
.pzd-tray-item .pzd-tile { transition: transform .28s cubic-bezier(.2,.8,.2,1); }
.pzd-tray-item.is-selected .pzd-tile { transform: scale(1.06); }
.pzd-sel {
  position: absolute; left: 0; top: 0; opacity: 0; pointer-events: none; border: 2px solid #a24bf0; border-radius: 4px;
  box-shadow: 0 0 10px rgba(162, 75, 240, .55), inset 0 0 8px rgba(162, 75, 240, .25);
  transition: transform .3s cubic-bezier(.2,.8,.2,1), width .3s cubic-bezier(.2,.8,.2,1), height .3s, opacity .2s;
}
@media (prefers-reduced-motion: reduce) { .pzd-sel, .pzd-tray-item .pzd-tile { transition: none; } }
.pzd-home, .pzd-sheet { container-type: inline-size; }
.pzd-sheet .pzd-scores { width: auto; }
.pzd-sheet .pzd-close { left: 90.6%; top: 5.4%; width: 5.4cqw; height: 5.4cqw; }

/* Share sheet (shown where the system share sheet can't attach the card) */
.pzd-share { position: absolute; inset: 0; z-index: 40; }
.pzd-share-back { position: absolute; inset: 0; background: rgba(0, 0, 0, .45); }
.pzd-share-panel {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 0 0 4.8cqw; border-radius: 3.6cqw 3.6cqw 0 0; background: #1c1c1e; color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
}
.pzd-share-head { display: flex; align-items: center; gap: 2.4cqw; padding: 3.8cqw 4.8cqw; border-bottom: 1px solid #38383a; }
.pzd-share-head img { width: 9.7cqw; height: 9.7cqw; border: 1px solid #fff; background: #fff; }
.pzd-share-head b { flex: 1; font-size: 3.9cqw; font-weight: 600; }
.pzd-share-x { width: 7.2cqw; height: 7.2cqw; padding: 1.8cqw; border: 0; border-radius: 50%; background: #3a3a3c; color: #c7c7cc; }
.pzd-share-x svg { width: 100%; height: 100%; }
.pzd-share-card { display: block; width: 62%; margin: 4.8cqw auto; border-radius: 3cqw; }
.pzd-share-row {
  display: flex; justify-content: space-between; align-items: center; margin: 0 4.8cqw 2.4cqw; padding: 3.4cqw 4.8cqw; width: calc(100% - 9.6cqw);
  border: 0; border-radius: 2.6cqw; background: #2c2c2e; color: #fff !important; font-size: 3.9cqw; text-decoration: none; text-align: left;
}
.pzd-share-row span { font-size: 4.6cqw; }

/* Puzzlies tiles, measured from the app (rim, groove, face, halo, connection points) */
.pzd-board { position: relative; gap: calc(var(--pzd-t) * .087); }
.pzd-tile {
  border-radius: 13%; overflow: visible;
  background: linear-gradient(180deg, #62f7f7 0, #37e6e8 9%, #33e2e5 90%, #2bd8dd 100%);
  box-shadow: inset 0 0 0 1px #17c3cc, inset 0 0 0 2px #74eef2, 0 0 calc(var(--pzd-t) * .06) rgba(63, 243, 238, .25);
}
.pzd-tile::before {
  content: ""; position: absolute; inset: 7.5%; border-radius: 9%;
  border: 1.5px solid #06a6ae; box-shadow: inset 0 0 0 1px rgba(124, 240, 243, .9);
  background: linear-gradient(100deg, #2ce3e7 0%, #36ecec 55%, #44f6f3 100%);
}
.pzd-board .pzd-tile::before {
  background: linear-gradient(118deg, transparent 60%, rgba(255, 255, 255, .32) 64%, rgba(255, 255, 255, .1) 69%, transparent 73%),
              linear-gradient(100deg, #2ce3e7 0%, #36ecec 55%, #44f6f3 100%);
}
.pzd-tile img { position: relative; z-index: 1; width: 60%; height: 60%; border-radius: 50%; box-shadow: 0 0 0 calc(var(--pzd-t) * .035) #1ae8e8; }
.pzd-pegs { z-index: 2; gap: calc(var(--pzd-t) * .07); transition: opacity .15s; }
.pzd-pegs i { border: 1px solid #262150; border-radius: 1.5px; }
.pzd-pegs--left i, .pzd-pegs--right i { width: calc(var(--pzd-t) * .13); height: calc(var(--pzd-t) * .035 + 1px); background: linear-gradient(90deg, #f0eef4, #c9b9e8); }
.pzd-pegs--top i, .pzd-pegs--bottom i { height: calc(var(--pzd-t) * .13); width: calc(var(--pzd-t) * .035 + 1px); background: linear-gradient(180deg, #f0eef4, #c9b9e8); }
.pzd-pegs--left { left: calc(var(--pzd-t) * -.13); } .pzd-pegs--right { right: calc(var(--pzd-t) * -.13); }
.pzd-pegs--top { top: calc(var(--pzd-t) * -.13); } .pzd-pegs--bottom { bottom: calc(var(--pzd-t) * -.13); }
.pzd-pegs.is-linked { opacity: 0; }
.pzd-bolts { position: absolute; left: 0; top: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 3; }
.pzd-bolt-glow { fill: none; stroke: #8fe6ff; stroke-width: 4; stroke-linejoin: round; opacity: .55; filter: blur(2px); }
.pzd-bolt { fill: none; stroke: #fff; stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; filter: drop-shadow(0 0 1.5px #bdf4ff); }
.pzd-bolt--faint { stroke-width: .8; opacity: .55; }
.pzd-board.is-shine .pzd-bolts { display: none; }
@supports (width: 1cqw) { .pzd { --pzd-t: clamp(46px, 25cqw, 76px); } .pzd-tray .pzd-tile { --pzd-t: calc(clamp(46px, 25cqw, 76px) * .82); } }
.pzd-tile img { width: 64%; height: 64%; box-shadow: 0 0 0 calc(var(--pzd-t) * .04) #1ae8e8; }
.pzd-board .pzd-tile::before {
  background: linear-gradient(128deg, transparent 58%, rgba(255, 255, 255, .2) 63%, rgba(255, 255, 255, .07) 78%, transparent 92%),
              linear-gradient(100deg, #2ce3e7 0%, #36ecec 55%, #44f6f3 100%);
}
/* First visit: logo and name instead of an empty scoreboard; New Game gently glows */
.pzd-welcome { position: absolute; left: 0; right: 0; top: 30%; display: flex; flex-direction: column; align-items: center; gap: 4cqw; }
.pzd-welcome img { width: 38%; filter: drop-shadow(0 4cqw 8cqw rgba(169, 92, 243, .35)); }
.pzd-welcome b { font-size: 8.6cqw; font-weight: 700; letter-spacing: .01em; }
.pzd-home .pzd-new.is-inviting { animation: pzd-invite 2.2s ease-in-out infinite; }
@keyframes pzd-invite { 50% { box-shadow: inset 0 3px 2px rgba(255, 255, 255, .25), 0 0 7cqw rgba(178, 92, 246, .85); } }
@media (prefers-reduced-motion: reduce) { .pzd-home .pzd-new.is-inviting { animation: none; } }
.pzd-pause { width: 5.4cqw; height: 5.4cqw; top: -30px; color: #fff; } .pzd-pause svg { width: 100%; height: 100%; display: block; }
/* Welcome logo: no glow, just soft twinkling sparkles */
.pzd-welcome img { filter: none; width: 100%; display: block; }
.pzd-logo { position: relative; width: 38%; display: block; }
.pzd-twinkle {
  position: absolute; width: 4.2cqw; height: 4.2cqw; opacity: 0; pointer-events: none;
  background: #fff; clip-path: polygon(50% 0, 60% 40%, 100% 50%, 60% 60%, 50% 100%, 40% 60%, 0 50%, 40% 40%);
  filter: drop-shadow(0 0 .6cqw rgba(255, 255, 255, .8)); animation: pzd-twinkle 3.2s ease-in-out infinite;
}
.pzd-twinkle:nth-of-type(1) { left: 2%; top: 4%; animation-delay: 0s; }
.pzd-twinkle:nth-of-type(2) { right: -4%; top: 30%; width: 3cqw; height: 3cqw; animation-delay: .7s; background: #c9f9ff; }
.pzd-twinkle:nth-of-type(3) { left: 44%; top: -10%; width: 2.6cqw; height: 2.6cqw; animation-delay: 1.5s; background: #f3dcff; }
.pzd-twinkle:nth-of-type(4) { left: -8%; bottom: 18%; width: 3cqw; height: 3cqw; animation-delay: 2.2s; background: #ffe9a8; }
.pzd-twinkle:nth-of-type(5) { right: 6%; bottom: -6%; animation-delay: 1.1s; background: #ffd1ef; }
@keyframes pzd-twinkle { 0%, 100% { opacity: 0; transform: scale(.2) rotate(0deg); } 18% { opacity: .95; transform: scale(1) rotate(25deg); } 36% { opacity: 0; transform: scale(.3) rotate(45deg); } }
@media (prefers-reduced-motion: reduce) { .pzd-twinkle { display: none; } }

/* Level screen laid out in the app's measured proportions (828 x 1792 reference) */
.pzd-game { position: absolute; inset: 0; display: block; container-type: inline-size; }
.pzd-game .pzd-hud { position: absolute; left: 4.1%; right: 4.1%; top: 8.1%; height: 9.6%; margin: 0; display: block; }
.pzd-game .pzd-card { position: absolute; top: 1.8cqw; bottom: 0; width: auto; height: auto; border-radius: 3.4cqw; gap: .4cqw; padding: 1.6cqw 0 0; }
.pzd-game .pzd-card:nth-child(1) { left: 0; width: 15.25%; }
.pzd-game .pzd-card:nth-child(2) { left: 37.1%; width: 25.8%; }
.pzd-game .pzd-card:nth-child(3) { left: 77.45%; width: 22.55%; }
.pzd-game .pzd-pill { top: -1.8cqw; padding: 0 1.7cqw; height: 3.6cqw; line-height: 3.6cqw; font-size: 2.3cqw; }
.pzd-game .pzd-card b { font-size: 4.2cqw; }
.pzd-game .pzd-card:nth-child(1) b { font-size: 4cqw; font-weight: 500; }
.pzd-game .pzd-card--obj img { width: 6.4cqw; max-width: none; }
.pzd-game .pzd-obj { font-size: 3.9cqw; }
.pzd-game .pzd-obj svg { width: 4.4cqw; }
.pzd-game .pzd-pause { position: absolute; right: 4.1%; top: 5.4%; width: 4.4cqw; height: 4.4cqw; }
.pzd-game .pzd-board { position: absolute; left: 0; right: 0; top: 19%; bottom: 30%; margin: 0; }
.pzd-game .pzd-tray { position: absolute; left: 0; right: 0; top: 70.5%; margin: 0; padding: 2.4cqw 4cqw; gap: 3.4cqw; }
.pzd-game .pzd-tray-item { padding: 3.6cqw; }
.pzd-game .pzd-foot { position: absolute; left: 4%; top: 88.6%; bottom: 2.8%; width: 19.7%; display: block; }
.pzd-game .pzd-score { position: absolute; inset: 0; width: auto; min-width: 0; padding: 2.6cqw 2.4cqw 1.6cqw; border-radius: 3.4cqw; justify-content: center; }
.pzd-game .pzd-score .pzd-pill { font-size: 2.3cqw; }
.pzd-game .pzd-score-n { font-size: 4.3cqw; }
.pzd-game .pzd-lvl { font-size: 4.3cqw; }
.pzd-game .pzd-bar { height: .8cqw; margin-top: 1cqw; }
/* Connection points as in the app: solid bright bars touching the tile edge, 13% apart */
.pzd-pegs { --pw: max(2.6px, calc(var(--pzd-t) * .04)); gap: calc(var(--pzd-t) * .13 - var(--pw)); }
.pzd-pegs i { border: 0; border-radius: 1.5px; box-shadow: 0 0 0 .6px rgba(10, 8, 40, .9); }
.pzd-pegs--left i, .pzd-pegs--right i { width: calc(var(--pzd-t) * .14); height: var(--pw); background: linear-gradient(90deg, #f6f4fa, #d6c8ef); }
.pzd-pegs--top i, .pzd-pegs--bottom i { height: calc(var(--pzd-t) * .14); width: var(--pw); background: linear-gradient(180deg, #f6f4fa, #d6c8ef); }
.pzd-pegs--left { left: calc(var(--pzd-t) * -.14 + 1px); } .pzd-pegs--right { right: calc(var(--pzd-t) * -.14 + 1px); }
.pzd-pegs--top { top: calc(var(--pzd-t) * -.14 + 1px); } .pzd-pegs--bottom { bottom: calc(var(--pzd-t) * -.14 + 1px); }

/* The app's own tile artwork and connector (pin with socket base, seated on the tile edge) */
.pzd-tile { background: url("puzzlies-demo/tile.webp") center / 100% 100% no-repeat; box-shadow: none; border-radius: 15%; }
.pzd-tile::before { display: none; }
.pzd-board .pzd-tile::before {
  display: block; inset: 0; border: 0; border-radius: 15%; box-shadow: none; pointer-events: none;
  background: linear-gradient(122deg, transparent 56%, rgba(255, 255, 255, .26) 61%, rgba(255, 255, 255, .55) 63%, rgba(255, 255, 255, .12) 67%, transparent 74%);
}
.pzd-tile img { box-shadow: 0 0 0 calc(var(--pzd-t) * .035) #22e6e8; }
.pzd-pegs { --len: calc(var(--pzd-t) * .17); --thk: calc(var(--pzd-t) * .0666); gap: calc(var(--pzd-t) * .13 - var(--thk)); }
.pzd-pegs i { border: 0; border-radius: 0; box-shadow: none; background: none center / 100% 100% no-repeat; }
.pzd-pegs--top i { width: var(--thk); height: var(--len); background-image: url("puzzlies-demo/connector-up.svg"); }
.pzd-pegs--bottom i { width: var(--thk); height: var(--len); background-image: url("puzzlies-demo/connector-down.svg"); }
.pzd-pegs--left i { width: var(--len); height: var(--thk); background-image: url("puzzlies-demo/connector-left.svg"); }
.pzd-pegs--right i { width: var(--len); height: var(--thk); background-image: url("puzzlies-demo/connector-right.svg"); }
.pzd-pegs--top { top: calc(var(--pzd-t) * -.151); } .pzd-pegs--bottom { bottom: calc(var(--pzd-t) * -.151); }
.pzd-pegs--left { left: calc(var(--pzd-t) * -.151); } .pzd-pegs--right { right: calc(var(--pzd-t) * -.151); }
.pzd-tile.is-spark .pzd-pegs i { animation: none; }
/* Spark where points meet */
.pzd-flash {
  position: absolute; z-index: 4; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, #fff 0 22%, rgba(190, 240, 255, .9) 32%, rgba(120, 220, 255, .35) 55%, transparent 70%);
  animation: pzd-flash .55s ease-out both;
}
.pzd-flash::before { content: ""; position: absolute; inset: -9px; background: repeating-conic-gradient(rgba(255, 255, 255, .95) 0 5deg, transparent 5deg 40deg);
  -webkit-mask: radial-gradient(circle, transparent 0 35%, #000 40% 60%, transparent 72%); mask: radial-gradient(circle, transparent 0 35%, #000 40% 60%, transparent 72%); }
@keyframes pzd-flash { 0% { transform: scale(.2); opacity: 0; } 25% { transform: scale(1.15); opacity: 1; } 100% { transform: scale(1.7); opacity: 0; } }
/* HUD cards placed by role, so levels without objectives keep Time on the right */
.pzd-game .pzd-card--obj { left: 37.1% !important; width: 25.8% !important; }
.pzd-game .pzd-card--time { left: 77.45% !important; width: 22.55% !important; }
/* Close (x) where the app's pause button sits: right edge 4.1%, centred 6.45% down the screen */
.pzd-game .pzd-pause { position: absolute; right: 0; top: calc(-17.2% - 2.2cqw); width: 4.4cqw; height: 4.4cqw; }
/* Empty slots measured from the app: 90% of a tile, double cyan outline, soft outer glow */
.pzd-slot { background: none; border: 0; box-shadow: none; border-radius: 0; }
.pzd-slot::before {
  content: ""; position: absolute; inset: 5%; border-radius: 15.5%; background: #090b31;
  border: 1px solid #0b8f9c;
  box-shadow: 0 0 calc(var(--pzd-t) * .05) rgba(25, 150, 185, .55), inset 0 0 0 1.5px #080a2c, inset 0 0 0 2.5px rgba(26, 52, 82, .9);
}
.pzd-slot.is-hint::before { border-color: var(--pzd-gold); }
.pzd-slot.is-dim::before { background: #1c0c32; border-color: rgba(255, 80, 210, .25); box-shadow: none; }
.pzd-slot.is-electric::before { background: #46153f; border-color: transparent; }
/* Connection pins stay visible; the bolts crackle across them */
.pzd-pegs.is-linked, .pzd-pegs.is-on { opacity: 1; }
/* Wrong move: red sparks and a red pulse on the tile */
.pzd-bolts--wrong .pzd-bolt-glow { stroke: #ff3b5c; opacity: .75; }
.pzd-bolts--wrong .pzd-bolt { stroke: #ffd0d8; filter: drop-shadow(0 0 2px #ff2d55); }
.pzd-cell.is-wrong .pzd-tile::after {
  content: ""; position: absolute; inset: 0; border-radius: 15%; pointer-events: none;
  background: rgba(255, 45, 85, .35); box-shadow: 0 0 calc(var(--pzd-t) * .2) rgba(255, 45, 85, .7);
  animation: pzd-wrong .5s ease-in-out 3 alternate;
}
@keyframes pzd-wrong { from { opacity: .3; } to { opacity: 1; } }

/* Connected tiles glow softly; a brighter pulse when the connection is made */
.pzd-board .pzd-cell.is-glow .pzd-tile { filter: drop-shadow(0 0 calc(var(--pzd-t) * .07) rgba(63, 243, 238, .55)); transition: filter .3s; }
.pzd-board .pzd-cell.is-glow-pulse .pzd-tile { animation: pzd-glowpulse .7s ease-out; }
@keyframes pzd-glowpulse {
  0% { filter: drop-shadow(0 0 0 rgba(63, 243, 238, 0)); }
  30% { filter: drop-shadow(0 0 calc(var(--pzd-t) * .2) rgba(150, 255, 250, .95)) brightness(1.12); }
  100% { filter: drop-shadow(0 0 calc(var(--pzd-t) * .07) rgba(63, 243, 238, .55)); }
}
/* Wrong move: everything turns red and crackles */
.pzd-board.is-wrong-all .pzd-tile { filter: drop-shadow(0 0 calc(var(--pzd-t) * .12) rgba(255, 45, 85, .85)) !important; animation: none; }
.pzd-board.is-wrong-all .pzd-tile::after {
  content: ""; position: absolute; inset: 0; z-index: 2; border-radius: 15%; pointer-events: none;
  background: linear-gradient(160deg, rgba(255, 70, 100, .78), rgba(220, 20, 60, .7)); animation: pzd-wrong .35s ease-in-out infinite alternate;
}
.pzd-board.is-wrong-all .pzd-slot::before { background: #3a0a1c; border-color: transparent; box-shadow: 0 0 calc(var(--pzd-t) * .08) rgba(255, 45, 85, .5); }
.pzd-board.is-wrong-all .pzd-bolts:not(.pzd-bolts--wrong) .pzd-bolt-glow { stroke: #ff3b5c; }
.pzd-board.is-wrong-all .pzd-bolts:not(.pzd-bolts--wrong) .pzd-bolt { stroke: #ffd0d8; }
.pzd-zap--red path { stroke: #ffd6dd; filter: drop-shadow(0 0 1.5px #ff2d55) drop-shadow(0 0 3px #ff2d55); }
.pzd-zap--red path + path { stroke: #ff3b5c; }
.pzd-cell .pzd-zap { z-index: 3; }
@media (prefers-reduced-motion: reduce) { .pzd-board .pzd-cell.is-glow-pulse .pzd-tile, .pzd-board.is-wrong-all .pzd-tile::after { animation: none; } }

/* Feature illustrations */
.feature-art { flex: none; width: 64px; height: 64px; }
/* App pages: less space above the intro */
.app-hero { padding-top: clamp(4px, 1.5vw, 16px); }
.app-hero + .section { padding-top: clamp(16px, 3vw, 32px); }
/* Our apps cards: bullet text lines up under the app title */
.card ul { margin-left: 84px; padding-left: 18px; }
@media (max-width: 420px) { .card ul { margin-left: 0; padding-left: 20px; } }
/* Wrong move in the app's own magenta-red (sampled from its electric frames) */
.pzd-bolts--wrong .pzd-bolt-glow, .pzd-board.is-wrong-all .pzd-bolts:not(.pzd-bolts--wrong) .pzd-bolt-glow { stroke: #e0248f; }
.pzd-bolts--wrong .pzd-bolt, .pzd-board.is-wrong-all .pzd-bolts:not(.pzd-bolts--wrong) .pzd-bolt { stroke: #ffd2f2; filter: drop-shadow(0 0 2px #ff4fc8); }
.pzd-cell.is-wrong .pzd-tile::after { background: rgba(200, 32, 136, .35); box-shadow: 0 0 calc(var(--pzd-t) * .2) rgba(224, 36, 143, .7); }
.pzd-board.is-wrong-all .pzd-tile { filter: drop-shadow(0 0 calc(var(--pzd-t) * .12) rgba(224, 36, 143, .85)) !important; }
.pzd-board.is-wrong-all .pzd-tile::after { background: linear-gradient(160deg, rgba(232, 70, 170, .78), rgba(180, 24, 120, .72)); }
.pzd-board.is-wrong-all .pzd-slot::before { background: #341044; box-shadow: 0 0 calc(var(--pzd-t) * .08) rgba(224, 36, 143, .5); }
.pzd-zap--red path { stroke: #f8a0e0; filter: drop-shadow(0 0 1.5px #ff4fd8) drop-shadow(0 0 3px #c82088); }
.pzd-zap--red path + path { stroke: #e0248f; }
/* Centre the intro line under section titles */
.section-head .lead { margin-inline: auto; }
/* App pages: intro text starts at the top beside the phone, no empty band above it */
.app-hero + .section.split { align-items: start; }
.app-hero + .section.split > div:first-child { padding-top: clamp(0px, 4vw, 48px); }
@media (max-width: 860px) { .app-hero + .section.split > div:first-child { padding-top: 0; } }
/* Primary buttons: softer, tighter glow */
.pzd-btn--primary { box-shadow: inset 0 2px 1px rgba(255, 255, 255, .22), 0 0 6px rgba(167, 78, 240, .3); }
@keyframes pzd-invite { 50% { box-shadow: inset 0 2px 1px rgba(255, 255, 255, .22), 0 0 2.4cqw rgba(178, 92, 246, .45); } }
/* Discreet "this is playable" cue on the first-visit home screen */
.pzd-tap {
  position: absolute; left: 0; right: 0; top: 81.4%; margin: 0; display: flex; align-items: center; justify-content: center; gap: 1.6cqw;
  font-size: 4.2cqw; font-weight: 500; letter-spacing: .02em; color: #fff; text-shadow: 0 0 2.4cqw rgba(201, 160, 255, .55); animation: pzd-tapfade 3s ease-in-out infinite;
}
.pzd-tap-hand {
  width: 4.4cqw; height: 4.4cqw; border-radius: 50%; border: 2px solid #d4b0ff;
  box-shadow: 0 0 0 0 rgba(201, 160, 255, .5); animation: pzd-tapdot 1.8s ease-out infinite;
}
@keyframes pzd-tapdot { 0% { box-shadow: 0 0 0 0 rgba(201, 160, 255, .55); } 70%, 100% { box-shadow: 0 0 0 2.2cqw rgba(201, 160, 255, 0); } }
@keyframes pzd-tapfade { 0%, 100% { opacity: .85; } 50% { opacity: 1; } }
.pzd-new { position: absolute; overflow: hidden; }
.pzd-new .pzd-ripple { position: absolute; left: 50%; top: 50%; width: 8cqw; height: 8cqw; margin: -4cqw 0 0 -4cqw; border-radius: 50%; pointer-events: none; opacity: 0; }
.pzd-new.is-inviting .pzd-ripple { background: radial-gradient(circle, rgba(255, 255, 255, .45), rgba(255, 255, 255, 0) 70%); animation: pzd-ripple 2.4s ease-out infinite 1s; }
@keyframes pzd-ripple { 0% { transform: scale(.2); opacity: .9; } 60%, 100% { transform: scale(4.5); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .pzd-tap, .pzd-tap-hand, .pzd-new .pzd-ripple { animation: none; } }
/* Explorito "Tap Introductions" bubble: salmon with navy text (6.4:1, passes WCAG AA) */
.exd-hint { background: #fa8072; color: #172136; box-shadow: 0 4px 12px rgba(250, 128, 114, .35); }
.exd-hint b { color: #172136; }
.exd-hint::before { border-right-color: #fa8072; }

/* Light / dark toggle */
.site-header .wrap { justify-content: flex-start; }
.site-header .logo { margin-right: auto; }
.site-nav { order: 1; }
.theme-toggle { order: 2; }
.nav-toggle { order: 3; }
.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 40px; height: 40px; padding: 0; border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface); color: var(--ink); cursor: pointer;
  transition: border-color .2s, transform .2s;
}
.theme-toggle:hover { border-color: var(--muted); }
.theme-toggle:active { transform: scale(.94); }
.theme-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.theme-toggle svg { width: 19px; height: 19px; }
.theme-toggle .i-moon { fill: currentColor; }
.theme-toggle .i-sun { fill: currentColor; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; display: none; }
:root[data-theme="dark"] .theme-toggle .i-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .i-sun { display: block; }
@media (max-width: 720px) { .theme-toggle { width: 44px; height: 44px; border-radius: 12px; } }

/* Dark theme: keep the navy logo discs and dark illustration details distinct from the page */
/* (app badge rings: see "App badges" below) */
:root[data-theme="dark"] .feature-art { filter: drop-shadow(0 0 1px rgba(255, 255, 255, .55)) drop-shadow(0 0 6px rgba(255, 255, 255, .08)); }

/* App pages: logo, name and tagline left-aligned above the intro, beside the demo */
.section.app-top { padding-top: clamp(12px, 3vw, 32px); align-items: center; }
.app-hero-id { display: flex; align-items: center; gap: 16px; margin-bottom: clamp(20px, 3vw, 32px); }
.app-hero-id img { width: 72px; height: 72px; flex: none; }
.app-hero-id h1 { margin: 0; font-size: clamp(1.6rem, 1.3rem + 1vw, 2rem); font-weight: 600; line-height: 1.15; }
.app-hero-id p { margin: 2px 0 0; font-weight: 500; font-size: clamp(1rem, .95rem + .3vw, 1.15rem); }


/* Readable type: body copy at least 16px (1rem), small print at least 14px, all in rem so browser text-size settings apply */
.nav-list { font-size: 1rem; }
.footer-links { font-size: 1rem; }
.copyright { font-size: .875rem; }
.btn { font-size: 1rem; }
.banner a { font-size: 1rem; }
.card-head p { font-size: 1rem; }
.card ul { font-size: 1rem; line-height: 1.6; }
.feature p { font-size: 1rem; line-height: 1.6; }
.eyebrow { font-size: .875rem; }
.text-links { font-size: 1rem; }
.mini-services ul, .mini-services .checklist li { font-size: 1rem; }
.prose h3 { font-size: 1.05rem; }
.appstore small { font-size: .7rem; }
p, li, address, h1, h2, h3 { overflow-wrap: break-word; }
.notfound-code { margin: 0; font-size: clamp(3rem, 2rem + 6vw, 6rem); font-weight: 600; line-height: 1.1; }
.notfound .notfound-code + h1 { font-size: clamp(1.4rem, 1.2rem + 1vw, 1.9rem); font-weight: 500; margin-top: 4px; }

/* Explorito path: scale the top bar with the phone so the language chip never meets the planet's crown */
.exd-path { padding: 12.5cqw 3.75cqw 0; }
.exd-path-top { gap: 1.9cqw; }
.exd-path .exd-chip { min-width: 13.1cqw; padding: 1.9cqw 1.9cqw 1.6cqw; border-radius: 3.75cqw; box-shadow: 0 .95cqw 0 var(--exd-pink); font-size: 4cqw; }
.exd-path .exd-chip b { font-size: 4.25cqw; }
.exd-path .exd-chip img { height: 5.3cqw; }
.exd-path .exd-chip--heart svg { width: 5cqw; }
.exd-path .exd-chip--lang { padding: 0 3.75cqw; font-size: 4.75cqw; }
.exd-planet--fund { top: 14.2%; }

/* Explorito: "Tap to try" cue in the same style as the Puzzlies demo (ping ring + text, tap ripple on the target) */
.exd-hint { display: flex; align-items: center; justify-content: center; gap: 1.6cqw; padding: 2.6cqw 2.8cqw; font-size: 3.9cqw; font-weight: 600; line-height: 1.25; text-align: left; }
.exd-tap-ring {
  flex: none; width: 4.2cqw; height: 4.2cqw; border-radius: 50%; border: 2px solid #172136;
  box-shadow: 0 0 0 0 rgba(23, 33, 54, .5); animation: exd-tapdot 1.8s ease-out infinite;
}
@keyframes exd-tapdot { 0% { box-shadow: 0 0 0 0 rgba(23, 33, 54, .5); } 70%, 100% { box-shadow: 0 0 0 2.2cqw rgba(23, 33, 54, 0); } }
.exd-planet--intro { overflow: visible; }
.exd-planet--intro .exd-ripple {
  position: absolute; left: 50%; top: 36%; width: 10cqw; height: 10cqw; margin: -5cqw 0 0 -5cqw; border-radius: 50%;
  pointer-events: none; opacity: 0; background: radial-gradient(circle, rgba(255, 255, 255, .6), rgba(255, 255, 255, 0) 70%);
  animation: exd-ripple 2.4s ease-out infinite 1s;
}
@keyframes exd-ripple { 0% { transform: scale(.2); opacity: .9; } 60%, 100% { transform: scale(3.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .exd-tap-ring, .exd-planet--intro .exd-ripple { animation: none; } }
:root[data-theme="dark"] .banner { border-block: 1px solid var(--line); }

/* Mobile polish */
@media (max-width: 560px) {
  .card-head { flex-direction: row; align-items: center; gap: 14px; }
  .card-head img { width: 60px; height: 60px; }
  .card ul { margin-left: 0; padding-left: 20px; }
  .app-hero-id { gap: 14px; }
  .app-hero-id img { width: 60px; height: 60px; }
}
.app-hero-id p { line-height: 1.35; }
.exd-intro-stars { font-size: 6cqw; }
.banner a { display: inline-block; padding: 10px 6px; }
.policy-contact a { display: inline-block; padding-block: 6px; }
.policy-contact { line-height: 1.5; }
.card-head p { line-height: 1.45; }
@media (max-width: 560px) { .card-head { align-items: flex-start; } .card-head img { margin-top: 4px; } }

/* PRO list uses the same outline tick as the home page */
.checklist svg { width: 18px; opacity: .75; }

/* Explorito path: planets a touch larger and lower to tighten the empty space */
.exd-planet { width: 52%; }
.exd-planet--fund { top: 15%; }
.exd-planet--intro { top: 47.5%; }
.exd-hint { top: 57%; }

/* Puzzlies home cue: more visible */
.pzd-tap { font-size: 4.6cqw; font-weight: 600; top: 80.6%; animation: none; opacity: 1; text-shadow: 0 0 3cqw rgba(201, 160, 255, .8); }
.pzd-tap-hand { width: 4.8cqw; height: 4.8cqw; border-width: 2.5px; border-color: #e2c8ff; }

/* Explorito: three stars on Introductions earns the crown, as on Fundamentals */
.exd-planet .exd-crown { position: absolute; z-index: 1; left: 36.8%; top: -10.7%; width: 26.3%; height: auto; pointer-events: none; }
.exd-planet .exd-crown.is-new { animation: exd-crown-in .7s cubic-bezier(.3, 1.5, .5, 1) .9s both; }
@keyframes exd-crown-in {
  0% { opacity: 0; transform: translateY(-60%) scale(.4) rotate(-12deg); }
  70% { opacity: 1; }
  100% { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) { .exd-planet .exd-crown.is-new { animation: none; } }

/* Real screenshots in phone frames: the screen takes the screenshots' exact shape (828 x 1792), so
   nothing is trimmed, and corner rounding is about 10% of the width (like the iPhone's), clear of the UI */
.shot-pair .phone { aspect-ratio: auto; border-radius: 32px; }
.screen--shot { height: auto; aspect-ratio: 828 / 1792; border-radius: 10% / 4.62%; }
@media (max-width: 420px) { .shot-pair .phone { border-radius: 26px; } }

/* Designed for different displays: real gameplay screenshots in device frames, never cropped */
.devices { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-end; gap: 40px clamp(32px, 4vw, 56px); }
.device-group { --h: clamp(220px, 22vw, 290px); display: flex; flex-direction: column; align-items: center; min-width: 0; }
.device-group h3 { margin-bottom: 18px; font-size: 1.15rem; font-weight: 500; }
.device-row { display: flex; align-items: flex-start; gap: clamp(14px, 2vw, 24px); }
.device { margin: 0; display: flex; flex-direction: column; align-items: center; }
.device-screen {
  /* the height and shape apply to the screen itself; the bezel sits outside it */
  position: relative; box-sizing: content-box; height: var(--h); aspect-ratio: var(--ratio); overflow: hidden;
  padding: 5px; border: 6px solid #666; border-radius: 30px; background: #030303;
  box-shadow: 0 0 0 2px #000, 0 24px 48px rgba(0, 0, 0, .22);
}
.device--ipad .device-screen { border-radius: 24px; }
.device-screen > img { display: block; width: 100%; height: 100%; object-fit: contain; border-radius: 20px; background: #050a2d; }
.device--ipad .device-screen > img { border-radius: 14px; }
/* Until its screenshot is added, a frame shows the board colour with a faint Puzzlies mark */
.device-screen:not(:has(> img))::after {
  content: ""; position: absolute; inset: 5px; border-radius: 20px;
  background: linear-gradient(rgba(5, 10, 45, .62), rgba(5, 10, 45, .62)), url("puzzlies.svg") center / min(26%, 56px) auto no-repeat, #050a2d;
}
.device--ipad .device-screen:not(:has(> img))::after { border-radius: 14px; }
.device figcaption { margin-top: 12px; color: var(--muted); font-size: .9375rem; font-weight: 500; text-align: center; white-space: nowrap; }
@media (max-width: 720px) {
  .devices { flex-direction: column; align-items: center; }
  /* phone: each group fills the width, frames keep their proportions */
  /* available width minus the gap and two 22 px bezels, shared by both screens' widths (466/678 + 951/669 of the height) */
  .device-group--duo { --h: min(300px, calc((100vw - 2 * var(--gutter) - 16px - 44px) / 2.109)); }   /* 466/678 + 951/669 */
  .device-group--ipad .device-screen { height: min(300px, calc((100vw - 2 * var(--gutter) - 22px) / (var(--ratio)))); }   /* full width at the screenshot's own shape */
  .device-row { gap: 16px; }
  .device figcaption { font-size: .875rem; white-space: normal; }   /* may wrap under the narrow compact screen */
}
/* narrow phones: the two Duo screens stack, both at the same height, as large as the width allows */
@media (max-width: 520px) {
  .device-group--duo .device-row { flex-direction: column; align-items: center; gap: 24px; }
  .device-group--duo { --h: min(260px, calc((100vw - 2 * var(--gutter) - 22px) / 1.4215)); }
}

/* Home hero: two-line headline, supporting line and two buttons.
   The banner is near-black in both themes, so it uses the lighter teal (#2bb3a6):
   7.6:1 as text, 6.4:1 behind the dark button label, and a 3:1+ outline. */
.banner { padding: clamp(64px, 11vw, 128px) var(--gutter) clamp(60px, 10vw, 116px); }
.banner h1 { font-weight: 600; font-size: min(clamp(2.5rem, 1.45rem + 4.6vw, 4.5rem), calc((100vw - 2 * var(--gutter)) / 10.4)); line-height: 1.06; letter-spacing: -.025em; }   /* each sentence is about 10 em wide: on phones the size follows the screen width so it stays on one line */
.banner h1 span { display: block; }
.banner h1 .banner-accent { color: #2bb3a6; }
.banner p.banner-lead { max-width: 44ch; margin: clamp(18px, 2.4vw, 26px) auto clamp(26px, 3.4vw, 36px); font-size: clamp(1.0625rem, 1rem + .4vw, 1.3rem); line-height: 1.6; opacity: .88; text-wrap: balance; }
.banner-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 14px; }
.banner a.btn-hero {
  display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 12px 28px;
  border: 2px solid #2bb3a6; border-radius: 12px; font-size: 1rem; font-weight: 600; text-decoration: none;
  transition: background .2s, border-color .2s, transform .2s;
}
.banner a.btn-hero--filled { background: #2bb3a6; color: #062a27; }
.banner a.btn-hero--filled:hover { background: #3fc9bc; border-color: #3fc9bc; color: #062a27; transform: translateY(-1px); }
.banner a.btn-hero--outline { background: transparent; color: #fff; }
.banner a.btn-hero--outline:hover { background: rgba(43, 179, 166, .16); color: #fff; transform: translateY(-1px); }
.banner a.btn-hero:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
@media (max-width: 420px) { .banner-actions { flex-direction: column; align-items: stretch; max-width: 320px; margin-inline: auto; } }
@media (prefers-reduced-motion: reduce) { .banner a.btn-hero { transition: none; } .banner a.btn-hero:hover { transform: none; } }

/* Client work: teal line icons in place of emoji */
.mini-services h3 .mini-icon { width: 26px; height: 26px; flex: none; color: var(--accent); }

/* Home: the Our Apps heading lines up on the left like Client work and Our Story */
#apps .section-head { text-align: left; }
#apps .section-head .lead { margin-inline: 0; }

/* Home: full-width bands (Work with us on white, Contact on the dark hero colour) */
.band { margin-top: var(--section); padding-block: var(--section); }
.band--surface { background: var(--surface); border-block: 1px solid var(--line); }
.band--dark { background: var(--banner); color: var(--banner-ink); }
:root[data-theme="dark"] .band--dark { border-block: 1px solid var(--line); }

/* Work with us: intro and button on the left, the three service groups on the right */
.work { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 88px); align-items: start; }
.work-intro .lead { margin-bottom: 24px; }
.svc + .svc, .work-note { margin-top: 22px; padding-top: 22px; border-top: 1px solid var(--line); }
.svc h3 { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; font-size: 1.0625rem; font-weight: 600; }
.svc .mini-icon { width: 22px; height: 22px; flex: none; color: var(--accent); }
.dots { list-style: none; margin: 0; padding: 0; color: var(--muted); font-size: 1rem; line-height: 1.55; }
.dots li { position: relative; padding-left: 18px; }
.dots li + li { margin-top: 6px; }
.dots li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.work-note { margin-bottom: 0; color: var(--muted); font-size: .9375rem; line-height: 1.6; }
@media (max-width: 860px) { .work { grid-template-columns: 1fr; gap: 36px; } }

/* Our Story: the first paragraph is the statement, the second supports it */
.story-lead { max-width: 52ch; margin-bottom: 14px; color: var(--ink); font-size: clamp(1.15rem, 1.04rem + .5vw, 1.4rem); line-height: 1.55; }

/* Contact: dark band that bookends the hero, with the email address as its button */
.band--dark .section-title { color: var(--banner-ink); }
.band--dark .lead { max-width: 42ch; margin: 0 auto 28px; color: rgba(255, 255, 255, .86); text-wrap: balance; }
.band--dark a.btn-hero {
  display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 12px 28px;
  border: 2px solid #2bb3a6; border-radius: 12px; background: #2bb3a6; color: #062a27;
  font-size: 1rem; font-weight: 600; text-decoration: none; overflow-wrap: anywhere; transition: background .2s, border-color .2s, transform .2s;
}
.band--dark a.btn-hero:hover { background: #3fc9bc; border-color: #3fc9bc; color: #062a27; transform: translateY(-1px); }
.band--dark a.btn-hero:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .band--dark a.btn-hero { transition: none; } .band--dark a.btn-hero:hover { transform: none; } }
.svc p { margin: 0; color: var(--muted); font-size: 1rem; line-height: 1.6; max-width: 56ch; }
/* the dark Contact band sits directly on the footer, as the hero sits under the header */
main:has(> .band--dark:last-child) + .site-footer { margin-top: 0; border-top: 0; }
main > .band--dark:last-child { margin-bottom: 0; }
.work-intro .lead { margin-bottom: 12px; }
.work-intro .lead:last-of-type { margin-bottom: 24px; }

/* App pages: same signature as the home page. A dark hero band (bold headline in the lighter teal),
   a white band for "Why You'll Love It", and the dark Contact band at the end. */
.app-band { background: var(--banner); color: var(--banner-ink); padding-block: clamp(36px, 6vw, 80px); }
:root[data-theme="dark"] .app-band { border-block: 1px solid var(--line); }
.app-band .app-hero-id h1 { color: var(--banner-ink); }
.app-band .app-hero-id p { color: rgba(255, 255, 255, .78); }
.app-band .split h2 { color: #2bb3a6; font-size: clamp(1.75rem, 1.15rem + 1.9vw, 2.5rem); font-weight: 600; line-height: 1.12; letter-spacing: -.02em; margin-bottom: 18px; text-wrap: balance; }
.app-band .lead { color: rgba(255, 255, 255, .86); }
.app-band .appstore { border-color: #8e8e93; }
.app-band a:focus-visible { outline-color: #fff; }
.love-band .features { margin-top: 28px; }
.displays-section .section-head { text-align: left; }
.displays-section .section-head .lead { margin-inline: 0; }
.app-band + .band { margin-top: 0; border-top: 0; }

/* Every dark band on the site (home hero, Contact, app heroes) uses one navy, --banner: #020414, lifted to
   #0a1030 in dark mode so the bands stay distinct from the near-black page (with a divider line above and below).
   On it: white headings 20:1 (18.6:1 dark mode), teal accent and button edges 7.9:1 (7.2:1), body text 14.9:1,
   subtitles 12.2:1; dark text on the teal buttons 5.9:1. A teal button always means the main action, on every page.
   The app logos use matching website badges (assets/*-badge.svg): a filled circle in the hero navy, marks at the same visual weight. */

/* App badges: a filled circle in the hero navy (#020414), with no ring. On the navy bands the circle
   blends into the background and the mark stands on its own. */
.card-head > img, .app-hero-id img { border-radius: 50%; box-shadow: 0 0 0 1.5px var(--badge-ring); }

/* Home app cards: bullet lists line up with the badge's left edge; "Learn more" is a quiet text link,
   so the App Store badge is the one button on each card. */
.card ul { margin-left: 0; padding-left: 1.15em; }
.card-link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; color: var(--accent); font-weight: 600; text-decoration: none; }
.card-link:hover { color: var(--accent-hover); text-decoration: underline; text-underline-offset: 4px; }

/* Puzzlies demo, Post-Run Replay (as in the app): "Replay" title, close, objectives only, "Watch again" at the end.
   The wrong move is washed out inside a crackling pink border (the shared .pzd-zap). */
.pzd-game.is-replay .pzd-hud > .pzd-card:not(.pzd-card--obj), .pzd-game.is-replay .pzd-pause, .pzd-game.is-replay .pzd-foot { visibility: hidden; }
.pzd-game.is-replay .pzd-hud { top: 11.6%; }
.pzd-replay-title { position: absolute; left: 0; right: 0; top: 4.2%; margin: 0; text-align: center; color: #fff; font-size: 6.9cqw; font-weight: 800; }
.pzd-replay-close { position: absolute; right: 4.6%; top: 4.9%; width: 5.4cqw; height: 5.4cqw; padding: 0; border: 0; background: none; color: #fff; }
.pzd-replay-close svg { width: 100%; height: 100%; }
.pzd-game .pzd-watch { position: absolute; left: 4.1%; right: 4.1%; bottom: 3.6%; width: auto; min-height: 0; height: 7%; font-size: 4.3cqw; background: #4a2a86; border: 0; box-shadow: none; color: #b9a6dc !important; }
.pzd-game .pzd-watch.is-ready { background: #a95cf3; color: #fff !important; }
.pzd-game .pzd-watch:disabled { cursor: default; }
/* Colours measured from the app's replay recording: white zigzag lines with a pink-magenta glow (#d355a6),
   and a magenta veil over the tile that turns its cyan to the app's light blue (#62b3d7), stronger at the edge. */
.pzd-cell.pzd-replay-wrong .pzd-tile::after {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; border-radius: 15%;
  background: rgba(154, 71, 173, .4); box-shadow: inset 0 0 calc(var(--pzd-t) * .13) rgba(211, 85, 166, .8);
}
.pzd-cell.pzd-replay-wrong .pzd-zap { z-index: 3; }
.pzd-cell.pzd-replay-wrong .pzd-tile { box-shadow: 0 0 calc(var(--pzd-t) * .1) rgba(211, 85, 166, .55); }
.pzd-cell.pzd-replay-wrong .pzd-zap path { stroke: #ffffff; stroke-width: 1.1; filter: drop-shadow(0 0 1.2px #ff5fd0) drop-shadow(0 0 3px #d355a6); }
.pzd-cell.pzd-replay-wrong .pzd-zap path + path { stroke: #ffe2fb; stroke-width: .8; opacity: .9; }

/* "Coming soon" label (Puzzlies, until the redesigned update is live on the App Store).
   A plain label, not a button: no fill, no hover, no pointer, not focusable. */
.coming-soon {
  display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 6px 14px 6px 11px;
  border: 1px solid var(--line); border-radius: 999px; background: none; color: var(--muted);
  font-size: .875rem; font-weight: 500; line-height: 1.3; cursor: default; user-select: text;
}
.coming-soon svg { width: 17px; height: 17px; flex: none; color: var(--accent); }
.app-band .coming-soon { border-color: rgba(255, 255, 255, .3); color: rgba(255, 255, 255, .86); }
.app-band .coming-soon svg { color: #2bb3a6; }
/* On the home cards the label takes its own line, and "Learn more" stays bottom-right, level with Explorito's */
.coming-soon-row { display: block; flex-basis: 100%; }
.card-actions .card-link { margin-left: auto; }
.app-band .coming-soon-row { margin-top: 4px; }
/* Company details required on UK company websites (registered number, office and place of registration) */
.company-info { width: 100%; margin: 4px 0 0; color: var(--muted); font-size: .875rem; line-height: 1.5; }

/* Puzzlies demo: the tray sits on a rounded panel, as in the app (colour measured from the app: #101038 on the board navy).
   The panel is the tray itself, so it stays put while the tiles scroll inside it and are clipped at its rounded edges. */
.pzd-game .pzd-tray { left: 1.4cqw; right: 1.4cqw; padding-left: 2.6cqw; padding-right: 2.6cqw; border-radius: 5.4cqw; background: #101038; }

/* Touch targets: at least 44 px (Apple's guideline) on every screen, without changing the look */
.site-header .logo, .site-footer .logo { display: inline-flex; align-items: center; min-height: 44px; }
.nav-list a { display: flex; align-items: center; min-height: 44px; }
.theme-toggle { position: relative; }
.theme-toggle::after { content: ""; position: absolute; inset: -3px; border-radius: inherit; }
/* the button's tap area is 3 px larger on every side (transparent border); the glow is a drop-shadow of the visible pill, so it looks exactly as before */
.pzd-home .pzd-new { height: calc(7.1% + 6px); margin: -3px; border: 3px solid transparent; background-clip: padding-box; box-shadow: inset 0 2px 1px rgba(255, 255, 255, .22); filter: drop-shadow(0 0 6px rgba(167, 78, 240, .3)); }
@media (prefers-reduced-motion: no-preference) { .pzd-home .pzd-new.is-inviting { animation-name: pzd-invite-hit; } }
@keyframes pzd-invite-hit { 50% { filter: drop-shadow(0 0 2.4cqw rgba(178, 92, 246, .45)); } }
.appstore small { font-size: .75rem; }

/* Demo score box in the new app design (Nov 2026): the same height as the app's buttons, sized to its text,
   with a vertical level bar on the right that fills from the bottom (measured on the 828 x 1792 recordings) */
.pzd-game .pzd-foot { left: 3.9%; top: 89.6%; bottom: 3.85%; width: auto; }
.pzd-game .pzd-score {
  position: absolute; top: 0; bottom: 0; left: 0; right: auto;
  display: grid; grid-template-columns: auto auto; grid-template-rows: auto auto; align-content: center; align-items: center;
  column-gap: 1.9cqw; row-gap: 0; padding: 1.5cqw 3.9cqw 0 4.2cqw;
}
.pzd-game .pzd-score-n { grid-column: 1; grid-row: 1; line-height: 1.15; }
.pzd-game .pzd-lvl { grid-column: 1; grid-row: 2; line-height: 1.15; }
.pzd-game .pzd-bar { position: relative; grid-column: 2; grid-row: 1 / 3; align-self: center; width: .97cqw; height: 8.45cqw; margin: 0; border-radius: 99px; background: #41332c; }
.pzd-game .pzd-bar i { position: absolute; left: 0; right: 0; bottom: 0; width: auto; min-height: .97cqw; border-radius: 99px; transition: height .6s ease; }
.pzd-game .pzd-score { border-width: .28cqw; }
.pzd-game .pzd-score-n, .pzd-game .pzd-lvl { font-size: 3.9cqw; line-height: 1.23; }
.pzd-game .pzd-lvl b { font-weight: 700; }

/* Designed for different displays, wider screens: the two Duo screens share a row at a readable size, iPad below */
@media (min-width: 721px) {
  .devices { flex-direction: column; align-items: center; }
  .device-group--duo { --h: min(430px, calc((min(var(--max), 100vw) - 2 * var(--gutter) - 24px - 48px) / 2.109)); }   /* 466/678 + 951/669 */
  .device-group--ipad { --h: min(430px, calc((min(var(--max), 100vw) - 2 * var(--gutter) - 22px) / 1.439)); }
}
/* iPhone Duo outer display: flat hinge edge on the left, rounded corners on the right */
.device--compact .device-screen {
  border-radius: 8px 34px 34px 8px; border-left: 10px solid transparent;
  background: linear-gradient(90deg, #3e3e41 0 4px, #8a8a8e 4px 6px, #3e3e41 6px 10px, #030303 10px) border-box;
}
.device--compact .device-screen > img { border-radius: 3px 24px 24px 3px; }

/* Very large text (browser or OS text size): wrap instead of scrolling sideways. No change at normal sizes. */
.site-header .wrap { flex-wrap: wrap; }
.footer-links { flex-wrap: wrap; row-gap: 4px; }
a[href^="mailto:"] { overflow-wrap: anywhere; }
.app-hero-id > div { min-width: 0; }
.app-hero-id h1, .app-hero-id p, .app-band h2 { overflow-wrap: break-word; }
@media (max-width: 720px) { .split > *, .card-head > div, .feature, .feature > div { min-width: 0; } }
.feature h3, .feature p { overflow-wrap: break-word; }

/* Board tiles: no permanent glint (the app's tiles are plain; the shine only sweeps across when a level is complete) */
.pzd-board .pzd-tile::before { display: none; }
/* Objective complete, as in the app: a spark runs round the icon's outline, the icon dims, the count becomes a tick */
.pzd-obj-icon { position: relative; display: inline-flex; justify-content: center; width: 100%; }
.pzd-obj-icon img { display: block; }
.pzd-game .pzd-obj-icon img { width: 6.4cqw; }
.pzd-card--obj.is-done img { opacity: 1; filter: brightness(.55) saturate(.8); }
.pzd-obj-trace { position: absolute; top: 0; bottom: 0; left: 50%; aspect-ratio: 56 / 55; height: 100%; transform: translateX(-50%) scale(1.08); pointer-events: none;
  filter: drop-shadow(0 0 1px #fff) drop-shadow(0 0 3px rgba(255, 170, 235, .9)); }
.pzd-obj-trace > span { position: absolute; inset: 0; overflow: hidden;
  -webkit-mask-size: 100% 100%, 80% 80%; mask-size: 100% 100%, 80% 80%; -webkit-mask-position: center; mask-position: center;
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-composite: xor; mask-composite: exclude; }
.pzd-obj-trace i { position: absolute; inset: -60%; background: conic-gradient(from 240deg, transparent 0deg, rgba(255, 255, 255, 0) 20deg, #fff 70deg, rgba(255, 255, 255, 0) 80deg, transparent 360deg); }
.pzd-obj { position: relative; }
.pzd-obj-old { position: absolute; inset: 0; display: grid; place-items: center; }
/* Wrong pick: the empty slots take the app's magenta */
.pzd-slot.is-electric::before { background: #3e1049; }
