/* ==========================================================================
   gaffr — Application-Specific Styles
   Page overrides, legacy compatibility, style guide helpers.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Auth pages — centred card layout
   -------------------------------------------------------------------------- */
.al-auth-card {
  max-width: 420px;
  margin: 2rem auto;
}

/* --------------------------------------------------------------------------
   Style Guide specific — showcase helpers
   -------------------------------------------------------------------------- */
.sg-section {
  padding: 2rem 0;
  border-bottom: 1px solid var(--al-border);
}
.sg-section:last-child {
  border-bottom: none;
}
.sg-title {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 1.25rem;
  color: var(--al-text-bright);
  letter-spacing: -0.02em;
}
.sg-subtitle {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--al-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
  margin-top: 0.5rem;
}
.sg-swatch {
  display: inline-block;
  width: 3.2rem;
  height: 3.2rem;
  border-radius: var(--al-radius);
  border: 1px solid var(--al-border-strong);
  box-shadow: var(--al-shadow-sm);
}
.sg-component-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* --------------------------------------------------------------------------
   Event list item style
   -------------------------------------------------------------------------- */
.al-event-item {
  border-left: 3px solid var(--al-primary) !important;
}
.al-event-item:hover {
  border-left-color: var(--al-secondary) !important;
}

/* --------------------------------------------------------------------------
   MOTM list item
   -------------------------------------------------------------------------- */
.al-motm-item {
  border-left: 3px solid var(--al-secondary) !important;
}

/* --------------------------------------------------------------------------
   Player stat highlights in profile view
   -------------------------------------------------------------------------- */
.al-stat-card {
  background: var(--al-bg-card);
  border: 1px solid var(--al-border);
  border-radius: var(--al-radius);
  padding: 1rem;
  text-align: center;
  transition: border-color var(--al-transition), box-shadow var(--al-transition);
}
.al-stat-card:hover {
  border-color: var(--al-border-accent);
  box-shadow: var(--al-shadow-glow);
}
.al-stat-card__value {
  font-family: var(--al-font-mono);
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--al-text-bright);
  line-height: 1.1;
}
.al-stat-card__label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--al-text-muted);
  margin-top: 0.3rem;
}

/* --------------------------------------------------------------------------
   Match ticker — horizontal scroll
   -------------------------------------------------------------------------- */
.al-ticker {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
}
.al-ticker::-webkit-scrollbar {
  height: 4px;
}
.al-ticker::-webkit-scrollbar-thumb {
  background: var(--al-border-strong);
  border-radius: 2px;
}

/* --------------------------------------------------------------------------
   Badge colour overrides — ensure they work in both modes
   (theme.css defines these too; app.css overrides only if needed)
   -------------------------------------------------------------------------- */

/* --------------------------------------------------------------------------
   Misc overrides
   -------------------------------------------------------------------------- */
.navbar-toggler {
  border-color: var(--al-border-strong);
}
.navbar-toggler-icon {
  filter: invert(0.7);
}
[data-bs-theme="light"] .navbar-toggler-icon {
  filter: none;
}

/* Bootstrap card class override */
.card {
  background: var(--al-bg-card);
  border-color: var(--al-border);
  border-radius: var(--al-radius-lg);
}

/* --------------------------------------------------------------------------
   Homepage — Photo Hero with Block Lettering
   The images are the background; a scrim keeps the white text readable.
   -------------------------------------------------------------------------- */
.al-hero--white {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0B2E14;
  color: #fff;
  padding: 6rem 1rem 4.5rem;
  overflow: hidden;
  min-height: 720px;
  /* Full-bleed */
  width: 100vw;
  margin-left: 50%;
  transform: translateX(-50%);
}
[data-bs-theme="dark"] .al-hero--white {
  background: #0A1128;
}

