:root {
  --navy: #0b2a4a;
  --navy-deep: #071d34;
  --navy-soft: #163e67;
  --gold: #c9a227;
  --gold-bright: #e0bd55;
  --gold-pale: #f7efd8;
  --white: #ffffff;
  --grey-50: #f4f6f9;
  --grey-100: #e9edf2;
  --grey-200: #d7dee7;
  --ink: #152234;
  --muted: #5b6b7c;
  --danger: #a92a22;
  --danger-soft: #fbeae8;
  --success: #1f6b47;
  --success-soft: #e7f4ec;
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --shadow-sm: 0 2px 8px rgba(9, 30, 52, 0.06);
  --shadow: 0 12px 32px rgba(9, 30, 52, 0.1);
  --shadow-lg: 0 22px 50px rgba(7, 29, 52, 0.16);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--grey-50);
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 700;
  line-height: 1.2;
  color: var(--navy);
}

p {
  margin: 0;
}

a {
  color: var(--navy);
}

img {
  max-width: 100%;
  height: auto;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

.container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}

.skip-link {
  position: absolute;
  top: -60px;
  left: 16px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--navy);
  color: var(--white);
  border-radius: 0 0 8px 8px;
  text-decoration: none;
}

.skip-link:focus {
  top: 0;
}

/* --------------------------------------------------------------------------
   Header and hero
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--white);
  border-bottom: 1px solid var(--grey-200);
  box-shadow: 0 2px 10px rgba(9, 30, 52, 0.04);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 78px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  text-decoration: none;
}

.brand-logo {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--gold);
  background: var(--white);
  flex: 0 0 auto;
}

.brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.brand-name {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.2;
}

.brand-sub {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  line-height: 1.4;
}

.header-tag {
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
  background: var(--gold-pale);
  border: 1px solid rgba(201, 162, 39, 0.35);
  border-radius: 999px;
  padding: 8px 14px;
}

.hero {
  position: relative;
  isolation: isolate;
  padding: 78px 0 124px;
  color: var(--white);
  background: var(--navy) url("../images/campus.png") center 42% / cover no-repeat;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(100deg, rgba(7, 29, 52, 0.94) 0%, rgba(9, 40, 70, 0.86) 48%, rgba(9, 40, 70, 0.48) 100%),
    linear-gradient(180deg, rgba(7, 29, 52, 0.15) 0%, rgba(7, 29, 52, 0.45) 100%);
}

.hero-inner {
  max-width: 1080px;
}

.eyebrow {
  margin-bottom: 16px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-bright);
}

.hero h1 {
  max-width: 720px;
  font-size: clamp(32px, 5.5vw, 54px);
  color: var(--white);
  text-wrap: balance;
}

.hero h1 span {
  color: var(--gold-bright);
}

.hero-copy {
  max-width: 560px;
  margin-top: 20px;
  font-size: clamp(16px, 2vw, 19px);
  color: rgba(255, 255, 255, 0.86);
}

/* --------------------------------------------------------------------------
   Public layout and cards
   -------------------------------------------------------------------------- */

.form-section {
  position: relative;
  z-index: 2;
  margin-top: -62px;
  padding-bottom: 64px;
}

.intro-card,
.card,
.state-box,
.success-panel {
  background: var(--white);
  border: 1px solid var(--grey-100);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.intro-card {
  padding: clamp(24px, 4vw, 38px);
  border-top: 4px solid var(--gold);
}

.intro-card h2 {
  margin-bottom: 14px;
  font-size: clamp(24px, 3vw, 30px);
}

.intro-card p {
  max-width: 780px;
  color: #3c4b5c;
}

.intro-card p + p {
  margin-top: 10px;
}

.state-box {
  margin-top: 24px;
  padding: 34px 28px;
  text-align: center;
  color: var(--muted);
}

.state-box h2 {
  margin-bottom: 8px;
  font-size: 24px;
}

.state-box p {
  max-width: 600px;
  margin: 0 auto 18px;
}

.state-error {
  border-top: 4px solid var(--danger);
}

.state-closed {
  border-top: 4px solid var(--gold);
}

.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  margin-right: 8px;
  vertical-align: -3px;
  border: 2px solid var(--grey-200);
  border-top-color: var(--navy);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.poll-form {
  margin-top: 24px;
}

.card {
  padding: clamp(20px, 3.5vw, 32px);
}

.section-heading {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 22px;
}

.section-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--gold-bright);
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
}

