/* ============================================================
   Teretana – stilovi (vizualno usklađeno s RiSource IT Ticketingom)
   ============================================================ */

:root {
  --font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: "Cascadia Mono", ui-monospace, Consolas, monospace;

  --bg: #f4f6fa;
  --surface: #ffffff;
  --surface-2: #f8f9fc;
  --surface-3: #eef0f5;
  --border: #e3e6ee;
  --border-strong: #d0d5e0;
  --text: #111827;
  --text-2: #4b5563;
  --text-3: #8a93a3;

  --primary: #1479c9;
  --primary-hover: #0f68ae;
  --primary-soft: #e7f4fd;
  --primary-text: #0f6ab2;
  --danger: #dc2626;
  --danger-soft: #fdecec;
  --success: #059669;
  --success-soft: #e6f6ef;
  --warn: #d97706;
  --warn-soft: #fdf3e2;

  --sidebar-bg: #111827;
  --sidebar-text: #9ca3af;
  --sidebar-hover: #1f2937;
  --sidebar-active: #273248;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .05);
  --shadow-md: 0 4px 12px rgba(16, 24, 40, .08);
  --shadow-lg: 0 20px 48px rgba(16, 24, 40, .18);
  --scrim: rgba(15, 23, 42, .42);

  --hour: 56px;

  color-scheme: light;
}

[data-theme="dark"] {
  --bg: #0b0f17;
  --surface: #121826;
  --surface-2: #171e2e;
  --surface-3: #1d2537;
  --border: #242d40;
  --border-strong: #313c55;
  --text: #e6e8ee;
  --text-2: #a5adbd;
  --text-3: #6c7589;

  --primary: #1f8fdf;
  --primary-hover: #3aa3ee;
  --primary-soft: rgba(35, 178, 249, .15);
  --primary-text: #6cc6f8;
  --danger: #f05252;
  --danger-soft: rgba(240, 82, 82, .14);
  --success: #34d399;
  --success-soft: rgba(52, 211, 153, .13);
  --warn: #f59e0b;
  --warn-soft: rgba(245, 158, 11, .14);

  --sidebar-bg: #080b12;
  --sidebar-hover: #141a28;
  --sidebar-active: #1c2436;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow-md: 0 4px 14px rgba(0, 0, 0, .35);
  --shadow-lg: 0 24px 56px rgba(0, 0, 0, .55);
  --scrim: rgba(0, 0, 0, .55);

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body {
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.45;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--primary-text); }
h1, h2, h3 { margin: 0; line-height: 1.25; }
button { font: inherit; }

.icon { width: 16px; height: 16px; flex: none; }
.muted { color: var(--text-3); }
.small { font-size: 12.5px; }
.nowrap { white-space: nowrap; }

/* ---------------------------------------------------------- layout */

.app { display: grid; grid-template-columns: 244px minmax(0, 1fr); min-height: 100vh; }

.sidebar {
  position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column; gap: 18px;
  padding: 18px 14px;
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, .18) transparent;
  z-index: 40;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 2px; color: #fff; text-decoration: none; }