/* Photo mosaic — runs at full strength, unlike the old 15% white-washed version */
.al-hero-mosaic {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(2, 1fr);
  gap: 3px;
  pointer-events: none;
  z-index: 0;
}
.al-hero-mosaic__item {
  overflow: hidden;
  position: relative;
}
.al-hero-mosaic__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.05);
  will-change: transform;
  animation: heroMosaic 22s ease-in-out infinite alternate;
}
.al-hero-mosaic__item:nth-child(2) img,
.al-hero-mosaic__item:nth-child(5) img {
  animation-duration: 26s;
  animation-delay: -4s;
}
.al-hero-mosaic__item:nth-child(3) img,
.al-hero-mosaic__item:nth-child(6) img {
  animation-duration: 30s;
  animation-delay: -8s;
}
/* Scrim — dark green wash for contrast against the photos */
.al-hero--white::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(180deg,
      rgba(9, 38, 18, 0.70) 0%,
      rgba(9, 38, 18, 0.80) 55%,
      rgba(9, 38, 18, 0.92) 100%
    ),
    radial-gradient(ellipse at 50% 45%, rgba(0,0,0,0.10) 0%, rgba(0,0,0,0.45) 100%);
}
[data-bs-theme="dark"] .al-hero--white::before {
  background:
    linear-gradient(180deg,
      rgba(10, 17, 40, 0.78) 0%,
      rgba(10, 17, 40, 0.86) 55%,
      rgba(10, 17, 40, 0.95) 100%
    ),
    radial-gradient(ellipse at 50% 45%, rgba(0,0,0,0.15) 0%, rgba(0,0,0,0.5) 100%);
}

/* Content layer */
.al-hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}
.al-hero-content::before {
  content: '';
  position: absolute;
  inset: -2rem -3.5rem;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(
    ellipse at 50% 40%,
    rgba(9, 38, 18, 0.82) 0%,
    rgba(9, 38, 18, 0.45) 55%,
    transparent 75%
  );
  border-radius: 50%;
}

/* Block text — massive, bold, uppercase */
.al-hero--white .al-hero-block-text {
  font-family: var(--al-font-heading);
  font-weight: 900;
  font-size: clamp(3rem, 10vw, 6rem);
  line-height: 0.92;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  color: #FFFFFF;
  text-shadow:
    0 1px 0 rgba(0,0,0,0.15),
    0 4px 28px rgba(0,0,0,0.55),
    0 0 48px rgba(0,0,0,0.35);
  margin: 0.5rem 0 1.5rem;
}
.al-hero--white .al-hero-block-text--accent {
  color: #A7F3C2;
  display: inline-block;
  text-shadow:
    0 1px 0 rgba(0,0,0,0.18),
    0 4px 24px rgba(0,0,0,0.5),
    0 0 32px rgba(0,0,0,0.3);
}

/* Eyebrow */
.al-hero-eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #A7F3C2;
  margin-bottom: 0.5rem;
  text-shadow: 0 1px 4px rgba(0,0,0,0.45);
}

/* Sub text */
.al-hero-sub {
  font-size: 1.125rem;
  line-height: 1.55;
  font-weight: 500;
  color: #FFFFFF;
  max-width: 540px;
  margin: 0 auto;
  padding: 0.4rem 0.85rem;
  background: rgba(9, 38, 18, 0.45);
  border-radius: var(--al-radius);
  text-shadow: 0 1px 10px rgba(0,0,0,0.4);
}
.al-hero-sub strong {
  color: #FFFFFF;
  font-weight: 800;
}

/* CTA */
.al-hero-cta {
  font-size: 1rem;
  padding: 0.8rem 2rem;
}

/* Smallprint */
.al-hero-smallprint {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.65);
  margin-top: 1.25rem;
}

