:root {
  color-scheme: light dark;
  --ink: #29232e;
  --muted-ink: #6f6676;
  --paper: #f8f3f5;
  --paper-2: #eee5ef;
  --deep: #342940;
  --deep-2: #1f1927;
  --lavender: #9176a8;
  --hyacinth: #a98abd;
  --rose: #c88f9f;
  --gold: #b99a62;
  --leaf: #526858;
  --glass: rgb(255 255 255 / 0.46);
  --glass-strong: rgb(255 255 255 / 0.68);
  --glass-border: rgb(255 255 255 / 0.44);
  --glass-shadow: rgb(49 37 58 / 0.16);
  --glass-highlight: rgb(255 255 255 / 0.76);
  --island: #08070a;
  --island-ink: #fff;
  --light-x: 50%;
  --light-y: 8%;
  --status-height: calc(3.7rem + env(safe-area-inset-top));
  --tab-height: calc(5.3rem + env(safe-area-inset-bottom));
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", sans-serif;
  font-synthesis: none;
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #f5edf6;
    --muted-ink: #c0b4c3;
    --paper: #17131d;
    --paper-2: #221a2a;
    --deep: #4d3a5d;
    --deep-2: #100d14;
    --lavender: #a98bc0;
    --hyacinth: #bc9bd0;
    --rose: #d39aaa;
    --gold: #c9ab71;
    --leaf: #6f8a76;
    --glass: rgb(54 44 63 / 0.5);
    --glass-strong: rgb(48 38 57 / 0.72);
    --glass-border: rgb(255 255 255 / 0.15);
    --glass-shadow: rgb(0 0 0 / 0.32);
    --glass-highlight: rgb(255 255 255 / 0.18);
  }
}

* { box-sizing: border-box; }

html {
  min-height: 100%;
  background: var(--paper);
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background:
    radial-gradient(circle at 85% 8%, rgb(169 138 189 / 0.2), transparent 28rem),
    radial-gradient(circle at 5% 72%, rgb(200 143 159 / 0.16), transparent 25rem),
    var(--paper);
}

button,
dialog { font: inherit; }

button { -webkit-tap-highlight-color: transparent; }

button:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--hyacinth) 75%, transparent);
  outline-offset: 3px;
}

h1,
h2,
p { margin-top: 0; }

h1,
h2 {
  margin-bottom: 0.55rem;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Helvetica Neue", sans-serif;
  font-weight: 600;
  letter-spacing: -0.035em;
}

h1 {
  font-size: clamp(2rem, 8vw, 3.7rem);
  line-height: 1.02;
}

h2 {
  font-size: clamp(1.25rem, 5vw, 1.85rem);
  line-height: 1.12;
}

p {
  line-height: 1.58;
}

small {
  display: block;
  color: var(--muted-ink);
  font-size: 0.78rem;
  line-height: 1.4;
}

.serif {
  font-family: "New York", Georgia, "Times New Roman", serif;
}

.eyebrow {
  margin-bottom: 0.42rem;
  color: var(--muted-ink);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.app-shell {
  position: relative;
  min-height: 100dvh;
  isolation: isolate;
}

.app-shell::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background: radial-gradient(circle at var(--light-x) var(--light-y), rgb(255 255 255 / 0.22), transparent 27rem);
  content: "";
  mix-blend-mode: soft-light;
}