.brand-logo {
  width: 36px; height: 36px; flex: none;
  display: grid; place-items: center;
  border-radius: 10px;
  background: linear-gradient(135deg, #23b2f9, #1479c9);
  color: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
}
.brand-logo .icon { width: 21px; height: 21px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name { font-weight: 700; font-size: 16px; letter-spacing: -.01em; }
.brand-sub { font-size: 11.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: #6cc6f8; }

.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-section { margin: 14px 12px 4px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #6b7280; }
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  color: var(--sidebar-text);
  text-decoration: none;
  font-weight: 500;
}
.nav-item:hover { background: var(--sidebar-hover); color: #e5e7eb; }
.nav-item.active { background: var(--sidebar-active); color: #fff; }
.nav-item .count {
  margin-left: auto;
  min-width: 22px; padding: 0 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .08);
  font-size: 11.5px; font-weight: 600; text-align: center; line-height: 20px;
}
.nav-item .count.warn { background: #f59e0b; color: #111827; }

.sidebar-footer { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }
.user-box {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 8px 10px 10px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(255, 255, 255, .06);
}
.user-box .ub-main { flex: 1; min-width: 0; }
.user-box .ub-main b, .user-box .ub-main small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-box .ub-main b { color: #f3f4f6; font-size: 13.5px; }
.user-box .ub-main small { font-size: 12px; color: var(--sidebar-text); }
.user-box .icon-btn { width: 30px; height: 30px; color: var(--sidebar-text); }
.user-box .icon-btn:hover { background: var(--sidebar-hover); color: #fff; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 14px;
  padding: 12px 24px;
  min-height: 62px;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.topbar h1 { font-size: 19px; font-weight: 700; letter-spacing: -.01em; white-space: nowrap; }
.topbar-actions { display: flex; gap: 8px; margin-left: auto; }
.menu-btn { display: none; }
.view { padding: 22px 24px 40px; }

/* ---------------------------------------------------------- gumbi i polja */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 8px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-weight: 600; font-size: 13.5px;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  transition: background .12s, border-color .12s;
}
.btn:hover { background: var(--surface-2); }
.btn:focus-visible, .icon-btn:focus-visible, .seg-btn:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-danger:hover { filter: brightness(.95); background: var(--danger); }
.btn-success { background: var(--success); border-color: var(--success); color: #fff; }
[data-theme="dark"] .btn-success { color: #052e1f; }
.btn-success:hover { filter: brightness(.95); background: var(--success); }
.btn-ghost { border-color: transparent; background: none; color: var(--text-2); }
.btn-ghost:hover { background: var(--surface-3); }
.btn-danger-ghost { border-color: transparent; background: none; color: var(--danger); }
.btn-danger-ghost:hover { background: var(--danger-soft); }
.btn.sm { padding: 5px 10px; font-size: 12.5px; }
.btn-block { width: 100%; padding: 10px 14px; }
.btn-lg { padding: 11px 18px; font-size: 14.5px; }
.sidebar .btn-new { width: 100%; padding: 10px 14px; }

.icon-btn {
  display: inline-grid; place-items: center;
  width: 34px; height: 34px;
  border: none; border-radius: var(--radius-sm);
  background: none; color: var(--text-2);
  cursor: pointer;
}
.icon-btn:hover { background: var(--surface-3); color: var(--text); }

label.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--text-2); }
label.field .req { color: var(--danger); }
input, select, textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font: inherit; font-weight: 400;
}
textarea { resize: vertical; min-height: 76px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
input[type="color"] { padding: 3px; height: 38px; }
.form { display: flex; flex-direction: column; gap: 14px; }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.hint { font-size: 12px; font-weight: 400; color: var(--text-3); }
.check { display: flex; align-items: center; gap: 9px; cursor: pointer; font-weight: 500; color: var(--text); }
.check input { width: 16px; height: 16px; margin: 0; }

.search {
  position: relative; display: flex; align-items: center;
  min-width: 220px; flex: 1; max-width: 340px;
}
.search .icon { position: absolute; left: 11px; color: var(--text-3); pointer-events: none; }
.search input { padding-left: 34px; }

.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 16px; }
.toolbar select { width: auto; min-width: 150px; }
.toolbar .spacer { flex: 1; }

.seg { display: inline-flex; padding: 3px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); }
.seg-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 11px; border: none; border-radius: 6px;
  background: none; color: var(--text-2); font-weight: 600; font-size: 13px; cursor: pointer;
}
.seg-btn.active { background: var(--surface-3); color: var(--text); }

.tabs { display: flex; gap: 4px; flex-wrap: wrap; border-bottom: 1px solid var(--border); margin-bottom: 14px; }
.tab {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 12px; margin-bottom: -1px;
  border: none; border-bottom: 2px solid transparent;
  background: none; color: var(--text-2); font-weight: 600; cursor: pointer;
}
.tab.active { color: var(--primary-text); border-bottom-color: var(--primary); }
.tab .n { padding: 0 6px; border-radius: 999px; background: var(--surface-3); font-size: 11.5px; color: var(--text-2); }

/* ---------------------------------------------------------- kartice, KPI */

.card, .panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.panel-head { display: flex; align-items: center; gap: 8px; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.panel-head h2 { font-size: 14.5px; font-weight: 700; }
.panel-head .link { margin-left: auto; font-size: 13px; font-weight: 600; text-decoration: none; }
.panel-body { padding: 14px 16px; }
.panel-empty { padding: 26px 16px; text-align: center; color: var(--text-3); }

.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi {
  position: relative; overflow: hidden;
  padding: 14px 16px 13px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  color: inherit; text-decoration: none;
  transition: transform .12s, box-shadow .12s, border-color .12s;
}
a.kpi:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); border-color: var(--border-strong); }
.kpi::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--c); }
.kpi-head { display: flex; align-items: center; justify-content: space-between; color: var(--text-2); font-size: 13px; font-weight: 500; }
.kpi-head .icon { color: var(--c); }
.kpi-value { font-size: 30px; font-weight: 700; letter-spacing: -.02em; margin-top: 6px; line-height: 1.1; }
.kpi-value small { font-size: 15px; font-weight: 600; color: var(--text-3); }
.kpi-sub { font-size: 12px; color: var(--text-3); margin-top: 4px; min-height: 17px; }
.kpi-sub.warn { color: var(--danger); font-weight: 600; }
.kpi-sub.good { color: var(--success); font-weight: 600; }

.dash-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px; align-items: start; }
.dash-side { display: flex; flex-direction: column; gap: 18px; }
.panel.attention { border-color: color-mix(in srgb, var(--warn) 40%, var(--border)); }

.bar { height: 6px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: inherit; background: var(--c, var(--primary)); }

