:root {
  color-scheme: light;
  --bg: #edf0e8;
  --page: #edf0e8;
  --panel: #ffffff;
  --ink: #393d3a;
  --muted: #5f6360;
  --line: #d5dbd0;
  --club-blue: #103c61;
  --club-blue-dark: #103c61;
  --club-blue-soft: #e6eff6;
  --club-yellow: #cdff69;
  --club-yellow-soft: #f1fadf;
  --green: #176a3b;
  --green-dark: #135f2c;
  --green-soft: #e9f3ea;
  --red: #b82105;
  --clay: var(--club-blue);
  --clay-soft: var(--club-blue-soft);
  --sky: var(--club-blue-soft);
  --gold: var(--club-yellow);
  --shadow: 0 18px 50px rgba(16, 60, 97, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--page);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(16px, 4vw, 36px);
  background: #ffffffeb;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  box-shadow: none;
  backdrop-filter: blur(16px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 220px;
}

.brand-mark {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background:
    linear-gradient(90deg, transparent 47%, rgba(255, 255, 255, 0.65) 47% 53%, transparent 53%),
    linear-gradient(0deg, transparent 47%, rgba(255, 255, 255, 0.65) 47% 53%, transparent 53%),
    var(--club-blue-dark);
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.55);
}

.brand-mark span {
  width: 19px;
  height: 19px;
  border-radius: 50%;
  background: var(--club-yellow);
  border: 2px solid rgba(21, 32, 23, 0.2);
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--club-blue-dark);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}


.season-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  margin-left: 8px;
  padding: 2px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--club-yellow-soft);
  color: var(--club-blue-dark);
  font-size: 0.74rem;
  font-weight: 900;
  vertical-align: middle;
}
.version-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  margin-left: 8px;
  padding: 2px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--club-blue-soft);
  color: var(--club-blue-dark);
  font-size: 0.74rem;
  font-weight: 900;
  vertical-align: middle;
}

h1 {
  margin-bottom: 0;
  color: var(--club-blue);
  font-size: clamp(1.45rem, 3vw, 2.15rem);
  font-weight: 850;
  line-height: 1.1;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(1.25rem, 2vw, 1.85rem);
}

h3 {
  margin-bottom: 8px;
  font-size: 1.05rem;
}


.test-mode-banner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 5px 8px 5px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--club-yellow-soft);
  color: var(--club-blue-dark);
  font-size: 0.86rem;
  font-weight: 800;
  white-space: nowrap;
}

.test-mode-banner[hidden] {
  display: none;
}

.test-mode-banner .secondary-button {
  min-height: 28px;
  padding: 5px 8px;
  font-size: 0.78rem;
}
.tabs,
.segmented,
.form-actions,
.card-actions,
.slot-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tab-button,
.segment,
.secondary-button,
.primary-button,
.icon-button {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  color: var(--ink);
  font-weight: 700;
}

.tab-button,
.segment {
  padding: 0 14px;
}

.tab-button.active,
.segment.active {
  border-color: var(--club-blue-dark);
  background: var(--club-blue-dark);
  color: #fff;
}


.header-online {
  display: grid;
  gap: 6px;
  min-width: min(100%, 430px);
  max-width: 520px;
  padding-left: 4px;
}

.online-status,
.header-online .online-hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.25;
}

.online-status {
  color: var(--club-blue-dark);
  font-weight: 850;
}

.header-auth-row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(100px, 0.9fr) auto auto auto;
  gap: 6px;
  align-items: center;
}

.header-auth-row input {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 10px;
  background: #fff;
  color: var(--ink);
}

.header-auth-row .primary-button,
.header-auth-row .secondary-button {
  min-height: 40px;
  padding: 0 10px;
  white-space: nowrap;
}
main {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 48px;
}

.hero-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  min-height: 0;
  padding: 16px 18px;
  margin-bottom: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #ffffffeb;
  box-shadow: var(--shadow);
}

