/* Palette sampled from the party's own sticker (blush/peach + sage + warm rose ink),
   kept light so white dominates — a baby mood, not a boho-wedding one.
   Always light: forced below regardless of device dark-mode setting, since a
   dark theme fought the explicit "bright, baby-soft" request. */
:root {
  color-scheme: light only;
  --bg: #FFFDFB;
  --surface: #FFFFFF;
  --ink: #6B5147;
  --muted: #A6897F;
  --blush: #F6D9CF;
  --blush-soft: #FBEAE3;
  --rose: #A85F52;
  --sage: #A3C19B;
  --sage-deep: #6E8F66;
  --gold: #D1A95D;
  --line: #F3E2DA;

  /* Fibonacci-derived spacing rhythm (converges to the golden ratio, 1.618) */
  --sp-1: 0.5rem;    /* 8px  */
  --sp-2: 0.8125rem; /* 13px */
  --sp-3: 1.3125rem; /* 21px */
  --sp-4: 2.125rem;  /* 34px */
  --sp-5: 3.4375rem; /* 55px */

  --shadow: 0 14px 28px -18px rgba(193, 127, 114, .28);
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body: "Mulish", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* overflow-x: the hero glow is deliberately wider than the column; without
   clipping, iOS Safari lets the whole page pan sideways. */
html, body { overflow-x: hidden; }
.view { display: none; position: relative; z-index: 1; min-height: 100vh; overflow-x: clip; }
.view.active { display: block; }

.wrap {
  width: 100%; max-width: 28rem; margin: 0 auto;
  padding: var(--sp-4) max(20px, env(safe-area-inset-left, 0px)) var(--sp-5);
  display: flex; flex-direction: column; gap: var(--sp-4);
}

/* Hero medallion — a single soft, CONTAINED glow behind it, not a page-wide wash */
.hero { display: grid; place-items: center; position: relative; }
.hero::before {
  content: ""; position: absolute; width: 140%; aspect-ratio: 1; z-index: 0;
  background: radial-gradient(closest-side, var(--blush-soft), transparent 70%);
}
/* golden-ratio proportion: medallion width ≈ column width / φ */
.medallion { position: relative; z-index: 1; width: min(58vw, calc(28rem / 1.618)); aspect-ratio: 1; }
.medallion img {
  position: relative; width: 100%; height: 100%;
  object-fit: cover; border-radius: 50%;
  background: #FFFFFF;
  box-shadow: 0 0 0 1px var(--line), 0 0 0 8px var(--surface), var(--shadow);
}

.spark, .leaf { position: absolute; pointer-events: none; z-index: 1; }
.spark { color: var(--gold); }
.leaf  { color: var(--sage); opacity: .9; }
.s1 { top: -2%; right: 2%; width: 1.4rem; }
.s2 { bottom: 6%; left: -5%; width: .95rem; }
.l1 { bottom: -4%; right: -2%; width: 2.8rem; transform: rotate(18deg); }
.l2 { top: -6%; left: 0%; width: 2.4rem; transform: scaleX(-1) rotate(10deg); }
.spark svg, .leaf svg { width: 100%; height: auto; display: block; }

.intro { text-align: center; display: flex; flex-direction: column; gap: var(--sp-1); align-items: center; }
.eyebrow {
  font-family: var(--display); font-style: italic; font-weight: 500;
  font-size: 1rem; color: var(--rose); margin: 0;
}
/* display name: body size × φ² — the one deliberately dramatic golden jump on the page */
.name {
  font-family: var(--display); font-weight: 600;
  font-size: clamp(2.6rem, 12vw, 3.4rem); color: var(--ink); margin: 0;
  letter-spacing: -.01em;
}
.sprig-rule { display: flex; align-items: center; gap: var(--sp-1); color: var(--sage); margin-top: var(--sp-1); }
.sprig-rule svg { width: 2.3rem; color: var(--sage); }
.sprig-rule .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--gold); }
.sub { font-size: .95rem; color: var(--muted); max-width: 22rem; text-wrap: pretty; margin: 0; }