.list-row {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--border);
  color: inherit; text-decoration: none; cursor: pointer;
}
.list-row:last-child { border-bottom: none; }
.list-row:hover { background: var(--surface-2); }
.list-row .lr-main { flex: 1; min-width: 0; }
.list-row .lr-main b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-row .lr-main small { display: block; color: var(--text-3); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-row .lr-end { text-align: right; flex: none; font-size: 12.5px; }
.time-chip {
  flex: none; width: 54px; padding: 5px 0;
  border-radius: 8px; text-align: center;
  background: color-mix(in srgb, var(--c) 16%, transparent);
  color: color-mix(in srgb, var(--c) 75%, var(--text));
  font-weight: 700; font-size: 13px; font-variant-numeric: tabular-nums;
  border-left: 3px solid var(--c);
}
.load-row { display: grid; grid-template-columns: 30px minmax(0, 1fr) 90px 40px; align-items: center; gap: 10px; padding: 8px 16px; }
.load-row .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------------------------------------------------------- avatari, oznake */

.avatar {
  --h: 210;
  width: 30px; height: 30px; flex: none;
  display: inline-grid; place-items: center;
  border-radius: 8px;
  font-size: 11.5px; font-weight: 700;
  color: hsl(var(--h) 60% 32%);
  background: hsl(var(--h) 70% 92%);
}
[data-theme="dark"] .avatar { color: hsl(var(--h) 85% 80%); background: hsl(var(--h) 35% 22%); }
.avatar.lg { width: 44px; height: 44px; font-size: 15px; border-radius: 12px; }

.pill {
  --c: var(--text-3);
  display: inline-flex; align-items: center; gap: 6px;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 12px; font-weight: 600;
  white-space: nowrap;
  color: color-mix(in srgb, var(--c) 80%, var(--text));
  background: color-mix(in srgb, var(--c) 15%, transparent);
  border: 1px solid color-mix(in srgb, var(--c) 30%, transparent);
}
.pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.pill.ok { --c: #10b981; }
.pill.warn { --c: #f59e0b; }
.pill.bad { --c: #ef4444; }
.pill.info { --c: #3b82f6; }
.pill.violet { --c: #8b5cf6; }
.pill.grey { --c: #94a3b8; }

/* ---------------------------------------------------------- tablice */

.table-wrap { overflow-x: auto; }
table.grid { width: 100%; border-collapse: collapse; }
table.grid th {
  padding: 10px 14px;
  text-align: left;
  font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--text-3);
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
table.grid td { padding: 11px 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.grid tr:last-child td { border-bottom: none; }
table.grid tbody tr { cursor: pointer; }
table.grid tbody tr:hover td { background: var(--surface-2); }
.who { display: flex; align-items: center; gap: 10px; min-width: 200px; }
.who b { display: block; font-weight: 600; }
.who small { display: block; color: var(--text-3); font-size: 12.5px; }
.table-foot { margin-top: 10px; font-size: 12.5px; color: var(--text-3); }

/* ---------------------------------------------------------- modal */

.modal-scrim {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: start center;
  padding: 5vh 16px;
  background: var(--scrim);
  overflow-y: auto;
  animation: fade .15s ease;
}
.modal {
  width: min(560px, 100%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  animation: pop .16s ease;
}
.modal.wide { width: min(760px, 100%); }
.modal-head { display: flex; align-items: center; gap: 10px; padding: 16px 18px 6px; }
.modal-head h2 { font-size: 17px; font-weight: 700; flex: 1; }
.modal-body { padding: 10px 18px 18px; }
.modal-foot {
  display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px;
  padding: 14px 18px;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
  border-radius: 0 0 16px 16px;
}
.modal-foot .foot-left { margin-right: auto; display: flex; gap: 8px; }
.form-error {
  display: flex; gap: 8px; align-items: flex-start;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: var(--danger-soft); color: var(--danger);
  font-weight: 500;
}
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.98); } }

.detail-grid { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 9px 10px; align-items: center; margin: 4px 0 16px; }
.detail-grid .icon { color: var(--text-3); }
.type-dot { width: 12px; height: 12px; border-radius: 4px; background: var(--c); flex: none; }
.capacity-box { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border); margin-bottom: 14px; }
.capacity-box .top { display: flex; justify-content: space-between; margin-bottom: 8px; font-weight: 600; }
.section-title { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); margin: 16px 0 8px; }
.attendees { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--radius-sm); max-height: 280px; overflow-y: auto; }
.attendee { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-bottom: 1px solid var(--border); }
.attendee:last-child { border-bottom: none; }
.attendee .name { flex: 1; min-width: 0; }
.attendee .name small { display: block; color: var(--text-3); font-size: 12px; }

.picker { position: relative; }
.picker-list {
  position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 5;
  max-height: 230px; overflow-y: auto;
  background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
}
.picker-item { display: flex; align-items: center; gap: 9px; padding: 8px 10px; cursor: pointer; }
.picker-item:hover, .picker-item.active { background: var(--surface-3); }

.swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.swatch { width: 28px; height: 28px; border-radius: 8px; border: 2px solid transparent; background: var(--c); cursor: pointer; }
.swatch.active { border-color: var(--text); box-shadow: 0 0 0 2px var(--surface) inset; }

.secret-box { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--success-soft); border: 1px solid color-mix(in srgb, var(--success) 35%, transparent); }
.secret-box code { font-family: var(--mono); font-size: 15px; font-weight: 700; user-select: all; }

/* ---------------------------------------------------------- toast */

#toasts { position: fixed; right: 18px; bottom: 18px; z-index: 200; display: flex; flex-direction: column; gap: 8px; }
.toast {
  display: flex; align-items: center; gap: 9px;
  padding: 11px 14px;
  border-radius: 10px;
  background: #111827; color: #f3f4f6;
  border: 1px solid #1f2937;
  box-shadow: var(--shadow-lg);
  font-weight: 500;
  animation: pop .18s ease;
}
.toast.error { background: #3b1219; border-color: #7f1d1d; color: #fecaca; }
.toast .icon { color: #34d399; }
.toast.error .icon { color: #f87171; }

/* ---------------------------------------------------------- prijava */

#boot { min-height: 100vh; display: grid; place-content: center; }
.spinner { width: 28px; height: 28px; border: 3px solid var(--border-strong); border-top-color: var(--primary); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.auth {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 32px 16px;
  background:
    radial-gradient(1000px 520px at 15% -10%, color-mix(in srgb, var(--primary) 22%, transparent), transparent 60%),
    radial-gradient(800px 480px at 110% 110%, color-mix(in srgb, #23b2f9 18%, transparent), transparent 60%),
    var(--bg);
}
.auth-card {
  width: min(440px, 100%);
  padding: 34px 32px 30px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-lg);
}
.auth-card.wide { width: min(500px, 100%); }
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 26px; }
.auth-brand .brand-logo { width: 50px; height: 50px; border-radius: 14px; }
.auth-brand .brand-logo .icon { width: 27px; height: 27px; }
.auth-brand-name { font-size: 20px; font-weight: 800; letter-spacing: -.02em; }
.auth-brand-sub { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--primary-text); }
.auth-card h1 { font-size: 22px; letter-spacing: -.01em; margin-bottom: 4px; }
.auth-lead { margin: 0 0 20px; color: var(--text-2); }
.auth-switch { margin-top: 18px; text-align: center; color: var(--text-2); }
.auth-switch a { font-weight: 600; cursor: pointer; }

/* ---------------------------------------------------------- kalendar */

.cal-nav { display: flex; align-items: center; gap: 6px; }
.cal-range { font-size: 16px; font-weight: 700; margin: 0 6px; white-space: nowrap; }
.cal-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: -4px 0 14px; font-size: 12.5px; color: var(--text-2); }
.cal-legend span { display: inline-flex; align-items: center; gap: 6px; }

.week {
  display: grid;
  grid-template-columns: 56px repeat(7, minmax(110px, 1fr));
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.week-scroll {
  overflow: auto;
  max-height: calc(100vh - 190px);
  min-height: 420px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.week-scroll .week { min-width: 860px; border: none; border-radius: 0; box-shadow: none; overflow: visible; }
.wk-head {
  position: sticky; top: 0; z-index: 5;
  padding: 10px 8px;
  text-align: center;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  border-left: 1px solid var(--border);
}
.wk-head:first-child { border-left: none; }
.wk-head .dow { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); }
.wk-head .dom { font-size: 20px; font-weight: 700; line-height: 1.2; }
.wk-head.today .dom {
  display: inline-grid; place-items: center;
  min-width: 34px; height: 34px; border-radius: 50%;
  background: var(--primary); color: #fff;
}
.wk-head.today .dow { color: var(--primary-text); }
.wk-gutter { position: relative; }
.wk-gutter span {
  position: absolute; right: 8px;
  font-size: 11px; color: var(--text-3); font-variant-numeric: tabular-nums;
  transform: translateY(-50%);
}
.wk-col {
  position: relative;
  border-left: 1px solid var(--border);
  background-image: repeating-linear-gradient(to bottom, var(--border) 0 1px, transparent 1px var(--hour));
}
.wk-col.today { background-color: color-mix(in srgb, var(--primary) 5%, transparent); }
.wk-col.past-day { background-color: color-mix(in srgb, var(--surface-3) 45%, transparent); }
.now-line { position: absolute; left: 0; right: 0; height: 2px; background: var(--danger); z-index: 2; }
.now-line::before { content: ""; position: absolute; left: -5px; top: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--danger); }

.ev {
  position: absolute;
  display: flex; flex-direction: column; gap: 1px;
  padding: 5px 7px 5px 8px;
  border-radius: 7px;
  border-left: 3px solid var(--c);
  background: color-mix(in srgb, var(--c) 17%, var(--surface));
  color: var(--text);
  overflow: hidden;
  cursor: pointer;
  font-size: 12px; line-height: 1.3;
  text-align: left;
  border-top: none; border-right: none; border-bottom: none;
  transition: box-shadow .12s, transform .12s;
}
.ev > * { flex: none; }
.ev:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); z-index: 4; }
.ev b { font-size: 12.5px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ev .t { color: var(--text-2); font-variant-numeric: tabular-nums; }
.ev .who-line { color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ev .occ { display: flex; align-items: center; gap: 6px; margin-top: auto; font-weight: 600; font-variant-numeric: tabular-nums; }
.ev .occ .bar { flex: 1; height: 4px; --c: var(--ev-c); }
.ev.mine { box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c) 70%, transparent); }
.ev.full .occ { color: var(--danger); }
.ev.past { opacity: .6; }
.ev.cancelled { opacity: .55; }
.ev.cancelled b { text-decoration: line-through; }
.ev .badge-mine {
  position: absolute; top: 4px; right: 4px;
  display: grid; place-items: center;
  width: 17px; height: 17px; border-radius: 50%;
  background: var(--c); color: #fff;
}
.ev .badge-mine .icon { width: 11px; height: 11px; }

.agenda { display: flex; flex-direction: column; gap: 16px; }
.agenda-day h3 { font-size: 13px; font-weight: 700; color: var(--text-2); margin: 0 0 8px 2px; }
.agenda-day h3::first-letter { text-transform: uppercase; }
.agenda-day h3.today { color: var(--primary-text); }
.agenda-item { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--border); cursor: pointer; }
.agenda-item:last-child { border-bottom: none; }
.agenda-item:hover { background: var(--surface-2); }
.agenda-item .ai-main { flex: 1; min-width: 0; }
.agenda-item .ai-main b { display: block; }
.agenda-item .ai-main small { display: block; color: var(--text-3); font-size: 12.5px; }
.agenda-item .ai-occ { width: 110px; flex: none; font-size: 12.5px; font-weight: 600; text-align: right; }
.agenda-item .ai-occ .bar { margin-top: 5px; }
.agenda-item.cancelled .ai-main b { text-decoration: line-through; color: var(--text-3); }

/* ---------------------------------------------------------- vrste treninga */

.type-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.type-card { position: relative; padding: 16px 16px 14px 19px; cursor: pointer; overflow: hidden; }
.type-card::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--c); }
.type-card:hover { box-shadow: var(--shadow-md); }
.type-card h3 { font-size: 15px; display: flex; align-items: center; gap: 8px; }
.type-card p { margin: 6px 0 10px; color: var(--text-2); font-size: 13px; min-height: 38px; }
.type-card .meta { display: flex; gap: 14px; font-size: 12.5px; color: var(--text-3); }
.type-card .meta span { display: inline-flex; align-items: center; gap: 5px; }
.type-card.inactive { opacity: .55; }

