/* Artist-App — neutral gebrandet. Eine Marke setzt später nur die Variablen im Block „Marke“.
   Schrift: DM Sans (OFL) aus /fonts/ wie die Care-App (self_hosted_fonts), sonst Systemschrift. */

@font-face { font-family: 'DM Sans'; src: url('/fonts/DMSans/DMSans-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'DM Sans'; src: url('/fonts/DMSans/DMSans-Medium.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'DM Sans'; src: url('/fonts/DMSans/DMSans-SemiBold.woff2') format('woff2'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'DM Sans'; src: url('/fonts/DMSans/DMSans-Bold.woff2') format('woff2'); font-weight: 700; font-display: swap; }

/* ── Marke (wenige Variablen) ───────────────────────────────────────────── */
:root {
  --brand: #2b4fd8;          /* Akzent: Knöpfe, aktive Elemente */
  --brand-ink: #ffffff;      /* Schrift auf Akzent */
  --hero-bg: #14161b;        /* Kopf */
  --hero-ink: #f4f2ec;
  --font: 'DM Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --brand: #8ea8ff;
    --brand-ink: #0d1020;
    --hero-bg: #0b0c0f;
    --hero-ink: #f4f2ec;
  }
}

/* ── Fläche und Text (abgeleitet) ───────────────────────────────────────── */
:root {
  color-scheme: light dark;
  --bg: #f5f4f0;
  --surface: #ffffff;
  --surface-2: #f0efea;
  --ink: #17181c;
  --ink-2: #5d6068;
  --ink-3: #8a8d95;
  --line: #e4e2dc;
  --ok: #1d7a4f;
  --warn: #9a5b00;
  --bad: #b3261e;
  --ok-soft: #e3f3ea;
  --warn-soft: #fbf0db;
  --bad-soft: #fbe6e4;
  --brand-soft: color-mix(in srgb, var(--brand) 12%, var(--surface));
  --shadow: 0 1px 2px rgba(20, 22, 27, .05), 0 6px 20px rgba(20, 22, 27, .05);
  --radius: 16px;
  --radius-sm: 10px;
  --gap: 14px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101216;
    --surface: #181b21;
    --surface-2: #20242b;
    --ink: #ecebe6;
    --ink-2: #a9acb4;
    --ink-3: #7d818a;
    --line: #2a2e36;
    --ok: #6fd6a0;
    --warn: #f3bf5a;
    --bad: #ff8f86;
    --ok-soft: rgba(111, 214, 160, .12);
    --warn-soft: rgba(243, 191, 90, .13);
    --bad-soft: rgba(255, 143, 134, .13);
    --shadow: 0 1px 2px rgba(0, 0, 0, .3);
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 64px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.45 var(--font); font-feature-settings: 'ss01';
  -webkit-font-smoothing: antialiased;
  padding-bottom: env(safe-area-inset-bottom);
}
h1, h2, h3, p { margin: 0; }
ul, ol { list-style: none; margin: 0; padding: 0; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
.tnum { font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ic { flex: none; display: inline-block; vertical-align: middle; }
.ic-sm { width: 16px; height: 16px; }
.ic-xs { width: 14px; height: 14px; }
.ic-sec { width: 20px; height: 20px; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 6px; }

/* ── Splash ─────────────────────────────────────────────────────────────── */
.splash { min-height: 100vh; display: grid; place-items: center; background: var(--hero-bg); color: var(--hero-ink); }
.splash-mark { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 18px;
  background: rgba(255, 255, 255, .08); animation: pulse 1.6s ease-in-out infinite; }
.splash-mark .ic { width: 28px; height: 28px; }
@keyframes pulse { 50% { transform: scale(1.06); opacity: .7; } }

/* ── Banner ─────────────────────────────────────────────────────────────── */
.banner { display: flex; gap: 8px; align-items: center; justify-content: center;
  padding: 9px 16px calc(9px); font-size: 14px; font-weight: 500; }
.banner-offline { background: var(--warn-soft); color: var(--warn); }
@supports (padding: env(safe-area-inset-top)) { .banner:first-child { padding-top: calc(9px + env(safe-area-inset-top)); } }

/* ── Kopf ───────────────────────────────────────────────────────────────── */
.hero { background: var(--hero-bg); color: var(--hero-ink); padding: calc(14px + env(safe-area-inset-top)) 18px 22px; }
.banner + .hero { padding-top: 14px; }
.hero-inner { max-width: 1120px; margin: 0 auto; }
.hero-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 36px; }
.eyebrow { font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; opacity: .72;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fixture-badge { flex: none; margin-left: auto; font-size: 12px; font-weight: 700; letter-spacing: .04em; padding: 4px 10px;
  border-radius: 999px; border: 1px dashed rgba(255, 255, 255, .35); color: var(--hero-ink); opacity: .8; }
.lang { display: inline-flex; padding: 3px; border-radius: 999px; background: rgba(255, 255, 255, .09); flex: none; }
.lang button { border: 0; background: transparent; color: inherit; opacity: .7; font-size: 13px; font-weight: 700;
  letter-spacing: .04em; padding: 6px 11px; min-width: 40px; border-radius: 999px; cursor: pointer; }
.lang button.on { background: var(--hero-ink); color: var(--hero-bg); opacity: 1; }
.hero-grid { display: grid; gap: 18px; margin-top: 14px; }
.hero-act { display: flex; align-items: center; gap: 14px; }
.avatar { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; flex: none; }
.avatar-ph { display: grid; place-items: center; background: rgba(255, 255, 255, .1); font-weight: 700; font-size: 20px; letter-spacing: .02em; }
.hero h1 { font-size: clamp(28px, 7.4vw, 40px); line-height: 1.08; font-weight: 700; letter-spacing: -.02em; }
.hero-sub { display: flex; gap: 6px; align-items: flex-start; margin-top: 6px; font-size: 14px; opacity: .75; }
.hero-sub .ic { margin-top: 2px; }

.next { background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--radius); padding: 16px 16px 14px; }
.next.is-live { border-color: color-mix(in srgb, var(--brand) 70%, transparent); }
.next-kicker { font-size: 12px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; opacity: .7; }
.next-time { font-size: 38px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; margin-top: 4px; }
.next-time .dash { opacity: .45; margin: 0 .12em; font-weight: 500; }
.next-meta { display: flex; flex-wrap: wrap; gap: 0 8px; font-size: 15px; font-weight: 500; margin-top: 2px; }
.dotsep { opacity: .5; }
.next-b2b { display: block; font-size: 14px; opacity: .72; margin-top: 2px; }
.next-empty { display: flex; gap: 8px; align-items: center; font-size: 15px; opacity: .85; }
.cd { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, .1); }
.cd-label { font-size: 13px; opacity: .7; font-weight: 500; }
.cd-units { display: flex; gap: 14px; margin-left: auto; }
.cd-unit { display: inline-flex; align-items: baseline; gap: 4px; }
.cd-unit b { font-size: 24px; font-weight: 700; letter-spacing: -.01em; }
.cd-unit small { font-size: 13px; opacity: .7; }
.cd-live { font-size: 14px; font-weight: 600; flex-wrap: wrap; }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: #ff5a4f; box-shadow: 0 0 0 0 rgba(255, 90, 79, .6); animation: live 1.8s infinite; }
@keyframes live { 70% { box-shadow: 0 0 0 9px rgba(255, 90, 79, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 90, 79, 0); } }
.cd-bar { flex: 1 1 100%; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .14); overflow: hidden; }
.cd-bar span { display: block; height: 100%; background: var(--brand); }

