/* ============================================================
   WillYouDateMe — "a note left at dusk"
   One committed visual world: a lit night garden, paper as the
   only warm light. Every colour is painted explicitly so the
   page holds on any host background.
   ============================================================ */

:root {
  /* ground */
  --night:      #150E20;
  --night-deep: #0C0714;
  --dusk:       #2A1B39;
  --mauve:      #6E5A7E;   /* neutral, biased toward the plum ground */
  --mauve-dim:  #4A3B58;

  /* paper */
  --paper-hi:   #FFE2E9;
  --paper:      #FFC7D6;
  --paper-lo:   #FF9FBB;
  --paper-card: #FBF1EC;
  --ink:        #7A2340;
  --ink-soft:   #A2596F;
  --ink-card:   #46212F;
  --rose:       #C1476B;

  /* light */
  --amber:      #FFC46B;
  --leaf:       #8FBF9F;

  --r-md: 14px;
  --r-lg: 22px;

  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
  --ease-out:    cubic-bezier(.16, .84, .44, 1);
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  height: 100%;
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--night);
  background-image:
    radial-gradient(120% 90% at 50% 118%, #34204A 0%, rgba(52,32,74,0) 60%),
    radial-gradient(90% 70% at 50% -10%, #241634 0%, rgba(36,22,52,0) 55%),
    linear-gradient(180deg, var(--night-deep) 0%, var(--night) 45%, #1B1129 100%);
  background-attachment: fixed;
  color: #E8DDEF;
  font-family: "Karla", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
  overscroll-behavior-y: none;
}

button, textarea, input { font: inherit; touch-action: manipulation; }

/* Any `display` an author sets beats the UA rule behind the hidden attribute,
   so state it once and for all: .shoo, .custom, .secret__chip and
   .receipt__row are all laid out with display and all start hidden. */
[hidden] { display: none !important; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.defs { position: absolute; width: 0; height: 0; }

/* ── ambience ─────────────────────────────────────────────── */

#fx {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 5;          /* petals fall in front of everything */
  pointer-events: none;
}

.halo {
  position: fixed;
  left: 50%;
  top: 42%;
  width: min(150vmax, 1100px);
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 50%,
      rgba(255,196,107,.20) 0%,
      rgba(255,150,150,.12) 26%,
      rgba(190,120,200,.07) 46%,
      rgba(21,14,32,0) 70%);
  animation: breathe 9s ease-in-out infinite;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(120% 100% at 50% 45%, rgba(12,7,20,0) 40%, rgba(12,7,20,.78) 100%);
}

@keyframes breathe {
  0%, 100% { opacity: .85; transform: translate(-50%, -50%) scale(1); }
  50%      { opacity: 1;   transform: translate(-50%, -50%) scale(1.06); }
}

/* ── stage & scenes ───────────────────────────────────────── */

.stage {
  position: relative;
  z-index: 3;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  align-items: center;
  align-content: safe center;   /* never strand the top of a tall card */
  padding:
    max(18px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right))
    max(18px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}

.scene {
  grid-area: 1 / 1;
  display: none;
  flex-direction: column;
  align-items: center;
  gap: clamp(16px, 3.2vh, 38px);
  width: 100%;
  max-width: 540px;
}

.scene.is-active {
  display: flex;
  animation: rise .7s var(--ease-out) both;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px) scale(.985); }
  to   { opacity: 1; transform: none; }
}

/* ── the heart post-it ────────────────────────────────────── */

.note {
  position: relative;
  width: min(80vw, 44dvh, 380px);
  filter:
    drop-shadow(0 1px 0 rgba(255,255,255,.22))
    drop-shadow(0 20px 32px rgba(10,4,18,.6))
    drop-shadow(0 0 64px rgba(255,140,170,.24));
  transform: rotate(-3deg);
  animation: bob 7s ease-in-out infinite;
  will-change: transform;
}

@keyframes bob {
  0%, 100% { transform: rotate(-3deg) translateY(0); }
  50%      { transform: rotate(-1.8deg) translateY(-9px); }
}