.profile-head { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.profile-head h2 { font-size: 18px; }

/* ---------------------------------------------------------- polje za datum (hrvatski format) */

.datefield { position: relative; display: flex; align-items: center; }
.datefield .date-text { padding-right: 38px; }
.date-btn {
  position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  display: grid; place-items: center;
  width: 30px; height: 30px;
  border: none; border-radius: 6px; background: none;
  color: var(--text-3); cursor: pointer;
}
.date-btn:hover { background: var(--surface-3); color: var(--text); }
input.invalid { border-color: var(--danger); box-shadow: 0 0 0 3px var(--danger-soft); }
.time-text { font-variant-numeric: tabular-nums; }

.dp {
  position: absolute; left: 0; top: calc(100% + 6px); z-index: 20;
  width: 284px; padding: 10px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  color: var(--text); font-weight: 400;
  animation: pop .12s ease;
}
.dp-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.dp-head b { font-size: 14px; }
.dp-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.dp-dow { padding: 4px 0; text-align: center; font-size: 11px; font-weight: 700; color: var(--text-3); text-transform: uppercase; }
.dp-day {
  height: 34px; border: none; border-radius: 8px;
  background: none; color: var(--text);
  font-size: 13px; font-variant-numeric: tabular-nums; cursor: pointer;
}
.dp-day:hover { background: var(--surface-3); }
.dp-day.out { color: var(--text-3); opacity: .55; }
.dp-day.sun { color: var(--danger); }
.dp-day.hol { color: var(--danger); font-weight: 700; background: var(--danger-soft); }
.dp-day.today { box-shadow: inset 0 0 0 1.5px var(--primary); }
.dp-day.sel { background: var(--primary); color: #fff; }
.dp-day:disabled { cursor: not-allowed; text-decoration: line-through; opacity: .45; }
.dp-foot { display: flex; justify-content: space-between; margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--border); }

/* ---------------------------------------------------------- blagdani */

.wk-head .hol {
  margin-top: 3px;
  font-size: 10.5px; font-weight: 700; line-height: 1.25;
  color: var(--danger);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.wk-head.holiday { background: color-mix(in srgb, var(--danger) 8%, var(--surface-2)); }
.wk-head.holiday .dom { color: var(--danger); }
.wk-col.holiday { background-color: color-mix(in srgb, var(--danger) 5%, transparent); }
.wk-col.closed {
  background-image:
    repeating-linear-gradient(135deg, color-mix(in srgb, var(--danger) 10%, transparent) 0 6px, transparent 6px 14px),
    repeating-linear-gradient(to bottom, var(--border) 0 1px, transparent 1px var(--hour));
  cursor: not-allowed;
}
.hol-pill { margin-left: 8px; vertical-align: 1px; text-transform: none; }

/* ---------------------------------------------------------- postavke */

.switch-row { display: flex; align-items: flex-start; gap: 14px; cursor: pointer; }
.switch { position: relative; flex: none; width: 42px; height: 24px; margin-top: 1px; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.switch i {
  position: absolute; inset: 0; border-radius: 999px;
  background: var(--border-strong); transition: background .15s;
  pointer-events: none;
}
.switch i::after {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 18px; height: 18px; border-radius: 50%;
  background: #fff; box-shadow: var(--shadow-sm);
  transition: transform .15s;
}
.switch input:checked + i { background: var(--primary); }
.switch input:checked + i::after { transform: translateX(18px); }
.switch input:focus-visible + i { outline: 2px solid var(--primary); outline-offset: 2px; }

.notice {
  display: flex; flex-direction: column; align-items: flex-start; gap: 10px;
  margin-top: 16px; padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--surface-2); border: 1px solid var(--border);
}
.notice.warn { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 40%, transparent); }
.notice .icon { color: var(--warn); }
.notice-list { align-self: stretch; max-height: 220px; overflow-y: auto; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); }
.notice-list .list-row { padding: 8px 12px; }

