/* ── FONTS ───────────────────────────────────────────────── */
@font-face {
  font-family: "Satoshi";
  src: url("fonts/satoshi/Satoshi-Light.otf") format("opentype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/satoshi/Satoshi-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/satoshi/Satoshi-Italic.otf") format("opentype");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/satoshi/Satoshi-Medium.otf") format("opentype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/satoshi/Satoshi-MediumItalic.otf") format("opentype");
  font-weight: 500;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/satoshi/Satoshi-Bold.otf") format("opentype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/satoshi/Satoshi-BoldItalic.otf") format("opentype");
  font-weight: 700;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/satoshi/Satoshi-Black.otf") format("opentype");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Biscuit Glitch";
  src: url("fonts/Biscuit Glitch.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
/* DM Mono — sense versió local, es carrega des de Google Fonts */
@import url("https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&display=swap");

/* ── TOKENS ─────────────────────────────────────────────── */
:root {
  --bg: #fdf8f3;
  --surface: #ffffff;
  --surface2: #f5f0ea;
  --surface3: #ede7e0;
  --border: #e8e0d8;
  --border2: #d8cec4;
  --text: #1c1815;
  --text2: #6b6058;
  --text3: #a89890;
  --coral: #ff6b6b;
  --coral-light: #ffe8e8;
  --teal: #2a9d8f;
  --teal-light: #e2f5f3;
  --yellow: #f4a261;
  --yellow-light: #fef3e8;
  --pink: #e76f9a;
  --pink-light: #faeff5;
  --purple: #7b68ee;
  --purple-light: #f0eeff;
  --green: #52b788;
  --green-light: #ebf8f2;
  --accent: #ff6b6b;
  --accent-bg: #ffe8e8;
  --accent2: #ff8e8e;
  --red: #e03030;
  --red-bg: #feeaea;
  --amber: #e07820;
  --amber-bg: #fef5e8;
  --mono: "DM Mono", monospace;
  --sans: "Satoshi", sans-serif;
  --display: "Biscuit Glitch", sans-serif;
  --r: 14px;
  --r-sm: 10px;
  --r-lg: 22px;
  --r-xl: 28px;
  --r-full: 9999px;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.06), 0 0 0 1px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 6px 24px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 12px 48px rgba(0, 0, 0, 0.15);
}
.dark {
  --bg: #151210;
  --surface: #1f1c1a;
  --surface2: #282420;
  --surface3: #322d28;
  --border: #3c3630;
  --border2: #4c4640;
  --text: #f0ede8;
  --text2: #a09088;
  --text3: #605850;
  --coral: #ff8080;
  --coral-light: #2a1515;
  --teal: #3abfaf;
  --teal-light: #0f2220;
  --yellow: #f5b070;
  --yellow-light: #251a08;
  --pink: #ee85aa;
  --pink-light: #2a1520;
  --purple: #9b8fff;
  --purple-light: #1a1840;
  --green: #62d898;
  --green-light: #0f2018;
  --accent: #ff8080;
  --accent-bg: #2a1515;
  --accent2: #ff9898;
  --red: #ff6060;
  --red-bg: #2a1010;
  --amber: #ffaa55;
  --amber-bg: #251808;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 6px 24px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 12px 48px rgba(0, 0, 0, 0.6);
}

/* ── RESET */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  font-size: 15px;
  line-height: 1.5;
  transition:
    background 0.2s,
    color 0.2s;
  -webkit-font-smoothing: antialiased;
}
button {
  font-family: var(--sans);
  cursor: pointer;
}
input,
select,
textarea {
  font-family: var(--sans);
}

/* ── LAYOUT */
.app-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ── TOPBAR */
.topbar {
  position: sticky;
  top: 0;
  z-index: 200;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: env(safe-area-inset-top, 0) 18px 0;
  min-height: 68px;
}
.topbar-title {
  font-family: var(--display);
  font-size: 1.1rem;
  color: var(--text);
}
.topbar-title span {
  color: var(--coral);
}
.topbar-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}

/* ── MAIN */
.main {
  flex: 1;
  max-width: 520px;
  margin: 0 auto;
  width: 100%;
  padding: 10px 16px 90px;
}

/* ── BOTTOM NAV */
.bottomnav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
  height: 66px;
  background: var(--surface);
  border-top: 2px solid var(--border);
  display: flex;
  padding-bottom: env(safe-area-inset-bottom, 0);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.06);
}
.bnav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: none;
  border: none;
  color: var(--text3);
  font-family: var(--sans);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition:
    color 0.15s,
    transform 0.1s;
}
.bnav-item.active {
  color: var(--coral);
}
.bnav-item:active {
  transform: scale(0.9);
}
.bnav-item svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.8;
  transition: stroke-width 0.1s;
}
.bnav-item.active svg {
  stroke-width: 2.5;
}

/* ── BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: none;
  border-radius: var(--r-sm);
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 700;
  padding: 10px 18px;
  transition: all 0.12s;
  cursor: pointer;
}
.btn:active {
  transform: scale(0.95);
}
.btn-primary {
  background: var(--coral);
  color: #fff;
  box-shadow: 0 4px 14px rgba(255, 107, 107, 0.38);
}
.btn-primary:hover {
  opacity: 0.92;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(255, 107, 107, 0.4);
}
.btn-secondary {
  background: var(--surface2);
  color: var(--text2);
  border: 2px solid var(--border);
}
.btn-secondary:hover {
  border-color: var(--border2);
  color: var(--text);
}
.btn-ghost {
  background: transparent;
  color: var(--text2);
  padding: 8px;
  border-radius: var(--r-sm);
}
.btn-ghost:hover {
  background: var(--surface2);
  color: var(--text);
}
.btn-danger {
  background: var(--red-bg);
  color: var(--red);
  border: 2px solid transparent;
}
.btn-danger:hover {
  border-color: var(--red);
}
.btn-full {
  width: 100%;
}
.btn-icon {
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: var(--r-sm);
}
.btn svg {
  width: 16px;
  height: 16px;
  stroke-width: 2;
  flex-shrink: 0;
}

/* ── CARDS */
.card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--r-lg);
  padding: 18px;
  box-shadow: var(--shadow);
}
.card + .card {
  margin-top: 10px;
}

/* ── HERO */
.hero {
  background: var(--teal);
  border-radius: var(--r-xl);
  padding: 22px 22px 20px;
  margin-bottom: 14px;
  color: #fff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 6px 24px rgba(42, 157, 143, 0.35);
}
.hero::before {
  content: "";
  position: absolute;
  top: -32px;
  right: -32px;
  width: 120px;
  height: 120px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 50%;
}
.hero::after {
  content: "";
  position: absolute;
  bottom: -20px;
  left: 50px;
  width: 80px;
  height: 80px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 50%;
}
.hero-name {
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1;
  position: relative;
  z-index: 1;
}
.hero-age {
  font-size: 0.82rem;
  opacity: 0.8;
  margin-top: 4px;
  font-weight: 600;
  position: relative;
  z-index: 1;
}
.hero-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 18px;
  position: relative;
  z-index: 1;
}
.hero-stat {
  background: rgba(255, 255, 255, 0.2);
  border-radius: var(--r);
  padding: 10px;
}
.hero-stat-val {
  font-family: var(--display);
  font-size: 1.9rem;
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.03em;
}
.hero-stat-lbl {
  font-size: 0.62rem;
  opacity: 0.78;
  margin-top: 3px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ── QGRID */
.qgrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 10px 0;
}
.qbtn {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--r-lg);
  padding: 16px 14px 14px;
  text-align: left;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: var(--shadow);
}
.qbtn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border2);
}
.qbtn:active {
  transform: scale(0.96);
}
.qbtn-ico {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.qbtn-ico svg {
  width: 22px;
  height: 22px;
  stroke-width: 2;
}
.qbtn-ico.milk {
  background: #dbeafe;
  color: #1d4ed8;
}
.qbtn-ico.poop {
  background: #fef3c7;
  color: #b45309;
}
.qbtn-ico.sleep {
  background: #ede9fe;
  color: #6d28d9;
}
.qbtn-ico.meds {
  background: #d1fae5;
  color: #065f46;
}
.qbtn-ico.weight {
  background: #fce7f3;
  color: #9d174d;
}
.dark .qbtn-ico.milk {
  background: #0f1e40;
  color: #60a5fa;
}
.dark .qbtn-ico.poop {
  background: #2a1800;
  color: #fbbf24;
}
.dark .qbtn-ico.sleep {
  background: #1a1540;
  color: #a78bfa;
}
.dark .qbtn-ico.meds {
  background: #0a2015;
  color: #34d399;
}
.dark .qbtn-ico.weight {
  background: #2a0a1e;
  color: #f472b6;
}
.qbtn-label {
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
}
.qbtn-last {
  font-size: 0.68rem;
  color: var(--text3);
  font-family: var(--mono);
}

/* ── LOG LIST */
.log-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.log-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--r);
  transition: all 0.12s;
  box-shadow: var(--shadow);
}
.log-item:hover {
  border-color: var(--border2);
  box-shadow: var(--shadow-lg);
}
.log-body {
  flex: 1;
  min-width: 0;
}
.log-type {
  font-family: var(--sans);
  font-size: 0.88rem;
  font-weight: 700;
}
.log-detail {
  font-size: 0.72rem;
  color: var(--text2);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
}
.log-time {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--text3);
  flex-shrink: 0;
  font-weight: 500;
}
.log-del {
  background: none;
  border: none;
  color: var(--text3);
  padding: 4px 6px;
  border-radius: 7px;
  cursor: pointer;
  transition: all 0.1s;
}
.log-del:hover {
  color: var(--red);
  background: var(--red-bg);
}