.note__paper {
  position: relative;
  aspect-ratio: 32 / 29.6;
  clip-path: url(#heartClip);
  background:
    /* light catching each lobe */
    radial-gradient(46% 40% at 26% 20%, rgba(255,255,255,.72) 0%, rgba(255,255,255,0) 62%),
    radial-gradient(42% 36% at 74% 18%, rgba(255,255,255,.46) 0%, rgba(255,255,255,0) 62%),
    /* the paper darkens toward the point */
    radial-gradient(120% 110% at 50% 34%, rgba(122,35,64,0) 52%, rgba(122,35,64,.20) 100%),
    linear-gradient(162deg, var(--paper-hi) 0%, var(--paper) 44%, var(--paper-lo) 100%);
}

/* paper grain */
.note__paper::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: .13;
  mix-blend-mode: multiply;
  pointer-events: none;
}

/* the soft fold running down the middle */
.note__paper::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(97deg,
    rgba(255,255,255,0) 44%, rgba(255,255,255,.34) 49.4%,
    rgba(122,35,64,.10) 50.6%, rgba(122,35,64,0) 57%);
  pointer-events: none;
}

/* stitched edge, drawn just inside the silhouette */
.note__stitch {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  fill: none;
  stroke: rgba(122,35,64,.30);
  stroke-width: .3;
  stroke-linecap: round;
  stroke-dasharray: 1.05 .95;
  pointer-events: none;
}

.note__text {
  position: absolute;
  left: 50%;
  top: 27%;
  width: 76%;
  margin: 0;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: .1em;
  text-align: center;
  font-family: "Caveat", "Bradley Hand", cursive;
  font-weight: 600;
  font-size: clamp(19px, 6.4cqw, 31px);
  line-height: 1.24;
  color: var(--ink);
}

.note__text span:first-child { font-size: 1.08em; }
.note__text span:last-child  { font-size: 1.14em; font-weight: 700; }

.note__sign {
  position: absolute;
  left: 50%;
  top: 63%;
  transform: translateX(-50%) rotate(-4deg);
  font-family: "Caveat", cursive;
  font-size: clamp(14px, 4.4cqw, 20px);
  color: var(--ink-soft);
  white-space: nowrap;
}

/* the note sizes its own type — container queries beat viewport maths here */
.note { container-type: inline-size; }

/* mini + done variants */
.note--mini {
  width: min(24vw, 13dvh, 120px);
  animation: bob 6s ease-in-out infinite;
}
.note__text--mini {
  top: 25%;
  width: 84%;
  font-size: clamp(17px, 21cqw, 27px);
  font-weight: 700;
}
.note--done { width: min(58vw, 27dvh, 300px); }
.note__text--done {
  top: 24%;
  font-size: clamp(26px, 15cqw, 46px);
  font-weight: 700;
  line-height: 1.06;
}

/* ── yes / no ─────────────────────────────────────────────── */

.choice {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.choice__slot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn {
  font-family: "Karla", sans-serif;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: .01em;
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 14px 34px;
  cursor: pointer;
  transition: transform .3s var(--ease-spring), box-shadow .28s var(--ease-out),
              background-color .2s linear, color .2s linear, border-color .2s linear;
}

.btn:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }

.btn--yes {
  background: linear-gradient(168deg, var(--paper-hi), var(--paper-lo));
  color: var(--ink);
  box-shadow: 0 10px 26px rgba(255,120,155,.28), inset 0 1px 0 rgba(255,255,255,.6);
  transform-origin: center;
  transform: scale(var(--yes-scale, 1));
}
.btn--yes:hover { transform: translateY(-3px) scale(var(--yes-scale, 1)); }
.btn--yes:active { transform: translateY(0) scale(calc(var(--yes-scale, 1) * .96)); }