/* ── Bereichs-Leiste ────────────────────────────────────────────────────── */
.secnav { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line); }
.secnav-inner { max-width: 1168px; margin: 0 auto; display: flex; gap: 6px; overflow-x: auto; padding: 9px 14px;
  scrollbar-width: none; }
.secnav-inner::-webkit-scrollbar { display: none; }
.secnav button { flex: none; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2);
  font-size: 14px; font-weight: 600; padding: 7px 13px; border-radius: 999px; cursor: pointer; }
.secnav button:hover { color: var(--ink); border-color: var(--ink-3); }

/* ── Layout ─────────────────────────────────────────────────────────────── */
.layout { max-width: 1168px; margin: 0 auto; padding: 14px 12px 8px; display: grid; gap: var(--gap); }
.col { display: grid; gap: var(--gap); align-content: start; min-width: 0; }
@media (min-width: 900px) {
  .layout { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); padding: 22px 24px 8px; gap: 20px; }
  .col { gap: 20px; }
  .hero { padding: 22px 24px 28px; }
  .hero-grid { grid-template-columns: 1fr minmax(320px, 400px); align-items: end; margin-top: 18px; }
  .avatar { width: 76px; height: 76px; }
  .secnav-inner { padding: 10px 24px; }
}

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 16px; box-shadow: var(--shadow); scroll-margin-top: 64px; min-width: 0; }
@media (min-width: 900px) { .card { padding: 22px 22px; } }
.sec-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 36px; }
.sec-head h2 { display: flex; align-items: center; gap: 9px; font-size: 19px; font-weight: 700; letter-spacing: -.01em; }
.sec-head h2 .ic { color: var(--brand); }
.sec-intro { color: var(--ink-2); font-size: 14.5px; margin-top: 4px; max-width: 60ch; }
.sec-action { margin-top: 12px; }
.sec-action .btn { width: 100%; }
@media (min-width: 560px) { .sec-action .btn { width: auto; } }
.empty { color: var(--ink-3); font-size: 15px; padding: 18px 0 4px; }