/* Discovery search panel */
.al-hero-search {
  display: flex;
  gap: 0.5rem;
  align-items: flex-end;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 620px;
  margin: 2rem auto 0;
  padding: 1rem;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: var(--al-radius-lg);
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  text-align: left;
}
[data-bs-theme="dark"] .al-hero-search {
  background: var(--al-bg-card);
  border-color: var(--al-border);
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}
.al-hero-search__field {
  flex: 1 1 180px;
  min-width: 0;
}
.al-hero-search__field label {
  display: block;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--al-text-muted);
  margin-bottom: 0.3rem;
}
.al-hero-search__field select,
.al-hero-search__field input {
  width: 100%;
  padding: 0.6rem 0.75rem;
  font-size: 0.9rem;
  font-family: inherit;
  border: 1px solid rgba(0,0,0,0.15);
  border-radius: var(--al-radius);
  background: #fff;
  color: #111;
}
[data-bs-theme="dark"] .al-hero-search__field select,
[data-bs-theme="dark"] .al-hero-search__field input {
  background: var(--al-bg-elevated);
  border-color: var(--al-border);
  color: var(--al-text);
}
.al-hero-search__field select:focus,
.al-hero-search__field input:focus {
  outline: none;
  border-color: var(--al-primary);
  box-shadow: 0 0 0 3px var(--al-primary-glow);
}
.al-hero-search__btn {
  flex: 0 0 auto;
  padding: 0.6rem 1.5rem;
  font-weight: 800;
}

/* Audience paths — two clear routes into the product */
.al-hero-paths {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}
.al-hero-path {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  flex: 1 1 220px;
  max-width: 260px;
  padding: 1.1rem 1rem;
  background: #fff;
  border: 2px solid rgba(0,0,0,0.08);
  border-radius: var(--al-radius-lg);
  text-decoration: none;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
[data-bs-theme="dark"] .al-hero-path {
  background: var(--al-bg-card);
  border-color: var(--al-border);
}
.al-hero-path:hover {
  transform: translateY(-3px);
  border-color: var(--al-primary);
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}
.al-hero-path__icon {
  font-size: 1.6rem;
  line-height: 1;
}
.al-hero-path__label {
  font-family: var(--al-font-heading);
  font-weight: 800;
  font-size: 1rem;
  color: var(--al-text-bright);
}
.al-hero-path__sub {
  font-size: 0.75rem;
  color: var(--al-text-muted);
  text-align: center;
}



@keyframes heroMosaic {
  0% { transform: scale(1); }
  100% { transform: scale(1.06); }
}

/* Responsive: hide some mosaic items on mobile */
@media (max-width: 767.98px) {
  .al-hero--white {
    min-height: auto;
    padding: 4rem 0.75rem 3rem;
  }
  .al-hero-content::before {
    inset: -1.5rem -1.5rem;
    background: radial-gradient(
      ellipse at 50% 40%,
      rgba(9, 38, 18, 0.8) 0%,
      rgba(9, 38, 18, 0.5) 60%,
      transparent 80%
    );
  }
  .al-hero-mosaic {
    grid-template-columns: repeat(2, 1fr);
  }
  .al-hero-mosaic__item--5,
  .al-hero-mosaic__item--6 {
    display: none;
  }
  .al-hero-eyebrow {
    font-size: 0.7rem;
  }
  .al-hero--white .al-hero-block-text {
    font-size: clamp(2.25rem, 11vw, 3.5rem);
    line-height: 0.98;
    margin: 0.25rem 0 1rem;
  }
  .al-hero-sub {
    font-size: 1rem;
    max-width: calc(100% - 1rem);
    padding: 0.35rem 0.65rem;
  }
  .al-hero-actions {
    flex-direction: column;
    gap: 0.6rem;
    margin-top: 1.25rem;
  }
  .al-hero-actions .btn {
    width: 100%;
    text-align: center;
  }
  .al-hero-search {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    padding: 0.75rem;
    margin-top: 1.5rem;
  }
  .al-hero-search__field {
    flex: 1 1 100%;
    width: 100%;
  }
  .al-hero-search__btn {
    width: 100%;
    padding: 0.75rem;
  }
  .al-hero-paths {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    margin-top: 1.25rem;
  }
  .al-hero-path {
    width: 100%;
    max-width: none;
    flex: none;
    padding: 1rem;
  }
}

/* --------------------------------------------------------------------------
   Homepage — Sections
   -------------------------------------------------------------------------- */
.al-section {
  padding: 4rem 0;
}
.al-section--alt {
  background: var(--al-surface);
  width: 100vw;
  margin-left: 50%;
  transform: translateX(-50%);
  padding: 4rem 1rem;
}
/* On turf, alternating bands are a translucent white veil rather than solid
   white — keeps the section rhythm without flattening the texture. */
[data-bs-theme="light"] .al-section--alt {
  background: rgba(255,255,255,0.55);
  border-top: 1px solid rgba(255,255,255,0.7);
  border-bottom: 1px solid rgba(0,0,0,0.05);
}
.al-section--highlight {
  background: var(--al-bg-elevated, var(--al-surface));
  border-radius: var(--al-radius-lg);
  padding: 3rem 2rem;
  margin-left: -1rem;
  margin-right: -1rem;
}
[data-bs-theme="light"] .al-section--highlight {
  background: rgba(255,255,255,0.75);
  border: 1px solid rgba(255,255,255,0.9);
  box-shadow: 0 4px 20px rgba(11,46,20,0.06);
}
.al-section--cta {
  background: var(--al-primary);
  width: 100vw;
  margin-left: 50%;
  transform: translateX(-50%);
  padding: 4rem 1rem;
  border-radius: 0;
}
[data-bs-theme="dark"] .al-section--cta {
  background: linear-gradient(135deg, #0D1225 0%, #1a2744 100%);
  border-top: 1px solid var(--al-border);
}
.al-section-heading {
  font-family: var(--al-font-heading);
  font-weight: 900;
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  letter-spacing: -0.03em;
  color: var(--al-text-bright);
  margin-bottom: 0.5rem;
}
.al-section-sub {
  font-size: 1.05rem;
  color: var(--al-text-muted);
  max-width: 560px;
  margin: 0 auto;
}

/* Hero actions */
.al-hero-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2rem;
}
.al-hero-actions .btn-outline-light {
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.65);
  background: rgba(0, 0, 0, 0.15);
}
.al-hero-actions .btn-outline-light:hover {
  color: #FFFFFF;
  border-color: #FFFFFF;
  background: rgba(255, 255, 255, 0.12);
}