.section-heading h2 {
  font-size: clamp(22px, 3vw, 27px);
}

.section-heading p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 14.5px;
}

.children-heading {
  margin-top: 34px;
}

/* Form fields */

.field-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}

.field {
  display: block;
  min-width: 0;
}

.field-label {
  display: block;
  margin-bottom: 7px;
  font-size: 14px;
  font-weight: 700;
  color: var(--navy);
}

.required {
  color: var(--danger);
}

.optional {
  font-weight: 400;
  color: var(--muted);
}

input[type="text"],
input[type="email"],
input[type="password"],
select {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  font-size: 16px;
  color: var(--ink);
  background: var(--white);
  border: 1.5px solid var(--grey-200);
  border-radius: var(--radius-sm);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

input::placeholder {
  color: #8a97a6;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
select:focus {
  border-color: var(--navy-soft);
  box-shadow: 0 0 0 3px rgba(22, 62, 103, 0.14);
}

input.is-invalid,
select.is-invalid {
  border-color: var(--danger);
  background: #fffafa;
}

input.is-invalid:focus,
select.is-invalid:focus {
  box-shadow: 0 0 0 3px rgba(169, 42, 34, 0.15);
}

.field-error {
  margin-top: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--danger);
}

.field-hint {
  margin: -2px 0 12px;
  font-size: 13.5px;
  color: var(--muted);
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 11px 20px;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  border: 1.5px solid transparent;
  border-radius: 999px;
  transition: transform 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.btn:focus-visible,
.remove-child:focus-visible,
a:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

.btn:active {
  transform: translateY(1px);
}

.btn:disabled {
  cursor: not-allowed;
  opacity: 0.62;
  transform: none;
}

.btn-primary {
  color: var(--navy-deep);
  background: linear-gradient(180deg, var(--gold-bright), var(--gold));
  border-color: var(--gold);
  box-shadow: 0 6px 18px rgba(201, 162, 39, 0.28);
}

.btn-primary:hover:not(:disabled) {
  background: linear-gradient(180deg, #eccd73, #d3ad32);
  box-shadow: 0 8px 22px rgba(201, 162, 39, 0.36);
}

.btn-outline {
  color: var(--navy);
  background: var(--white);
  border-color: var(--grey-200);
}

.btn-outline:hover:not(:disabled) {
  border-color: var(--navy-soft);
  background: var(--grey-50);
}

.btn-ghost {
  color: var(--navy);
  background: transparent;
  border-color: transparent;
}

.btn-ghost:hover:not(:disabled) {
  background: var(--grey-100);
}

.btn-danger {
  color: var(--danger);
  background: var(--white);
  border-color: #e6c2bd;
}

.btn-danger:hover:not(:disabled) {
  background: var(--danger-soft);
}

.btn-lg {
  min-height: 54px;
  padding: 15px 28px;
  font-size: 16px;
}

.btn-sm {
  min-height: 38px;
  padding: 8px 14px;
  font-size: 13px;
}

.btn .btn-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(7, 29, 52, 0.3);
  border-top-color: var(--navy-deep);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* Child cards */

.children-list {
  display: grid;
  gap: 22px;
}

.child-card {
  position: relative;
  border-top: 3px solid var(--navy);
}

.child-card.is-invalid {
  border-color: var(--danger);
}

.child-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--grey-100);
}

.child-head h3 {
  font-size: 23px;
}

.remove-child {
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 700;
  color: var(--danger);
  background: transparent;
  border: 0;
  border-radius: 6px;
}

.remove-child:hover {
  background: var(--danger-soft);
}

.sports-fieldset,
.days-fieldset {
  margin: 22px 0 0;
  padding: 0;
  border: 0;
}

.sports-fieldset legend,
.days-fieldset legend {
  padding: 0;
  margin-bottom: 7px;
  font-size: 14px;
  font-weight: 700;
  color: var(--navy);
}

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

.sports-placeholder {
  grid-column: 1 / -1;
  padding: 16px;
  font-size: 14px;
  color: var(--muted);
  background: var(--grey-50);
  border: 1px dashed var(--grey-200);
  border-radius: var(--radius-sm);
}

.sport-option {
  position: relative;
  display: block;
}

.sport-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.sport-option span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 52px;
  padding: 12px 14px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--navy);
  background: var(--white);
  border: 1.5px solid var(--grey-200);
  border-radius: var(--radius-sm);
  cursor: pointer;
  user-select: none;
  transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.sport-option span::after {
  content: "";
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  border: 1.5px solid var(--grey-200);
  border-radius: 5px;
  background: var(--white);
}

