:root {
  --bg: #000;
  --panel: #07040d;
  --panel-2: #0f0a1c;
  --line: #231941;
  --line-2: #33265c;
  --violet: #b026ff;
  --violet-soft: #7d2bc0;
  --cyan: #00e5ff;
  --cyan-soft: #0a8fa3;
  --pink: #ff2e88;
  --lime: #c6ff3d;
  --amber: #ffb938;
  --text: #ece8ff;
  --muted: #8a82ad;
  --radius: 3px;
  --cut: 10px;
  --font: "League Spartan", "Futura", "Century Gothic", "Avenir Next", system-ui, sans-serif;
  --nav-h: 64px;
  /* colori delle persone (in ordine di id) */
  --u0: var(--violet);
  --u1: var(--cyan);
  --u2: var(--lime);
  --u3: var(--amber);
  color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body {
  font-family: var(--font);
  font-size: 17px;
  min-height: 100dvh;
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
  background:
    radial-gradient(120% 60% at 100% 0%, rgba(176, 38, 255, .10), transparent 60%),
    radial-gradient(90% 50% at 0% 100%, rgba(0, 229, 255, .07), transparent 60%),
    var(--bg);
  background-attachment: fixed;
}
[hidden] { display: none !important; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input, select, textarea { font: inherit; }

.screen { max-width: 520px; margin: 0 auto; padding: 0 16px 40px; }
#app { padding-bottom: calc(var(--nav-h) + 30px + env(safe-area-inset-bottom)); }

.c0 { --uc: var(--u0); } .c1 { --uc: var(--u1); } .c2 { --uc: var(--u2); } .c3 { --uc: var(--u3); }

/* ---------- login ---------- */
#login { min-height: 100dvh; display: flex; align-items: center; }
.login-box { width: 100%; display: flex; flex-direction: column; align-items: center; }
.logo { width: 170px; height: 170px; margin-bottom: 36px; }
.logo path, .brand path { fill: none; stroke-width: 7; stroke-linecap: square; stroke-linejoin: miter; }
.logo-a { stroke: var(--violet); filter: drop-shadow(0 0 6px var(--violet)); }
.logo-b { stroke: var(--cyan); filter: drop-shadow(0 0 6px var(--cyan)); }
.field.token-field {
  height: 80px; text-align: center; font-size: 22px; letter-spacing: .08em;
  border-color: var(--cyan); box-shadow: 0 0 18px rgba(0, 229, 255, .25), inset 0 0 12px rgba(0, 229, 255, .12);
}
.login-label {
  margin: 30px 0 10px; color: var(--violet); font-weight: 800; font-size: 30px;
  text-shadow: 0 0 14px rgba(176, 38, 255, .7);
}
.login-box .btn { margin-top: 18px; }

/* ---------- controlli ---------- */
.label {
  display: block; margin: 22px 0 8px; color: var(--cyan);
  font-weight: 700; font-size: 14px; letter-spacing: .14em; text-transform: uppercase;
}
.field {
  width: 100%; min-height: 50px; padding: 12px 14px;
  font-size: 18px; color: var(--text);
  background: var(--panel); border: 2px solid var(--violet); border-radius: var(--radius);
  outline: none; -webkit-appearance: none; appearance: none;
  transition: box-shadow .15s, border-color .15s;
}
.field:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(0, 229, 255, .18), 0 0 18px rgba(0, 229, 255, .25); }
.field:disabled { opacity: .6; }
textarea.field { resize: vertical; min-height: 80px; }
select.field {
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 9l7 7 7-7' fill='none' stroke='%2300e5ff' stroke-width='2.6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center; background-size: 24px;
}
select.field.small { min-height: 42px; font-size: 16px; padding: 8px 36px 8px 10px; }
.row { display: flex; gap: 10px; align-items: center; }
.row > * { flex: 1; min-width: 0; }
.unit { position: relative; }
.unit .field { padding-right: 38px; font-variant-numeric: tabular-nums; }
.unit span { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); font-weight: 700; }