/* --------------------------------------------------------------------------
   Social Proof / Stats Bar
   -------------------------------------------------------------------------- */
.al-proof-bar {
  background: var(--al-surface);
  border-top: 1px solid var(--al-border);
  border-bottom: 1px solid var(--al-border);
  padding: 2rem 1rem;
  width: 100vw;
  margin-left: 50%;
  transform: translateX(-50%);
}
/* Sits immediately under the dark photo hero — a deeper green band bridges the
   hero and the turf below instead of slamming back to white. */
[data-bs-theme="light"] .al-proof-bar {
  background: #123D1E;
  border-top: none;
  border-bottom: 3px solid var(--al-primary);
}
[data-bs-theme="light"] .al-proof-bar .al-proof-item__number {
  color: #FFFFFF;
}
[data-bs-theme="light"] .al-proof-bar .al-proof-item__label {
  color: rgba(255,255,255,0.7);
}
[data-bs-theme="light"] .al-proof-bar .al-proof-launch {
  color: rgba(255,255,255,0.8);
}
[data-bs-theme="light"] .al-proof-bar .al-proof-launch strong {
  color: #FFFFFF;
}
.al-proof-bar__inner {
  display: flex;
  justify-content: center;
  gap: 3rem;
  flex-wrap: wrap;
  max-width: 800px;
  margin: 0 auto;
}
.al-proof-item {
  text-align: center;
}
.al-proof-item__number {
  display: block;
  font-family: var(--al-font-heading);
  font-size: 2rem;
  font-weight: 900;
  color: var(--al-text-bright);
  line-height: 1.1;
}
.al-proof-item__label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--al-text-muted);
}

/* --------------------------------------------------------------------------
   How It Works Steps
   -------------------------------------------------------------------------- */
.al-step-number {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: var(--al-primary);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--al-font-heading);
  font-size: 1.3rem;
  font-weight: 900;
  margin-bottom: 1rem;
  box-shadow: 0 4px 12px rgba(29,185,84,0.3);
}
[data-bs-theme="dark"] .al-step-number {
  box-shadow: 0 4px 12px rgba(0,240,255,0.2);
}
.al-step-title {
  font-family: var(--al-font-heading);
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--al-text-bright);
  margin-bottom: 0.5rem;
}
.al-step-desc {
  font-size: 0.88rem;
  color: var(--al-text-muted);
  line-height: 1.5;
}