.sport-option span:hover {
  border-color: var(--navy-soft);
}

.sport-option input:checked + span {
  color: var(--white);
  background: var(--navy);
  border-color: var(--navy);
  box-shadow: 0 4px 12px rgba(11, 42, 74, 0.18);
}

.sport-option input:checked + span::after {
  content: "\2713";
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--navy);
  background: var(--gold-bright);
  border-color: var(--gold-bright);
}

.sport-option input:focus-visible + span {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

.sport-option input:disabled + span {
  cursor: not-allowed;
  opacity: 0.45;
  background: var(--grey-50);
  border-color: var(--grey-200);
  box-shadow: none;
}

.sport-option input:disabled:checked + span {
  opacity: 0.78;
  background: var(--navy);
}

.sports-message {
  min-height: 20px;
  margin-top: 9px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}

.sports-message.is-warning {
  color: var(--gold);
}

.sports-message.is-error {
  color: var(--danger);
}

.days-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.day-option {
  position: relative;
  display: inline-block;
}

.day-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.day-option span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 9px 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy);
  background: var(--white);
  border: 1.5px solid var(--grey-200);
  border-radius: 999px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.day-option input:checked + span {
  color: var(--navy-deep);
  background: var(--gold-pale);
  border-color: var(--gold);
}

.day-option input:focus-visible + span {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

.day-option span:hover {
  border-color: var(--gold);
}

.card-error {
  margin-top: 16px;
  padding: 12px 14px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--danger);
  background: var(--danger-soft);
  border-radius: var(--radius-sm);
}

.add-child-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 20px;
}

.add-child-row .hint {
  font-size: 13px;
  color: var(--muted);
}

.submit-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 28px;
  padding: clamp(22px, 4vw, 34px);
  color: rgba(255, 255, 255, 0.8);
  background:
    radial-gradient(circle at 100% 0%, rgba(201, 162, 39, 0.18), transparent 48%),
    var(--navy);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.submit-card h2 {
  margin-bottom: 4px;
  color: var(--white);
  font-size: 24px;
}

.submit-card p {
  font-size: 14px;
}

.submit-card .btn {
  align-self: flex-start;
}

.form-alert {
  margin-top: 18px;
  padding: 14px 18px;
  font-size: 14px;
  font-weight: 600;
  color: var(--danger);
  background: var(--danger-soft);
  border: 1px solid #eccfca;
  border-radius: var(--radius-sm);
}

/* Success */

.success-panel {
  margin-top: 24px;
  padding: clamp(36px, 7vw, 64px) 24px;
  text-align: center;
  border-top: 4px solid var(--gold);
}

.success-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  margin-bottom: 20px;
  color: var(--navy);
  background: var(--gold-pale);
  border: 2px solid var(--gold);
  border-radius: 50%;
}

.success-panel h2 {
  font-size: clamp(28px, 4vw, 36px);
}

.success-lead {
  margin-top: 12px;
  font-size: 18px;
  font-weight: 600;
  color: var(--navy);
}