.hero-band .eyebrow {
  color: var(--club-blue-dark);
}

.hero-band h2 {
  margin-bottom: 0;
  font-size: clamp(1.25rem, 2vw, 1.85rem);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(86px, 1fr));
  gap: 10px;
}

.stat {
  min-width: 86px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--club-yellow-soft);
  border: 1px solid var(--line);
  color: var(--club-blue-dark);
}

.stat strong {
  display: block;
  font-size: 1.32rem;
}

.stat span {
  font-size: 0.78rem;
}

.view {
  display: none;
}

.view.active {
  display: block;
}


.request-browser {
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.request-browser-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.request-browser-heading h2 {
  margin-bottom: 0;
  font-size: 1rem;
}

.request-browser .toolbar {
  margin-bottom: 8px;
}
.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.match-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.match-card,
.form-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 24px rgba(24, 41, 28, 0.06);
}


.own-request-card {
  gap: 10px;
}

.own-request-card .players {
  margin-bottom: 2px;
}
.match-card {
  display: flex;
  flex-direction: column;
  min-height: 280px;
  padding: 18px;
}

.match-card.proposed {
  border-color: rgba(16, 60, 97, 0.22);
  background: #f1f7fc;
}

.match-card.confirmed {
  border-color: rgba(23, 106, 59, 0.48);
  background: #dff4e4;
}

.match-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.85rem;
  margin-bottom: 10px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 8px;
  background: var(--sky);
  color: #23505a;
  font-size: 0.78rem;
  font-weight: 800;
}

.badge.open {
  background: #eef1ec;
  color: var(--muted);
}

.badge.proposed {
  background: var(--clay-soft);
  color: #8c3f25;
}

.badge.confirmed {
  background: #ddf0df;
  color: var(--club-blue-dark);
}

.players {
  margin: 0 0 14px;
  font-size: 1.18rem;
  font-weight: 850;
}

.slot-list {
  display: grid;
  gap: 8px;
  margin: 12px 0 16px;
  padding: 0;
  list-style: none;
}

.slot-item {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  min-height: 44px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfa;
}

.slot-item.confirmed {
  border-color: rgba(35, 122, 69, 0.45);
  background: #edf8ef;
}

.muted,

.empty-state {
  display: grid;
  gap: 8px;
  align-content: center;
  min-height: 126px;
  padding: 18px;
  border: 1px dashed #cfd9c8;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
}

.empty-state strong {
  color: var(--ink);
  font-size: 1rem;
}

.empty-state p {
  margin-bottom: 4px;
}

.empty-state .secondary-button {
  justify-self: start;
}
.empty {
  color: var(--muted);
}

.card-actions {
  margin-top: auto;
}

.primary-button,
.secondary-button {
  padding: 0 16px;
}


.danger-button {
  border-color: #e4b8ad;
  background: #fff1ee;
  color: #8f321f;
}

.danger-button:hover {
  border-color: #c96b55;
  background: #ffe3dd;
}
.primary-button {
  border-color: var(--club-blue-dark);
  background: var(--club-blue-dark);
  color: #fff;
}

.primary-button:hover,
.tab-button.active:hover,
.segment.active:hover {
  background: var(--club-blue);
}

.secondary-button:hover,
.tab-button:not(.active):hover,
.segment:not(.active):hover {
  border-color: var(--club-blue-dark);
}

.form-panel {
  padding: clamp(18px, 3vw, 30px);
}

.form-heading,
.section-heading {
  margin-bottom: 18px;
}

label {
  display: grid;
  gap: 7px;
  margin-bottom: 15px;
  color: #344137;
  font-weight: 750;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 12px 13px;
}

textarea {
  resize: vertical;
}

.slot-fields,
.list-layout,
.data-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.slot-fields {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}


.test-mode-panel {
  grid-column: 1 / -1;
  border-color: rgba(190, 126, 36, 0.3);
  background: linear-gradient(135deg, rgba(255, 248, 232, 0.96), rgba(255, 255, 255, 0.96));
}