/* --------------------------------------------------------------------------
   Feature Tiles (6-grid with SVG icons)
   -------------------------------------------------------------------------- */
.al-feature-tile {
  display: flex;
  flex-direction: column;
  background: var(--al-bg-card);
  border: 1px solid var(--al-border);
  border-radius: var(--al-radius-lg);
  padding: 2rem 1.25rem 1.5rem;
  text-align: center;
  height: 100%;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.al-feature-tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  border-color: var(--al-primary);
}
/* Push the CTA to the bottom so tiles with different copy lengths still align */
.al-feature-tile__link {
  margin-top: auto;
  padding-top: 1rem;
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--al-primary);
}
.al-feature-tile:hover .al-feature-tile__link {
  text-decoration: underline;
}
[data-bs-theme="dark"] .al-feature-tile:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}
.al-feature-tile__icon {
  color: var(--al-primary);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.al-feature-tile__icon svg {
  width: 32px;
  height: 32px;
}
.al-feature-tile__title {
  font-family: var(--al-font-heading);
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--al-text-bright);
  margin-bottom: 0.5rem;
}
.al-feature-tile__desc {
  font-size: 0.82rem;
  color: var(--al-text-muted);
  line-height: 1.5;
  margin: 0;
}

/* --------------------------------------------------------------------------
   Sport Tiles
   -------------------------------------------------------------------------- */
.al-sport-tile {
  background: var(--al-bg-card);
  border: 1px solid var(--al-border);
  border-radius: var(--al-radius-lg);
  padding: 1.25rem 0.75rem;
  text-align: center;
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.al-sport-tile:hover {
  transform: translateY(-2px);
  border-color: var(--al-primary);
}
.al-sport-tile__icon {
  font-size: 2rem;
  margin-bottom: 0.4rem;
}
.al-sport-tile__name {
  font-weight: 800;
  font-size: 0.8rem;
  color: var(--al-text-bright);
}
.al-sport-tile__count {
  font-family: var(--al-font-mono);
  font-size: 0.7rem;
  color: var(--al-primary);
}

/* --------------------------------------------------------------------------
   Audience Cards (Players / Organisers / League Admins)
   -------------------------------------------------------------------------- */
.al-audience-card {
  background: var(--al-bg-card);
  border: 1px solid var(--al-border);
  border-radius: var(--al-radius-lg);
  padding: 2rem 1.5rem;
  height: 100%;
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.al-audience-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  border-color: var(--al-primary);
}
[data-bs-theme="dark"] .al-audience-card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}
.al-audience-card__icon {
  color: var(--al-primary);
  margin-bottom: 1rem;
}
.al-audience-card__title {
  font-family: var(--al-font-heading);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--al-text-bright);
  margin-bottom: 0.5rem;
}
.al-audience-card__desc {
  font-size: 0.85rem;
  color: var(--al-text-muted);
  line-height: 1.5;
  margin-bottom: 1rem;
}
.al-audience-card__link {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--al-primary);
  text-decoration: none;
}
.al-audience-card__link:hover {
  text-decoration: underline;
}

/* --------------------------------------------------------------------------
   Value Prop Section
   -------------------------------------------------------------------------- */
.al-value-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
}
.al-value-list li {
  position: relative;
  padding: 0.5rem 0 0.5rem 1.8rem;
  font-size: 0.9rem;
  color: var(--al-text-muted);
  border-bottom: 1px solid var(--al-border);
}
.al-value-list li:last-child {
  border-bottom: none;
}
.al-value-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0.5rem;
  color: var(--al-primary);
  font-weight: 900;
}
/* "What you can stop using" panel — replaces the unverifiable % claim */
.al-replaces {
  padding: 1.75rem;
  border-radius: var(--al-radius-lg);
  background: var(--al-primary-glow);
  border: 2px solid var(--al-border-accent);
}
.al-replaces__title {
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--al-primary);
  margin-bottom: 1rem;
}
.al-replaces__list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
}
.al-replaces__list li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--al-text-muted);
  border-bottom: 1px solid var(--al-border);
  text-decoration: line-through;
  text-decoration-color: var(--al-primary);
  text-decoration-thickness: 2px;
}
.al-replaces__list li:last-child {
  border-bottom: none;
}
.al-replaces__list li span {
  font-size: 1.1rem;
  text-decoration: none;
  display: inline-block;
}
.al-replaces__foot {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--al-text-bright);
  margin: 0;
}