/* ── Knöpfe ─────────────────────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid transparent;
  border-radius: 12px; padding: 11px 16px; font-weight: 600; font-size: 15px; cursor: pointer; text-decoration: none;
  min-height: 44px; white-space: nowrap; }
.btn-sm { padding: 7px 12px; font-size: 14px; min-height: 36px; border-radius: 10px; }
.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { filter: brightness(1.06); }
.btn-secondary { background: var(--surface-2); color: var(--ink); border-color: var(--line); }
.btn-ghost { background: transparent; color: var(--ink-2); }
.btn-ghost:hover { background: var(--surface-2); color: var(--ink); }
.btn-danger { color: var(--bad); }
.btn-danger-solid { background: var(--bad); color: #fff; }
@media (prefers-color-scheme: dark) { .btn-danger-solid { color: #1a0a09; } }
.btn:disabled { opacity: .6; cursor: progress; }
.icon-btn { border: 0; background: var(--surface-2); color: var(--ink-2); width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer; }

/* ── Stand ──────────────────────────────────────────────────────────────── */
.status { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 650; padding: 3px 9px 3px 7px;
  border-radius: 999px; white-space: nowrap; flex: none; }
.status-confirmed { color: var(--ok); background: var(--ok-soft); }
.status-submitted { color: var(--warn); background: var(--warn-soft); }
.status-declined { color: var(--bad); background: var(--bad-soft); }
.status-compact { padding: 4px; }
.reason { margin-top: 8px; padding: 9px 11px; border-radius: var(--radius-sm); background: var(--bad-soft); color: var(--ink);
  font-size: 14.5px; border-left: 3px solid var(--bad); }
.reason b { color: var(--bad); font-weight: 650; }

/* ── Zeitstrahl ─────────────────────────────────────────────────────────── */
.timeline { margin-top: 10px; }
.tl-day { position: sticky; top: 52px; z-index: 1; padding: 14px 0 8px; background: var(--surface);
  font-size: 13px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--ink-2); }