.test-mode-panel select {
  border-color: rgba(190, 126, 36, 0.35);
}

.profile-link-admin {
  display: grid;
  gap: 14px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(190, 126, 36, 0.22);
}

.profile-link-list {
  display: grid;
  gap: 10px;
}

.profile-link-row {
  display: grid;
  grid-template-columns: minmax(220px, 0.85fr) minmax(420px, 1.45fr);
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(190, 126, 36, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
}



.profile-link-editor {
  display: grid;
  grid-template-columns: minmax(160px, 0.8fr) minmax(220px, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.profile-link-editor select {
  min-width: 0;
}

.profile-link-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.profile-link-actions .secondary-button {
  min-height: 40px;
  padding: 8px 10px;
  white-space: nowrap;
}
.profile-link-row > span {
  display: grid;
  gap: 2px;
}

.profile-link-row.linked {
  border-color: rgba(34, 122, 92, 0.24);
}

.profile-link-row.suggested {
  border-color: rgba(190, 126, 36, 0.32);
}


.profile-link-row.duplicate {
  border-color: rgba(180, 68, 58, 0.42);
  background: rgba(255, 242, 240, 0.86);
}

.profile-link-row.duplicate .profile-link-editor > small {
  color: #9f2f25;
  font-weight: 800;
}
.profile-link-row.missing {
  opacity: 0.78;
}
.profile-link-row small {
  color: var(--muted);
}
.people-list {
  display: grid;
  gap: 8px;
}

.person-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
}

dialog {
  width: min(680px, calc(100% - 28px));
  border: 0;
  border-radius: 8px;
  padding: 0;
  box-shadow: var(--shadow);
}


.accept-identity {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid rgba(34, 122, 92, 0.22);
  border-radius: 8px;
  background: rgba(234, 247, 241, 0.78);
}

.accept-identity span {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--muted);
  text-transform: uppercase;
}

.accept-identity strong {
  color: var(--ink);
}
dialog::backdrop {
  background: rgba(16, 24, 18, 0.42);
}

.dialog-panel {
  position: relative;
  padding: 24px;
  background: #fff;
}

.icon-button {
  width: 40px;
  padding: 0;
  font-size: 1.35rem;
}

.close-dialog {
  position: absolute;
  top: 12px;
  right: 12px;
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  max-width: min(420px, calc(100% - 36px));
  padding: 12px 14px;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 160ms ease, transform 160ms ease;
  pointer-events: none;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}


.profile-panel {
  display: grid;
  grid-template-columns: auto minmax(300px, 520px);
  gap: 14px;
  align-items: center;
  margin-bottom: 18px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 24px rgba(24, 41, 28, 0.06);
}

.profile-panel h2 {
  margin-bottom: 0;
  font-size: clamp(1.25rem, 2vw, 1.85rem);
}

.profile-panel .eyebrow {
  margin-bottom: 2px;
}

.profile-controls {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 8px;
  align-items: center;
}


.personal-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.9fr);
  gap: 16px;
  align-items: start;
  margin-bottom: 26px;
}

.compact-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.stack-list {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
}

.summary-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 58px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
}


.inline-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.summary-row strong,
.summary-row span {
  display: block;
}

.summary-row span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.86rem;
}

.summary-row p {
  margin: 0;
  color: var(--muted);
}

.confirmed-row {
  border-color: rgba(23, 106, 59, 0.48);
  background: #dff4e4;
}

.inline-heading {
  margin: 4px 0 8px;
}

.summary-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
}