.success-panel p:not(.success-lead) {
  margin-top: 8px;
  color: var(--muted);
}

/* Footer */

.site-footer {
  padding: 30px 0;
  color: rgba(255, 255, 255, 0.7);
  background: var(--navy-deep);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-brand img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.footer-brand div {
  display: flex;
  flex-direction: column;
}

.footer-brand strong {
  color: var(--white);
  font-family: var(--serif);
  font-size: 15px;
}

.footer-brand span,
.footer-links {
  font-size: 12.5px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.footer-links a {
  color: var(--gold-bright);
  text-decoration: none;
  font-weight: 600;
}

.footer-links a:hover {
  text-decoration: underline;
}

/* --------------------------------------------------------------------------
   Admin
   -------------------------------------------------------------------------- */

.admin-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 8% 0%, rgba(201, 162, 39, 0.08), transparent 34%),
    var(--grey-50);
}

.admin-header {
  color: var(--white);
  background: var(--navy);
  border-bottom: 3px solid var(--gold);
}

.admin-header .header-inner {
  min-height: 74px;
}

.admin-header .brand-name {
  color: var(--white);
  font-size: 17px;
}

.admin-header .brand-sub {
  color: var(--gold-bright);
}

.admin-header .brand-logo {
  border-color: var(--gold);
}

.admin-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.admin-header .btn-outline {
  color: var(--white);
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.3);
}

.admin-header .btn-outline:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.5);
}

.admin-main {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 32px 20px 64px;
}

/* Login */

.login-view {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 77px);
  padding: 40px 20px 80px;
}

.login-card {
  width: 100%;
  max-width: 430px;
  padding: 36px 32px;
  background: var(--white);
  border: 1px solid var(--grey-100);
  border-top: 4px solid var(--gold);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.login-logo {
  display: block;
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  border: 2px solid var(--gold);
  border-radius: 50%;
}

.login-card h1 {
  text-align: center;
  font-size: 27px;
}

.login-card > p {
  margin: 8px 0 26px;
  text-align: center;
  font-size: 14px;
  color: var(--muted);
}

.login-card .btn {
  width: 100%;
  margin-top: 8px;
}

.login-error {
  margin-top: 16px;
  padding: 11px 14px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--danger);
  background: var(--danger-soft);
  border-radius: var(--radius-sm);
}

.login-note {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--grey-100);
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
  color: var(--muted);
}

/* Dashboard */

.dashboard-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.dashboard-head h1 {
  font-size: clamp(27px, 4vw, 36px);
}

.dashboard-head p {
  margin-top: 4px;
  font-size: 14px;
  color: var(--muted);
}

.poll-control {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--white);
  border: 1px solid var(--grey-100);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 999px;
}

.status-pill::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.status-open {
  color: var(--success);
  background: var(--success-soft);
}

.status-closed {
  color: var(--danger);
  background: var(--danger-soft);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  position: relative;
  overflow: hidden;
  padding: 20px 22px;
  background: var(--white);
  border: 1px solid var(--grey-100);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.stat-card::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, transparent 50%, rgba(201, 162, 39, 0.12) 50%);
}

.stat-label {
  display: block;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.stat-value {
  display: block;
  margin-top: 6px;
  font-family: var(--serif);
  font-size: 36px;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.1;
}

.admin-card {
  margin-bottom: 24px;
  background: var(--white);
  border: 1px solid var(--grey-100);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.admin-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--grey-100);
}

.admin-card-head h2 {
  font-size: 21px;
}

.admin-card-body {
  padding: 22px 24px 26px;
}

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

.filters-grid .field-label {
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.filters-grid input,
.filters-grid select {
  min-height: 44px;
  padding: 9px 12px;
  font-size: 14px;
}

.filters-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
}

.filters-summary {
  font-size: 13px;
  color: var(--muted);
}

.table-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.row-count {
  display: inline-block;
  margin-left: 8px;
  padding: 3px 9px;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 700;
  color: var(--navy);
  background: var(--grey-100);
  border-radius: 999px;
  vertical-align: 2px;
}