table.grid.static tbody tr { cursor: default; }
table.grid tr.past td { color: var(--text-3); }
table.grid tr.past td b { font-weight: 500; }

.toast.warn { background: #3a2a07; border-color: #78520b; color: #fde68a; }
.toast.warn .icon { color: #fbbf24; }

/* ---------------------------------------------------------- odjava i dolasci */

.info-box {
  display: flex; align-items: flex-start; gap: 9px;
  margin: -4px 0 14px; padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: var(--primary-soft);
  color: var(--text-2); font-size: 13px;
}
.info-box .icon { margin-top: 2px; color: var(--primary-text); }
.info-box b { color: var(--text); }
.info-box.ok { background: var(--success-soft); }
.info-box.ok .icon { color: var(--success); }

.visit-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 10px; }
.visit-stats div { padding: 8px 10px; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border); }
.visit-stats b { display: block; font-size: 19px; line-height: 1.2; }
.visit-stats span { font-size: 11.5px; color: var(--text-3); }

/* ---------------------------------------------------------- mobitel */

.scrim-nav { display: none; }

@media (max-width: 1100px) {
  .dash-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 860px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .sidebar {
    position: fixed; left: 0; top: 0; bottom: 0; width: 260px;
    transform: translateX(-100%);
    transition: transform .22s ease;
  }
  .app.nav-open .sidebar { transform: none; }
  .app.nav-open .scrim-nav { display: block; position: fixed; inset: 0; z-index: 35; background: var(--scrim); }
  .menu-btn { display: inline-grid; }
  .topbar { padding: 10px 16px; gap: 8px; }
  .topbar h1 { font-size: 17px; }
  .topbar .btn .lbl { display: none; }
  .view { padding: 16px 16px 32px; }
  .search { max-width: none; min-width: 0; }
  .toolbar select { flex: 1; min-width: 0; }
  .agenda-item .ai-occ { width: 76px; }
  .load-row { grid-template-columns: 30px minmax(0, 1fr) 60px 30px; }
}