.summary-heading {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.summary-heading strong {
  line-height: 1.25;
}

.summary-heading span,
.summary-note {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.35;
}

.summary-note {
  margin: 0;
}

.action-panel {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}


.summary-panel.confirmed-row {
  border-color: rgba(23, 106, 59, 0.56);
  background: #d8f1df;
}
.summary-panel.action-panel:not(.confirmed-row) {
  border-color: rgba(16, 60, 97, 0.22);
  background: #f1f7fc;
}


.overview-panel {
  border-color: rgba(34, 122, 92, 0.28);
  background: linear-gradient(135deg, rgba(234, 247, 241, 0.96), rgba(255, 255, 255, 0.96));
}

.personal-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.metric-pill {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(34, 122, 92, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
}

.metric-pill strong,
.metric-pill span {
  display: block;
}

.metric-pill strong {
  font-size: 1.25rem;
  line-height: 1.1;
  color: var(--ink);
}

.metric-pill span {
  margin-top: 3px;
  font-size: 0.76rem;
  color: var(--muted);
}
.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.name-chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  max-width: 100%;
  padding: 5px 9px;
  border-radius: 8px;
  background: #f4f7f1;
  border: 1px solid var(--line);
  color: #344137;
  font-size: 0.86rem;
  line-height: 1.2;
}

.file-import-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 40px;
  margin-bottom: 12px;
  padding: 0 16px;
  border: 1px solid var(--club-blue-dark);
  border-radius: 8px;
  background: var(--club-blue-dark);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.file-import-button:hover {
  background: var(--club-blue);
}

.file-import-button input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 980px) {
  .app-header,
  
.toolbar {
    align-items: stretch;
    flex-direction: column;
  }
  .tabs,
  .header-online {
    width: 100%;
    max-width: none;
  }

  .tab-button {
    flex: 1 1 130px;
  }

  .header-auth-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto auto auto;
  }
}

@media (max-width: 820px) {
  .profile-link-row,
  .profile-link-editor {
    grid-template-columns: 1fr;
  }

  .action-panel,
  .hero-band,
  .login-required-content,
  .profile-panel,
  .profile-controls,
  .personal-layout,
  .slot-fields,
  .list-layout,
  .data-layout {
    grid-template-columns: 1fr;
  }

  .hero-stats {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 520px) {
  main {
    width: min(100% - 20px, 1180px);
  }

  .hero-stats {
    grid-template-columns: 1fr;
  }

  .personal-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .mobile-menu-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
  }

  .tabs {
    display: none;
    align-items: stretch;
    flex-direction: column;
    width: 100%;
  }

  .tabs.mobile-open {
    display: flex;
  }

  .segmented,
  .header-auth-row,
  .profile-controls,
  .form-actions,
  .card-actions,
  .slot-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .header-auth-row {
    display: flex;
  }

  .segment,
  .primary-button,
  .secondary-button,
  .header-auth-row input {
    width: 100%;
  }

  .tabs .tab-button,
  .tabs .nav-link-button {
    width: 100%;
    min-height: 36px;
    padding: 0 12px;
    justify-content: center;
    font-size: 0.9rem;
  }
}














.admin-intro-panel,
.admin-layout .test-mode-panel {
  grid-column: 1 / -1;
}

















.danger-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid #f0b4aa;
  border-radius: 8px;
  background: #fff1ef;
  color: #8f2419;
  font-weight: 850;
}

.danger-toggle input {
  width: 18px;
  height: 18px;
  accent-color: #b82105;
}

.warning-note {
  margin: 0;
  padding: 9px 11px;
  border-left: 4px solid #b82105;
  border-radius: 6px;
  background: #fff7f5;
  color: #6b342f;
  font-size: 0.88rem;
}
.locked-identity {
  display: grid;
  gap: 2px;
  min-width: min(100%, 260px);
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f6fbf7;
  color: var(--ink);
}

.locked-identity[hidden] {
  display: none;
}

.locked-identity span,
.locked-identity small {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 750;
}

.locked-identity strong {
  color: var(--club-blue-dark);
  font-size: 0.98rem;
}