.app-shell::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: var(--hyacinth);
  content: "";
  opacity: 0.045;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 80 120'%3E%3Cg fill='black'%3E%3Cellipse cx='40' cy='18' rx='8' ry='13'/%3E%3Cellipse cx='29' cy='28' rx='8' ry='12' transform='rotate(-38 29 28)'/%3E%3Cellipse cx='51' cy='28' rx='8' ry='12' transform='rotate(38 51 28)'/%3E%3Cellipse cx='33' cy='42' rx='8' ry='12' transform='rotate(-25 33 42)'/%3E%3Cellipse cx='47' cy='42' rx='8' ry='12' transform='rotate(25 47 42)'/%3E%3Cellipse cx='40' cy='55' rx='8' ry='12'/%3E%3Cpath d='M38 112h4V58h-4zM38 91C22 78 13 78 7 79c8 5 17 14 31 26zM42 101c13-13 23-16 31-16-7 8-16 17-31 27z'/%3E%3C/g%3E%3C/svg%3E");
  -webkit-mask-position: 0 0;
  -webkit-mask-repeat: repeat;
  -webkit-mask-size: 92px 138px;
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 80 120'%3E%3Cg fill='black'%3E%3Cellipse cx='40' cy='18' rx='8' ry='13'/%3E%3Cellipse cx='29' cy='28' rx='8' ry='12' transform='rotate(-38 29 28)'/%3E%3Cellipse cx='51' cy='28' rx='8' ry='12' transform='rotate(38 51 28)'/%3E%3Cellipse cx='33' cy='42' rx='8' ry='12' transform='rotate(-25 33 42)'/%3E%3Cellipse cx='47' cy='42' rx='8' ry='12' transform='rotate(25 47 42)'/%3E%3Cellipse cx='40' cy='55' rx='8' ry='12'/%3E%3Cpath d='M38 112h4V58h-4zM38 91C22 78 13 78 7 79c8 5 17 14 31 26zM42 101c13-13 23-16 31-16-7 8-16 17-31 27z'/%3E%3C/g%3E%3C/svg%3E");
  mask-position: 0 0;
  mask-repeat: repeat;
  mask-size: 92px 138px;
}

.system-layer {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  z-index: 50;
  height: var(--status-height);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: max(0.82rem, env(safe-area-inset-top)) 1.18rem 0;
  pointer-events: none;
}

.system-time,
.system-icons {
  padding-top: 0.2rem;
  color: var(--ink);
  font-size: 0.74rem;
  font-weight: 600;
}

.dynamic-island {
  position: absolute;
  top: max(0.55rem, env(safe-area-inset-top));
  left: 50%;
  width: 7.35rem;
  height: 2.3rem;
  overflow: hidden;
  border: 1px solid rgb(255 255 255 / 0.09);
  border-radius: 999px;
  color: var(--island-ink);
  background: var(--island);
  box-shadow: 0 0.55rem 1.5rem rgb(0 0 0 / 0.27), inset 0 1px rgb(255 255 255 / 0.09);
  pointer-events: auto;
  transform: translateX(-50%);
  transform-origin: top center;
  transition:
    width 520ms cubic-bezier(0.2, 0.9, 0.2, 1),
    height 520ms cubic-bezier(0.2, 0.9, 0.2, 1),
    border-radius 520ms cubic-bezier(0.2, 0.9, 0.2, 1),
    box-shadow 300ms ease;
}

.dynamic-island.is-expanded {
  width: min(22rem, calc(100vw - 2.25rem));
  height: 5rem;
  border-radius: 1.65rem;
  box-shadow: 0 0.95rem 2.2rem rgb(0 0 0 / 0.32), inset 0 1px rgb(255 255 255 / 0.12);
}

.island-compact {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.48rem;
  opacity: 1;
  transition: opacity 160ms ease 220ms, transform 300ms ease;
}

.dynamic-island.is-expanded .island-compact {
  opacity: 0;
  transform: scale(0.72);
  transition-delay: 0ms;
}

.island-pulse {
  width: 0.58rem;
  height: 0.58rem;
  border-radius: 50%;
  background: var(--hyacinth);
  box-shadow: 0 0 0.8rem rgb(188 155 208 / 0.78);
  animation: island-pulse 2.1s ease-in-out infinite;
}

.island-compact-paw { opacity: 0.9; }

.island-expanded {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 2.7rem minmax(0, 1fr);
  align-items: center;
  gap: 0.78rem;
  padding: 0.65rem 0.9rem;
  opacity: 0;
  transform: translateY(0.4rem) scale(0.94);
  transition: opacity 180ms ease, transform 280ms cubic-bezier(0.2, 0.9, 0.2, 1);
}