/* --------------------------------------------------------------------------
   Post-registration role choice (/welcome)
   -------------------------------------------------------------------------- */
.al-welcome {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem 0 4rem;
}
.al-welcome__title {
  font-family: var(--al-font-heading);
  font-weight: 900;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  letter-spacing: -0.03em;
  color: var(--al-text-bright);
  margin-bottom: 0.5rem;
}
.al-welcome__sub {
  color: var(--al-text-muted);
  font-size: 1.05rem;
}
.al-welcome-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 2rem 1.75rem;
  background: var(--al-bg-card);
  border: 2px solid var(--al-border);
  border-radius: var(--al-radius-lg);
  text-decoration: none;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.al-welcome-card:hover {
  transform: translateY(-4px);
  border-color: var(--al-primary);
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.al-welcome-card__icon {
  font-size: 2.5rem;
  line-height: 1;
  margin-bottom: 0.75rem;
}
.al-welcome-card__title {
  font-family: var(--al-font-heading);
  font-weight: 800;
  font-size: 1.35rem;
  color: var(--al-text-bright);
  margin-bottom: 0.5rem;
}
.al-welcome-card__desc {
  font-size: 0.9rem;
  color: var(--al-text-muted);
  line-height: 1.6;
}
.al-welcome-card__list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem;
}
.al-welcome-card__list li {
  position: relative;
  padding: 0.35rem 0 0.35rem 1.5rem;
  font-size: 0.85rem;
  color: var(--al-text-muted);
}
.al-welcome-card__list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--al-primary);
  font-weight: 900;
}
.al-welcome-card__cta {
  margin-top: auto;
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--al-primary);
}
.al-welcome-card:hover .al-welcome-card__cta {
  text-decoration: underline;
}
.al-welcome__skip {
  font-size: 0.85rem;
  color: var(--al-text-muted);
}

/* Pre-launch message shown instead of a wall of zeroes */
.al-proof-launch {
  text-align: center;
  font-size: 0.95rem;
  color: var(--al-text-muted);
  max-width: 560px;
}
.al-proof-launch strong {
  display: block;
  font-family: var(--al-font-heading);
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--al-text-bright);
  margin-bottom: 0.25rem;
}

/* --------------------------------------------------------------------------
   Table team link
   -------------------------------------------------------------------------- */
.al-table-team-link {
  font-weight: 700;
  color: var(--al-text-bright);
  text-decoration: none;
}
.al-table-team-link:hover {
  color: var(--al-primary);
}

/* --------------------------------------------------------------------------
   Feature list (reused in various places)
   -------------------------------------------------------------------------- */
.al-feature-list {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
}
.al-feature-list li {
  position: relative;
  padding-left: 1.4rem;
  padding-top: 0.3rem;
  padding-bottom: 0.3rem;
  font-size: 0.85rem;
  color: var(--al-text-muted);
  border-bottom: 1px solid var(--al-border);
}
.al-feature-list li:last-child {
  border-bottom: none;
}
.al-feature-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0.3rem;
  color: var(--al-primary);
  font-weight: 800;
  font-size: 0.8rem;
}

/* --------------------------------------------------------------------------
   Empty states — styled icons
   -------------------------------------------------------------------------- */
.al-empty-icon {
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background: var(--al-primary-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin: 0 auto 1rem;
}
[data-bs-theme="light"] .al-empty-icon {
  background: rgba(29,185,84,0.08);
}

/* --------------------------------------------------------------------------
   Hover feedback everywhere — subtle lift on interactive cards
   -------------------------------------------------------------------------- */
.al-card[href]:hover,
a.al-card:hover,
.list-group-item-action:hover {
  transform: translateY(-2px);
}

/* ====================================================================
   DASHBOARD — logged-in home screen (src/Views/dashboard/index.php)
   Built entirely on the theme-aware --al-* vars so light/dark come free.
   ==================================================================== */

.al-dash-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.al-dash-title {
  font-weight: 800;
  letter-spacing: -0.02em;
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  color: var(--al-text-bright);
  margin: 0 0 0.15rem;
}

.al-dash-sub {
  color: var(--al-text-muted);
  font-size: 0.9rem;
}

.al-dash-sub strong { color: var(--al-text); }

/* --- Manager mode switch --- */
.al-mode-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  user-select: none;
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--al-border-strong);
  border-radius: 999px;
  background: var(--al-surface);
}

