:root {
  --ink: #172234;
  --muted: #687386;
  --paper: #f3f6fa;
  --card: #ffffff;
  --line: #d9e0e8;
  --green: #1769aa;
  --green-dark: #102a43;
  --lime: #ffc857;
  --orange: #e07a3f;
  --blue: #4c9fcb;
  --shadow: 0 18px 50px rgba(23, 34, 52, .09);
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: "DM Sans", sans-serif; min-height: 100vh; }
body.modal-open { overflow: hidden; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
.masquerade-banner { position: sticky; top: 0; z-index: 20; margin-left: 230px; padding: 10px 42px; background: #fff2c2; border-bottom: 1px solid #e1bd50; color: #4b3510; font-weight: 700; }
.sidebar { position: fixed; inset: 0 auto 0 0; width: 230px; padding: 28px 18px; background: var(--green-dark); color: white; display: flex; flex-direction: column; z-index: 5; }
.brand { display: flex; gap: 12px; color: white; text-decoration: none; align-items: center; padding: 0 8px 36px; }
.brand-mark { width: 38px; height: 38px; border: 2px solid var(--lime); border-radius: 50%; display: grid; place-items: center; color: var(--lime); font: 700 24px/1 Oswald; transform: rotate(-8deg); }
.brand strong { display: block; font: 600 18px/1 Oswald; letter-spacing: .08em; }
.brand small { color: #aebfd1; font-size: 10px; text-transform: uppercase; letter-spacing: .12em; }
nav { display: grid; gap: 6px; }
.nav-link { border: 0; background: transparent; color: #aebfd1; padding: 13px 12px; border-radius: 8px; text-align: left; font-weight: 600; }
.nav-link span { color: #7fa4c2; font: 500 11px Oswald; margin-right: 12px; }
.nav-link:hover, .nav-link.active { background: #19466b; color: white; }
.nav-link.active span { color: var(--lime); }
.sidebar-bottom { margin-top: auto; }
.season-meter { border: 1px solid #315a7c; padding: 14px; border-radius: 10px; }
.season-meter div:first-child { display: flex; justify-content: space-between; font-size: 12px; }
.season-meter strong { color: var(--lime); }
.season-meter small { color: #aebfd1; font-size: 10px; }
.meter { height: 4px; background: #315a7c; margin: 10px 0 8px; overflow: hidden; }
.meter i { display: block; width: 0; height: 100%; background: var(--lime); transition: width .3s; }
.sidebar .text-button { color: #aebfd1; margin: 18px auto 0; display: block; }
main { margin-left: 230px; padding: 0 42px 48px; }
.topbar { height: 126px; display: flex; align-items: center; gap: 18px; }
.topbar h1 { margin: 2px 0 0; font: 600 38px/1 Oswald; text-transform: uppercase; letter-spacing: .02em; }
.topbar select { width: auto; min-width: 140px; margin: 0; }
.avatar-wrap { position: relative; margin-left: auto; }
.avatar-button { width: 46px; height: 46px; border-radius: 50%; border: 2px solid var(--green); background: var(--card); color: var(--green-dark); font-weight: 800; position: relative; }
.avatar-alert { position: absolute; right: -2px; top: -4px; min-width: 18px; height: 18px; display: inline-grid; place-items: center; border-radius: 20px; background: #d78532; color: white; font-size: 11px; border: 2px solid var(--card); }
.avatar-alert[hidden] { display: none; }
.avatar-alert svg { width: 13px; height: 13px; }
.profile-menu, .floating-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 170px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); padding: 7px; z-index: 60; }
.profile-menu button, .floating-menu button { display: block; width: 100%; border: 0; background: transparent; color: var(--ink); text-align: left; border-radius: 7px; padding: 10px; font-weight: 700; }
.profile-menu button:hover, .floating-menu button:hover { background: #eaf4fb; }
.eyebrow { margin: 0; color: var(--green); font: 600 10px/1.2 "DM Sans"; text-transform: uppercase; letter-spacing: .16em; }
.menu-button { display: none; }
.primary-button, .secondary-button { border: 0; border-radius: 6px; padding: 12px 17px; font-weight: 700; transition: transform .15s, background .15s; }
.primary-button { background: var(--green); color: white; }
.primary-button:hover { background: var(--green-dark); transform: translateY(-1px); }
.secondary-button { background: #e8ebe5; color: var(--ink); }
.secondary-button:hover { background: #dce3da; }
.wide { width: 100%; }
select[multiple] { min-height: 118px; }
.text-button, .icon-button { border: 0; background: transparent; color: var(--green); font-weight: 700; padding: 5px; }
.view { display: none; animation: reveal .25s ease; }
.view.active { display: block; }
@keyframes reveal { from { opacity: 0; transform: translateY(5px); } }
.hero-grid, .content-grid, .progress-grid, .log-layout { display: grid; gap: 18px; }
.hero-grid { grid-template-columns: 1.65fr 1fr; }
.today-card { min-height: 300px; background: var(--green); color: white; border-radius: 12px; padding: 30px; position: relative; overflow: hidden; box-shadow: var(--shadow); }
.today-card::after { content: ""; position: absolute; width: 280px; height: 280px; border: 55px solid rgba(215,237,93,.14); border-radius: 50%; right: -100px; bottom: -160px; }
.today-card .eyebrow { color: var(--lime); }
.today-card h2 { font: 600 44px/1.04 Oswald; text-transform: uppercase; max-width: 560px; margin: 22px 0 12px; }
.today-card .meta { color: #c9d9e7; margin-bottom: 24px; }
.today-card .drill-preview { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 28px; }
.today-card .drill-preview span { background: rgba(255,255,255,.09); padding: 7px 10px; border-radius: 4px; font-size: 11px; }
.today-card button { background: var(--lime); color: var(--green-dark); }
.readiness-card, .panel { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 24px; box-shadow: var(--shadow); }
.section-heading { display: flex; justify-content: space-between; gap: 15px; align-items: flex-start; margin-bottom: 22px; }
.section-heading h2 { font: 600 24px/1.1 Oswald; text-transform: uppercase; margin: 6px 0 0; }
.readiness-card .section-heading strong { font: 600 34px Oswald; color: var(--green); }
.feeling-group { margin-bottom: 17px; }
.feeling-group > strong { display: block; margin-bottom: 8px; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.feeling-options { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; }
.feeling-choice { min-height: 72px; border: 2px solid var(--line); background: #fff; border-radius: 7px; padding: 5px 2px; color: var(--muted); font-size: 8px; font-weight: 700; }
.feeling-choice svg { display: block; width: 34px; height: 34px; margin: auto auto 3px; }
.feeling-choice.selected { border: 3px solid var(--green-dark); color: var(--green-dark); background: #eaf4fb; }
label { display: block; color: var(--ink); font-size: 12px; font-weight: 700; }
label output, label small { float: right; color: var(--green); }
input, textarea, select { display: block; width: 100%; border: 1px solid var(--line); border-radius: 6px; background: #fff; padding: 11px 12px; color: var(--ink); margin-top: 7px; outline-color: var(--green); }
input[type="range"] { padding: 0; accent-color: var(--green); margin: 10px 0 18px; }
textarea { resize: vertical; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 18px 0; }
.stat-card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 18px; }
.stat-card small { color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.stat-card strong { display: block; margin-top: 6px; font: 600 30px Oswald; }
.stat-card em { font-style: normal; color: var(--green); font-size: 11px; }
.content-grid { grid-template-columns: 1.65fr 1fr; }
.workload-alert { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-top: 18px; padding: 15px 18px; border: 2px solid #d78532; border-left-width: 8px; background: #fff4dd; border-radius: 9px; font-size: 12px; }
.workload-alert.clear { border-color: #2978b5; background: #eaf4fb; }
.workload-alert strong { display: block; font: 600 17px Oswald; text-transform: uppercase; margin-bottom: 3px; }
.week-strip { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; }
.day-cell { padding: 13px 7px; border: 1px solid var(--line); border-radius: 7px; text-align: center; min-height: 90px; }
.day-cell small { display: block; color: var(--muted); font-size: 9px; text-transform: uppercase; }
.day-cell strong { display: block; margin: 8px 0; font: 600 17px Oswald; }
.day-cell i { width: 7px; height: 7px; display: inline-block; border-radius: 50%; background: var(--line); }
.day-cell.done { background: #eaf4fb; border-color: #9fc9e4; }
.day-cell.done i { background: var(--green); }
.day-cell.today { border: 2px solid var(--green); }
.balance-list, .category-progress { display: grid; gap: 16px; }
.balance-item div, .category-item div { display: flex; justify-content: space-between; font-size: 11px; margin-bottom: 6px; }
.balance-bar, .category-bar { height: 6px; background: #e8e6de; border-radius: 10px; overflow: hidden; }
.balance-bar i, .category-bar i { display: block; height: 100%; background: var(--green); border-radius: 10px; }
.view-actions { display: flex; justify-content: space-between; align-items: center; gap: 15px; margin-bottom: 18px; }
.view-heading { margin: 6px 0 0; font: 600 27px Oswald; text-transform: uppercase; }
.filter-row { display: flex; gap: 6px; flex-wrap: wrap; }
.filter { border: 1px solid var(--line); background: var(--card); color: var(--muted); border-radius: 30px; padding: 8px 13px; font-size: 11px; font-weight: 700; }
.filter.active { background: var(--green-dark); color: white; border-color: var(--green-dark); }
.plan-list { display: grid; gap: 10px; }
.workout-card { display: grid; grid-template-columns: 100px 1fr auto; gap: 20px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 18px; }
.workout-day { border-right: 1px solid var(--line); }
.workout-day small { display: block; color: var(--muted); text-transform: uppercase; font-size: 9px; letter-spacing: .1em; }
.workout-day strong { font: 600 22px Oswald; text-transform: uppercase; }
.workout-card h3 { margin: 0 0 5px; font: 600 19px Oswald; text-transform: uppercase; }
.workout-card p { margin: 0; color: var(--muted); font-size: 11px; }
.tag { display: inline-block; padding: 4px 7px; border-radius: 3px; margin-right: 6px; background: #e5f1f9; color: var(--green); font-size: 9px; font-weight: 700; text-transform: uppercase; }
.card-actions { display: flex; gap: 6px; }
.card-actions button { border: 1px solid var(--line); background: white; border-radius: 5px; padding: 8px 10px; color: var(--ink); font-weight: 700; font-size: 11px; }
.variant-chip { border: 1px solid #9fc9e4; background: #eaf4fb; color: var(--green); border-radius: 20px; padding: 5px 9px; margin: 10px 5px 0 0; font-size: 10px; font-weight: 700; }
.variant-row { display: inline-flex; align-items: baseline; gap: 3px; margin-right: 5px; }
.variant-action { border: 0; background: transparent; color: var(--muted); padding: 3px; font-size: 9px; font-weight: 700; }
.log-layout { grid-template-columns: .95fr 1.4fr; }
.form-stack { display: grid; gap: 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.history-list { display: grid; gap: 10px; max-height: 630px; overflow: auto; }
.history-item { border-bottom: 1px solid var(--line); padding: 4px 0 14px; }
.history-item:last-child { border: 0; }
.history-item div { display: flex; justify-content: space-between; gap: 10px; }
.history-item h3 { margin: 0; font: 600 17px Oswald; text-transform: uppercase; }
.history-item strong { color: var(--green); font: 600 18px Oswald; }
.history-item p { color: var(--muted); font-size: 11px; margin: 7px 0 0; }
.pitch-status-card { padding: 18px; border: 2px solid #2978b5; border-left-width: 8px; border-radius: 8px; background: #eaf4fb; margin-bottom: 18px; }
.pitch-status-card.restricted { border-color: #d78532; background: #fff0df; }
.pitch-status-card h3 { margin: 0 0 5px; font: 600 24px Oswald; text-transform: uppercase; }
.pitch-status-card p { margin: 5px 0; color: var(--muted); font-size: 12px; }
.rest-rules { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; margin-bottom: 20px; }
.rest-rules div { background: #f0eee7; padding: 9px 4px; text-align: center; border-radius: 5px; }
.rest-rules strong, .rest-rules span { display: block; font-size: 10px; }
.rest-rules strong { color: var(--green); }
.test-history { display: grid; gap: 12px; }
.test-card { border: 1px solid var(--line); border-radius: 8px; padding: 16px; }
.test-card h3 { margin: 0 0 12px; font: 600 18px Oswald; text-transform: uppercase; }
.test-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.test-metrics span { background: #f2f0e9; padding: 8px; border-radius: 4px; color: var(--muted); font-size: 9px; }
.test-metrics strong { display: block; color: var(--ink); font: 600 16px Oswald; }
.library-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.drill-card { background: var(--card); border: 1px solid var(--line); border-radius: 9px; padding: 18px; }
.drill-card.needs-approval { border: 2px dashed #d78532; }
.drill-card h3 { font: 600 19px Oswald; text-transform: uppercase; margin: 11px 0 6px; }
.drill-card p { color: var(--muted); font-size: 11px; line-height: 1.5; }
.drill-card a { display: inline-block; color: var(--green); font-size: 11px; font-weight: 700; margin: 12px 0 0 12px; }
.drill-card button { margin-top: 12px; padding: 8px 10px; font-size: 10px; }
.tag.neutral { background: #eef0f3; color: var(--muted); }
.drill-status { border-left: 4px solid #2978b5; background: #eaf4fb; border-radius: 3px; padding: 7px 9px; font-size: 10px; font-weight: 700; }
.needs-approval .drill-status { border-color: #d78532; }
.approval-note { display: inline-block; margin-top: 12px; color: var(--muted); font-size: 10px; }
.panel-copy { color: var(--muted); font-size: 12px; line-height: 1.6; margin: -10px 0 20px; }
.equipment-add { align-self: end; margin-bottom: 0; }
.equipment-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 22px; }
.equipment-item { display: flex; justify-content: space-between; gap: 8px; border: 1px solid var(--line); background: #f7f9fb; border-radius: 6px; padding: 11px; color: var(--ink); text-align: left; font-weight: 700; font-size: 11px; }
.equipment-item small { color: var(--muted); font-size: 9px; }
.session-drill-list { display: grid; gap: 8px; }
.log-drill { display: grid; grid-template-columns: 1fr 150px; gap: 12px; align-items: center; border: 1px solid var(--line); border-radius: 7px; padding: 11px; }
.check-label { display: flex; align-items: center; gap: 10px; }
.check-label input { width: 18px; margin: 0; accent-color: var(--green); }
.check-label span { display: block; }
.check-label strong, .check-label small { display: block; float: none; }
.check-label small { margin-top: 3px; color: var(--muted); font-weight: 500; }
.wide-dialog { width: min(780px, calc(100vw - 24px)); }
.builder-guidance { border-left: 5px solid #2978b5; background: #eaf4fb; border-radius: 5px; padding: 12px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.variation-slots { display: grid; gap: 10px; }
.variation-slot { padding: 11px; border: 1px solid var(--line); border-radius: 7px; background: #f7f9fb; }
.variation-slot span { display: block; color: var(--green); text-transform: uppercase; letter-spacing: .08em; font-size: 9px; }
.builder-warnings { display: grid; gap: 6px; }
.builder-warnings p, .builder-ready { margin: 0; padding: 9px 11px; border-left: 5px solid #d78532; background: #fff4dd; border-radius: 4px; font-size: 11px; font-weight: 700; }
.builder-warnings .blocked, .builder-warnings .approval { border-left-style: double; border-left-width: 8px; }
.builder-ready { border-color: #2978b5; background: #eaf4fb; }
.agenda-list { display: grid; gap: 10px; }
.agenda-item { display: grid; grid-template-columns: 105px 1fr auto; gap: 15px; align-items: center; background: var(--card); border: 1px solid var(--line); border-left: 6px solid #2978b5; border-radius: 8px; padding: 15px; }
.agenda-item.unread { border-left-color: #d78532; background: #fff9ed; }
.agenda-item time { color: var(--muted); font-size: 10px; font-weight: 700; text-transform: uppercase; }
.agenda-item h3 { margin: 4px 0; font: 600 18px Oswald; text-transform: uppercase; }
.agenda-item p { margin: 0; color: var(--muted); font-size: 11px; }
.agenda-item > button, .conflict-actions button { border: 1px solid var(--line); background: #fff; border-radius: 5px; padding: 8px; font-size: 10px; font-weight: 700; }
.conflict-actions { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 8px; }
.admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.profile-actions { display: flex; gap: 10px; justify-content: flex-end; margin-bottom: 18px; position: relative; }
.refresh-button { display: inline-flex; align-items: center; gap: 7px; }
.refresh-icon { display: inline-grid; place-items: center; width: 18px; height: 18px; border: 1px solid currentColor; border-radius: 50%; font-size: 10px; line-height: 1; }
.refresh-button.refreshing .refresh-icon { animation: spin .45s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.profile-stack { display: grid; gap: 18px; }
.association-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; border-bottom: 1px solid var(--line); }
.association-tab { border: 0; border-bottom: 3px solid transparent; background: transparent; color: var(--muted); padding: 10px 12px; font-size: 11px; font-weight: 800; text-transform: uppercase; }
.association-tab.active { color: var(--green-dark); border-bottom-color: var(--green); }
.association-pane { display: none; }
.association-pane.active { display: block; }
.directory-filters { display: grid; grid-template-columns: minmax(180px,1fr) 150px minmax(170px,220px); gap: 8px; margin-bottom: 10px; }
.directory-filters input, .directory-filters select { min-height: 38px; }
.table-controls { display: grid; grid-template-columns: minmax(180px,1fr) minmax(150px,220px); gap: 8px; margin-bottom: 10px; }
.table-controls input, .table-controls select { min-height: 38px; }
.association-list { display: grid; gap: 8px; }
.association-row, .association-member { display: flex; justify-content: space-between; align-items: center; gap: 12px; border: 1px solid var(--line); border-radius: 7px; padding: 12px; background: #f7f9fb; }
.association-row.clickable { cursor: pointer; transition: background .15s, border-color .15s, transform .15s; }
.association-row.clickable:hover { background: #eaf4fb; border-color: #b9d4e8; transform: translateY(-1px); }
.association-row strong, .association-row small, .association-member strong, .association-member small { display: block; }
.association-row small, .association-member small { color: var(--muted); font-size: 10px; margin-top: 3px; }
.association-dialog-body { padding: 25px; display: grid; gap: 18px; }
.association-modal-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.association-detail-section { display: grid; gap: 8px; margin-top: 14px; }
.association-detail-section h3 { margin: 0; font: 600 17px Oswald; text-transform: uppercase; }
.entity-facts { display: grid; grid-template-columns: repeat(auto-fit,minmax(170px,1fr)); gap: 8px; }
.entity-facts div { border: 1px solid var(--line); border-radius: 7px; padding: 10px; background: #f7f9fb; }
.entity-facts strong, .entity-facts span { display: block; }
.entity-facts strong { font-size: 10px; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.empty-state.compact { padding: 18px; }
.table-wrap { overflow-x: auto; }
.profile-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.profile-table th { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; text-align: left; }
.profile-table th, .profile-table td { padding: 12px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.profile-table tr:hover { background: #eaf4fb; }
.profile-table code { font-size: 11px; white-space: nowrap; }
.table-sort { border: 0; background: transparent; color: inherit; padding: 0; font: inherit; text-transform: inherit; letter-spacing: inherit; cursor: pointer; }
.table-sort.active { color: var(--ink); }
.row-actions { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }
.icon-action { border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 5px; padding: 7px 9px; font-size: 10px; font-weight: 800; }
.icon-action.danger { border-color: #d78532; color: #9a3412; }
.text-button.danger { color: #9a3412; }
.settings-row { display: flex; justify-content: space-between; gap: 16px; align-items: center; margin-bottom: 14px; }
.settings-row strong, .settings-row small { display: block; }
.settings-row small { color: var(--muted); font-size: 11px; margin-top: 3px; }
.toggle-button { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 999px; padding: 8px 12px; background: #eef0f3; color: var(--ink); font-weight: 800; }
.toggle-button span { width: 28px; height: 16px; border-radius: 20px; background: #aebfd1; position: relative; }
.toggle-button span::after { content: ""; position: absolute; width: 12px; height: 12px; border-radius: 50%; background: #fff; top: 2px; left: 2px; transition: .15s; }
.toggle-button[aria-pressed="true"] { background: #eaf4fb; color: var(--green-dark); }
.toggle-button[aria-pressed="true"] span { background: var(--green); }
.toggle-button[aria-pressed="true"] span::after { left: 14px; }
.masquerade-dialog { width: 90vw; height: 90vh; max-width: none; max-height: none; border-radius: 14px; overflow: visible; overscroll-behavior: contain; }
.masquerade-shell-heading { height: 58px; display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--card); }
.masquerade-dialog iframe { width: 100%; height: calc(100% - 58px); border: 0; background: var(--paper); }
.database-lookup-button { position: fixed; right: 24px; top: 24px; z-index: 4; border: 1px solid var(--line); border-radius: 6px; background: var(--lime); color: #0b1c14; padding: 10px 12px; font-size: 11px; font-weight: 900; text-transform: uppercase; box-shadow: var(--shadow); }
.database-lookup-panel { position: fixed; right: 24px; top: 72px; z-index: 5; width: min(430px, calc(100vw - 48px)); max-height: min(620px, calc(100vh - 100px)); overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: var(--card); box-shadow: var(--shadow); }
.database-lookup-heading { display: flex; justify-content: space-between; align-items: start; gap: 12px; padding: 14px; border-bottom: 1px solid var(--line); }
.database-lookup-heading h2 { margin: 3px 0 0; font: 600 20px Oswald; text-transform: uppercase; }
.database-lookup-controls { display: grid; grid-template-columns: 150px 1fr; gap: 8px; padding: 12px; border-bottom: 1px solid var(--line); }
.database-lookup-controls input, .database-lookup-controls select { min-height: 38px; }
.database-lookup-results { max-height: 430px; overflow: auto; padding: 8px; display: grid; gap: 6px; }
.database-lookup-row { display: grid; gap: 3px; width: 100%; border: 1px solid var(--line); border-radius: 7px; background: #f7f9fb; color: var(--ink); text-align: left; padding: 10px; }
.database-lookup-row:hover { background: #eaf4fb; border-color: #b9d4e8; }
.database-lookup-row strong, .database-lookup-row small, .database-lookup-row code { display: block; }
.database-lookup-row small { color: var(--muted); font-size: 10px; }
.database-lookup-row code { font-size: 11px; white-space: normal; word-break: break-all; }
.manage-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.manage-row strong, .manage-row small { display: block; }
.manage-row small { color: var(--muted); font-size: 9px; margin-top: 3px; }
.manage-row button { border: 1px solid var(--line); background: #fff; border-radius: 5px; padding: 7px; font-size: 9px; font-weight: 700; }
.auth-screen { display: none; position: fixed; inset: 0; z-index: 100; background: var(--green-dark); padding: 20px; place-items: center; }
.auth-screen.show { display: grid; }
.auth-card { width: min(440px, 100%); background: var(--card); border-radius: 14px; padding: 30px; box-shadow: 0 30px 80px rgba(0,0,0,.3); }
.auth-card h1 { font: 600 34px Oswald; text-transform: uppercase; margin: 8px 0; }
.auth-card p { color: var(--muted); font-size: 12px; line-height: 1.5; }
.auth-error { border-left: 5px solid #d78532; padding: 8px; background: #fff4dd; }
#alert-badge:not(:empty) { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 20px; background: var(--lime); color: var(--green-dark); margin-left: 4px; }
.bottom-nav { display: none; }
.progress-grid { grid-template-columns: 1.5fr 1fr; margin-bottom: 18px; }
.bar-chart { height: 250px; display: flex; align-items: end; gap: 12px; padding-top: 24px; }
.chart-bar { flex: 1; height: 100%; display: flex; align-items: end; justify-content: center; position: relative; border-bottom: 1px solid var(--line); }
.chart-bar i { display: block; width: 65%; max-width: 42px; min-height: 4px; background: var(--green); border-radius: 4px 4px 0 0; }
.chart-bar strong { position: absolute; top: auto; bottom: calc(var(--height) + 5px); font: 600 11px Oswald; }
.chart-bar small { position: absolute; bottom: -20px; color: var(--muted); font-size: 8px; text-transform: uppercase; }
.takeaway-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.takeaway { background: #f2f0e9; border-radius: 7px; padding: 15px; }
.takeaway small { color: var(--green); font-size: 9px; font-weight: 700; text-transform: uppercase; }
.takeaway p { font-size: 12px; margin: 8px 0 0; line-height: 1.5; }
dialog { border: 0; border-radius: 12px; padding: 0; width: min(600px, calc(100vw - 24px)); background: var(--card); box-shadow: 0 25px 80px rgba(0,0,0,.25); }
dialog::backdrop { background: rgba(11,28,20,.65); backdrop-filter: blur(3px); }
dialog form { padding: 25px; display: grid; gap: 17px; }
.dialog-heading, .dialog-actions { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
.dialog-heading h2 { font: 600 27px Oswald; text-transform: uppercase; margin: 4px 0 0; }
.icon-button { font-size: 25px; color: var(--muted); }
.dialog-actions { justify-content: flex-end; }
.toast { position: fixed; right: 25px; bottom: 25px; background: var(--green-dark); color: white; border-left: 4px solid var(--lime); padding: 13px 18px; border-radius: 5px; font-size: 12px; font-weight: 700; transform: translateY(100px); opacity: 0; transition: .25s; z-index: 20; }
.toast.show { transform: translateY(0); opacity: 1; }
.empty-state { padding: 40px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: 8px; }
@media (max-width: 1000px) {
  .sidebar { transform: translateX(-100%); transition: transform .2s; }
  .sidebar.open { transform: translateX(0); }
  .masquerade-banner { margin-left: 0; padding: 10px 22px; }
  main { margin-left: 0; padding: 0 22px 35px; }
  .menu-button { display: block; border: 1px solid var(--line); background: var(--card); padding: 8px; border-radius: 4px; }
  .hero-grid, .content-grid, .progress-grid, .log-layout, .admin-grid { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  main { padding: 0 12px 86px; }
  .topbar { height: 104px; }
  .topbar h1 { font-size: 29px; }
  .topbar .primary-button, .topbar select { display: none; }
  .avatar-button { min-height: 44px; }
  button, select, input { min-height: 44px; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .week-strip { overflow-x: auto; grid-template-columns: repeat(7, 72px); }
  .workout-card { grid-template-columns: 1fr; gap: 10px; }
  .workout-day { border-right: 0; border-bottom: 1px solid var(--line); padding-bottom: 8px; }
  .view-actions { align-items: flex-start; }
  .takeaway-grid { grid-template-columns: 1fr; }
  .library-grid { grid-template-columns: 1fr; }
  .equipment-grid { grid-template-columns: 1fr 1fr; }
  .log-drill { grid-template-columns: 1fr; }
  .rest-rules { grid-template-columns: repeat(5, minmax(60px, 1fr)); overflow-x: auto; }
  .feeling-options { gap: 3px; }
  .feeling-choice { min-height: 78px; font-size: 7px; }
  .feeling-choice svg { width: 32px; height: 32px; }
  .agenda-item { grid-template-columns: 1fr; gap: 7px; }
  .directory-filters { grid-template-columns: 1fr; }
  .table-controls { grid-template-columns: 1fr; }
  .database-lookup-button { right: 12px; top: 12px; }
  .database-lookup-panel { right: 12px; top: 58px; width: calc(100vw - 24px); }
  .database-lookup-controls { grid-template-columns: 1fr; }
  dialog, .wide-dialog { width: 100%; max-width: none; height: 100%; max-height: none; border-radius: 0; }
  dialog form { min-height: 100%; align-content: start; overflow-y: auto; }
  .bottom-nav { display: grid; position: fixed; inset: auto 0 0; z-index: 30; grid-template-columns: repeat(5, 1fr); background: var(--green-dark); padding: 6px env(safe-area-inset-right) calc(6px + env(safe-area-inset-bottom)) env(safe-area-inset-left); }
  .bottom-nav button { min-height: 50px; border: 0; background: transparent; color: #aebfd1; font-size: 9px; font-weight: 700; }
  .bottom-nav button.active { color: var(--lime); background: #19466b; border-radius: 6px; }
}