.table-scroll {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.responses-table {
  width: 100%;
  min-width: 1080px;
  border-collapse: collapse;
  font-size: 13.5px;
}

.responses-table th,
.responses-table td {
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--grey-100);
}

.responses-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--muted);
  background: var(--grey-50);
  border-bottom: 1px solid var(--grey-200);
}

.responses-table tbody tr:hover {
  background: #fbfcfe;
}

.responses-table tbody tr:last-child td {
  border-bottom: 0;
}

.cell-id {
  font-family: "Consolas", "Courier New", monospace;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  color: var(--navy);
}

.cell-email {
  word-break: break-word;
  min-width: 170px;
}

.cell-name {
  min-width: 140px;
}

.stage-badge {
  display: inline-block;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  color: var(--navy);
  background: var(--gold-pale);
  border-radius: 999px;
}

.table-empty {
  padding: 48px 24px;
  text-align: center;
  color: var(--muted);
}

.table-empty strong {
  display: block;
  margin-bottom: 4px;
  font-family: var(--serif);
  font-size: 20px;
  color: var(--navy);
}

.table-loading {
  padding: 34px;
  text-align: center;
  color: var(--muted);
}

/* Sports summary */

.summary-intro {
  margin-bottom: 18px;
  font-size: 13.5px;
  color: var(--muted);
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
}

.summary-group {
  padding: 18px;
  background: var(--grey-50);
  border: 1px solid var(--grey-100);
  border-radius: 14px;
}

.summary-group h3 {
  font-size: 17px;
  margin-bottom: 2px;
}

.summary-group .summary-stage-count {
  margin-bottom: 14px;
  font-size: 12px;
  color: var(--muted);
}

.summary-row {
  display: grid;
  grid-template-columns: 1fr 38px;
  align-items: center;
  gap: 10px;
  margin-bottom: 9px;
  font-size: 13px;
}

.summary-row:last-child {
  margin-bottom: 0;
}

.summary-label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.summary-bar-track {
  width: 100%;
  height: 6px;
  overflow: hidden;
  background: var(--grey-200);
  border-radius: 999px;
}

.summary-bar {
  height: 100%;
  min-width: 0;
  background: linear-gradient(90deg, var(--gold), var(--gold-bright));
  border-radius: 999px;
  transition: width 0.3s ease;
}

.summary-count {
  text-align: right;
  font-weight: 700;
  color: var(--navy);
}

.summary-empty {
  font-size: 13px;
  color: var(--muted);
}

/* Toast */

.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 100;
  max-width: calc(100vw - 40px);
  padding: 13px 18px;
  font-size: 14px;
  font-weight: 600;
  color: var(--white);
  background: var(--navy);
  border-left: 4px solid var(--gold);
  border-radius: 10px;
  box-shadow: var(--shadow-lg);
}

.toast.is-error {
  border-left-color: #e2685f;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (min-width: 700px) {
  .field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .submit-card {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .submit-card .btn {
    flex: 0 0 auto;
  }
}

@media (max-width: 620px) {
  .header-inner {
    min-height: 68px;
  }

  .brand-logo {
    width: 44px;
    height: 44px;
  }

  .brand-name {
    font-size: 15px;
  }

  .brand-sub {
    font-size: 10px;
  }

  .header-tag {
    display: none;
  }

  .hero {
    padding: 54px 0 106px;
  }

  .form-section {
    margin-top: -54px;
  }

  .card,
  .intro-card {
    padding: 20px 18px;
  }

  .section-number {
    width: 32px;
    height: 32px;
    font-size: 16px;
  }

  .sports-grid {
    grid-template-columns: 1fr;
  }

  .add-child-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-main {
    padding: 24px 14px 50px;
  }

  .admin-card-head,
  .admin-card-body {
    padding-left: 16px;
    padding-right: 16px;
  }

  .dashboard-head {
    flex-direction: column;
  }

  .poll-control {
    width: 100%;
    justify-content: space-between;
  }

  .login-card {
    padding: 28px 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