/* Nav cards (landing) */
.cards { display: flex; flex-direction: column; gap: var(--sp-2); }
.card {
  position: relative; display: flex; align-items: center; gap: var(--sp-2);
  width: 100%; text-align: left; font: inherit; color: inherit;
  background: var(--surface); border: 1px solid var(--line); border-radius: 20px;
  padding: var(--sp-3); box-shadow: var(--shadow); cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.card:active { transform: scale(.985); }
.ic {
  flex: none; width: 2.75rem; height: 2.75rem; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--blush-soft); color: var(--rose);
}
.ic.green { background: color-mix(in srgb, var(--sage) 28%, transparent); color: var(--sage-deep); }
.ic.gold { background: color-mix(in srgb, var(--gold) 22%, transparent); color: #A37F3A; }
.ic svg { width: 1.35rem; height: 1.35rem; }
.ct { display: flex; flex-direction: column; gap: .12rem; min-width: 0; flex: 1; }
.ct h2 { font-family: var(--display); font-weight: 600; font-size: 1.15rem; margin: 0; color: var(--ink); }
.ct p { margin: 0; font-size: .85rem; color: var(--muted); }
.arrow { flex: none; color: var(--rose); opacity: .8; }
.arrow svg { width: 1.1rem; height: 1.1rem; display: block; }

.foot {
  text-align: center; font-size: .78rem; color: var(--muted);
  display: flex; flex-direction: column; gap: var(--sp-1); align-items: center; margin-top: .2rem;
}
.foot .heart { color: var(--rose); }

/* Inner views (mural / recado) */
.view-header {
  display: flex; align-items: center; gap: var(--sp-2);
  max-width: 28rem; margin: 0 auto;
  padding: var(--sp-4) 20px 0;
}
.view-header h2 { font-family: var(--display); font-weight: 600; margin: 0; font-size: 1.4rem; color: var(--ink); }
.btn-back {
  background: var(--surface); border: 1px solid var(--line); border-radius: 50%;
  width: 2.3rem; height: 2.3rem; font-size: 1.1rem; cursor: pointer; color: var(--ink);
  display: grid; place-items: center; box-shadow: var(--shadow);
}

.panel { max-width: 28rem; margin: var(--sp-2) auto 0; padding: 0 20px; }

.upload-form {
  display: flex; gap: var(--sp-1); flex-wrap: wrap; align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: 18px;
  padding: var(--sp-2); box-shadow: var(--shadow); margin-bottom: var(--sp-3);
}
.upload-form input[type=text] {
  flex: 1; min-width: 120px; padding: .7rem .8rem; border-radius: 12px;
  border: 1px solid var(--line); background: var(--bg); color: var(--ink); font: inherit;
}
.file-label {
  background: var(--rose); color: #fff; padding: .7rem 1.1rem; border-radius: 12px;
  font-weight: 700; cursor: pointer; font-size: .92rem; white-space: nowrap;
}
.file-label input { display: none; }
.upload-status { width: 100%; color: var(--muted); font-size: .85rem; min-height: 1.1rem; }

.grid {
  max-width: 28rem; margin: 0 auto; padding: 0 20px var(--sp-4);
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-1);
}
.grid img {
  width: 100%; height: 7.2rem; object-fit: cover; border-radius: 14px;
  cursor: pointer; border: 1px solid var(--line); box-shadow: 0 6px 14px -8px rgba(193,127,114,.3);
}

.upload-hint { width: 100%; margin: 0; color: var(--muted); font-size: .8rem; }
.grid-video {
  position: relative; padding: 0; border: 0; background: none; cursor: pointer; display: block;
}
.grid-video img { display: block; }
.grid-video .play-badge {
  position: absolute; left: 6px; bottom: 6px; display: inline-flex; align-items: center; gap: 3px;
  background: rgba(255, 253, 251, .92); color: var(--rose); border-radius: 999px;
  padding: 2px 8px 2px 6px; font: 700 .72rem/1.4 var(--body, inherit);
  box-shadow: 0 2px 6px rgba(80, 50, 40, .18);
}

/* Ultras: a vertical timeline, sage thread with gold beads, oldest first */
.ultras {
  list-style: none; max-width: 28rem; margin: 0 auto; padding: 0 20px var(--sp-5);
  display: flex; flex-direction: column; gap: var(--sp-4); position: relative;
}
.ultras li { position: relative; padding-left: var(--sp-4); }
.ultras li::before {
  content: ""; position: absolute; left: .55rem; top: 0; bottom: calc(-1 * var(--sp-4));
  border-left: 1.5px dashed var(--sage);
}
.ultras li:last-child::before { bottom: 0; }
.ultras li::after {
  content: ""; position: absolute; left: .25rem; top: 1rem; width: .7rem; height: .7rem;
  border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px var(--bg);
}
.ultras img {
  width: 100%; display: block; border-radius: 18px; cursor: pointer;
  border: 1px solid var(--line); box-shadow: 0 0 0 6px var(--surface), var(--shadow);
  background: #222;
}
/* Interactive timeline: a plain flex rail (one stop per exam) synced to a
   swipeable Swiper deck. Not a Swiper itself: with a handful of exams every stop
   fits on a phone at once, and nothing is left hidden past the edge. */
