/* Keto Bakery contact card. Two skins (cream, forest) share one layout:
   a single column on phones, identity panel + content column on wide screens.
   Logical properties throughout, so RTL languages need no extra rules. */

@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("fonts/fraunces-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Fraunces";
  font-style: italic;
  font-weight: 300 700;
  font-display: swap;
  src: url("fonts/fraunces-italic.woff2") format("woff2");
}
@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/dm-sans-normal.woff2") format("woff2");
}

:root {
  --bg: #fbf8f3;
  --panel: #ffffff;
  --surface: #ffffff;
  --tint: #f3ece1;
  --line: #e8dfd1;
  --ink: #1e2a23;
  --muted: #667067;
  --brand: #2f5d46;
  --brand-strong: #224635;
  --on-brand: #ffffff;
  --soft: #e4ece4;
  --gold: #b3854a;
  --accent: #2f5d46;
  --wa: #1fa855;
  --wa-strong: #178a45;
  --glow-a: rgb(228 236 228 / 0.9);
  --glow-b: rgb(179 133 74 / 0.16);
  --shadow-soft: 0 1px 2px rgb(30 42 35 / 0.04), 0 8px 24px -10px rgb(30 42 35 / 0.12);
  --shadow-lift: 0 2px 4px rgb(30 42 35 / 0.05), 0 24px 48px -18px rgb(30 42 35 / 0.24);
  --display: "Fraunces", ui-serif, Georgia, serif;
  --body: "DM Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  color-scheme: light;
}

[data-theme="forest"] {
  --bg: #17332a;
  --panel: #1f4234;
  --surface: rgb(255 255 255 / 0.06);
  --tint: rgb(255 255 255 / 0.09);
  --line: rgb(255 255 255 / 0.13);
  --ink: #f7f2e8;
  --muted: rgb(247 242 232 / 0.66);
  --brand: #e9d3ac;
  --brand-strong: #f3e4c6;
  --on-brand: #17332a;
  --soft: rgb(255 255 255 / 0.1);
  --gold: #e9d3ac;
  --accent: #e9d3ac;
  --glow-a: rgb(47 93 70 / 0.9);
  --glow-b: rgb(233 211 172 / 0.1);
  --shadow-soft: 0 1px 2px rgb(0 0 0 / 0.1), 0 10px 26px -12px rgb(0 0 0 / 0.4);
  --shadow-lift: 0 2px 4px rgb(0 0 0 / 0.12), 0 28px 54px -20px rgb(0 0 0 / 0.55);
  color-scheme: dark;
}

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

html {
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100svh;
  background: var(--bg);
  color: var(--ink);
  font: 400 1rem/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; }
img, svg, iframe { display: block; max-width: 100%; }
[hidden] { display: none !important; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 0.5rem;
}

::selection { background: var(--brand); color: var(--on-brand); }

.i { width: 1.4rem; height: 1.4rem; flex: none; }
[dir="rtl"] .link-go .i,
[dir="rtl"] .more .i,
[dir="rtl"] .dock .i:last-child { transform: scaleX(-1); }

.accent { font-style: italic; font-weight: 400; color: var(--accent); }

.eyebrow {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
}

/* ── Backdrop ─────────────────────────────────────────────────────────── */
.backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background:
    radial-gradient(60rem 40rem at -10% -10%, var(--glow-a), transparent 60%),
    radial-gradient(50rem 36rem at 110% 105%, var(--glow-b), transparent 60%),
    var(--bg);
}
.backdrop img { display: none; }

/* ── Page frame ───────────────────────────────────────────────────────── */
.page {
  width: 100%;
  max-width: 34rem;
  margin-inline: auto;
}

/* ── Identity ─────────────────────────────────────────────────────────── */
.identity { --card: var(--bg); position: relative; }

.cover {
  position: relative;
  height: 15.5rem;
  background: var(--tint);
  overflow: hidden;
}
.cover > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 78% 50%;
  animation: settle 1.6s var(--ease) both;
}
.cover::after {
  content: "";
  position: absolute;
  inset: 45% 0 -1px;
  background: linear-gradient(to bottom, transparent, var(--card));
}

