/* Web / iPhone additions */
:root { --safe-top: max(env(safe-area-inset-top), 20px); --safe-bottom: max(env(safe-area-inset-bottom), 10px); }
html { -webkit-text-size-adjust: 100%; }
body { overscroll-behavior-y: none; }
.toast { white-space: normal; }

/* Lasting indicator under the header */
.open-note { display: inline-flex; align-items: center; gap: 7px; margin: -4px 0 16px 2px; padding: 5px 11px 5px 9px; border-radius: 99px;
  font-size: 12.5px; font-weight: 550; letter-spacing: -.005em; color: var(--label2); background: rgba(255,255,255,.055); border: .5px solid rgba(255,255,255,.08);
  transition: transform .3s var(--spring), opacity .6s var(--ease); }
.open-note:active { transform: scale(.96); }
.open-note .on-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px rgba(48,209,88,.16); }
.open-note .on-sep { color: var(--label3); }
.open-note .on-dim { color: var(--label3); }
.boot .open-note { opacity: 0; }

/* First-visit notice */
.web-intro { border-radius: var(--r-card); padding: 20px 18px 12px; margin-bottom: 18px; overflow: hidden; text-align: left;
  transition: opacity .38s var(--ease), transform .45s var(--ease); }
.web-intro::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(120% 70% at 100% 0%, rgba(10,132,255,.22), transparent 60%), radial-gradient(90% 60% at 0% 100%, rgba(191,90,242,.14), transparent 65%); }
.web-intro > * { position: relative; }
.web-intro.leaving { opacity: 0; transform: translateY(-10px) scale(.97); }
.boot .web-intro { opacity: 0; transform: translateY(14px); }
.web-intro h3 { margin: 0 0 6px; font-size: 19px; font-weight: 700; letter-spacing: -.02em; }
.web-intro p { margin: 0 0 14px; font-size: 14.5px; line-height: 1.45; color: var(--label2); }
.wi-art { display: flex; justify-content: flex-start; margin-bottom: 14px; }
.wi-phone { width: 46px; height: 74px; border-radius: 12px; padding: 3px; background: linear-gradient(160deg, rgba(255,255,255,.35), rgba(255,255,255,.08)); box-shadow: 0 10px 26px -10px rgba(10,132,255,.7); }
.wi-screen { position: relative; width: 100%; height: 100%; border-radius: 9px; background: linear-gradient(170deg, #1a2cff 0%, #6a2bd9 55%, #0e8a78 100%); overflow: hidden; }
.wi-pin { position: absolute; left: 50%; top: 44%; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.35); }
.wi-pin::after { content: ""; position: absolute; left: 3.5px; top: 3.5px; width: 5px; height: 5px; border-radius: 50%; background: #2f4dff; }
.wi-ring { position: absolute; left: 50%; top: 58%; width: 26px; height: 9px; margin-left: -13px; border-radius: 50%; border: 1.5px solid rgba(255,255,255,.8); animation: wiPulse 2.4s var(--ease) infinite; }
@keyframes wiPulse { 0% { transform: scale(.4); opacity: 1; } 100% { transform: scale(1.5); opacity: 0; } }
.wi-rows { display: flex; flex-direction: column; gap: 10px; margin: 0 0 16px; padding: 12px 13px; border-radius: 16px; background: rgba(255,255,255,.05); border: .5px solid rgba(255,255,255,.08); }
.wi-row { display: flex; gap: 11px; align-items: flex-start; font-size: 13.5px; line-height: 1.4; color: var(--label2); }
.wi-row b { display: block; color: var(--label); font-size: 14.5px; font-weight: 620; margin-bottom: 1px; }
.wi-ico { flex: none; width: 24px; height: 24px; margin-top: 1px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.12); }
.wi-row.ok .wi-ico { background: linear-gradient(160deg, #4be37a, #1fae4a); }
.wi-ico svg { width: 13px; height: 13px; fill: none; stroke: #fff; stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; }
.wi-link { display: block; width: 100%; margin-top: 4px; padding: 12px 0 6px; font-size: 15px; font-weight: 600; color: #4aa3ff; text-align: center; }
.wi-link:active { opacity: .6; }

/* In-app arrival alert */
.arrivals { position: fixed; z-index: 30; left: 12px; right: 12px; top: calc(var(--safe-top) + 8px); max-width: 520px; margin: 0 auto; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.arrival { pointer-events: auto; border-radius: 24px; padding: 14px 16px 12px; background: linear-gradient(180deg, rgba(255,255,255,.14), rgba(255,255,255,.05)), rgba(20,24,40,.82);
  border: .5px solid rgba(48,209,88,.45); box-shadow: inset 0 1px 0 var(--hi), 0 0 0 1px rgba(48,209,88,.18), 0 24px 60px -18px rgba(0,0,0,.8), 0 16px 50px -20px rgba(48,209,88,.5);
  transform: translateY(-130%) scale(.94); opacity: 0; transition: transform .6s var(--spring), opacity .35s var(--ease); }
.arrival.on { transform: none; opacity: 1; }
.arrival.off { transform: translateY(-40%) scale(.96); opacity: 0; transition-duration: .35s; }
.arr-top { display: flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 650; letter-spacing: .02em; text-transform: uppercase; color: #6ee79a; }
.arr-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(48,209,88,.2); animation: pulse 1.6s ease-in-out infinite; }
.arr-time { margin-left: auto; color: var(--label3); text-transform: none; font-weight: 550; letter-spacing: 0; }
.arr-note { margin-top: 8px; font-size: 18px; font-weight: 680; letter-spacing: -.02em; line-height: 1.28; }
.arr-place { margin-top: 3px; font-size: 14px; color: #7cc0ff; font-weight: 560; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.arr-place span { color: var(--label2); font-weight: 450; }
.arr-btns { display: flex; gap: 8px; margin-top: 12px; }
.arr-btns button { flex: 1; height: 42px; border-radius: 13px; font-size: 15.5px; font-weight: 650; letter-spacing: -.01em; transition: transform .3s var(--spring); }
.arr-btns button:active { transform: scale(.96); }
.arr-later { background: rgba(255,255,255,.1); color: var(--label); }
.arr-done { background: linear-gradient(180deg, #3ddc6c, #1fae4a); color: #fff; box-shadow: inset 0 1px 0 rgba(255,255,255,.3); }
@media (max-height: 720px) {
  .wi-art { display: none; }
  .web-intro { padding-top: 16px; }
  .web-intro p { margin-bottom: 12px; }
  .wi-rows { margin-bottom: 12px; gap: 8px; }
}
.arr-zman { margin-top: 4px; font-size: 14.5px; font-weight: 600; color: #d9c7ff; font-variant-numeric: tabular-nums; }
.arr-ask { margin-top: 12px; padding: 12px; border-radius: 14px; background: rgba(191,90,242,.12); border: .5px solid rgba(191,90,242,.3); font-size: 14px; color: #e6d6ff; line-height: 1.35; }
.arr-vote { display: flex; gap: 8px; margin-top: 10px; }
.arr-vote button { flex: 1; height: 38px; border-radius: 11px; font-size: 14.5px; font-weight: 650; background: rgba(255,255,255,.1); color: #fff; }
.arr-vote button:first-child { background: linear-gradient(160deg, #d27bff, #9b3cff); }
.arr-vote button:active { transform: scale(.96); }