.form-locked-identity {
  margin-top: 0;
}
.login-required-panel {
  max-width: 820px;
  margin: 0 auto 24px;
  padding: clamp(18px, 3vw, 28px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.login-required-panel[hidden] {
  display: none;
}

.login-required-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(140px, 190px);
  gap: 18px;
  align-items: center;
}

.login-required-panel h2 {
  margin-bottom: 8px;
  font-size: clamp(1.25rem, 2vw, 1.85rem);
}

.login-required-panel p:last-child {
  margin: 0;
  color: var(--muted);
}

.login-open-stat {
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--club-yellow-soft);
  color: var(--club-blue-dark);
  text-align: center;
}

.login-open-stat strong {
  font-size: 2rem;
  line-height: 1;
}

.login-open-stat span {
  font-size: 0.78rem;
  font-weight: 800;
}

.logged-out-lock .tabs,
.logged-out-lock #view-dashboard .profile-panel,
.logged-out-lock #view-dashboard .personal-layout,
.logged-out-lock #view-dashboard .request-browser,
.logged-out-lock #view-create,
.logged-out-lock #view-players,
.logged-out-lock #view-data,
.logged-out-lock #view-admin {
  display: none;
}

.tab-button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}
.club-logo {
  display: block;
  width: 66px;
  height: 82px;
  object-fit: contain;
}

.hero-stats {
  grid-template-columns: minmax(150px, 210px);
}

.stat-open {
  text-align: center;
}

.stat-open span {
  display: block;
  color: var(--club-blue-dark);
  font-weight: 850;
}
.purpose-panel {
  padding: clamp(18px, 3vw, 28px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.purpose-panel[hidden] {
  display: none;
}

.purpose-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.purpose-card {
  display: grid;
  gap: 7px;
  min-height: 132px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--club-blue-soft);
  color: var(--ink);
  text-align: left;
}

.purpose-card:hover {
  border-color: var(--club-blue-dark);
  background: #fff;
}

.purpose-card strong {
  color: var(--club-blue-dark);
  font-size: 1rem;
}

.purpose-card span {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.35;
}

@media (max-width: 760px) {
  .purpose-grid {
    grid-template-columns: 1fr;
  }
}
#view-create .form-panel,
#view-create .purpose-panel {
  max-width: 820px;
  margin-inline: auto;
}

.fixed-purpose-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 12px;
  align-items: center;
  margin-bottom: 15px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--club-yellow-soft);
}

.fixed-purpose-row span {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 850;
  text-transform: uppercase;
}

.fixed-purpose-row strong {
  color: var(--club-blue-dark);
  font-size: 1rem;
}







.mobile-menu-button {
  display: none;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: var(--club-blue-dark);
  color: #fff;
  font-weight: 850;
}

.nav-link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 14px;
  background: var(--panel);
  color: var(--ink);
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
}
/* final mobile navigation override */
@media (max-width: 520px) {
  .mobile-menu-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
  }

  .tabs {
    display: none;
    align-items: stretch;
    flex-direction: column;
    width: 100%;
  }

  .tabs.mobile-open {
    display: flex;
  }
}

.header-auth-row [hidden] {
  display: none !important;
}
/* unified mobile menu entries */
@media (max-width: 520px) {
  .tabs .tab-button,
  .tabs .nav-link-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 0 12px;
    background: var(--panel);
    color: var(--ink);
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
  }

  .tabs .tab-button.active {
    border-color: var(--club-blue-dark);
    background: var(--club-blue-soft);
    color: var(--club-blue-dark);
  }
}

/* final compact mobile menu */
@media (max-width: 520px) {
  .tabs.mobile-open {
    display: flex;
    align-items: flex-start;
    gap: 6px;
  }

  .tabs .tab-button,
  .tabs .nav-link-button {
    flex: 0 0 auto;
    width: auto;
    min-width: 0;
    min-height: 36px;
    align-self: flex-start;
    padding: 0 12px;
  }

  .tabs [hidden],
  .tabs .tab-button[hidden],
  .tabs .admin-only-tab[hidden],
  .tabs .admin-tab[hidden] {
    display: none !important;
  }
}