.cover-actions {
  position: absolute;
  inset: calc(0.9rem + env(safe-area-inset-top)) 1rem auto;
  z-index: 1;
  display: flex;
  justify-content: space-between;
}
.glass {
  display: grid;
  place-items: center;
  width: 2.9rem;
  height: 2.9rem;
  border-radius: 50%;
  background: rgb(255 255 255 / 0.78);
  color: #1e2a23;
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  backdrop-filter: blur(14px) saturate(1.4);
  box-shadow: 0 6px 20px -8px rgb(30 42 35 / 0.45);
  transition: transform 0.25s var(--ease), background-color 0.25s;
}
.glass:hover { background: #fff; transform: scale(1.06); }
.glass:active { transform: scale(0.94); }

.who {
  position: relative;
  margin-top: -3.6rem;
  padding: 0 1.25rem;
  text-align: center;
}

.avatar {
  width: 6.6rem;
  height: 6.6rem;
  margin: 0 auto 1.15rem;
  border-radius: 50%;
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 0 0 5px var(--card), 0 0 0 6px var(--line), var(--shadow-lift);
  animation: pop 0.8s var(--ease) both;
}
.avatar img,
.avatar svg { width: 100%; height: 100%; object-fit: cover; }

h1 {
  margin-top: 0.55rem;
  font: 400 2.75rem/1.02 var(--display);
  letter-spacing: -0.012em;
}

.bio {
  max-width: 27rem;
  margin: 0.9rem auto 0;
  color: var(--muted);
  font-size: 1.02rem;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 1.1rem;
  padding: 0.45rem 0.95rem 0.45rem 0.8rem;
  border-radius: 99rem;
  background: var(--soft);
  font-size: 0.86rem;
  font-weight: 600;
}
.status .dot {
  position: relative;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #c2703d;
}
.status.is-open .dot { background: var(--wa); }
.status.is-open .dot::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--wa);
  animation: ping 1.8s ease-out infinite;
}

.tools {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.6rem;
  margin-top: 1.5rem;
}
.tool {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  min-height: 4.4rem;
  padding: 0.85rem 0.4rem 0.75rem;
  border-radius: 1.25rem;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.2;
  transition: transform 0.25s var(--ease), border-color 0.25s, box-shadow 0.25s, color 0.25s;
}
.tool .i { color: var(--accent); }
.tool:hover { transform: translateY(-2px); border-color: var(--accent); box-shadow: var(--shadow-soft); }
.tool:active { transform: scale(0.97); }

.socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin-top: 1.1rem;
}
.socials a {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  transition: transform 0.25s var(--ease), background-color 0.25s, color 0.25s, border-color 0.25s;
}
.socials a:hover {
  transform: translateY(-3px);
  background: var(--brand);
  border-color: var(--brand);
  color: var(--on-brand);
}
.socials a:active { transform: scale(0.94); }

/* ── Content column ───────────────────────────────────────────────────── */
.content {
  display: grid;
  gap: 2.9rem;
  padding: 1.6rem 1.25rem calc(6.5rem + env(safe-area-inset-bottom));
  min-width: 0;
}
.content > * { min-width: 0; }

.links { display: grid; gap: 0.7rem; }

.link {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.9rem;
  min-height: 4.6rem;
  padding: 0.75rem 0.85rem;
  border-radius: 1.6rem;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s var(--ease), box-shadow 0.3s, border-color 0.3s;
}
.link:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); border-color: transparent; }
.link:active { transform: scale(0.985); }

.link-icon {
  display: grid;
  place-items: center;
  width: 3.1rem;
  height: 3.1rem;
  border-radius: 50%;
  background: var(--soft);
  color: var(--accent);
}
.link.is-whatsapp .link-icon { background: rgb(31 168 85 / 0.14); color: var(--wa); }
.link-text { display: grid; text-align: start; }
.link-text strong { font-size: 1.05rem; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; }
.link-text small { margin-top: 0.1rem; font-size: 0.85rem; color: var(--muted); overflow-wrap: anywhere; }

