:root {
  color-scheme: light;
  --purple: #3d096a;
  --purple-dark: #3b0764;
  --ink: #17132a;
  --muted: #6b667d;
  --line: #e7e3ef;
  --surface: #ffffff;
  --bg: #f6f4f9;
  --green: #0f8f63;
  --red: #b42318;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--ink);
}

body.is-calendar-changing .calendar-week,
body.is-calendar-changing .mini-calendar {
  opacity: .72;
  transition: opacity .12s ease;
}

.hero {
  min-height: 165px;
  background:
    linear-gradient(120deg, rgba(59, 7, 100, .95), rgba(109, 40, 217, .88)),
    radial-gradient(circle at 82% 25%, rgba(255,255,255,.28), transparent 28%);
  color: white;
  padding: 24px clamp(18px, 5vw, 64px) 24px;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  right: -70px;
  bottom: -110px;
  width: 430px;
  height: 220px;
  border: 5px solid rgba(255,255,255,.26);
  border-radius: 50%;
  transform: rotate(-12deg);
}

nav, .section-head, .stats, .settings {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

nav { position: relative; z-index: 1; }
.top-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
  position: absolute;
  right: clamp(18px, 5vw, 64px);
  bottom: 34px;
  z-index: 2;
}

.mobile-menu-toggle {
  display: none;
}

.mobile-menu-backdrop {
  display: none;
}

.top-actions a,
.main-menu a {
  color: white;
  text-decoration: none;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  padding: 8px 11px;
  font-weight: 800;
  background: #3d096a;
  border: 1px solid rgba(255,255,255,.28);
}

.top-actions a.active,
.main-menu a.active {
  background: #3d096a;
  color: #ffffff;
  border-color: #3d096a;
}

.profile-pill {
  width: 42px;
  padding: 0;
  border-radius: 999px;
  background: #3d096a;
  color: #ffffff;
}