.tl-day:first-child { padding-top: 6px; }
.tl-item { display: grid; grid-template-columns: 52px 30px minmax(0, 1fr); gap: 0 10px; position: relative; padding-bottom: 16px; }
.tl-item::before { content: ''; position: absolute; left: 76px; top: 30px; bottom: 0; width: 2px; background: var(--line); }
.tl-item:last-child::before, .tl-item:has(+ .tl-day)::before { display: none; }
.tl-time { text-align: right; padding-top: 4px; line-height: 1.2; }
.tl-time b { display: block; font-size: 16px; font-weight: 700; }
.tl-time span { display: block; font-size: 13px; color: var(--ink-3); margin-top: 2px; }
.tl-dot { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2);
  color: var(--ink-2); border: 1px solid var(--line); position: relative; z-index: 1; }
.tl-slot .tl-dot { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.tl-item.st-submitted .tl-dot { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, transparent); background: var(--warn-soft); }
.tl-item.st-declined .tl-dot { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 45%, transparent); background: var(--bad-soft); }
.tl-body { padding-top: 3px; min-width: 0; }
.tl-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.kicker { font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.tl-title { font-size: 16px; font-weight: 600; margin-top: 2px; overflow-wrap: anywhere; }
.tl-slot .tl-title { font-size: 17px; }
.tl-sub { font-size: 14px; color: var(--ink-2); }
.arrow { color: var(--ink-3); font-weight: 400; }
.tl-item.is-past { opacity: .5; }
.tl-item.st-declined .tl-title { text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--bad) 60%, transparent); }
.tl-item.is-live .tl-dot { box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 25%, transparent); }

/* ── Einträge (Reise, Unterkunft, Shuttle) ──────────────────────────────── */
.entries { margin-top: 12px; display: grid; gap: 10px; }
.entry { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; padding: 14px; border-radius: 14px;
  background: var(--surface-2); border: 1px solid transparent; }
.entry.st-submitted { background: var(--surface); border-color: color-mix(in srgb, var(--warn) 45%, var(--line)); border-style: dashed; }
.entry.st-declined { background: var(--surface); border-color: color-mix(in srgb, var(--bad) 35%, var(--line)); }
.entry-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--surface);
  color: var(--brand); border: 1px solid var(--line); }
.entry-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.entry-title { font-size: 16.5px; font-weight: 650; margin-top: 3px; overflow-wrap: anywhere; }
.entry-time { margin-top: 4px; font-size: 15px; color: var(--ink-2); }
.entry-time b { color: var(--ink); font-weight: 700; }
.entry-meta { display: flex; gap: 6px; align-items: center; margin-top: 4px; font-size: 14px; color: var(--ink-2); overflow-wrap: anywhere; }
.entry-note { margin-top: 6px; font-size: 14.5px; color: var(--ink-2); font-style: italic; overflow-wrap: anywhere; }
.entry-actions { display: flex; gap: 4px; margin: 8px 0 -6px -10px; }
.kv { margin: 6px 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.kv div { background: var(--surface); border-radius: 10px; padding: 7px 10px; }
.kv dt { font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-3); }
.kv dd { margin: 2px 0 0; font-size: 14px; color: var(--ink-2); }
.kv dd b { color: var(--ink); }

/* ── Personen ───────────────────────────────────────────────────────────── */
.group { margin-top: 16px; }
.group + .group { padding-top: 16px; border-top: 1px solid var(--line); }
.group-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.group-head h3 { display: flex; align-items: center; gap: 8px; font-size: 16px; font-weight: 700; }
.group-head h3 .ic { color: var(--ink-3); }
.count { font-size: 13.5px; font-weight: 500; color: var(--ink-3); }
.people { margin-top: 10px; display: grid; gap: 2px; }
.person, .contact { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.person:last-child, .contact:last-child { border-bottom: 0; }
.initials { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-size: 14px; font-weight: 700;
  background: var(--brand-soft); color: var(--brand); letter-spacing: .02em; }
.person.st-submitted .initials { background: var(--warn-soft); color: var(--warn); }
.person.st-declined .initials { background: var(--bad-soft); color: var(--bad); }
.person.st-declined .person-name { text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--bad) 60%, transparent); }
.person-name { font-size: 16.5px; font-weight: 650; overflow-wrap: anywhere; }
.person-role { font-size: 14px; color: var(--ink-2); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; padding: 3px 9px; border-radius: 8px;
  background: var(--surface-2); color: var(--ink-2); }