/* ---------------------------------------------------------- lozinka – prikaži/sakrij */

.password-wrap { position: relative; display: flex; align-items: center; }
.password-wrap input { padding-right: 42px; }
.password-wrap .pw-toggle { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; }

/* ---------------------------------------------------------- zaboravljena lozinka */

.forgot-link { margin-top: -6px; text-align: right; font-size: 13px; }
.forgot-link a, .auth-card [data-mode] { cursor: pointer; font-weight: 600; }
.auth-icon {
  display: grid; place-items: center;
  width: 46px; height: 46px; margin-bottom: 14px;
  border-radius: 12px;
}
.auth-icon .icon { width: 24px; height: 24px; }
.auth-icon.ok { background: var(--success-soft); color: var(--success); }
.auth-icon.bad { background: var(--danger-soft); color: var(--danger); }

/* ---------------------------------------------------------- članarine i uplate */

.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.chip {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 5px 11px;
  border: 1px solid var(--border); border-radius: 999px;
  background: var(--surface); color: var(--text-2);
  font-weight: 600; font-size: 12.5px; cursor: pointer;
}
.chip span { padding: 0 6px; border-radius: 999px; background: var(--surface-3); font-size: 11.5px; }
.chip.active { border-color: var(--primary); color: var(--primary-text); background: var(--primary-soft); }
.chip:hover:not(.active) { background: var(--surface-2); }

td.num, th.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.debt { color: var(--danger); }
.kpi-value.debt { color: var(--danger); }
.usage { min-width: 92px; font-size: 12.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.usage .bar { margin-top: 4px; height: 4px; }
.pay-total {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px;
  margin-top: 10px; padding: 10px 14px;
  border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border);
  color: var(--text-2);
}
.pay-total b { color: var(--text); }
.plan-price { font-size: 22px; font-weight: 700; margin-top: 6px; letter-spacing: -.01em; }
.type-card .plan-price + p { min-height: 0; }
.member-chip {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border);
}
.member-chip > div { flex: 1; min-width: 0; }
.member-chip b { display: block; }
.member-chip small { display: block; color: var(--text-3); font-size: 12.5px; }
.pay-now { display: flex; flex-direction: column; gap: 10px; padding: 12px; border-radius: var(--radius-sm); border: 1px dashed var(--border-strong); }
.link-btn { cursor: pointer; font-weight: 600; text-decoration: none; }
.link-btn:hover { text-decoration: underline; }
a.kpi { cursor: pointer; }