.dynamic-island.is-expanded .island-expanded {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 180ms;
}

.island-symbol {
  width: 2.55rem;
  height: 2.55rem;
  display: grid;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 0.16);
  border-radius: 50%;
  background: rgb(169 138 189 / 0.58);
  box-shadow: inset 0 1px rgb(255 255 255 / 0.25);
}

.island-copy { min-width: 0; }

.island-copy strong,
.island-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.island-copy strong {
  display: block;
  color: var(--island-ink);
  font-size: 0.9rem;
}

.island-copy small {
  margin-top: 0.16rem;
  color: rgb(255 255 255 / 0.67);
  font-size: 0.69rem;
}

@keyframes island-pulse {
  0%, 100% { opacity: 0.5; transform: scale(0.82); }
  50% { opacity: 1; transform: scale(1.08); }
}

#app-main {
  min-height: 100dvh;
  padding-bottom: var(--tab-height);
}

.screen {
  display: none;
  min-height: calc(100dvh - var(--tab-height));
  padding-top: var(--status-height);
  animation: screen-in 360ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.screen.is-active { display: block; }

@keyframes screen-in {
  from { opacity: 0; transform: translateY(0.55rem) scale(0.994); }
  to { opacity: 1; transform: none; }
}

.intro-screen {
  position: relative;
  min-height: 100dvh;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 50% 31%, rgb(185 154 98 / 0.3), transparent 24%),
    linear-gradient(145deg, var(--deep-2), color-mix(in srgb, var(--deep) 72%, var(--lavender) 28%));
}

.intro-content {
  position: relative;
  z-index: 2;
  max-width: 34rem;
  margin: 0 auto;
  padding: clamp(6rem, 18vh, 10rem) 1.25rem 3rem;
  text-align: center;
}

.intro-screen .eyebrow,
.intro-screen .lead { color: rgb(255 255 255 / 0.78); }

.opening-paw {
  width: 6rem;
  height: 6rem;
  display: grid;
  place-items: center;
  margin: 0 auto 1.2rem;
  border: 1px solid rgb(255 255 255 / 0.34);
  border-radius: 50%;
  background: rgb(255 255 255 / 0.08);
  box-shadow: inset 0 1px rgb(255 255 255 / 0.18), 0 1rem 2rem rgb(0 0 0 / 0.12);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.lead {
  max-width: 29rem;
  margin-right: auto;
  margin-left: auto;
  font-size: clamp(1rem, 4vw, 1.25rem);
}

.botanical {
  position: absolute;
  width: 7.5rem;
  height: auto;
  pointer-events: none;
  color: var(--hyacinth);
  filter: drop-shadow(0 0.5rem 0.9rem rgb(0 0 0 / 0.13));
  opacity: 0.48;
}

.botanical .stem {
  fill: none;
  stroke: var(--leaf);
  stroke-linecap: round;
  stroke-width: 3;
}

.botanical .leaves { fill: var(--leaf); opacity: 0.82; }
.botanical .petals { fill: currentColor; opacity: 0.94; }
.botanical-left { bottom: -1.25rem; left: 0.35rem; transform: rotate(-9deg); }
.botanical-right { top: 2rem; right: 0.35rem; transform: rotate(168deg); opacity: 0.34; }
.hero-botanical { top: -0.7rem; left: 0.65rem; z-index: 2; transform: rotate(-11deg); opacity: 0.28; }
.journey-botanical { top: -1.4rem; right: 0.5rem; transform: rotate(154deg); opacity: 0.24; }
.letter-botanical { right: -1.3rem; bottom: -2.8rem; transform: rotate(18deg); opacity: 0.2; }

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.1rem;
}

.action-row.centered { justify-content: center; }