.tag-acc { background: var(--brand-soft); color: var(--brand); }
.tag-open { background: transparent; border: 1px dashed var(--line); color: var(--ink-3); font-weight: 500; }
.person-contact { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 7px; font-size: 14px; }
.person-contact a { display: inline-flex; align-items: center; gap: 5px; color: var(--ink-2); text-decoration: none; overflow-wrap: anywhere; }
.person-contact a:hover { color: var(--brand); }

/* ── Rider ──────────────────────────────────────────────────────────────── */
.rider-counts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.rc { font-size: 13.5px; padding: 4px 10px; border-radius: 999px; background: var(--surface-2); color: var(--ink-2); }
.rc b { font-weight: 700; color: var(--ink); }
.rc-confirmed { background: var(--ok-soft); } .rc-confirmed b { color: var(--ok); }
.rc-open { background: var(--warn-soft); } .rc-open b { color: var(--warn); }
.rc-declined { background: var(--bad-soft); } .rc-declined b { color: var(--bad); }
.rc.rc-zero { background: var(--surface-2); } .rc.rc-zero b { color: var(--ink-3); }
.rider-items { margin-top: 8px; }
.ri { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 2px 10px; align-items: baseline; padding: 9px 0;
  border-bottom: 1px solid var(--line); font-size: 15px; }
.ri:last-child { border-bottom: 0; }
.ri-state { align-self: center; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; }
.ri-confirmed .ri-state { color: var(--ok); background: var(--ok-soft); }
.ri-open .ri-state { color: var(--warn); background: var(--warn-soft); }
.ri-declined .ri-state { color: var(--bad); background: var(--bad-soft); }
.ri-label { overflow-wrap: anywhere; }
.ri-declined .ri-label { color: var(--ink-2); }
.ri-qty { color: var(--ink-2); font-size: 14px; text-align: right; }
.ri-note { grid-column: 2 / -1; font-size: 14px; color: var(--ink-2); }
.ri-note b { color: var(--bad); font-weight: 650; }

/* ── Kontakte ───────────────────────────────────────────────────────────── */
.contacts { margin-top: 8px; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }

/* ── Fuß ────────────────────────────────────────────────────────────────── */
.foot { max-width: 1168px; margin: 0 auto; padding: 14px 18px 40px; color: var(--ink-3); font-size: 13.5px; display: grid; gap: 4px; text-align: center; }
.foot-fixture { color: var(--warn); }
.foot-forget { color: var(--ink-3); margin-top: 6px; }

/* ── Hinweise ───────────────────────────────────────────────────────────── */
.toast { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px);
  z-index: 60; max-width: min(92vw, 460px); background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 14px;
  font-size: 15px; font-weight: 500; box-shadow: 0 10px 30px rgba(0, 0, 0, .25); opacity: 0; transition: opacity .2s, transform .2s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.update-toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(76px + env(safe-area-inset-bottom)); z-index: 70;
  border: 0; border-radius: 999px; background: var(--brand); color: var(--brand-ink); font-weight: 700; padding: 12px 20px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, .25); cursor: pointer; }

/* ── Seiten ohne Daten ──────────────────────────────────────────────────── */
.message-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: var(--bg); }
.message-card { max-width: 420px; text-align: center; display: grid; justify-items: center; gap: 12px; }
.message-icon { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; background: var(--surface-2); color: var(--ink-2); }
.message-icon .ic { width: 30px; height: 30px; }
.message-card h1 { font-size: 24px; font-weight: 700; letter-spacing: -.01em; }
.message-card p { color: var(--ink-2); }
.message-lang { margin-top: 10px; }
.message-lang .lang { background: var(--surface-2); }
.message-lang .lang button.on { background: var(--ink); color: var(--bg); }

/* ── Formular-Blatt ─────────────────────────────────────────────────────── */
dialog.sheet { border: 0; padding: 0; margin: auto auto 0; width: 100%; max-width: 100%; max-height: 92dvh;
  border-radius: 22px 22px 0 0; background: var(--surface); color: var(--ink); box-shadow: 0 -10px 40px rgba(0, 0, 0, .25); }