/* ── SECTION HEADER */
.sec-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 18px 0 10px;
}
.sec-title {
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--text);
}

/* ── STATS */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.stat-card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--r-lg);
  padding: 16px 16px 14px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.stat-card:nth-child(1) {
  background: linear-gradient(135deg, var(--coral-light), var(--surface));
}
.stat-card:nth-child(2) {
  background: linear-gradient(135deg, var(--teal-light), var(--surface));
}
.stat-card:nth-child(3) {
  background: linear-gradient(135deg, var(--purple-light), var(--surface));
}
.stat-card:nth-child(4) {
  background: linear-gradient(135deg, var(--yellow-light), var(--surface));
}
.stat-val {
  font-family: var(--display);
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--text);
  line-height: 1;
  letter-spacing: -0.04em;
}
.stat-lbl {
  font-family: var(--display);
  font-size: 0.68rem;
  color: var(--text3);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 6px;
}
.chart-wrap {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--r-lg);
  padding: 16px;
  box-shadow: var(--shadow);
}
.chart-bars {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 82px;
}
.bar-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.bar {
  width: 100%;
  border-radius: 8px 8px 0 0;
  background: var(--coral);
  opacity: 0.85;
  min-height: 4px;
  transition: height 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.bar-day {
  font-size: 0.6rem;
  color: var(--text3);
  font-family: var(--mono);
  text-transform: uppercase;
}
.bar-val {
  font-family: var(--display);
  font-size: 0.7rem;
  color: var(--text2);
  font-weight: 800;
}

/* ── GROWTH */
.growth-wrap {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--r-lg);
  padding: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.growth-wrap svg text {
  font-family: var(--mono);
}
.growth-wrap svg {
  overflow: visible;
}
.growth-selector {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
}
.seg-btn {
  flex: 1;
  padding: 8px 6px;
  border-radius: var(--r-sm);
  border: 2px solid var(--border);
  background: var(--surface2);
  font-family: var(--display);
  font-size: 0.74rem;
  font-weight: 800;
  color: var(--text2);
  cursor: pointer;
  transition: all 0.12s;
}
.seg-btn:active {
  transform: scale(0.94);
}
.seg-btn.active {
  background: var(--coral);
  color: #fff;
  border-color: var(--coral);
  box-shadow: 0 3px 10px rgba(255, 107, 107, 0.3);
}

/* ── WEIGHT LOG */
.weight-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--r);
  margin-bottom: 6px;
  box-shadow: var(--shadow);
}
.weight-val {
  font-family: var(--display);
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--text);
}
.weight-date {
  font-size: 0.72rem;
  color: var(--text3);
  font-weight: 600;
}
.weight-delta {
  font-family: var(--mono);
  font-size: 0.72rem;
}
.weight-delta.up {
  color: var(--green);
}
.weight-delta.dn {
  color: var(--red);
}

/* ── FORMULA */
.calc-result {
  background: var(--teal-light);
  border: 2px solid var(--teal);
  border-radius: var(--r-lg);
  padding: 18px;
  margin-top: 12px;
}
.calc-main {
  font-family: var(--display);
  font-size: 1.8rem;
  color: var(--teal);
  font-weight: 900;
  letter-spacing: -0.03em;
}
.calc-detail {
  font-size: 0.8rem;
  color: var(--text2);
  margin-top: 4px;
  font-weight: 600;
}

/* ── MODAL */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(10, 10, 8, 0.5);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fadeIn 0.18s ease;
}
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
.modal {
  background: var(--surface);
  border-radius: 28px 28px 0 0;
  width: 100%;
  max-width: 520px;
  max-height: 92vh;
  overflow-y: auto;
  padding: 0 20px 48px;
  animation: slideUp 0.25s cubic-bezier(0.32, 0.72, 0, 1);
}
@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}
.modal-handle {
  width: 44px;
  height: 5px;
  background: var(--border2);
  border-radius: 3px;
  margin: 14px auto 22px;
}
.modal-title {
  font-family: var(--display);
  font-size: 1.4rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

/* ── FORM */
.field {
  margin-bottom: 14px;
}
.field label {
  display: block;
  font-family: var(--display);
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text3);
  margin-bottom: 6px;
}
.field input,
.field select {
  width: 100%;
  padding: 11px 14px;
  background: var(--surface2);
  border: 2px solid var(--border);
  border-radius: var(--r-sm);
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 600;
  transition: border-color 0.15s;
}
.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--coral);
  background: var(--surface);
}
.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}
.chip {
  padding: 7px 14px;
  border-radius: var(--r-full);
  font-family: var(--display);
  font-size: 0.82rem;
  font-weight: 800;
  border: 2px solid var(--border);
  background: var(--surface2);
  color: var(--text2);
  cursor: pointer;
  transition: all 0.12s;
}
.chip:active {
  transform: scale(0.94);
}
.chip.active {
  background: var(--coral);
  border-color: var(--coral);
  color: #fff;
  box-shadow: 0 2px 10px rgba(255, 107, 107, 0.3);
}
.modal-actions {
  display: flex;
  gap: 8px;
  margin-top: 20px;
}
.modal-actions .btn {
  flex: 1;
  padding: 14px;
  font-size: 0.95rem;
  border-radius: var(--r);
}