.btn {
  width: 100%; min-height: 54px; margin-top: 26px; padding: 0 18px;
  background: linear-gradient(100deg, var(--violet), #7a3cff 55%, var(--cyan));
  color: #fff; font-weight: 800; font-size: 20px; letter-spacing: .06em; text-transform: lowercase;
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut));
  text-shadow: 0 1px 6px rgba(0, 0, 0, .4);
  transition: transform .08s, filter .15s;
}
.btn:active { transform: scale(.98); filter: brightness(1.2); }
.btn:disabled { opacity: .5; }
.btn.small { min-height: 40px; margin: 0; font-size: 16px; width: auto; }
.btn.ghost {
  background: transparent; color: var(--cyan); border: 2px solid var(--cyan); clip-path: none;
  box-shadow: inset 0 0 12px rgba(0, 229, 255, .15);
}
.btn.danger { background: transparent; color: var(--pink); border: 2px solid var(--pink); clip-path: none; }
.link { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; padding: 8px; }
.link.danger { color: var(--pink); }
.error { color: var(--pink); min-height: 1.2em; margin: 10px 0 0; font-size: 15px; }
.hint { color: var(--muted); font-size: 14px; line-height: 1.35; margin: 8px 0; }
.empty { color: var(--muted); text-align: center; margin: 40px 0; }

/* segmented control */
.seg {
  display: flex; border: 2px solid var(--line-2); border-radius: 999px; padding: 3px; gap: 2px;
  background: var(--panel);
}
.seg button {
  flex: 1; min-height: 38px; border-radius: 999px; color: var(--muted);
  font-weight: 700; font-size: 15px; padding: 0 8px; white-space: nowrap;
  transition: background .2s, color .2s;
}
.seg button.on { background: var(--violet); color: #fff; box-shadow: 0 0 14px rgba(176, 38, 255, .6); }
.seg button.on.uc { background: var(--uc, var(--violet)); color: #000; box-shadow: 0 0 14px var(--uc, var(--violet)); }

/* chip */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 0 14px;
  border: 2px solid var(--line-2); border-radius: 999px; color: var(--text); font-weight: 600; font-size: 15px;
  background: var(--panel);
}
.chip.on { border-color: var(--uc, var(--cyan)); color: #000; background: var(--uc, var(--cyan)); box-shadow: 0 0 12px var(--uc, var(--cyan)); }
.chip.due { border-color: var(--amber); }

/* avatar */
.av {
  display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  font-size: 12px; font-weight: 800; color: #000; background: var(--uc, var(--muted)); flex: none;
  box-shadow: 0 0 8px var(--uc, transparent); line-height: 1;
}
.uname { color: var(--uc); font-weight: 700; }

/* ---------- barra superiore ---------- */
.topbar {
  position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 12px;
  padding: 12px 0 10px; background: linear-gradient(var(--bg) 75%, transparent);
}
.brand { width: 44px; height: 44px; display: grid; place-items: center; }
.brand svg { width: 40px; height: 40px; }
.view-title {
  margin: 0; font-size: 30px; font-weight: 800; letter-spacing: .02em; color: var(--text);
  text-shadow: 0 0 12px rgba(176, 38, 255, .8), 0 0 2px rgba(0, 229, 255, .6);
}

.banner {
  display: flex; flex-direction: column; gap: 12px; margin: 6px 0 4px; padding: 14px 16px;
  border: 1px solid var(--violet-soft); border-radius: var(--radius); background: var(--panel-2); font-size: 15px;
}
.banner-actions { display: flex; align-items: center; gap: 10px; }

/* ---------- barra di navigazione ---------- */
.navbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: flex; justify-content: center;
  padding: 6px max(8px, calc((100vw - 520px) / 2)) calc(6px + env(safe-area-inset-bottom));
  background: rgba(3, 1, 8, .94); border-top: 1px solid var(--line-2);
  box-shadow: 0 -6px 24px rgba(176, 38, 255, .12);
  backdrop-filter: blur(8px);
}
.nav {
  flex: 1; min-height: 52px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; color: var(--muted); font-size: 11px; font-weight: 600; letter-spacing: .04em;
}
.nav svg { width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.nav.active { color: var(--cyan); }
.nav.active svg { filter: drop-shadow(0 0 5px var(--cyan)); }

/* ---------- card ---------- */
.card {
  margin: 14px 0; padding: 14px; background: var(--panel); border: 1px solid var(--line-2);
  border-radius: var(--radius); position: relative;
}
.card::before {
  content: ""; position: absolute; left: -1px; top: -1px; width: 28px; height: 2px;
  background: var(--cyan); box-shadow: 0 0 8px var(--cyan);
}
.card h2 {
  margin: 0 0 12px; font-size: 14px; letter-spacing: .14em; text-transform: uppercase; color: var(--cyan);
}
.card h2 small { color: var(--muted); letter-spacing: .04em; text-transform: none; font-weight: 600; }
.section-title {
  margin: 22px 0 10px; font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--violet);
  display: flex; align-items: center; gap: 10px;
}
.section-title::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--line-2), transparent); }