dialog.sheet::backdrop { background: rgba(10, 11, 14, .5); backdrop-filter: blur(2px); }
dialog.sheet[open] { animation: up .22s ease-out; }
@keyframes up { from { transform: translateY(24px); } }
@media (min-width: 640px) {
  dialog.sheet { margin: auto; max-width: 560px; border-radius: 22px; max-height: 88vh; }
}
.sheet-form { display: flex; flex-direction: column; max-height: inherit; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 18px 6px; }
.sheet-head h2 { font-size: 20px; font-weight: 700; letter-spacing: -.01em; }
.sheet-body { padding: 6px 18px 8px; overflow-y: auto; display: grid; gap: 14px; }
.sheet-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px calc(14px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line); }
.sheet-foot .btn-primary, .sheet-foot .btn-danger-solid { flex: 1 1 auto; max-width: 260px; }
.field { display: grid; gap: 6px; min-width: 0; border: 0; margin: 0; padding: 0; }
.field label, .field legend { font-size: 14px; font-weight: 650; color: var(--ink); padding: 0; }
.req { color: var(--bad); margin-left: 3px; }
.opt { color: var(--ink-3); font-weight: 400; font-size: 13px; margin-left: 6px; }
.field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: 11px 13px; font-size: 16px;
  border: 1.5px solid var(--line); border-radius: 12px; background: var(--bg); color: var(--ink); }
.field textarea { min-height: 72px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 22%, transparent); }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: var(--bad); }
.field-error { color: var(--bad); font-size: 13.5px; font-weight: 500; min-height: 0; }
.field-error:empty { display: none; }
.hint { color: var(--ink-3); font-size: 13px; }
.hint-block { display: flex; gap: 6px; align-items: center; margin-top: -6px; }
.row2 { display: grid; gap: 14px; }
@media (min-width: 420px) { .row2 { grid-template-columns: 1fr 1fr; } }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg-opt { position: relative; }
.seg-opt input { position: absolute; opacity: 0; inset: 0; margin: 0; }
.seg-opt span { display: inline-flex; align-items: center; gap: 6px; padding: 9px 13px; border-radius: 12px; border: 1.5px solid var(--line);
  font-size: 15px; font-weight: 600; color: var(--ink-2); background: var(--bg); cursor: pointer; min-height: 44px; }
.seg-opt input:checked + span { border-color: var(--brand); color: var(--brand); background: var(--brand-soft); }
.seg-opt input:focus-visible + span { outline: 2px solid var(--brand); outline-offset: 2px; }
.switches { display: grid; gap: 10px; }
@media (min-width: 420px) { .switches { grid-template-columns: 1fr 1fr; } }
.switch { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--bg);
  border: 1.5px solid var(--line); cursor: pointer; font-weight: 600; font-size: 15px; min-height: 48px; position: relative; }
.switch input { position: absolute; opacity: 0; }
.switch-ui { width: 38px; height: 22px; border-radius: 999px; background: var(--line); position: relative; flex: none; transition: background .15s; }
.switch-ui::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff;
  transition: transform .15s; box-shadow: 0 1px 2px rgba(0, 0, 0, .2); }
.switch input:checked + .switch-ui { background: var(--brand); }
.switch input:checked + .switch-ui::after { transform: translateX(16px); }
.switch input:focus-visible + .switch-ui { outline: 2px solid var(--brand); outline-offset: 2px; }
.submit-note { display: flex; gap: 8px; align-items: flex-start; color: var(--ink-2); font-size: 13.5px; background: var(--surface-2);
  padding: 10px 12px; border-radius: 12px; }
.submit-note .ic { margin-top: 2px; color: var(--ink-3); }
.form-error { color: var(--bad); font-weight: 600; font-size: 14.5px; }
.form-error:empty { display: none; }
.confirm-text { font-size: 16px; color: var(--ink-2); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