.glass-surface,
.glass-card,
.glass-button,
.memory-card,
.glass-chip {
  border: 1px solid var(--glass-border);
  background: var(--glass);
  box-shadow: 0 0.75rem 1.8rem var(--glass-shadow), inset 0 1px var(--glass-highlight);
  -webkit-backdrop-filter: saturate(165%) blur(24px);
  backdrop-filter: saturate(165%) blur(24px);
}

.glass-button {
  min-height: 2.85rem;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  color: inherit;
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.glass-button:hover { transform: translateY(-1px) scale(1.012); }
.glass-button:active { transform: scale(0.97); }

.primary-action,
.glass-button.is-selected {
  color: #fff;
  background: rgb(76 57 91 / 0.84);
  border-color: rgb(255 255 255 / 0.2);
}

.hero,
.profile-hero {
  position: relative;
  width: min(100% - 1rem, 68rem);
  min-height: 28rem;
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid var(--glass-border);
  border-radius: 2rem;
  background: linear-gradient(145deg, var(--lavender), var(--deep));
  box-shadow: 0 1.2rem 3rem var(--glass-shadow), inset 0 1px var(--glass-highlight);
}

.hero-photo,
.profile-photo,
.photo-placeholder {
  display: grid;
  place-items: center;
  color: rgb(255 255 255 / 0.78);
  font-size: 0.76rem;
  letter-spacing: 0.04em;
  text-align: center;
  background:
    radial-gradient(circle at 72% 16%, rgb(185 154 98 / 0.42), transparent 29%),
    linear-gradient(140deg, var(--deep), color-mix(in srgb, var(--deep) 58%, var(--lavender) 42%));
}

.hero-photo {
  position: absolute;
  inset: 0;
}

.hero-photo::after,
.profile-photo::after {
  content: "🐾";
  display: block;
  margin-top: 0.45rem;
  font-size: 2rem;
}

.hero::after,
.profile-hero::after {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(0deg, rgb(25 19 31 / 0.92), transparent 68%);
  content: "";
}

.hero-copy,
.profile-copy {
  position: absolute;
  right: 1.2rem;
  bottom: 1.25rem;
  left: 1.2rem;
  z-index: 3;
  max-width: 36rem;
  color: #fff;
}

.hero-copy .eyebrow,
.profile-copy .eyebrow { color: rgb(255 255 255 / 0.72); }
.hero-copy p,
.profile-copy p { margin-bottom: 0; }

.profile-hero { min-height: 26rem; }
.profile-photo { position: absolute; inset: 0; }

.content-pad {
  width: min(100%, 68rem);
  margin: 0 auto;
  padding: 1.2rem 1rem 2.2rem;
}

.card-grid,
.fact-grid,
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.glass-card,
.memory-card {
  position: relative;
  overflow: hidden;
  border-radius: 1.55rem;
}

.glass-card::after,
.memory-card::after {
  position: absolute;
  top: 0;
  left: 10%;
  width: 52%;
  height: 1px;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, var(--glass-highlight), transparent);
  content: "";
}

.navigation-card {
  min-height: 10.8rem;
  padding: 1rem;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.navigation-card:hover { transform: translateY(-2px); }
.navigation-card:active { transform: scale(0.985); }
.navigation-card strong,
.navigation-card small { display: block; }
.navigation-card strong { margin-bottom: 0.35rem; }

.card-icon,
.timeline-marker {
  width: 3rem;
  height: 3rem;
  display: grid;
  place-items: center;
  margin-bottom: 0.75rem;
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  color: #fff;
  background: rgb(145 118 168 / 0.72);
  box-shadow: inset 0 1px rgb(255 255 255 / 0.32);
}

.section-block { margin-top: 1.35rem; }

.section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.7rem;
}

.section-heading h2 { margin-bottom: 0; }