/* ---------- registra ---------- */
.doer { margin: 6px 0 4px; }
.doer .label { margin-top: 8px; }
.todo { display: flex; flex-direction: column; gap: 8px; }
.todo-item {
  display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 6px 12px; text-align: left;
  background: var(--panel-2); border: 1px solid var(--line-2); border-left: 3px solid var(--uc);
  border-radius: var(--radius);
}
.todo-item .emoji { font-size: 22px; }
.todo-item .grow { flex: 1; font-weight: 600; }
.todo-item small { color: var(--muted); }

.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.tile {
  position: relative; min-height: 96px; padding: 10px 6px 8px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  background: var(--panel-2); border: 1px solid var(--line-2); border-radius: var(--radius);
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 0 100%);
  transition: transform .08s, border-color .15s, box-shadow .15s;
}
.tile:active { transform: scale(.96); border-color: var(--cyan); box-shadow: inset 0 0 18px rgba(0, 229, 255, .3); }
.tile .emoji { font-size: 30px; line-height: 1; }
.tile .name { font-size: 14px; font-weight: 700; text-align: center; line-height: 1.1; word-break: break-word; }
.tile .dur { font-size: 12px; color: var(--muted); }
.tile .count {
  position: absolute; top: 6px; left: 6px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--cyan); color: #000; font-size: 11px; font-weight: 800; display: grid; place-items: center;
}
.more { display: block; margin: 18px auto 0; }