.link-go {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  border: 1px solid var(--line);
  transition: transform 0.3s var(--ease), background-color 0.3s, color 0.3s, border-color 0.3s;
}
.link-go .i { width: 1.1rem; height: 1.1rem; }
a:hover > .link-go {
  transform: translateX(3px);
  background: var(--brand);
  border-color: var(--brand);
  color: var(--on-brand);
}
[dir="rtl"] a:hover > .link-go { transform: translateX(-3px); }

.link.is-primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  color: var(--on-brand);
  box-shadow: var(--shadow-lift);
}
.link.is-primary.is-whatsapp { background: linear-gradient(135deg, #24b765, var(--wa-strong)); color: #fff; }
.link.is-primary .link-icon { background: rgb(255 255 255 / 0.18); color: inherit; }
[data-theme="forest"] .link.is-primary:not(.is-whatsapp) .link-icon { background: rgb(23 51 42 / 0.12); }
.link.is-primary .link-text small { color: inherit; opacity: 0.8; }
.link.is-primary .link-go { border-color: transparent; background: rgb(255 255 255 / 0.18); }
.link.is-primary:hover > .link-go { background: #fff; color: var(--brand-strong); }
.link.is-primary.is-whatsapp:hover > .link-go { color: var(--wa-strong); }

/* ── Section blocks ───────────────────────────────────────────────────── */
.head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.15rem;
}
.head .eyebrow { display: flex; align-items: center; gap: 0.6rem; }
.head .eyebrow::before { content: ""; width: 1.6rem; height: 1px; background: var(--gold); opacity: 0.6; }
.head h2 {
  margin-top: 0.45rem;
  font: 400 2rem/1.08 var(--display);
  letter-spacing: -0.02em;
}
.more {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding-bottom: 0.25rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
}
.more .i { width: 1rem; height: 1rem; transition: transform 0.3s var(--ease); }
.more:hover .i { transform: translateX(3px); }

/* Products */
.strip {
  display: flex;
  gap: 0.85rem;
  margin-inline: -1.25rem;
  padding: 0.25rem 1.25rem 0.75rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 1.25rem;
  scrollbar-width: none;
}
.strip::-webkit-scrollbar { display: none; }
.strip li { flex: none; width: 9.75rem; scroll-snap-align: start; }
.strip a { display: block; }
.strip-img {
  display: block;
  aspect-ratio: 1;
  border-radius: 1.4rem;
  overflow: hidden;
  background: var(--tint);
  box-shadow: var(--shadow-soft);
}
.strip-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.strip a:hover .strip-img img { transform: scale(1.08); }
.strip strong { display: block; margin-top: 0.7rem; font: 400 1.08rem/1.2 var(--display); }
.strip small { display: block; margin-top: 0.2rem; font-size: 0.86rem; font-weight: 600; }
.strip small i { font-style: normal; font-weight: 400; font-size: 0.72rem; color: var(--muted); }

/* Locations */
.places { display: grid; gap: 0.9rem; }
.place {
  border-radius: 1.8rem;
  border: 1px solid var(--line);
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
/* The embed is cropped (its own controls and footer sit in the cropped edge)
   and inert, so a swipe scrolls the page; tapping opens the real map. */
.map { position: relative; aspect-ratio: 16 / 9; background: var(--tint); overflow: hidden; }
.map iframe {
  position: absolute;
  inset: -3rem;
  width: calc(100% + 6rem);
  height: calc(100% + 6rem);
  max-width: none;
  border: 0;
  pointer-events: none;
  filter: saturate(0.55) sepia(0.14) contrast(0.96);
}
[data-theme="forest"] .map iframe { filter: saturate(0.45) sepia(0.1) brightness(0.86); }
.map-hit { position: absolute; inset: 0; }
.map-hit span {
  position: absolute;
  inset: 0.8rem 0.8rem auto auto;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.85rem 0.45rem 0.65rem;
  border-radius: 99rem;
  background: rgb(255 255 255 / 0.92);
  color: #1e2a23;
  font-size: 0.8rem;
  font-weight: 600;
  box-shadow: 0 6px 18px -8px rgb(30 42 35 / 0.5);
  transition: transform 0.25s var(--ease);
}
[dir="rtl"] .map-hit span { inset: 0.8rem auto auto 0.8rem; }
.map-hit span .i { width: 1rem; height: 1rem; color: #2f5d46; }
.map-hit:hover span { transform: translateY(-2px); }
.map-credit {
  position: absolute;
  inset: auto 0.5rem 0.4rem auto;
  padding: 0.1rem 0.45rem;
  border-radius: 0.5rem;
  background: rgb(255 255 255 / 0.8);
  color: #445048;
  font-size: 0.65rem;
}
[dir="rtl"] .map-credit { inset: auto auto 0.4rem 0.5rem; }
.place-body { display: flex; gap: 0.9rem; padding: 1.15rem 1.15rem 0.2rem; }
.place-pin {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.9rem;
  height: 2.9rem;
  border-radius: 50%;
  background: var(--soft);
  color: var(--accent);
}
.place-text { min-width: 0; }
.place h3 { font: 400 1.4rem/1.15 var(--display); }
.place p { margin-top: 0.2rem; color: var(--muted); overflow-wrap: anywhere; }
.place .note { font-size: 0.88rem; }
.place-actions { display: flex; flex-wrap: wrap; gap: 0.55rem; padding: 0.95rem 1.15rem 1.15rem; }

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.9rem;
  padding: 0.6rem 1.15rem;
  border-radius: 99rem;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 0.93rem;
  font-weight: 600;
  transition: transform 0.25s var(--ease), background-color 0.25s, border-color 0.25s, color 0.25s;
}
.pill .i { width: 1.15rem; height: 1.15rem; }
.pill:hover { border-color: var(--accent); transform: translateY(-2px); }
.pill:active { transform: scale(0.97); }
.pill.is-solid { border-color: transparent; background: var(--brand); color: var(--on-brand); }
.pill.is-solid:hover { background: var(--brand-strong); }

/* Hours */
.hours {
  padding: 0.5rem 1.25rem 1.1rem;
  border-radius: 1.8rem;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}
.hours li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.82rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}
.hours li:last-child { border-bottom: 0; }
.hours li.is-today { color: var(--ink); font-weight: 600; }
.hours li.is-today > span:first-child { display: inline-flex; align-items: center; gap: 0.55rem; }
.hours li.is-today > span:first-child::before {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: var(--accent);
}
.hours-note {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--line);
  font-size: 0.8rem;
  color: var(--muted);
}
.hours-note .i { width: 1rem; height: 1rem; }

/* Gallery */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-flow: dense;
  gap: 0.5rem;
}
.gallery li { aspect-ratio: 1; }
.gallery li:first-child { grid-column: span 2; grid-row: span 2; }
.gallery button {
  width: 100%;
  height: 100%;
  border-radius: 1.25rem;
  overflow: hidden;
  background: var(--tint);
}
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.gallery button:hover img { transform: scale(1.07); }