.ut { max-width: 28rem; margin: 0 auto; padding-bottom: var(--sp-5); }
.ut-rail-wrap { position: relative; padding: var(--sp-2) 0 var(--sp-3); }
.ut-rail-hint { text-align: center; font-size: .72rem; color: var(--muted); margin: 0 0 .5rem; letter-spacing: .02em; }
.ut-rail {
  position: relative; display: flex; justify-content: space-between; gap: .25rem;
  overflow-x: auto; padding: .3rem 20px 0; scrollbar-width: none;
}
.ut-rail::-webkit-scrollbar { display: none; }
.ut-rail::before {
  content: ""; position: absolute; left: 32px; right: 32px; top: calc(.3rem + 1.15rem);
  border-top: 1.5px dashed var(--sage);
}
.ut-dot {
  flex: none; display: flex; flex-direction: column; align-items: center; gap: .25rem;
  min-width: 2.9rem; padding: 0; border: 0; background: none; font: inherit; color: inherit;
  cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.ut-day {
  width: 2.3rem; height: 2.3rem; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); border: 1.5px solid var(--sage); color: var(--sage-deep);
  font-weight: 700; font-size: .9rem; position: relative; z-index: 1;
  transition: background .25s, color .25s, transform .25s, border-color .25s;
}
.ut-mon { font-size: .72rem; color: var(--muted); letter-spacing: .02em; white-space: nowrap; }
.ut-dot.active .ut-day {
  background: var(--gold); border-color: var(--gold); color: #fff; transform: scale(1.12);
}
.ut-dot.active .ut-mon { color: var(--rose); font-weight: 700; }
.ut-dot.undated .ut-day { border-style: dashed; }
.ut-rail-wrap.scrollable .ut-rail {
  -webkit-mask-image: linear-gradient(to right, transparent, #000 1.5rem, #000 calc(100% - 1.5rem), transparent);
  mask-image: linear-gradient(to right, transparent, #000 1.5rem, #000 calc(100% - 1.5rem), transparent);
}

.ut-nav {
  display: flex; align-items: center; justify-content: center; gap: var(--sp-2);
  margin: 0 auto var(--sp-1); padding: 0 20px;
}

.ut-arrow {
  width: 2.5rem; height: 2.5rem; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); border: 1px solid var(--line); color: var(--rose);
  box-shadow: var(--shadow); cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.ut-arrow svg { width: 1.2rem; height: 1.2rem; }
.ut-arrow:disabled { opacity: .3; box-shadow: none; cursor: default; }
.ut-arrow:not(:disabled):active { transform: scale(.94); }
.ut-play {
  position: relative; width: 3.2rem; height: 3.2rem; border-radius: 50%; border: 0;
  display: grid; place-items: center; background: var(--rose); color: #fff;
  box-shadow: var(--shadow); cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.ut-play:active { transform: scale(.95); }
.ut-play > svg:not(.ut-ring) { width: 1.35rem; height: 1.35rem; grid-area: 1 / 1; }
.ut-play .ic-pause, .ut-play.playing .ic-play { display: none; }
.ut-play.playing .ic-pause { display: block; }
/* progress ring: how long until the next exam */
.ut-ring { position: absolute; inset: -5px; width: calc(100% + 10px); height: calc(100% + 10px); transform: rotate(-90deg); pointer-events: none; }
.ut-ring circle {
  fill: none; stroke: var(--gold); stroke-width: 2.5; stroke-linecap: round;
  stroke-dasharray: 138.2; stroke-dashoffset: 138.2;
}
.ut-cover img { transition: opacity .22s ease; }
.ut-cover img.fading { opacity: 0; }
/* deterrents against saving: no iOS long-press sheet, no selection, no drag */
#view-ultras img, .pswp img {
  -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; -webkit-user-drag: none;
}
#view-ultras .ut-card, #view-ultras .ut-rail { -webkit-user-select: none; user-select: none; }

.ut-main { padding: var(--sp-1) 0 var(--sp-2); }
.ut-slide { transition: opacity .3s, transform .3s; opacity: .45; transform: scale(.94); }
.ut-slide.swiper-slide-active { opacity: 1; transform: none; }
.ut-card {
  margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 22px;
  padding: var(--sp-1); box-shadow: var(--shadow);
}
.ut-card img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; border-radius: 16px;
  background: #1d1a19; cursor: zoom-in;
}
.ut-card figcaption { padding: var(--sp-2) var(--sp-1) var(--sp-1); }
.ut-card .ultra-caption { margin: .35rem 0 0; }
.ut-gap {
  display: inline-block; font-size: .75rem; font-weight: 700; color: var(--sage-deep);
  background: color-mix(in srgb, var(--sage) 22%, transparent); border-radius: 999px; padding: .2rem .65rem;
}
.ut-date { margin: .2rem 0 0; font-size: .9rem; color: var(--ink); }
.ut-device { margin: .15rem 0 0; font-size: .75rem; color: var(--muted); }
.ut-cover, .ut-thumb { position: relative; display: block; }
.ut-thumb { flex: none; }
.ut-3d {
  position: absolute; top: .45rem; left: .45rem; pointer-events: none;
  font-size: .68rem; font-weight: 700; letter-spacing: .04em; color: #fff;
  background: color-mix(in srgb, var(--rose) 88%, transparent); border-radius: 999px; padding: .12rem .5rem;
}
.ut-thumb .ut-3d { top: .2rem; left: .2rem; font-size: .55rem; padding: .05rem .32rem; }
.ut-note { margin: .2rem 0 0; font-size: .9rem; color: var(--ink); }
.ut-strip {
  display: flex; gap: .4rem; overflow-x: auto; padding: .5rem .1rem .1rem;
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.ut-strip::-webkit-scrollbar { display: none; }
/* fade the right edge while there are more thumbnails to scroll to */
.ut-strip.more {
  -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 2.5rem), transparent);
  mask-image: linear-gradient(to right, #000 calc(100% - 2.5rem), transparent);
}
.ut-strip img {
  flex: none; width: 3.4rem; height: 3.4rem; object-fit: cover; border-radius: 10px;
  border: 1px solid var(--line); background: #1d1a19; cursor: zoom-in;
}
.ut-count { text-align: center; font-size: .8rem; font-weight: 600; color: var(--muted); margin: 0 0 var(--sp-1); }

.ultra-caption {
  margin: var(--sp-2) 0 0; font-family: var(--display); font-style: italic;
  font-size: 1.1rem; color: var(--rose);
}

.hint { max-width: 22rem; margin: 0 auto var(--sp-3); color: var(--muted); text-align: center; font-size: .9rem; padding: 0 20px; }

.message-form {
  max-width: 28rem; margin: 0 auto; padding: 0 20px var(--sp-4);
  display: flex; flex-direction: column; gap: var(--sp-2);
}
.message-form label { display: flex; flex-direction: column; gap: .4rem; font-size: .85rem; color: var(--muted); }
.message-form input, .message-form textarea, .message-form select {
  font: inherit; font-size: 1rem; padding: .8rem .9rem; border-radius: 14px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink); resize: vertical;
}
.message-form .btn-primary { align-self: stretch; margin-top: var(--sp-1); }
.message-form .btn-primary:disabled { opacity: .6; }
.msg-video-field { display: flex; flex-direction: column; gap: .4rem; }
.message-form .msg-video-pick {
  flex-direction: row; justify-content: center; align-items: center; cursor: pointer;
  border: 1.5px dashed var(--line); border-radius: 12px; padding: .8rem; background: var(--surface);
  color: var(--rose); font-weight: 700; font-size: .9rem;
}
.msg-video-pick input { display: none; }
.msg-video-preview { display: flex; flex-direction: column; gap: .4rem; align-items: center; }
.msg-video-preview video { width: 100%; max-height: 22rem; border-radius: 12px; background: #000; }
.msg-video-remove {
  background: none; border: 0; color: var(--muted); text-decoration: underline; font: inherit;
  font-size: .85rem; cursor: pointer;
}

.btn-primary {
  font-family: var(--body); font-weight: 700; font-size: 1rem;
  background: var(--rose); color: #fff; border: none; border-radius: 14px;
  padding: .9rem 1.2rem; cursor: pointer; box-shadow: var(--shadow);
}

.thanks { max-width: 22rem; margin: 15vh auto 0; text-align: center; padding: 0 20px; }
.thanks-emoji { font-size: 2.8rem; margin: 0 0 .4rem; }
.hidden { display: none !important; }

.lightbox {
  position: fixed; inset: 0; background: rgba(42, 33, 29, .9);
  display: flex; align-items: center; justify-content: center;
  z-index: 50; padding: 20px;
}
.lightbox { flex-direction: column; gap: var(--sp-2); }
.lightbox img, .lightbox video { max-width: 100%; max-height: calc(100% - 7rem); border-radius: 12px; }
.lightbox video { background: #000; }
.lightbox.has-actions img { max-height: calc(100% - 11rem); }
.lb-actions { display: flex; flex-direction: column; align-items: stretch; gap: .5rem; width: min(100%, 20rem); }
.btn-magic {
  font-family: var(--body); font-weight: 700; font-size: 1rem; cursor: pointer;
  color: #fff; border: none; border-radius: 14px; padding: .9rem 1.2rem;
  background: linear-gradient(100deg, #E7A9A0, var(--gold));
  box-shadow: 0 0 0 3px rgba(209, 169, 93, .35), 0 8px 22px -8px rgba(209, 169, 93, .8);
}
.btn-ghost {
  font-family: var(--body); font-weight: 700; font-size: 1rem; cursor: pointer;
  background: var(--surface); color: var(--rose); border: 1px solid var(--line);
  border-radius: 14px; padding: .85rem 1.2rem;
}
.btn-ghost:disabled, .pe-actions .btn-primary:disabled { opacity: .6; }

/* Polaroid editor */
.pe {
  position: fixed; inset: 0; z-index: 60; background: var(--bg); overflow-y: auto;
  display: flex; flex-direction: column; gap: var(--sp-2);
  padding: max(16px, env(safe-area-inset-top, 0px)) 16px max(20px, env(safe-area-inset-bottom, 0px));
}
.pe-head { display: flex; align-items: center; gap: .8rem; }
.pe-head h2 { margin: 0; font-family: var(--display); font-weight: 600; font-size: 1.3rem; color: var(--ink); }
.pe-stage { display: flex; justify-content: center; padding: .4rem 0; }
.pe-card {
  position: relative; width: min(100%, 22rem, calc((100dvh - 19rem) * .8));
  transform: rotate(-1.5deg); box-shadow: 0 14px 30px -12px rgba(80, 50, 40, .45);
  container-type: inline-size; background: #FFFDFB; min-height: 6rem;
}
.pe-card img { display: block; width: 100%; height: auto; }
.pe-card img.developing { animation: pe-develop 2s ease-out; }
@keyframes pe-develop {
  0% { filter: sepia(1) brightness(1.7) contrast(.45) blur(1.5px); }
  100% { filter: none; }
}
.pe-caption {
  position: absolute; font-family: "Caveat", cursive; font-weight: 600; line-height: 1;
  white-space: nowrap; pointer-events: none; transform: translateY(-50%);
}
.pe-styles { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; }
.pe-styles button {
  font: 700 .75rem var(--body); color: var(--ink); background: var(--surface); cursor: pointer;
  border: 2px solid var(--line); border-radius: 12px; padding: .45rem .25rem; line-height: 1.2;
  display: flex; flex-direction: column; align-items: center; gap: .3rem;
}
.pe-styles button[aria-checked="true"] { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(209, 169, 93, .3); }
.pe-styles .swatch { font-size: 1.2rem; line-height: 1; }
.pe-field { display: flex; flex-direction: column; gap: .35rem; font-size: .85rem; color: var(--muted); }
.pe-field input {
  font-family: "Caveat", cursive; font-weight: 600; font-size: 1.5rem; color: var(--ink);
  border: 1.5px dashed var(--line); border-radius: 12px; padding: .35rem .8rem; background: var(--surface);
}
.pe-actions { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.pe-hint { margin: 0; text-align: center; color: var(--muted); font-size: .8rem; min-height: 1rem; }
.lb-actions .btn-primary:disabled { opacity: .6; }
.lb-hint { margin: 0; color: rgba(255, 255, 255, .75); font-size: .8rem; }

.tv-link {
  display: flex; align-items: center; justify-content: center; gap: .5rem;
  margin: 0 0 var(--sp-3); padding: .75rem 1rem; border-radius: 14px;
  background: var(--surface); border: 1px dashed var(--sage); color: var(--sage-deep);
  font-weight: 700; font-size: .92rem; text-decoration: none;
}
.tv-link svg { width: 1.05rem; height: 1.05rem; }

/* --- Telão: slideshow for a TV / projector (also works on a phone) --- */
body.tv { height: 100vh; height: 100dvh; overflow: hidden; background: var(--bg); cursor: default; }
body.tv.idle { cursor: none; }
.tv-backdrop {
  position: fixed; inset: -60px; background-size: cover; background-position: center;
  filter: blur(48px) saturate(1.1); opacity: .32; transition: background-image 1.2s;
}
.tv-backdrop::after { content: ""; position: absolute; inset: 0; background: radial-gradient(closest-side, transparent, var(--bg)); }
.tv-stage { position: fixed; inset: 0 0 5.5rem; display: grid; place-items: center; }
.tv-frame {
  grid-area: 1 / 1; margin: 0; padding: clamp(8px, 1.2vw, 16px); background: #fff; border-radius: 6px;
  box-shadow: 0 30px 60px -30px rgba(107, 81, 71, .45); opacity: 0; transform: scale(.985);
  transition: opacity 1.2s ease, transform 1.2s ease; text-align: center;
}
.tv-frame.on { opacity: 1; transform: none; }
.tv-frame img {
  display: block; max-width: 88vw; max-height: calc(100vh - 13rem); max-height: calc(100dvh - 13rem);
  object-fit: contain; border-radius: 3px;
}
.tv-frame.on img { animation: tv-drift 8s ease-out forwards; }
@keyframes tv-drift { from { transform: scale(1); } to { transform: scale(1.03); } }
@media (prefers-reduced-motion: reduce) { .tv-frame.on img { animation: none; } }
.tv-frame figcaption {
  font-family: var(--display); font-style: italic; color: var(--rose);
  font-size: clamp(1rem, 2vw, 1.6rem); padding-top: .4em; min-height: 1.6em;
}
.tv-empty { grid-area: 1 / 1; text-align: center; color: var(--muted); font-size: clamp(1rem, 2.2vw, 1.8rem); }
.tv-empty img { width: clamp(120px, 18vw, 220px); border-radius: 50%; box-shadow: var(--shadow); display: block; margin: 0 auto 1rem; }
.tv-new {
  position: fixed; top: 1.2rem; left: 50%; transform: translateX(-50%);
  background: var(--gold); color: #fff; font-weight: 700; border-radius: 999px;
  padding: .4rem 1rem; font-size: clamp(.85rem, 1.6vw, 1.2rem); box-shadow: var(--shadow);
}
.tv-bar {
  position: fixed; left: 0; right: 0; bottom: 0; height: 5.5rem; padding: 0 clamp(16px, 3vw, 48px);
  display: flex; align-items: center; gap: 1rem; background: rgba(255, 253, 251, .86);
  border-top: 1px solid var(--line); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.tv-logo { width: 3.4rem; height: 3.4rem; border-radius: 50%; box-shadow: 0 0 0 1px var(--line); }
.tv-title { font-family: var(--display); font-weight: 600; font-size: clamp(1.1rem, 2.2vw, 1.9rem); color: var(--ink); }
.tv-cta { margin-left: auto; color: var(--rose); font-weight: 700; font-size: clamp(.8rem, 1.5vw, 1.2rem); text-align: right; }
.tv-count { color: var(--muted); font-size: clamp(.75rem, 1.2vw, 1rem); white-space: nowrap; }
.tv-tools { position: fixed; top: 1rem; right: 1rem; display: flex; gap: .5rem; transition: opacity .4s; }
body.tv.idle .tv-tools { opacity: 0; pointer-events: none; }
.tv-tools a, .tv-tools button {
  font: inherit; font-size: .85rem; font-weight: 700; color: var(--ink); text-decoration: none;
  background: rgba(255, 255, 255, .9); border: 1px solid var(--line); border-radius: 999px; padding: .45rem .9rem; cursor: pointer;
}
@media (max-width: 640px) {
  .tv-cta { display: none; }
  .tv-stage { inset: 0 0 4.5rem; }
  .tv-bar { height: 4.5rem; }
  .tv-logo { width: 2.6rem; height: 2.6rem; }
}