.al-mode-toggle__label {
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--al-text-muted);
  white-space: nowrap;
}

/* The real checkbox stays focusable but invisible — the track/thumb is the visual. */
.al-mode-toggle input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.al-mode-toggle__track {
  position: relative;
  display: block;
  width: 2.4rem;
  height: 1.35rem;
  border-radius: 999px;
  background: var(--al-border-strong);
  transition: background 0.18s ease;
  flex-shrink: 0;
}

.al-mode-toggle__thumb {
  position: absolute;
  top: 0.16rem;
  left: 0.16rem;
  width: 1.03rem;
  height: 1.03rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.35);
  transition: transform 0.18s ease;
}

.al-mode-toggle input:checked ~ .al-mode-toggle__track { background: var(--al-primary); }
.al-mode-toggle input:checked ~ .al-mode-toggle__track .al-mode-toggle__thumb { transform: translateX(1.05rem); }
.al-mode-toggle input:focus-visible ~ .al-mode-toggle__track { outline: 2px solid var(--al-primary); outline-offset: 2px; }
body.al-manager-on .al-mode-toggle__label { color: var(--al-primary); }

/* --- Manager band (sits above the player content) --- */
.al-manager-band[hidden] { display: none; }

.al-manager-band__bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.al-manager-band__eyebrow {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--al-primary);
}

.al-manager-band__actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.al-manager-band__rule {
  margin: 1.75rem 0;
  border: 0;
  border-top: 2px solid var(--al-border-strong);
  opacity: 1;
}

/* --- Stat row --- */
.al-stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.al-stat {
  background: var(--al-surface);
  border: 1px solid var(--al-border);
  border-radius: var(--al-radius);
  padding: 0.85rem 1rem;
}

.al-stat--warn { border-color: rgba(255,140,0,0.35); }
.al-stat--warn .al-stat__value { color: var(--al-pending); }

.al-stat__value {
  display: block;
  font-family: var(--al-font-mono);
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--al-text-bright);
  line-height: 1.2;
}

.al-stat__label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--al-text-muted);
  margin-top: 0.15rem;
}

/* --- Generic list row, used by every dashboard panel --- */
.al-row-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--al-border);
}

.al-row-item:last-child { border-bottom: 0; }
.al-row-item:hover { background: var(--al-bg-hover); }

.al-row-item__main { min-width: 0; }

.al-row-item__title {
  display: block;
  font-weight: 700;
  color: var(--al-text-bright);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

a.al-row-item__title:hover { color: var(--al-primary); }

.al-row-item__meta {
  display: block;
  font-size: 0.78rem;
  color: var(--al-text-muted);
  margin-top: 0.1rem;
}

.al-row-item__side {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.al-row-item__side form { margin: 0; }

/* Owed-money card gets a warning edge so it reads as the thing to action first. */
.al-card--owed { border-color: rgba(255,140,0,0.4); }
.al-card--owed .al-card-header { color: var(--al-pending); }

/* --- Quick links --- */
.al-quick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 0.5rem;
}

.al-quick {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--al-border);
  border-radius: var(--al-radius);
  background: var(--al-surface);
  color: var(--al-text);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.85rem;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.al-quick:hover { border-color: var(--al-border-accent); color: var(--al-primary); }
.al-quick span { font-size: 1.1rem; line-height: 1; }

@media (max-width: 575.98px) {
  .al-row-item { flex-direction: column; align-items: stretch; gap: 0.5rem; }
  .al-row-item__side { justify-content: space-between; }
  .al-row-item__title { white-space: normal; }
}