/* Footer */
.foot { display: grid; gap: 1.3rem; }
.foot-brand {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.9rem;
  padding: 0.85rem;
  border-radius: 1.6rem;
  background: var(--tint);
  transition: transform 0.3s var(--ease);
}
.foot-brand:hover { transform: translateY(-2px); }
.foot-logo { width: 3rem; height: 3rem; border-radius: 50%; overflow: hidden; }
.foot-brand small { display: block; font-size: 0.8rem; color: var(--muted); }
.foot-brand strong { display: block; font: 400 1.3rem/1.2 var(--display); }
.foot > p { text-align: center; font-size: 0.78rem; color: var(--muted); }

/* ── Floating order button (phones) ───────────────────────────────────── */
.dock {
  position: fixed;
  inset: auto 1rem calc(0.9rem + env(safe-area-inset-bottom));
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  max-width: 31.5rem;
  min-height: 3.5rem;
  margin-inline: auto;
  padding: 0.8rem 1.3rem;
  border-radius: 99rem;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  color: var(--on-brand);
  font-weight: 600;
  box-shadow: var(--shadow-lift);
  opacity: 0;
  transform: translateY(1.5rem);
  pointer-events: none;
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}
.dock.is-whatsapp { background: linear-gradient(135deg, #24b765, var(--wa-strong)); color: #fff; }
.dock.is-on { opacity: 1; transform: none; pointer-events: auto; }
.dock .i:last-child { width: 1.1rem; height: 1.1rem; }
.dock span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── Dialogs ──────────────────────────────────────────────────────────── */
dialog {
  border: 0;
  padding: 0;
  color: var(--ink);
}
dialog::backdrop {
  background: rgb(23 34 28 / 0.6);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.modal {
  width: min(23.5rem, calc(100vw - 2rem));
  padding: 2.4rem 1.6rem 1.8rem;
  border-radius: 2.2rem;
  background: var(--panel);
  text-align: center;
  box-shadow: var(--shadow-lift);
}
.modal[open] { animation: sheet 0.4s var(--ease) both; }
.modal h2 { margin-top: 0.4rem; font: 400 2rem/1.1 var(--display); letter-spacing: -0.02em; }
.modal-text { margin: 1.1rem auto 1.3rem; max-width: 17rem; font-size: 0.92rem; color: var(--muted); }
.modal-close {
  position: absolute;
  inset: 0.9rem 0.9rem auto auto;
  display: grid;
  place-items: center;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  background: var(--tint);
  transition: transform 0.25s var(--ease);
}
[dir="rtl"] .modal-close { inset: 0.9rem auto auto 0.9rem; }
.modal-close:hover { transform: rotate(90deg); }
.qr-code {
  width: 14.5rem;
  max-width: 100%;
  aspect-ratio: 1;
  margin: 1.4rem auto 0;
  padding: 1rem;
  border-radius: 1.6rem;
  background: #fff;
  box-shadow: inset 0 0 0 1px #e8dfd1;
}
.qr-code svg { width: 100%; height: 100%; }

.lightbox {
  width: 100vw;
  max-width: 100vw;
  height: 100svh;
  max-height: 100svh;
  background: transparent;
}
.lightbox[open] { display: grid; place-items: center; }
.lightbox img {
  max-width: min(92vw, 60rem);
  max-height: 84svh;
  border-radius: 1.6rem;
  box-shadow: 0 30px 80px -20px rgb(0 0 0 / 0.6);
  animation: sheet 0.4s var(--ease) both;
}
.lightbox .modal-close,
.lightbox-nav {
  background: rgb(255 255 255 / 0.92);
  color: #1e2a23;
  box-shadow: 0 8px 24px -8px rgb(0 0 0 / 0.5);
}
.lightbox-nav {
  position: absolute;
  top: 50%;
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  margin-top: -1.5rem;
  border-radius: 50%;
  transition: transform 0.25s var(--ease), background-color 0.25s;
}
.lightbox-nav:hover { background: #fff; transform: scale(1.08); }
.lightbox-nav.is-prev { inset-inline-start: 0.75rem; }
.lightbox-nav.is-next { inset-inline-end: 0.75rem; }
.lightbox-nav.is-prev .i { transform: scaleX(-1); }
[dir="rtl"] .lightbox-nav.is-prev .i { transform: none; }
[dir="rtl"] .lightbox-nav.is-next .i { transform: scaleX(-1); }

.toast {
  position: fixed;
  inset: calc(1rem + env(safe-area-inset-top)) 0 auto;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: max-content;
  max-width: calc(100vw - 2rem);
  margin-inline: auto;
  padding: 0.7rem 1.15rem 0.7rem 0.9rem;
  border-radius: 99rem;
  background: #1e2a23;
  color: #fff;
  font-size: 0.92rem;
  font-weight: 600;
  box-shadow: var(--shadow-lift);
  animation: pop 0.35s var(--ease) both;
}
.toast .i { width: 1.15rem; height: 1.15rem; color: #6fe0a0; }

/* ── 404 ──────────────────────────────────────────────────────────────── */
.lost {
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 0.2rem;
  min-height: 100svh;
  padding: 2rem 1.5rem;
  text-align: center;
}
.lost .avatar { box-shadow: var(--shadow-lift); }
.lost .pill { margin-top: 1.8rem; }
.lost .pill .i { width: 1.05rem; height: 1.05rem; }

/* ── Wide screens: identity panel beside the content ──────────────────── */
@media (min-width: 64rem) {
  .backdrop img {
    display: block;
    position: absolute;
    inset: -12%;
    width: 124%;
    height: 124%;
    object-fit: cover;
    filter: blur(70px) saturate(1.25);
    opacity: 0.38;
  }
  [data-theme="forest"] .backdrop img { opacity: 0.2; }
  .backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, var(--bg) 8%, transparent 55%, var(--bg) 100%);
    opacity: 0.72;
  }

  .page {
    display: grid;
    grid-template-columns: minmax(0, 27rem) minmax(0, 36rem);
    justify-content: center;
    align-items: start;
    gap: 4.5rem;
    max-width: none;
    padding: 3.5rem 2.5rem 5rem;
  }

  .identity {
    --card: var(--panel);
    position: sticky;
    top: 3.5rem;
    border-radius: 2.6rem;
    background: var(--panel);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-lift);
    overflow: hidden;
  }
  .cover { height: 15rem; }
  .cover-actions { display: none; }
  .who { padding: 0 2.25rem 2.25rem; }
  h1 { font-size: 3.2rem; }
  .tools { margin-top: 1.7rem; }

  .content { padding: 0.5rem 0 0; gap: 3.6rem; }
  .head h2 { font-size: 2.5rem; }
  .strip {
    margin-inline: 0;
    padding-inline: 0 2.5rem;
    scroll-padding-inline: 0;
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 4rem), transparent);
    mask-image: linear-gradient(to right, #000 calc(100% - 4rem), transparent);
  }
  [dir="rtl"] .strip {
    -webkit-mask-image: linear-gradient(to left, #000 calc(100% - 4rem), transparent);
    mask-image: linear-gradient(to left, #000 calc(100% - 4rem), transparent);
  }
  .strip li { width: 10.5rem; }
  .gallery { gap: 0.7rem; }
  .gallery button { border-radius: 1.5rem; }
  .dock { display: none; }
}

@media (min-width: 64rem) and (max-height: 50rem) {
  .identity { position: static; }
}

/* ── Motion ───────────────────────────────────────────────────────────── */
@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}
@keyframes pop {
  from { opacity: 0; transform: scale(0.86); }
  to { opacity: 1; transform: none; }
}
@keyframes sheet {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to { opacity: 1; transform: none; }
}
@keyframes settle {
  from { transform: scale(1.1); }
  to { transform: none; }
}
@keyframes ping {
  to { transform: scale(2.6); opacity: 0; }
}

@media (prefers-reduced-motion: no-preference) {
  .who > .rise,
  .links > .rise { animation: rise 0.7s var(--ease) both; }
  .who > .rise:nth-child(2) { animation-delay: 0.08s; }
  .who > .rise:nth-child(3) { animation-delay: 0.14s; }
  .who > .rise:nth-child(4) { animation-delay: 0.2s; }
  .who > .rise:nth-child(5) { animation-delay: 0.26s; }
  .who > .rise:nth-child(6) { animation-delay: 0.32s; }
  .who > .socials { animation: rise 0.7s var(--ease) 0.38s both; }
  .links > .rise:nth-child(1) { animation-delay: 0.3s; }
  .links > .rise:nth-child(2) { animation-delay: 0.36s; }
  .links > .rise:nth-child(3) { animation-delay: 0.42s; }
  .links > .rise:nth-child(4) { animation-delay: 0.48s; }
  .links > .rise:nth-child(5) { animation-delay: 0.54s; }
  .links > .rise:nth-child(n + 6) { animation-delay: 0.6s; }

  /* Sections further down fade in as they scroll into view. */
  @supports (animation-timeline: view()) {
    .block {
      animation: rise linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 40%;
    }
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