.btn--no {
  background: rgba(110,90,126,.16);
  color: #CFC0DA;
  border-color: rgba(207,192,218,.30);
  padding: 14px 30px;
  backdrop-filter: blur(3px);
  position: relative;
  z-index: 4;
  will-change: transform;
  /* it scoots — a short spring, not a teleport */
  transition: transform .38s var(--ease-spring), color .2s linear,
              border-color .2s linear, opacity .3s linear;
}
.btn--no:hover { color: #EADFF2; border-color: rgba(234,223,242,.5); }

.hint {
  min-height: 1.4em;
  margin: 0;
  font-size: 14px;
  color: var(--mauve);
  letter-spacing: .02em;
  text-align: center;
  opacity: 0;
  transition: opacity .4s linear;
}
.hint.is-on { opacity: 1; }

/* ── the plan card (a notecard on the dark) ───────────────── */

.card {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: clamp(20px, 5vw, 30px);
  border-radius: 4px 18px 4px 18px;
  background: linear-gradient(180deg, #FFF9F5 0%, var(--paper-card) 100%);
  color: var(--ink-card);
  box-shadow:
    0 1px 0 rgba(255,255,255,.7) inset,
    0 26px 50px rgba(8,3,16,.6),
    0 0 70px rgba(255,170,190,.10);
  transform: rotate(.4deg);
  overflow: hidden;
}

.card__head { display: flex; flex-direction: column; gap: 3px; }

.card__title {
  margin: 0;
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  font-size: clamp(28px, 8vw, 38px);
  line-height: 1.05;
  letter-spacing: -.01em;
  color: var(--ink-card);
}

.card__sub { margin: 0; font-size: 14px; color: #8A6472; }

.field {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
}

.field__label {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #9A7080;
}

.field__label i {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 19px;
  height: 19px;
  border-radius: 50%;
  background: var(--rose);
  color: #FFF3F6;
  font-style: normal;
  font-size: 11px;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}

.input {
  width: 100%;
  font-family: "Caveat", cursive;
  font-size: 22px;
  line-height: 1.35;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-bottom: 1.5px solid rgba(193,71,107,.26);
  border-radius: 0;
  padding: 6px 2px 8px;
  resize: none;
  background-image: repeating-linear-gradient(180deg, transparent 0 30px, rgba(193,71,107,.12) 30px 31px);
  background-position: 0 3px;
  -webkit-appearance: none;
  appearance: none;
}
.input::placeholder { color: rgba(154,112,128,.62); font-family: "Karla", sans-serif; font-size: 15px; }
.input:focus { outline: none; border-bottom-color: var(--rose); }
.input:focus-visible { outline: 2px solid rgba(193,71,107,.4); outline-offset: 4px; }

.field__count {
  align-self: flex-end;
  font-size: 11px;
  color: #A88894;
  font-variant-numeric: tabular-nums;
}

/* day rail — bleeds to the card edge so it reads as scrollable */
.field--bleed .days {
  padding-inline: clamp(20px, 5vw, 30px);
  margin-inline: calc(-1 * clamp(20px, 5vw, 30px));
}

.days {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-block: 2px 10px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(193,71,107,.35) transparent;
}
.days::-webkit-scrollbar { height: 4px; }
.days::-webkit-scrollbar-thumb { background: rgba(193,71,107,.28); border-radius: 99px; }

.day {
  flex: 0 0 auto;
  scroll-snap-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  min-width: 60px;
  padding: 9px 10px 10px;
  border-radius: var(--r-md);
  border: 1.5px solid rgba(193,71,107,.22);
  background: rgba(255,255,255,.5);
  color: var(--ink-card);
  cursor: pointer;
  transition: transform .2s var(--ease-spring), background-color .18s linear,
              border-color .18s linear, color .18s linear;
}
.day:hover { border-color: rgba(193,71,107,.5); }
.day__dow { font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #9A7080; }
.day__num { font-family: "Instrument Serif", Georgia, serif; font-size: 22px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.day__mon { font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: #9A7080; }

.day[aria-checked="true"] {
  background: var(--rose);
  border-color: var(--rose);
  color: #FFF4F7;
  box-shadow: 0 8px 18px rgba(193,71,107,.32);
  transform: translateY(-2px);
}
.day[aria-checked="true"] .day__dow,
.day[aria-checked="true"] .day__mon { color: rgba(255,244,247,.82); }

/* time chips */
.times { display: flex; flex-wrap: wrap; gap: 8px; }

.time {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 9px 14px;
  border-radius: 999px;
  border: 1.5px solid rgba(193,71,107,.22);
  background: rgba(255,255,255,.5);
  color: var(--ink-card);
  font-size: 14px;
  cursor: pointer;
  transition: transform .2s var(--ease-spring), background-color .18s linear,
              border-color .18s linear, color .18s linear;
}
.time:hover { border-color: rgba(193,71,107,.5); }
.time b { font-weight: 700; font-variant-numeric: tabular-nums; }
.time span { color: #9A7080; font-size: 13px; }

.time[aria-checked="true"] {
  background: var(--rose);
  border-color: var(--rose);
  color: #FFF4F7;
  box-shadow: 0 8px 18px rgba(193,71,107,.3);
  transform: translateY(-2px);
}
.time[aria-checked="true"] span { color: rgba(255,244,247,.8); }

.custom {
  align-items: center;
  gap: 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #9A7080;
  animation: rise .35s var(--ease-out) both;
}
.custom:not([hidden]) { display: flex; }

.input--time {
  width: auto;
  -webkit-appearance: auto;
  appearance: auto;
  font-family: "Karla", sans-serif;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
  background-image: none;
  color: var(--ink-card);
}

.card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding-top: 4px;
  border-top: 1px dashed rgba(193,71,107,.24);
}

.summary {
  margin: 0;
  flex: 1 1 170px;
  font-family: "Caveat", cursive;
  font-size: 20px;
  line-height: 1.2;
  color: var(--ink-soft);
}
.summary.is-set { color: var(--ink); }

.btn--confirm {
  background: var(--rose);
  color: #FFF4F7;
  box-shadow: 0 12px 24px rgba(193,71,107,.34);
}
.btn--confirm:hover:not(:disabled) { transform: translateY(-2px); }
.btn--confirm:disabled {
  background: rgba(193,71,107,.18);
  color: rgba(70,33,47,.42);
  box-shadow: none;
  cursor: not-allowed;
}
.btn--confirm.is-sending { pointer-events: none; opacity: .75; }

/* the nickname, when it is the wrong nickname */
.field.has-error .input { border-bottom-color: var(--rose); }
.field.has-error { animation: shake .4s var(--ease-out) both; }

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-7px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(2px); }
}

/* ── the option that does not advertise itself ─────────────── */

.secret {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 26px;
}

.secret__latch {
  border: 0;
  background: none;
  padding: 2px 4px;
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
  opacity: .16;
  filter: grayscale(1);
  transform: rotate(-8deg);
  transition: opacity .3s var(--ease-out), filter .3s var(--ease-out),
              transform .4s var(--ease-spring);
}
.secret__latch:hover,
.secret__latch:focus-visible { opacity: .9; filter: none; transform: rotate(24deg); }
.secret__latch:focus-visible { outline: 2px solid var(--rose); outline-offset: 2px; border-radius: 6px; }
.secret__latch.is-open { opacity: .45; filter: none; transform: rotate(90deg); }

.secret__chip {
  align-items: baseline;
  gap: 7px;
  padding: 9px 14px;
  border-radius: 999px;
  border: 1.5px dashed rgba(193,71,107,.4);
  background: rgba(255,255,255,.5);
  color: var(--ink-card);
  font-size: 14px;
  cursor: pointer;
  animation: rise .35s var(--ease-out) both;
  transition: transform .2s var(--ease-spring), background-color .18s linear,
              border-color .18s linear, color .18s linear;
}
.secret__chip:not([hidden]) { display: inline-flex; }
.secret__chip b { font-weight: 700; }
.secret__chip span { color: #9A7080; font-size: 13px; }
.secret__chip:hover { border-color: var(--rose); }
.secret__chip[aria-checked="true"] {
  background: var(--ink-card);
  border-style: solid;
  border-color: var(--ink-card);
  color: #FFF4F7;
  box-shadow: 0 8px 18px rgba(70,33,47,.34);
  transform: translateY(-2px);
}
.secret__chip[aria-checked="true"] span { color: rgba(255,244,247,.75); }

/* ── shoo ──────────────────────────────────────────────────── */

.shoo {
  position: fixed;
  inset: 0;
  z-index: 40;
  place-items: center;
  padding: 22px;
  background: rgba(12,7,20,.62);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity .22s var(--ease-out);
}
.shoo:not([hidden]) { display: grid; }
.shoo.is-on { opacity: 1; }

.shoo__box {
  width: min(100%, 340px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
  padding: 26px 24px 22px;
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, #FFF9F5 0%, var(--paper-card) 100%);
  border: 1px solid rgba(193,71,107,.3);
  box-shadow: 0 28px 60px rgba(8,3,16,.6);
  transform: translateY(14px) scale(.94);
  transition: transform .32s var(--ease-spring);
}
.shoo.is-on .shoo__box { transform: none; }

.shoo__broom {
  margin: 0;
  font-size: 40px;
  line-height: 1;
  animation: sweep 1.1s var(--ease-out) infinite;
}
@keyframes sweep {
  0%, 100% { transform: rotate(-18deg); }
  50% { transform: rotate(18deg); }
}

.shoo__title {
  margin: 0;
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  font-size: 30px;
  line-height: 1.05;
  color: var(--ink-card);
}
.shoo__body {
  margin: 0;
  font-family: "Caveat", cursive;
  font-size: 22px;
  line-height: 1.25;
  color: var(--rose);
}
.btn--shoo {
  margin-top: 6px;
  padding: 11px 20px;
  font-size: 14px;
  background: var(--ink-card);
  color: #FFF4F7;
  box-shadow: 0 10px 22px rgba(70,33,47,.32);
}
.btn--shoo:hover { transform: translateY(-2px); }

@media (prefers-reduced-motion: reduce) {
  .shoo__broom, .field.has-error { animation: none; }
}

/* ── receipt ──────────────────────────────────────────────── */

.receipt {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
  text-align: center;
  padding: clamp(18px, 5vw, 26px);
  border-radius: var(--r-lg);
  background: rgba(42,27,57,.66);
  border: 1px solid rgba(255,196,107,.22);
  backdrop-filter: blur(10px);
  box-shadow: 0 24px 50px rgba(8,3,16,.55);
}

.receipt__title {
  margin: 0;
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  font-size: clamp(32px, 9vw, 50px);
  line-height: 1;
  color: #FFEAF0;
}
.receipt__title em { font-style: italic; color: var(--amber); }

.receipt__rows { margin: 0; width: 100%; display: flex; flex-direction: column; }

.receipt__row {
  align-items: baseline;
  gap: 14px;
  padding: 9px 2px;
  border-top: 1px solid rgba(255,255,255,.09);
  text-align: left;
}
.receipt__row dt {
  flex: 0 0 68px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mauve);
}
.receipt__row dd { margin: 0; flex: 1; font-size: 16px; color: #F2E6F7; }
.receipt__row:not([hidden]) { display: flex; }
.receipt__row--note dd {
  font-family: "Caveat", cursive;
  font-size: 21px;
  line-height: 1.25;
  color: var(--paper);
}

.receipt__status {
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13.5px;
  color: var(--mauve);
}
.receipt__status.is-sent { color: var(--amber); }
.muted { font-style: italic; color: var(--mauve); opacity: .85; }

.dot {
  flex: 0 0 auto;
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--mauve-dim);
  animation: pulse 1.4s ease-out infinite;
}
.receipt__status.is-sent .dot {
  background: var(--amber); animation: none;
  box-shadow: 0 0 12px rgba(255,196,107,.8);
}

@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(255,196,107,.45); }
  70%  { box-shadow: 0 0 0 9px rgba(255,196,107,0); }
  100% { box-shadow: 0 0 0 0 rgba(255,196,107,0); }
}

.linkbtn {
  background: none;
  border: 0;
  padding: 4px 6px;
  font-size: 13px;
  letter-spacing: .06em;
  color: var(--mauve);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: rgba(110,90,126,.5);
  cursor: pointer;
}
.linkbtn:hover { color: #CFC0DA; }
.linkbtn:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; border-radius: 4px; }

/* ── sound toggle ─────────────────────────────────────────── */

.sound {
  position: fixed;
  top: max(14px, env(safe-area-inset-top));
  right: max(14px, env(safe-area-inset-right));
  z-index: 30;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(207,192,218,.2);
  background: rgba(42,27,57,.5);
  color: var(--mauve);
  font-size: 15px;
  cursor: pointer;
  backdrop-filter: blur(6px);
  transition: color .2s linear, border-color .2s linear, transform .2s var(--ease-spring);
}
.sound:hover { transform: scale(1.06); color: #CFC0DA; }
.sound[aria-pressed="true"] { color: var(--amber); border-color: rgba(255,196,107,.45); }
.sound:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }

/* ── phones ───────────────────────────────────────────────── */

@media (max-width: 480px) {
  .scene { gap: 18px; }
  .btn { padding: 15px 30px; font-size: 16px; }
  .btn--no { padding: 15px 26px; }
  .card__foot { flex-direction: column-reverse; align-items: stretch; gap: 12px; }
  .btn--confirm { width: 100%; }
  .summary { text-align: center; flex: 0 0 auto; }
  .receipt__row { gap: 10px; }
  .receipt__row dt { flex-basis: 58px; letter-spacing: .1em; }
}

/* landscape phones: the note has to give up height */
@media (max-height: 560px) and (orientation: landscape) {
  .stage { padding-block: 14px; }
  .scene { gap: 12px; }
  .note { width: min(38vw, 60vh, 260px); }
  .note--done { width: min(30vw, 48vh, 200px); }
  .note--mini { display: none; }
}

/* ── motion preferences ───────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  .note, .halo { animation: none; }
  .note { transform: rotate(-3deg); }
  .scene.is-active { animation: none; }
  .btn, .day, .time { transition: none; }
  .btn--no { transition: transform .12s linear; }
  .dot { animation: none; }
}