/* ---------- navigazione periodo ---------- */
.period { display: flex; align-items: center; gap: 6px; margin: 12px 0; }
.period .lbl { flex: 1; text-align: center; font-weight: 700; font-size: 18px; }
.period .lbl small { display: block; color: var(--muted); font-size: 13px; font-weight: 600; }
.arrow {
  width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid var(--line-2); border-radius: 50%;
}
.arrow svg { width: 22px; height: 22px; fill: none; stroke: var(--cyan); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.today-btn { font-size: 13px; color: var(--cyan); padding: 6px 8px; }
.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 10px 0; }
.toolbar .btn { flex: 1; }
.edit-toggle.on { background: var(--amber); color: #000; border-color: var(--amber); box-shadow: 0 0 14px rgba(255, 185, 56, .5); }
.edit-note {
  padding: 10px 12px; border: 1px dashed var(--amber); color: var(--amber); font-size: 14px; border-radius: var(--radius);
  margin: 8px 0;
}

/* ---------- griglia settimanale ---------- */
.grid {
  display: grid; grid-template-columns: minmax(66px, 1.35fr) 26px repeat(7, minmax(0, 1fr));
  align-items: stretch; margin: 6px 0; font-size: 13px;
}
.g-head { text-align: center; color: var(--muted); font-size: 11px; font-weight: 700; padding: 4px 0 6px; line-height: 1.15; }
.g-head b { display: block; font-size: 15px; color: var(--text); }
.g-head.today b { color: var(--cyan); text-shadow: 0 0 8px var(--cyan); }
.g-head.today { color: var(--cyan); }
.g-head.custom::after { content: "✎"; display: block; color: var(--amber); font-size: 10px; line-height: 1; }
.g-cat {
  grid-column: 1 / -1; padding: 12px 0 4px; font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--violet); border-bottom: 1px solid var(--line);
}
.g-label {
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 2px;
  padding: 6px 4px 6px 0; border-top: 1px solid var(--line); min-width: 0;
}
.g-label .emoji { font-size: 20px; line-height: 1; }
.g-label .name { font-size: 12px; font-weight: 700; line-height: 1.05; word-break: break-word; }
.g-av { display: grid; place-items: center; padding: 3px 0; }
.g-av.first, .g-cell.first { border-top: 1px solid var(--line); }
.g-cell { display: grid; place-items: center; padding: 3px 2px; }
.box {
  width: 100%; max-width: 34px; aspect-ratio: 1; display: grid; place-items: center;
  border-radius: 3px; border: 1px solid #1a1330; background: #05030a;
  font-size: 17px; font-weight: 800; line-height: 1; color: var(--uc);
}
.g-cell.today .box { border-color: #2e2250; }
.box.planned { border: 2px solid var(--uc); box-shadow: 0 0 6px color-mix(in srgb, var(--uc) 45%, transparent); }
.box.due { border: 2px dashed var(--uc); color: color-mix(in srgb, var(--uc) 50%, transparent); animation: pulse 2s ease-in-out infinite; }
.box.done { border: 2px solid var(--uc); background: color-mix(in srgb, var(--uc) 18%, #000); text-shadow: 0 0 8px var(--uc); }
.box.extra { border: 1px solid color-mix(in srgb, var(--uc) 50%, transparent); text-shadow: 0 0 8px var(--uc); font-size: 14px; }
.box.covered { border: 2px solid var(--line-2); font-size: 12px; }
.box.missed { border: 2px solid var(--pink); color: var(--pink); text-shadow: 0 0 8px var(--pink); }
.box.on { border: 2px solid var(--uc); background: var(--uc); box-shadow: 0 0 10px var(--uc); }
.box.clickable { cursor: pointer; }
@keyframes pulse { 50% { box-shadow: 0 0 10px color-mix(in srgb, var(--uc) 60%, transparent); } }

.legend { display: flex; flex-wrap: wrap; gap: 10px 16px; margin: 14px 0; font-size: 13px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend .box { width: 20px; height: 20px; font-size: 12px; --uc: var(--cyan); }

/* ---------- mese ---------- */
.month { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.m-head { text-align: center; color: var(--muted); font-size: 12px; font-weight: 700; padding: 2px 0 4px; }
.m-day {
  min-width: 0; min-height: 62px; padding: 4px 3px; border: 1px solid var(--line); border-radius: 3px; background: var(--panel);
  display: flex; flex-direction: column; align-items: stretch; gap: 1px; text-align: left; position: relative;
}
.m-day .n { font-size: 14px; font-weight: 800; }
.m-day.today { border-color: var(--cyan); box-shadow: 0 0 10px rgba(0, 229, 255, .35); }
.m-day.today .n { color: var(--cyan); }
.m-day.custom::after { content: "✎"; position: absolute; top: 3px; right: 4px; font-size: 10px; color: var(--amber); }
.m-day.missed { border-color: color-mix(in srgb, var(--pink) 60%, transparent); }
.m-day.alldone { border-color: color-mix(in srgb, var(--lime) 50%, transparent); }
.m-day .u { font-size: 11px; font-weight: 700; color: var(--uc); line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: clip; }
.m-day.other { visibility: hidden; }

/* ---------- pannelli (sheet) ---------- */
.sheet { position: fixed; inset: 0; z-index: 50; background: rgba(0, 0, 0, .72); display: flex; align-items: flex-end; }
.sheet-box {
  width: 100%; max-width: 520px; margin: 0 auto; max-height: 92dvh; overflow-y: auto;
  padding: 20px 16px calc(24px + env(safe-area-inset-bottom));
  background: var(--panel-2); border-top: 2px solid var(--violet);
  box-shadow: 0 -10px 40px rgba(176, 38, 255, .25);
  display: flex; flex-direction: column; gap: 10px;
  animation: up .2s ease-out;
}
.sheet-box .btn { width: 100%; margin: 0; min-height: 50px; }
.sheet-box .label { margin: 12px 0 4px; }
.sheet-head { display: flex; align-items: flex-start; gap: 10px; }
.sheet-head h2 { flex: 1; margin: 0; font-size: 24px; line-height: 1.1; }
.sheet-head h2 small { display: block; margin-top: 4px; font-size: 14px; font-weight: 600; color: var(--muted); }
.x { width: 40px; height: 40px; font-size: 22px; color: var(--muted); flex: none; }
.sheet-user { margin: 0; font-size: 22px; }
.sheet-user strong { color: var(--cyan); }
.sheet-note { margin: 0 0 6px; color: var(--muted); font-size: 15px; }
.who-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.who-btn {
  min-height: 64px; border: 2px solid var(--uc, var(--line-2)); border-radius: var(--radius);
  font-size: 20px; font-weight: 800; color: var(--uc, var(--text)); background: var(--panel);
  box-shadow: inset 0 0 14px color-mix(in srgb, var(--uc, transparent) 25%, transparent);
}
.who-btn:active { background: var(--uc, var(--line-2)); color: #000; }
.quick { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.quick button { padding: 6px 12px; border: 1px solid var(--line-2); border-radius: 999px; font-size: 14px; color: var(--muted); }
.quick button:active { color: var(--cyan); border-color: var(--cyan); }
.meta { color: var(--muted); font-size: 14px; }

.list { list-style: none; margin: 0; padding: 0; }
.list li, .list .li {
  display: flex; align-items: center; gap: 10px; padding: 11px 2px; border-bottom: 1px solid var(--line);
  width: 100%; text-align: left;
}
.list .emoji { font-size: 22px; width: 28px; text-align: center; flex: none; }
.list .grow { flex: 1; min-width: 0; }
.list .grow b { display: block; font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.list .grow small { color: var(--muted); font-size: 13px; }
.list .dur { font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.list .st { width: 26px; text-align: center; font-weight: 800; }
.st.done { color: var(--lime); } .st.missed { color: var(--pink); } .st.covered { color: var(--muted); } .st.due { color: var(--amber); }
.list .archived { opacity: .45; }
.ppl { display: inline-flex; gap: 3px; }

.day-group { margin-top: 18px; }
.day-group h3 {
  margin: 0; padding: 6px 0; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--violet);
  display: flex; justify-content: space-between; border-bottom: 1px solid var(--line-2);
}
.day-group h3 span { color: var(--muted); }
.summary { display: flex; justify-content: space-between; color: var(--muted); font-size: 14px; margin: 12px 0 0; }
.summary b { color: var(--text); }
.filters { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.filters .wide { grid-column: 1 / -1; }

.plan-slots { display: flex; flex-direction: column; gap: 2px; }
.plan-row { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.plan-row .grow { flex: 1; font-weight: 600; font-size: 15px; }
.plan-row .chip { min-height: 32px; padding: 0 10px; }

.cat-head { display: flex; align-items: center; gap: 8px; }
.cat-head .section-title { flex: 1; }
.cat-head .link { font-size: 13px; padding: 4px; }

/* ---------- grafici ---------- */
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart text { font-family: var(--font); fill: var(--muted); font-size: 11px; }
.chart .grid-line { stroke: var(--line); stroke-width: 1; }
.chart .f0 { fill: var(--u0); } .chart .f1 { fill: var(--u1); } .chart .f2 { fill: var(--u2); } .chart .f3 { fill: var(--u3); }
.chart .s0 { stroke: var(--u0); } .chart .s1 { stroke: var(--u1); } .chart .s2 { stroke: var(--u2); } .chart .s3 { stroke: var(--u3); }
.chart .line { fill: none; stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.chart .glow { filter: drop-shadow(0 0 4px currentColor); }
.chart .miss { fill: var(--pink); }
.chart .cover { fill: #3a2f5c; }
.chart .track { fill: #120c22; }
.person { display: grid; grid-template-columns: auto 1fr auto; gap: 4px 10px; align-items: center; margin: 8px 0; }
.person .big { font-size: 26px; font-weight: 800; color: var(--uc); text-shadow: 0 0 10px var(--uc); font-variant-numeric: tabular-nums; }
.person .bar { grid-column: 1 / -1; }
.balance-msg { margin: 12px 0 0; padding: 10px 12px; border-left: 3px solid var(--amber); background: #120d05; font-size: 15px; }
.balance-msg.even { border-color: var(--lime); background: #0b1204; }
.rowbar { margin: 10px 0; }
.rowbar .top { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; margin-bottom: 4px; }
.rowbar .top b { font-weight: 700; }
.rowbar .top span { color: var(--muted); white-space: nowrap; }
.chart-legend { display: flex; gap: 14px; font-size: 13px; margin-top: 8px; color: var(--muted); flex-wrap: wrap; }
.chart-legend span { display: inline-flex; align-items: center; gap: 5px; }
.chart-legend i { width: 12px; height: 12px; border-radius: 2px; background: var(--uc); display: inline-block; }
.chart-legend i.miss { background: var(--pink); } .chart-legend i.cover { background: #3a2f5c; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: calc(var(--nav-h) + 22px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  width: max-content; max-width: calc(100vw - 24px);
  display: flex; align-items: center; gap: 12px;
  background: #140b26; color: var(--text); font-weight: 600; font-size: 15px; padding: 10px 16px; border-radius: 999px;
  border: 1px solid var(--cyan); box-shadow: 0 0 20px rgba(0, 229, 255, .35);
  z-index: 60; animation: up .2s ease-out; --tx: -50%;
}
.toast-btn { color: var(--cyan); font-weight: 800; text-transform: lowercase; padding: 4px 2px; }
@keyframes up { from { transform: translate(var(--tx, 0), 20px); opacity: 0; } }

@media (max-width: 360px) {
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .grid { grid-template-columns: minmax(56px, 1.1fr) 24px repeat(7, minmax(0, 1fr)); }
}