.logout-button {
  width: auto;
  min-width: 0;
  padding: 8px 11px;
  color: #ffffff;
  background: #3d096a;
  border: 1px solid rgba(255,255,255,.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.header-action-icon {
  width: 23px;
  height: 23px;
  display: block;
}

.logout-icon {
  display: none;
}

.hero section { max-width: 940px; margin-top: 0; position: relative; z-index: 1; padding-right: 230px; }

.hero-title-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.hero-logo-frame {
  height: clamp(76px, 6vw, 100px);
  display: flex;
  align-items: flex-start;
  flex: 0 0 auto;
  max-width: 170px;
  overflow: hidden;
  transform: translateY(10px);
}

.hero-logo {
  width: auto;
  height: 100%;
  max-width: 170px;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-size: .78rem; font-weight: 800; opacity: .82; }
h1 { font-size: clamp(1.8rem, 3.6vw, 3.35rem); line-height: 1.04; margin: 8px 0 0; letter-spacing: 0; }
h2 { margin: 0 0 18px; font-size: 1.2rem; }
h3 { margin: 0 0 12px; font-size: 1rem; }
p { line-height: 1.55; }

.shell {
  width: min(1220px, calc(100% - 32px));
  margin: 18px auto 56px;
  position: relative;
}

.main-menu-wrap {
  width: 100%;
  margin: 0;
  position: relative;
  z-index: 3;
  background: #ffffff;
  border-bottom: 1px solid var(--line);
  box-shadow: 0 10px 26px rgba(41, 27, 71, .08);
}

.main-menu {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  padding: 10px 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.main-menu a {
  gap: 7px;
  min-height: 36px;
  padding: 7px 10px;
  color: var(--ink);
  background: transparent;
  border-color: transparent;
  font-size: .86rem;
  font-weight: 850;
}

.main-menu a:hover {
  color: #3d096a;
  background: #f4efff;
  border-color: #eadff8;
}

.main-menu a.active {
  color: #ffffff;
  background: #3d096a;
  border-color: #3d096a;
}

.main-menu a.needs-attention {
  background: #fff2b8;
  border-color: #e6c84f;
  color: #3d096a;
}

.main-menu a.needs-attention.active {
  background: #3d096a;
  border-color: #e6c84f;
  color: #ffffff;
  box-shadow: inset 0 0 0 2px #f2d766;
}

.nav-icon {
  width: 16px;
  height: 16px;
  display: block;
  flex: 0 0 auto;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
}

.stats article, .panel, .login-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 42px rgba(41, 27, 71, .08);
}

.stats article { padding: 18px; }
.stats span { display: block; font-size: 2rem; font-weight: 850; color: var(--purple); }
.stats p { margin: 4px 0 0; color: var(--muted); }

.grid { display: grid; gap: 18px; margin-bottom: 18px; }
.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.panel { padding: 22px; margin-bottom: 18px; }

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

label { display: grid; gap: 6px; color: var(--muted); font-weight: 700; font-size: .86rem; }
input, select {
  width: 100%;
  min-height: 42px;
  border: 1px solid #d8d2e5;
  border-radius: 7px;
  padding: 9px 10px;
  font: inherit;
  color: var(--ink);
  background: white;
}

.check, .settings label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.check input, .settings input[type="checkbox"] { width: auto; min-height: auto; }
button {
  border: 0;
  border-radius: 7px;
  min-height: 42px;
  padding: 9px 14px;
  background: #3d096a;
  color: white;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.danger {
  background: #ffffff;
  border: 1px solid var(--red);
  color: var(--red);
}

.danger:hover {
  background: #fff0ee;
}

.edit-toggle {
  background: #ffffff;
  border: 1px solid #071225;
  color: #000000;
}

.icon-button {
  width: 42px;
  min-width: 42px;
  padding: 0;
  font-size: 1.05rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.icon-svg {
  width: 18px;
  height: 18px;
  display: block;
}

.icon-edit {
  width: 22px;
  height: 22px;
}

.small {
  min-height: 34px;
  min-width: 34px;
  width: 34px;
  padding: 0;
  font-size: .82rem;
}

.tiny {
  min-width: 28px;
  width: 28px;
  min-height: 28px;
  padding: 0;
  line-height: 1;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-radius: 7px;
  padding: 9px 14px;
  color: white;
  text-decoration: none;
  font-weight: 800;
}

.button-link.disabled {
  color: #8b849b;
  background: #e8e4ef;
  cursor: not-allowed;
}

.secondary { background: #3d096a; }
.ghost { background: #3d096a; border: 1px solid rgba(255,255,255,.35); }
.muted { color: var(--muted); margin-top: -8px; }
.alert { border-radius: 7px; padding: 12px 14px; font-weight: 750; }
.success { background: #e8fff5; color: var(--green); border: 1px solid #b9efd8; }
.error { background: #fff0ee; color: var(--red); border: 1px solid #f4c3bd; }

.bulk-save-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.bulk-save-button:disabled {
  background: #e8e4ef;
  color: #8b849b;
  cursor: not-allowed;
}

.settings {
  justify-content: flex-start;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
  margin: 0;
}

.calendar-toolbar {
  display: grid;
  gap: 10px;
}

.calendar-admin {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.inline-form {
  display: flex;
  align-items: end;
  gap: 10px;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fbfaff;
}

.compact-inline {
  min-height: 0;
  padding: 10px 12px;
}

.week-actions {
  align-items: end;
  justify-content: flex-start;
}

.main-week-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  justify-self: center;
}

.main-week-actions .button-link {
  min-height: 34px;
  padding: 7px 12px;
  font-size: .82rem;
}

.main-week-actions .week-icon-button {
  width: 42px;
  min-width: 42px;
  padding-inline: 0;
}

.main-week-actions .week-icon-button .icon-svg {
  width: 20px;
  height: 20px;
}

.week-actions form {
  margin: 0;
}

.auto-plan-form,
.filter-form {
  display: flex;
  align-items: end;
  gap: 8px;
  flex-wrap: wrap;
}

.auto-plan-form label,
.filter-form label {
  min-width: 150px;
}

.auto-plan-form input {
  width: 120px;
}

.team-limit-picker {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.team-limit-picker[hidden] {
  display: none;
}

.team-limit-picker label {
  min-width: 0;
  border-radius: 8px;
  padding: 8px;
}

.team-limit-picker select {
  width: 100%;
}

.team-limit-picker label.highlight-league {
  background: #fff6cf;
  border: 1px solid #f0d982;
}

.stacked-filter {
  padding: 10px;
  margin-bottom: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfaff;
}

.compact-inline label {
  min-width: 170px;
}

.export-actions {
  justify-content: flex-start;
}

.export-team-filter {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px 12px;
  background: #ffffff;
}

.export-team-filter legend {
  padding: 0 6px;
  color: var(--muted);
  font-weight: 900;
}

.export-team-filter div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
}

.export-team-filter label {
  min-width: auto;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
}

.mini-calendar {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fbfaff;
  margin-bottom: 16px;
}

.mini-calendar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.mini-calendar-head a {
  color: var(--purple);
  text-decoration: none;
  font-size: 1.35rem;
  font-weight: 900;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
}

.mini-disabled {
  color: #aaa2b8;
  font-size: 1.35rem;
  font-weight: 900;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.mini-calendar-head a:hover {
  background: #eee7ff;
}

.mini-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.mini-calendar-grid a,
.mini-weekday,
.mini-outside {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font-size: .82rem;
  font-weight: 800;
}

.mini-calendar-grid a {
  color: var(--ink);
  text-decoration: none;
  background: white;
  border: 1px solid var(--line);
}

.mini-calendar-grid a:hover,
.mini-calendar-grid a.today {
  color: white;
  background: var(--purple);
  border-color: var(--purple);
}

.mini-calendar-grid a.has-matchday {
  color: #ffffff;
  background: #3d096a;
  border-color: #3d096a;
}

.mini-calendar-grid a.has-matchday.today {
  background: #3d096a;
  border-color: #3d096a;
}

.mini-weekday,
.mini-calendar-grid a.muted-day,
.mini-outside {
  color: var(--muted);
  background: transparent;
  border-color: transparent;
}

.mini-outside {
  opacity: .38;
}

.profile-panel {
  max-width: 760px;
}

.pending-card {
  text-align: center;
}

.pending-user-row {
  background: #fff9dd;
  border-color: #ecd56b;
}

.form-divider {
  grid-column: 1 / -1;
  margin-top: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--purple-dark);
  font-weight: 900;
}

.settings input[type="time"], .settings select { width: 110px; }
.planner { display: grid; grid-template-columns: 300px 1fr; gap: 18px; align-items: start; }
aside { border-right: 1px solid var(--line); padding-right: 18px; }
.actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.todo, .event, .list p, .list-row {
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 12px;
  margin-bottom: 10px;
  background: #fbfaff;
}
.todo {
  cursor: grab;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  border-left: 5px solid var(--accent);
}
.todo span, .event span { display: block; margin-top: 5px; color: var(--muted); font-size: .88rem; }
.list-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.admin-row {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fbfaff;
}

.admin-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.admin-summary p {
  margin: 0;
}

.single-line-summary {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.block-summary {
  min-width: 0;
}

.block-summary span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: .9rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.row-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.edit-panel {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.block-dropdown {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.list-row p {
  border: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  box-shadow: none;
}

.color-dot {
  width: 11px;
  height: 11px;
  border-radius: 999px;
  display: inline-block;
  margin-right: 8px;
  vertical-align: -1px;
  box-shadow: 0 0 0 2px rgba(255,255,255,.9), 0 0 0 3px var(--line);
}

.compact-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 10px;
}

.edit-list {
  display: grid;
  gap: 12px;
}

.team-edit-list {
  gap: 8px;
}

.team-list-header {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 0 12px 2px;
  color: var(--muted);
  font-weight: 900;
}

.team-header-fields,
.team-row-form {
  display: grid;
  grid-template-columns: minmax(160px, 1.1fr) minmax(120px, 1fr) minmax(150px, 1fr) minmax(110px, 1fr);
  gap: 10px;
  align-items: center;
}

.team-list-header > span {
  min-width: 96px;
  text-align: center;
}

.log-list {
  display: grid;
  gap: 8px;
}

.log-row {
  display: grid;
  grid-template-columns: minmax(150px, .8fr) minmax(220px, 1.5fr) 150px;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fbfaff;
}

.log-row span,
.log-row time {
  color: var(--muted);
}

.log-row time {
  text-align: right;
  font-weight: 800;
}

.edit-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fbfaff;
}

.matchday-edit-row.has-venue {
  background: #eefaf2;
  border-color: #bde8c8;
}

.team-edit-list .edit-row {
  padding: 8px 12px;
}

.team-draggable-row {
  cursor: grab;
}

.team-draggable-row:active {
  cursor: grabbing;
}

.team-draggable-row.is-dragging-team {
  opacity: .55;
  border-color: var(--purple);
  box-shadow: 0 10px 24px rgba(109, 40, 217, .16);
}

.team-draggable-row.is-drop-target {
  border-top-color: var(--purple);
  border-top-width: 3px;
}

.team-drag-handle {
  cursor: grab;
}

.team-drag-handle:active {
  cursor: grabbing;
}

.row-form,
.matchday-edit-form {
  display: grid;
  gap: 10px;
  align-items: end;
}

.row-form {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.team-row-form {
  grid-template-columns: minmax(160px, 1.1fr) minmax(120px, 1fr) minmax(150px, 1fr) minmax(110px, 1fr);
}

.matchday-edit-form {
  grid-template-columns: repeat(auto-fit, minmax(135px, 1fr));
}

.team-count {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 5px 10px;
  background: #ffffff;
  display: grid;
  align-content: center;
  gap: 1px;
  text-decoration: none;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.team-count:hover,
.team-count.active {
  border-color: var(--purple);
  box-shadow: 0 8px 18px rgba(109, 40, 217, .12);
  transform: translateY(-1px);
}

.team-count strong {
  color: var(--purple);
  font-size: 1.05rem;
  line-height: 1;
}

.calendar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}

.calendar-week {
  display: grid;
  grid-template-columns: 1fr;
}

.venue-column {
  min-height: 250px;
  border: 1px dashed #c8bdd9;
  border-radius: 8px;
  padding: 13px;
  background: linear-gradient(#fff, #faf8ff);
}

.venue-column h3 {
  border-left: 5px solid var(--purple);
  padding-left: 10px;
}

.venue-column.is-hover { outline: 3px solid rgba(109, 40, 217, .18); }
.slot.is-hover { background: #f0e9ff; outline: 2px solid rgba(109, 40, 217, .3); outline-offset: -2px; }
.drop-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  margin-bottom: 12px;
}

.event {
  border-left: 5px solid var(--accent);
  background: color-mix(in srgb, var(--accent) 14%, white);
}

.calendar-venue {
  overflow-x: auto;
}

.venue-calendar-head {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) auto minmax(120px, 1fr);
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.venue-calendar-head::after {
  content: "";
}

.venue-calendar-head h3 {
  margin-bottom: 0;
}

.week-grid {
  display: grid;
  grid-template-columns: 76px repeat(var(--days), minmax(145px, 1fr));
  grid-auto-rows: minmax(58px, auto);
  min-width: calc(76px + var(--days) * 145px);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: white;
}

.time-head,
.day-head,
.time-cell,
.slot {
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.time-head,
.day-head {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #f3effb;
}

.day-head {
  min-height: 54px;
  padding: 9px 10px;
}

.day-head strong,
.day-head span {
  display: block;
}

.day-head span {
  color: var(--muted);
  font-size: .86rem;
  margin-top: 2px;
}

.time-cell {
  min-height: 58px;
  padding: 9px 8px;
  background: #faf8ff;
  color: var(--muted);
  font-weight: 800;
  font-size: .82rem;
}

.slot {
  min-height: 58px;
  padding: 5px;
  background: #fff;
  transition: background .14s ease, outline .14s ease;
  position: relative;
}

.slot.is-blocked {
  background: repeating-linear-gradient(
    -45deg,
    #fff3f0,
    #fff3f0 8px,
    #ffe3df 8px,
    #ffe3df 16px
  );
}

.slot.has-event {
  background: color-mix(in srgb, var(--accent) 8%, white);
  padding: 4px;
  z-index: 2;
}

.slot.is-covered {
  background: transparent;
  z-index: 1;
}

.slot.is-covered-block {
  background: transparent;
  z-index: 1;
}

.slot.block-span {
  z-index: 2;
}

body.is-dragging-calendar-event .slot.is-covered {
  z-index: 4;
}

.event.compact {
  min-height: 100%;
  height: 100%;
  margin: 0;
  padding: 8px;
  font-size: .84rem;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 6px;
}

.movable-event {
  cursor: grab;
}

.event-actions {
  display: inline-flex;
  gap: 5px;
  align-items: flex-start;
}

.event-actions form {
  margin: 0;
}

.event.compact span {
  font-size: .76rem;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(23, 19, 42, .46);
}

.modal-backdrop[hidden] {
  display: none;
}

.modal-box {
  width: min(760px, 100%);
  max-height: calc(100vh - 36px);
  overflow: auto;
  background: white;
  border-radius: 8px;
  border: 1px solid var(--line);
  box-shadow: 0 28px 80px rgba(23, 19, 42, .28);
  padding: 20px;
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.modal-head h2 {
  margin: 0;
}

.modal-close {
  background: #3d096a;
}

.event-edit-button {
  background: #ffffff;
  border: 1px solid #071225;
  color: #000000;
}

.save-icon-button {
  background: #ffffff;
  border: 1px solid #071225;
  color: #000000;
}

.order-button {
  background: #ffffff;
  border: 1px solid var(--line);
  color: #25133f;
}

.icon-save {
  width: 20px;
  height: 20px;
}

.row-actions form {
  margin: 0;
}

.blocked-label {
  display: block;
  color: var(--red);
  font-size: .78rem;
  font-weight: 800;
  line-height: 1.25;
}

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #3b0764, #7c3aed);
}

.login-card { width: min(430px, calc(100% - 28px)); padding: 28px; }
.login-card h1 { font-size: 2.1rem; color: var(--purple-dark); }
.stack { display: grid; gap: 14px; }

.register-toggle {
  display: inline-block;
  margin-top: 24px;
  color: var(--purple-dark);
  font-weight: 400;
  text-decoration: none;
}

.register-form {
  margin-top: 6px;
}

.register-form.is-hidden {
  display: none;
}

@media (max-width: 850px) {
  .two, .planner { grid-template-columns: 1fr; }
  .edit-row, .row-form, .matchday-edit-form, .log-row, .team-row-form { grid-template-columns: 1fr; }
  .team-list-header { display: none; }
  .log-row time { text-align: left; }
  aside { border-right: 0; border-bottom: 1px solid var(--line); padding: 0 0 18px; }
  .form-grid, .drop-form { grid-template-columns: 1fr; }
  nav { align-items: flex-start; }
  .top-actions {
    position: absolute;
    right: 16px;
    bottom: 14px;
    justify-content: flex-end;
    margin-top: 0;
  }
  .mobile-menu-toggle {
    position: absolute;
    left: 16px;
    bottom: 14px;
    z-index: 4;
    width: 46px;
    min-width: 46px;
    min-height: 42px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #000000;
    background: #ffffff;
    border: 1px solid rgba(255,255,255,.55);
    box-shadow: 0 10px 22px rgba(23, 19, 42, .18);
  }
  .logout-button {
    min-width: 42px;
    width: 42px;
    height: 42px;
    padding: 0;
    color: #ffffff;
    background: #3d096a;
    border: 1px solid rgba(255,255,255,.35);
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .logout-text {
    display: none;
  }
  .logout-icon {
    display: block;
    width: 24px;
    height: 24px;
  }
  .mobile-menu-backdrop {
    position: fixed;
    inset: 0;
    z-index: 15;
    display: block;
    background: rgba(23, 19, 42, .42);
  }
  .mobile-menu-backdrop[hidden] {
    display: none;
  }
  .main-menu-wrap {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 16;
    width: min(320px, 86vw);
    height: 100vh;
    margin-top: 0;
    padding: 22px 16px;
    background: #ffffff;
    border-right: 1px solid var(--line);
    border-bottom: 0;
    box-shadow: 18px 0 42px rgba(23, 19, 42, .22);
    transform: translateX(-105%);
    transition: transform .22s ease;
  }
  body.mobile-menu-open .main-menu-wrap {
    transform: translateX(0);
  }
  body.mobile-menu-open {
    overflow: hidden;
  }
  .main-menu {
    width: 100%;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 8px;
  }
  .main-menu a {
    min-height: 44px;
    justify-content: flex-start;
    padding: 10px 12px;
    border-color: var(--line);
    background: #fbfaff;
  }
  .main-menu a.active {
    background: #3d096a;
    border-color: #3d096a;
  }
  .hero section { padding: 0 70px 54px 0; }
  .hero-title-row { align-items: center; gap: 12px; }
  .hero-logo-frame { height: 76px; max-width: 110px; transform: translateY(8px); }
  .hero-logo { max-width: 110px; }
  .hero { min-height: 205px; }
}