.ms-list { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.ms-item { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-bottom: 1px solid var(--border); cursor: pointer; }
.ms-item:last-child { border-bottom: none; }
.ms-item:hover { background: var(--surface-2); }
.ms-item .ms-main { flex: 1; min-width: 0; }
.ms-item .ms-main b { display: block; }
.ms-item .ms-main small { display: block; color: var(--text-3); font-size: 12px; }
.ms-item .ms-end { text-align: right; font-size: 12.5px; }
.ms-actions { display: flex; gap: 6px; margin: 8px 0 4px; }

/* ---------------------------------------------------------- članski portal */

.member-hello { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin-bottom: 16px; }
.member-hello h2 { font-size: 22px; }
.member-hello span { color: var(--text-3); font-size: 13px; }

.member-top { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 18px; align-items: start; margin-bottom: 18px; }
.member-side { display: flex; flex-direction: column; gap: 14px; }
.member-side .visit-stats { margin: 0; }
.member-side .visit-stats div { background: var(--surface); }

.member-card {
  --mc1: #1479c9; --mc2: #0b3f73;
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; gap: 6px;
  min-height: 200px; padding: 20px 22px;
  border-radius: 18px;
  background:
    radial-gradient(420px 220px at 110% -20%, rgba(255, 255, 255, .18), transparent 60%),
    linear-gradient(135deg, var(--mc1), var(--mc2));
  color: #fff; text-decoration: none;
  box-shadow: 0 14px 34px color-mix(in srgb, var(--mc2) 45%, transparent);
}
.member-card::after {
  content: ""; position: absolute; right: -40px; bottom: -60px;
  width: 200px; height: 200px; border-radius: 50%;
  border: 28px solid rgba(255, 255, 255, .06);
}
.member-card.mc-istjece { --mc1: #d97706; --mc2: #7c3d06; }
.member-card.mc-istekla, .member-card.mc-bez { --mc1: #475569; --mc2: #1e293b; }
.mc-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.mc-brand { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; opacity: .9; }
.mc-top .pill { background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .25); color: #fff; }
.mc-name { margin-top: 10px; font-size: 13px; opacity: .85; }
.mc-plan { font-size: 22px; font-weight: 800; letter-spacing: -.01em; }
.mc-big { margin-top: 6px; font-size: 34px; font-weight: 800; line-height: 1; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.mc-big small { font-size: 14px; font-weight: 600; opacity: .85; letter-spacing: 0; }
.mc-bar { height: 6px; margin-top: 6px; border-radius: 999px; background: rgba(255, 255, 255, .22); overflow: hidden; }
.mc-bar i { display: block; height: 100%; border-radius: inherit; background: #fff; }
.mc-foot { display: flex; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 10px; font-size: 13px; opacity: .9; }
.mc-empty { margin-top: 8px; font-size: 13.5px; opacity: .9; }

.next-training { padding: 16px 18px; cursor: pointer; border-left: 4px solid var(--c, var(--primary)); }
.next-training.empty { cursor: default; border-left-color: var(--border-strong); }
.next-training:hover:not(.empty) { box-shadow: var(--shadow-md); }
.nt-label { font-size: 12.5px; color: var(--text-3); }
.nt-label b { color: var(--primary-text); }
.nt-title { display: flex; align-items: center; gap: 9px; margin: 6px 0 2px; font-size: 19px; font-weight: 700; }
.nt-title .type-dot { background: var(--c); }
.nt-meta { color: var(--text-2); font-size: 13px; }
.nt-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; }

dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 10px 18px; margin: 0; }
dl.facts dt { color: var(--text-3); font-size: 13px; }
dl.facts dd { margin: 0; font-weight: 500; }

.price-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.price-card {
  position: relative;
  display: flex; flex-direction: column; gap: 2px;
  padding: 14px 16px;
  border-radius: var(--radius); border: 1px solid var(--border);
  background: var(--surface-2);
}
.price-card .plan-price { margin: 2px 0 4px; }
.price-card small { color: var(--text-3); font-size: 12.5px; line-height: 1.4; }
.price-card.current { border-color: var(--primary); box-shadow: 0 0 0 1px var(--primary); }
.price-flag { align-self: flex-start; margin-bottom: 4px; }

.bottom-nav { display: none; }

@media (max-width: 860px) {
  .member-top { grid-template-columns: minmax(0, 1fr); }
  .app.member .menu-btn { display: none; }
  .app.member .view { padding-bottom: 96px; }
  .bottom-nav {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
    display: grid; grid-template-columns: repeat(5, 1fr);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
    background: color-mix(in srgb, var(--surface) 94%, transparent);
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--border);
  }
  .bn-item {
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    padding: 6px 2px; border-radius: 10px;
    color: var(--text-3); text-decoration: none;
    font-size: 11px; font-weight: 600;
  }
  .bn-item .icon { width: 21px; height: 21px; }
  .bn-item.active { color: var(--primary-text); background: var(--primary-soft); }
  #toasts { bottom: 84px; left: 12px; right: 12px; }
}

@media (max-width: 600px) {
  .list-row.has-action { flex-wrap: wrap; row-gap: 8px; }
  .list-row.has-action .lr-main { flex: 1 1 calc(100% - 70px); }
  .list-row.has-action .lr-main b, .list-row.has-action .lr-main small { white-space: normal; }
  .list-row.has-action .lr-end { flex: 1; margin-left: 66px; text-align: left; width: auto !important; display: flex; align-items: center; gap: 10px; }
  .list-row.has-action .lr-end .bar { flex: 1; margin-top: 0 !important; }
  .member-card { min-height: 180px; padding: 18px; }
  .price-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .price-card { padding: 12px; }
  .price-card .plan-price { font-size: 18px; }
  .price-flag { position: static; align-self: flex-start; margin-bottom: 4px; }
  .mc-big { font-size: 30px; }
  dl.facts { grid-template-columns: 1fr; gap: 2px; }
  dl.facts dd { margin-bottom: 8px; }
  .visit-stats span { font-size: 11px; }
}


/* ---------------------------------------------------------- platforma (Global Admin) */

.ga-banner, .trial-banner {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 8px 24px;
  font-size: 13px;
}
.ga-banner { background: linear-gradient(90deg, #6d28d9, #4c1d95); color: #f5f3ff; }
.ga-banner b { color: #fff; }
.ga-banner .btn { margin-left: auto; background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.3); color: #fff; }
.ga-banner .btn:hover { background: rgba(255,255,255,.24); }
.trial-banner { background: var(--primary-soft); color: var(--text-2); border-bottom: 1px solid var(--border); }
.trial-banner a { margin-left: auto; font-weight: 600; text-decoration: none; }
.nav-item.platform-back { cursor: pointer; color: #c4b5fd; margin-bottom: 6px; border: 1px dashed rgba(196,181,253,.35); }
.nav-item.platform-back:hover { color: #fff; background: rgba(139,92,246,.2); }

.link-box { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border-radius: var(--radius-sm);
  background: var(--surface-2); border: 1px solid var(--border); }
.link-row { display: flex; gap: 8px; }
.link-row input { font-family: var(--mono); font-size: 13px; }

.gym-modal { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 22px; }
@media (max-width: 760px) { .gym-modal { grid-template-columns: 1fr; } .ga-banner, .trial-banner { padding: 8px 16px; } }


/* ---------------------------------------------------------- registracija, računi, izbor teretane */

.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--border); }
.choice {
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px; text-align: left;
  padding: 14px; border-radius: var(--radius); border: 1px solid var(--border-strong);
  background: var(--surface-2); color: var(--text); font: inherit; cursor: pointer;
  transition: border-color .15s, background .15s;
}
.choice:hover { border-color: var(--primary); background: var(--primary-soft); }
.choice .icon { width: 22px; height: 22px; color: var(--primary-text); margin-bottom: 4px; }
.choice b { font-size: 15px; }
.choice span { font-size: 12.5px; color: var(--text-2); line-height: 1.35; }

.consents { display: flex; flex-direction: column; gap: 9px; padding: 12px 14px; border-radius: var(--radius-sm);
  background: var(--surface-2); border: 1px solid var(--border); }
.check.consent, .consents .check, .parent-block .check { align-items: flex-start; font-weight: 400; font-size: 13.5px; line-height: 1.4; }
.consents .check input, .parent-block .check input, .check.consent input { margin-top: 2px; flex: none; }
.req { color: var(--danger); font-weight: 700; }
.parent-block { display: flex; flex-direction: column; gap: 10px; padding: 12px 14px; border-radius: var(--radius-sm);
  background: var(--warn-soft); border: 1px solid color-mix(in srgb, var(--warn) 35%, transparent); }
.parent-block[hidden] { display: none; }
.rules-text { white-space: pre-wrap; line-height: 1.55; max-height: 60vh; overflow: auto; }

.gym-results { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.gym-pick {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  padding: 10px 12px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text); font: inherit; text-decoration: none; cursor: pointer;
}
.gym-pick:hover:not([disabled]) { border-color: var(--primary); background: var(--primary-soft); }
.gym-pick[disabled] { cursor: default; opacity: .75; }
.gym-pick.current { border-color: var(--primary); }
.gym-pick > span:not(.pill):not(.avatar) { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.gym-pick small { color: var(--text-3); font-size: 12.5px; }
.gym-pick > .icon { color: var(--text-3); }

.verify-banner { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 24px; font-size: 13px;
  background: var(--warn-soft); color: var(--text); border-bottom: 1px solid var(--border); }
.verify-banner > .icon { color: var(--warn); flex: none; }
.verify-banner .btn { margin-left: auto; }
.tab .n.warn { background: var(--warn); color: #111827; }
dl.facts.small-facts { font-size: 13px; gap: 6px 16px; }
dl.facts.small-facts .icon { width: 14px; height: 14px; color: var(--success); vertical-align: -2px; }

@media (max-width: 560px) {
  .choice-grid { grid-template-columns: 1fr; }
  .verify-banner { padding: 8px 16px; }
}