.memory-card {
  width: 100%;
  padding: 0;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.memory-card:hover { transform: translateY(-2px); }
.memory-card:active { transform: scale(0.99); }

.photo-placeholder {
  min-height: 10.5rem;
  padding: 1rem;
}

.photo-placeholder.orane-photo,
.orane-photo {
  background:
    radial-gradient(circle at 28% 17%, rgb(185 154 98 / 0.42), transparent 29%),
    linear-gradient(140deg, var(--deep), color-mix(in srgb, var(--deep) 55%, var(--rose) 45%));
}

.family-photo {
  background:
    radial-gradient(circle at 50% 14%, rgb(185 154 98 / 0.4), transparent 28%),
    linear-gradient(140deg, color-mix(in srgb, var(--lavender) 45%, var(--deep) 55%), color-mix(in srgb, var(--rose) 38%, var(--deep) 62%));
}

.memory-copy {
  display: block;
  padding: 0.85rem;
}

.memory-copy strong,
.memory-copy small { display: block; }
.memory-copy strong { margin-bottom: 0.25rem; }

.install-card {
  width: 100%;
  display: grid;
  grid-template-columns: 3.1rem minmax(0, 1fr);
  gap: 0.8rem;
  align-items: center;
  margin-top: 1rem;
  padding: 0.95rem;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.install-card .card-icon { margin: 0; }
.install-card strong { display: block; margin-bottom: 0.2rem; }

.chip-row,
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.85rem;
}

.glass-chip {
  padding: 0.42rem 0.72rem;
  border-radius: 999px;
  color: var(--muted-ink);
  font-size: 0.8rem;
}

.fact-grid article { min-height: 7.2rem; padding: 0.95rem; }
.fact-grid strong,
.fact-grid small { display: block; }
.fact-grid strong { margin-bottom: 0.35rem; }

.journey-heading {
  position: relative;
  width: min(100% - 1rem, 68rem);
  margin: 0 auto;
  padding: 5.5rem 1.25rem 2.2rem;
  overflow: hidden;
  border: 1px solid var(--glass-border);
  border-radius: 2rem;
  color: #fff;
  background:
    radial-gradient(circle at 18% 15%, rgb(185 154 98 / 0.35), transparent 25rem),
    linear-gradient(145deg, var(--deep), var(--deep-2));
  box-shadow: 0 1.2rem 3rem var(--glass-shadow), inset 0 1px rgb(255 255 255 / 0.24);
}

.journey-heading .eyebrow,
.journey-heading p { color: rgb(255 255 255 / 0.72); }
.journey-heading p:last-child { margin-bottom: 0; }

.timeline { display: grid; gap: 0.75rem; }

.timeline-item {
  display: grid;
  grid-template-columns: 3.2rem minmax(0, 1fr);
  gap: 0.85rem;
  align-items: center;
  padding: 0.9rem;
}

.timeline-marker { margin: 0; }
.timeline-item strong,
.timeline-item small { display: block; }
.timeline-item strong { margin-bottom: 0.22rem; }

.gallery-pad,
.letter-pad { padding-top: 1.4rem; }
.filter-row { margin: 1rem 0; }
.gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gallery-item[hidden] { display: none; }

.selection-message {
  margin: 0.9rem 0 0;
  padding: 0.85rem 0.95rem;
  border-left: 3px solid var(--gold);
  color: var(--muted-ink);
  font-size: 0.8rem;
}

.letter-card {
  max-width: 40rem;
  margin: 0 auto;
  padding: clamp(1.25rem, 5vw, 2rem);
}

.letter-card::before {
  display: block;
  width: 5rem;
  height: 0.2rem;
  margin: 0 auto 1.2rem;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, var(--hyacinth), transparent);
  content: "";
}

.quote { color: var(--muted-ink); font-size: 1.08rem; }
.signature { margin-top: 1.3rem; }

.tab-bar {
  position: fixed;
  right: max(0.65rem, env(safe-area-inset-right));
  bottom: max(0.55rem, env(safe-area-inset-bottom));
  left: max(0.65rem, env(safe-area-inset-left));
  z-index: 45;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.2rem;
  max-width: 38rem;
  margin: 0 auto;
  padding: 0.4rem;
  border-radius: 1.65rem;
}

.tab-bar[hidden] { display: none; }