/* ── AUTH */
.auth-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 40px 24px;
  text-align: center;
}
.auth-logo {
  font-family: var(--display);
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--coral);
  margin-bottom: 6px;
  letter-spacing: -0.04em;
}
.auth-title {
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: -0.04em;
  margin-bottom: 10px;
  line-height: 1.1;
}
.auth-sub {
  font-size: 0.95rem;
  color: var(--text2);
  margin-bottom: 36px;
  max-width: 300px;
  font-weight: 500;
}
.btn-google {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--r-lg);
  padding: 14px 28px;
  font-family: var(--display);
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text);
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: var(--shadow-lg);
}
.btn-google:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-2px);
}
.auth-note {
  font-size: 0.72rem;
  color: var(--text3);
  margin-top: 20px;
  max-width: 260px;
  font-weight: 600;
}

/* ── SETTINGS */
.srow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.srow:last-child {
  border-bottom: none;
}
.srow-lbl {
  font-family: var(--display);
  font-size: 0.9rem;
  font-weight: 800;
}
.srow-sub {
  font-size: 0.72rem;
  color: var(--text3);
  margin-top: 2px;
  font-weight: 600;
}
.toggle {
  width: 46px;
  height: 27px;
  border-radius: var(--r-full);
  background: var(--surface3);
  border: none;
  cursor: pointer;
  position: relative;
  transition: background 0.2s;
  flex-shrink: 0;
}
.toggle.on {
  background: var(--coral);
}
.toggle::after {
  content: "";
  position: absolute;
  top: 3.5px;
  left: 3.5px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  transition: left 0.2s;
}
.toggle.on::after {
  left: 22.5px;
}
.invite-box {
  background: var(--teal-light);
  border: 2px dashed var(--teal);
  border-radius: var(--r-lg);
  padding: 20px;
  text-align: center;
}
.invite-code {
  font-family: var(--display);
  font-size: 2.2rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  color: var(--teal);
  margin: 10px 0;
}

/* ── TOAST */
.toast {
  position: fixed;
  bottom: 82px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--text);
  color: var(--bg);
  padding: 11px 22px;
  border-radius: var(--r-full);
  font-family: var(--display);
  font-size: 0.85rem;
  font-weight: 800;
  z-index: 999;
  white-space: nowrap;
  animation: toastAnim 2.5s ease forwards;
  pointer-events: none;
  box-shadow: var(--shadow-lg);
}
@keyframes toastAnim {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(10px);
  }
  12% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
  75% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translateX(-50%) translateY(-6px);
  }
}

/* ── BADGES */
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--r-full);
  font-family: var(--display);
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.badge-blue {
  background: var(--teal-light);
  color: var(--teal);
}
.badge-amber {
  background: var(--yellow-light);
  color: var(--yellow);
}
.badge-green {
  background: var(--green-light);
  color: var(--green);
}
.badge-red {
  background: var(--red-bg);
  color: var(--red);
}

/* ── EMPTY */
.empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--text3);
  font-family: var(--display);
  font-size: 0.9rem;
  font-weight: 700;
}

/* ── NOTICE */
.config-notice {
  background: var(--yellow-light);
  border: 2px solid var(--yellow);
  border-radius: var(--r-lg);
  padding: 14px 16px;
  margin-bottom: 14px;
  font-size: 0.8rem;
  color: var(--amber);
  line-height: 1.6;
  font-weight: 600;
}
.config-notice strong {
  display: block;
  margin-bottom: 4px;
  font-size: 0.85rem;
  font-weight: 900;
}
.config-notice code {
  font-family: var(--mono);
  font-size: 0.75rem;
  background: rgba(0, 0, 0, 0.08);
  padding: 1px 5px;
  border-radius: 4px;
}

/* No-zoom */
* {
  touch-action: pan-x pan-y;
}
input,
select,
textarea {
  font-size: 16px !important;
}