.tab-bar button {
  min-height: 3.45rem;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 0.1rem;
  padding: 0.25rem 0.2rem;
  border: 0;
  border-radius: 1.25rem;
  color: var(--muted-ink);
  background: transparent;
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

.tab-bar button span { font-size: 1rem; }
.tab-bar button small { font-size: 0.6rem; }

.tab-bar button[aria-current="page"] {
  color: #fff;
  background: rgb(76 57 91 / 0.84);
  box-shadow: 0 0.4rem 0.9rem var(--glass-shadow), inset 0 1px rgb(255 255 255 / 0.28);
}

.tab-bar button[aria-current="page"] small { color: rgb(255 255 255 / 0.8); }
.tab-bar button:active { transform: scale(0.92); }

.install-dialog {
  width: min(100% - 1.4rem, 30rem);
  max-height: calc(100dvh - 2rem);
  padding: 0;
  border: 0;
  color: var(--ink);
  background: transparent;
}

.install-dialog::backdrop {
  background: rgb(18 13 22 / 0.55);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.dialog-card {
  position: relative;
  padding: 1.35rem;
  border-radius: 1.85rem;
  background: var(--glass-strong);
}

.dialog-close {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  width: 2.2rem;
  height: 2.2rem;
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  color: var(--ink);
  background: var(--glass);
  cursor: pointer;
}

.app-icon-preview {
  width: 4.5rem;
  height: 4.5rem;
  display: grid;
  place-items: center;
  margin-bottom: 1rem;
  border: 1px solid rgb(255 255 255 / 0.3);
  border-radius: 1.2rem;
  color: #fff;
  background:
    radial-gradient(circle at 30% 18%, rgb(255 255 255 / 0.28), transparent 34%),
    linear-gradient(145deg, var(--lavender), var(--deep));
  box-shadow: 0 0.8rem 1.6rem var(--glass-shadow), inset 0 1px rgb(255 255 255 / 0.32);
  font-size: 1.7rem;
}

.dialog-card ol {
  margin: 1rem 0 1.2rem;
  padding-left: 1.4rem;
  color: var(--muted-ink);
}

.dialog-card li { margin-bottom: 0.55rem; line-height: 1.45; }
.dialog-done { width: 100%; }

.offline-toast {
  position: fixed;
  right: 1rem;
  bottom: calc(var(--tab-height) + 0.6rem);
  left: 1rem;
  z-index: 60;
  max-width: 26rem;
  margin: 0 auto;
  padding: 0.75rem 1rem;
  border-radius: 999px;
  color: var(--ink);
  text-align: center;
  font-size: 0.8rem;
}

.offline-toast[hidden] { display: none; }
.svg-definitions { position: absolute; }

@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .glass-surface,
  .glass-card,
  .glass-button,
  .memory-card,
  .glass-chip { background: var(--paper-2); }

  .intro-screen .glass-button { background: rgb(255 255 255 / 0.15); }
}

@media (min-width: 760px) {
  .hero,
  .profile-hero { min-height: 34rem; }
  .content-pad { padding-right: 1.25rem; padding-left: 1.25rem; }
  .gallery-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 520px) {
  .system-time,
  .system-icons { font-size: 0.67rem; }
  .system-icons { letter-spacing: -0.03em; }
  .hero,
  .profile-hero { min-height: 26rem; border-radius: 1.65rem; }
  .card-grid,
  .fact-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr 1fr; gap: 0.65rem; }
  .gallery-item .photo-placeholder { min-height: 8.2rem; }
  .gallery-item .memory-copy { padding: 0.7rem; }
  .gallery-item .memory-copy strong { font-size: 0.84rem; }
  .botanical { width: 5.9rem; }
}

@media (max-width: 370px) {
  .system-icons { display: none; }
  .tab-bar { right: 0.35rem; left: 0.35rem; }
  .tab-bar button small { font-size: 0.56rem; }
  .gallery-grid { grid-template-columns: 1fr; }
}

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

  .island-pulse { animation: none; }
}
