/* =============================================
   STONEWALL SPORTS HOUSTON
   Master Stylesheet — GitHub Pages
   ============================================= */

/* --- GOOGLE FONTS --- */
@import url('https://fonts.googleapis.com/css2?family=League+Spartan:wght@400;700;800;900&display=swap');

/* --- CSS VARIABLES --- */
:root {
  --red: #e8192c;
  --bg: #0d0d0d;
  --surface: #161616;
  --card: #1e1e1e;
  --nav: #161616;
  --muted: #888888;
  --white: #ffffff;
}

/* --- RESET --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--white);
  font-family: 'League Spartan', 'Segoe UI', system-ui, sans-serif;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* =============================================
   NAVIGATION
   ============================================= */

.sw-nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: #1a1a1a;
  background-image:
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 4px,
      rgba(255,255,255,0.045) 4px,
      rgba(255,255,255,0.045) 5px
    );
  border-bottom: 1px solid #2a2a2a;
  width: 100%;
}

.sw-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  height: 64px;
  max-width: 1400px;
  margin: 0 auto;
}

/* Logo */
.sw-nav-logo img {
  height: 40px;
  width: auto;
}

/* Desktop nav links */
.sw-nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}

.sw-nav-links > li {
  position: relative;
}

/* All nav links same color — dim on non-active, white on active/hover */
.sw-nav-links > li > a,
.sw-nav-links > li > button {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 8px 14px;
  font-size: .8rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #aaa;
  background: none;
  border: none;
  cursor: pointer;
  transition: color .2s;
  white-space: nowrap;
  font-family: inherit;
}

.sw-nav-links > li > a:hover,
.sw-nav-links > li > a.active {
  color: var(--white);
}

/* Hover dropdown parent link also brightens */
.sw-nav-hover-dd:hover > a {
  color: var(--white);
}

.sw-nav-links > li > a.nav-cta {
  background: var(--red);
  color: #fff !important;
  padding: 8px 18px;
  margin-left: 8px;
  letter-spacing: 1px;
}
.sw-nav-links > li > a.nav-cta:hover {
  background: #c4001f;
}

/* Dropdown chevron */
.sw-nav-links > li > a .chevron,
.sw-nav-links > li > button .chevron {
  font-style: normal;
  font-size: .6rem;
  transition: transform .2s;
  display: inline-block;
}
.sw-nav-hover-dd.open > a .chevron,
.sw-nav-links > li.open > button .chevron {
  transform: rotate(180deg);
}

/* Dropdown menu */
.sw-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--card);
  border: 1px solid #2a2a2a;
  border-top: 2px solid var(--red);
  min-width: 180px;
  flex-direction: column;
  z-index: 100;
}

/* Invisible bridge fills any sub-pixel gap between nav item and dropdown */
.sw-nav-hover-dd::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 6px;
}

.sw-nav-hover-dd:hover .sw-dropdown,
.sw-nav-hover-dd.open .sw-dropdown,
.sw-nav-links > li.open .sw-dropdown {
  display: flex;
}

.sw-dropdown a {
  padding: 12px 18px;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #aaa;
  border-bottom: 1px solid #2a2a2a;
  transition: color .2s, background .2s;
  white-space: nowrap;
}
.sw-dropdown a:last-child { border-bottom: none; }
.sw-dropdown a:hover { color: #fff; background: #2a2a2a; }

/* Hamburger */
.sw-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.sw-hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  transition: transform .3s, opacity .3s;
}
.sw-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.sw-hamburger.open span:nth-child(2) { opacity: 0; }
.sw-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav drawer */
.sw-mobile-nav {
  display: none;
  flex-direction: column;
  background: var(--nav);
  border-top: 1px solid #2a2a2a;
  padding: 12px 0 24px;
}
.sw-mobile-nav.open { display: flex; }

.sw-mobile-nav a,
.sw-mobile-nav button {
  padding: 13px 32px;
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #aaa;
  background: none;
  border: none;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: color .2s;
}
.sw-mobile-nav a:hover,
.sw-mobile-nav button:hover { color: var(--white); }

.sw-mobile-sub {
  display: none;
  flex-direction: column;
  background: #111;
  border-left: 2px solid var(--red);
  margin: 0 32px;
}
.sw-mobile-sub.open { display: flex; }
.sw-mobile-sub a {
  padding: 11px 20px;
  font-size: .75rem;
  color: #888;
  letter-spacing: 1px;
}
.sw-mobile-sub a:hover { color: var(--white); }

/* Split-row: link on left, chevron toggle on right */
.sw-mobile-dd-row {
  display: flex;
  align-items: stretch;
}
.sw-mobile-dd-row > a {
  flex: 1;
  justify-content: flex-start;
}
.sw-mobile-dd-row > .sw-mobile-toggle {
  padding: 13px 24px 13px 12px;
  border-left: 1px solid #2a2a2a;
  justify-content: center;
  font-size: .6rem;
}

.sw-mobile-nav .nav-cta-mobile {
  margin: 16px 32px 0;
  background: var(--red);
  color: #fff;
  text-align: center;
  padding: 14px 20px;
  font-weight: 800;
  font-size: .82rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  display: block;
}

/* =============================================
   RAINBOW BAR
   ============================================= */

.rainbow-bar {
  height: 5px;
  width: 100%;
  background: linear-gradient(90deg, #ff595e, #ff924c, #ffca3a, #8ac926, #1982c4, #6a4c93, #ff595e);
}

/* =============================================
   HERO
   ============================================= */

.sw-hero {
  position: relative;
  min-height: 86vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 24px 60px;
  overflow: hidden;
  width: 100%;
}

.sw-hero-bg {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(45deg, #161616 0, #161616 10px, #191919 10px, #191919 20px);
  opacity: 0.5;
  z-index: 0;
}

.sw-hero > * { position: relative; z-index: 1; }

.sw-hero h1 {
  font-size: clamp(2.5rem, 8vw, 6rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -2px;
  margin-bottom: 20px;
  text-transform: uppercase;
  color: var(--white);
}
.sw-hero h1 span { color: var(--red); }

.sw-hero p {
  font-size: 1.1rem;
  color: #aaa;
  max-width: 540px;
  margin-bottom: 40px;
  line-height: 1.8;
}

.sw-hero-btns {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}

.sw-scroll-hint {
  margin-top: 50px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: #444;
  font-size: .7rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.sw-scroll-line {
  width: 1px;
  height: 50px;
  background: linear-gradient(to bottom, #e8192c, transparent);
}

/* =============================================
   BUTTONS
   ============================================= */

.btn-red {
  background: var(--red);
  color: #fff;
  padding: 14px 34px;
  font-weight: 800;
  font-size: .95rem;
  letter-spacing: .5px;
  text-transform: uppercase;
  text-decoration: none;
  display: inline-block;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: background .2s;
}
.btn-red:hover { background: #c4001f; color: #fff; }

.btn-ghost {
  border: 2px solid #444;
  color: #fff;
  padding: 13px 32px;
  font-weight: 700;
  font-size: .95rem;
  text-transform: uppercase;
  text-decoration: none;
  display: inline-block;
  background: transparent;
  transition: border-color .2s;
}
.btn-ghost:hover { border-color: #fff; }

/* =============================================
   AWARD BANNER
   ============================================= */

.sw-award {
  background: var(--red);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-size: .85rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #fff;
  width: 100%;
  flex-wrap: wrap;
  text-align: center;
}

/* =============================================
   SECTIONS
   ============================================= */

.sw-section {
  padding: 80px 48px;
  width: 100%;
}
.sw-section-dark { background: var(--bg); }
.sw-section-surface { background: var(--surface); }

.sw-sec-label {
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 10px;
}

.sw-sec-title {
  font-size: clamp(1.6rem, 4vw, 2.8rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -1px;
  margin-bottom: 12px;
  color: var(--white);
}

.sw-sec-sub {
  color: var(--muted);
  font-size: .95rem;
  max-width: 500px;
  margin-bottom: 40px;
}

/* =============================================
   SPORTS GRID
   ============================================= */

.sw-sports-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
}

.sw-sport-card {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 1 / 0.85;
  min-height: 200px;
}

.sw-sport-img {
  width: 100%;
  height: 100%;
  background: var(--card);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform .3s;
  position: absolute;
  inset: 0;
}
.sw-sport-card:hover .sw-sport-img { transform: scale(1.04); }

.sw-sport-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.85) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  z-index: 2;
}
.sw-sport-overlay h3 {
  font-size: 1.2rem;
  font-weight: 900;
  text-transform: uppercase;
  color: #fff;
  margin: 0;
}
.sw-sport-overlay p { font-size: .78rem; color: #bbb; margin: 4px 0 0; }

.sw-sport-tag {
  display: inline-block;
  margin-top: 10px;
  font-size: .68rem;
  font-weight: 800;
  padding: 4px 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.tag-red { background: var(--red); color: #fff; }
.tag-white { background: #fff; color: #000; }
.tag-outline { border: 1px solid #555; color: #aaa; }

/* =============================================
   EVENTS
   ============================================= */

.sw-events-list { display: flex; flex-direction: column; gap: 1px; }

.sw-ev {
  background: var(--card);
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 20px;
  border-left: 3px solid transparent;
  transition: border-color .2s;
  flex-wrap: wrap;
}
.sw-ev:hover { border-left-color: var(--red); }

.sw-ev-date { min-width: 50px; text-align: center; }
.sw-ev-date .mo { font-size: .65rem; font-weight: 800; letter-spacing: 2px; text-transform: uppercase; color: var(--red); }
.sw-ev-date .dy { font-size: 2rem; font-weight: 900; line-height: 1; color: #fff; }

.sw-ev-info h3 { font-size: .9rem; font-weight: 800; text-transform: uppercase; color: #fff; margin: 0; }
.sw-ev-info p { font-size: .8rem; color: var(--muted); margin: 3px 0 0; }

.sw-ev-badge {
  margin-left: auto;
  font-size: .68rem;
  font-weight: 800;
  padding: 5px 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  white-space: nowrap;
}

/* =============================================
   QUOTE
   ============================================= */

.sw-quote-section {
  background: var(--surface);
  text-align: center;
  padding: 22px 24px;
  width: 100%;
}

.sw-quote {
  font-size: clamp(.85rem, 1.5vw, 1rem);
  font-weight: 700;
  max-width: 560px;
  margin: 0 auto 8px;
  line-height: 1.4;
  font-style: italic;
  color: #fff;
}

.sw-quote-attr { font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: 2px; }

/* Dark variant so quote visually separates from events section above */
.sw-quote-dark { background: var(--bg) !important; border-top: 1px solid #2a2a2a; border-bottom: 1px solid #2a2a2a; }

/* =============================================
   ABOUT
   ============================================= */

.sw-about-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: stretch;
}

.sw-stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 32px; }
.sw-stat { background: var(--card); padding: 20px; border-top: 2px solid var(--red); }
.sw-stat .num { font-size: 2rem; font-weight: 900; color: var(--red); }
.sw-stat .lbl { font-size: .75rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; margin-top: 2px; }

/* =============================================
   BOARD
   ============================================= */

.sw-board-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 2px;
}

/* =============================================
   NEWSLETTER
   ============================================= */

.sw-nl-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2px;
}

/* =============================================
   STANDINGS TABLE
   ============================================= */

.sw-standings-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .85rem;
}
.sw-standings-table th {
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--red);
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid #2a2a2a;
}
.sw-standings-table td {
  padding: 14px 16px;
  color: #ccc;
  border-bottom: 1px solid #1e1e1e;
}
.sw-standings-table tr:hover td { background: var(--card); }
.sw-standings-table td:first-child { font-weight: 800; color: #fff; }

/* =============================================
   FOOTER
   ============================================= */

.sw-footer {
  background: #0a0a0a;
  border-top: 1px solid #1e1e1e;
  padding: 48px 48px 32px;
}

.sw-footer-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1.4fr;
  gap: 48px;
  max-width: 1400px;
  margin: 0 auto 40px;
}

.sw-footer-brand img { height: 60px; margin-bottom: 16px; }
.sw-footer-brand p { font-size: .85rem; color: var(--muted); line-height: 1.6; max-width: 260px; }

.sw-footer-col h4 {
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 16px;
}
.sw-footer-col a {
  display: block;
  font-size: .83rem;
  color: var(--muted);
  margin-bottom: 10px;
  transition: color .2s;
}
.sw-footer-col a:hover { color: var(--white); }

.sw-footer-bottom {
  border-top: 1px solid #1e1e1e;
  padding-top: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 1400px;
  margin: 0 auto;
  font-size: .75rem;
  color: #444;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* =============================================
   PAGE HERO (interior pages)
   ============================================= */

.sw-page-hero {
  background: var(--surface);
  padding: 60px 48px;
  border-bottom: 1px solid #2a2a2a;
}
.sw-page-hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -1px;
  color: var(--white);
  margin-bottom: 12px;
}
.sw-page-hero p { font-size: 1rem; color: var(--muted); max-width: 540px; }

/* =============================================
   UTILITY
   ============================================= */

.text-red { color: var(--red); }
.text-muted { color: var(--muted); }

/* =============================================
   MOBILE RESPONSIVE
   ============================================= */

@media (max-width: 900px) {
  .sw-nav-links { display: none; }
  .sw-hamburger { display: flex; }
  .sw-footer-inner { grid-template-columns: 1fr 1fr; }
  .sw-footer-newsletter-col { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  .sw-section { padding: 50px 20px; }
  .sw-page-hero { padding: 40px 20px; }
  .sw-hero { padding: 60px 20px 40px; min-height: 75vh; }
  .sw-hero p { font-size: 1rem; }
  .sw-hero-btns { flex-direction: column; align-items: center; }
  .sw-hero-btns a { width: 100%; max-width: 300px; text-align: center; }
  .sw-about-inner { grid-template-columns: 1fr; gap: 32px; }
  .sw-sports-grid { grid-template-columns: 1fr; }
  .sw-board-grid { grid-template-columns: 1fr 1fr; }
  .sw-ev { flex-direction: column; align-items: flex-start; gap: 10px; }
  .sw-ev-badge { margin-left: 0; }
  .sw-award { font-size: .78rem; gap: 8px; }
  .sw-footer { padding: 40px 20px 24px; }
  .sw-footer-inner { grid-template-columns: 1fr; gap: 32px; }
  .sw-footer-bottom { flex-direction: column; text-align: center; }
  .sw-quote-section { padding: 18px 20px; }
  .sw-standings-table th,
  .sw-standings-table td { padding: 10px; }
}

@media (max-width: 480px) {
  .sw-board-grid { grid-template-columns: 1fr; }
  .sw-nav-inner { padding: 0 20px; }
}

/* ── Footer newsletter column ────────────────────────────── */
.sw-footer-newsletter-col h4 {
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 14px;
}
.sw-footer-newsletter-col p {
  font-size: .8rem;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 14px;
}
/* The LeagueApps widget renders as a white iframe — clip it tight */
.sw-footer-newsletter-widget {
  overflow: hidden;
  border-radius: 4px;
  max-width: 220px;
  width: 220px;
}
.sw-footer-newsletter-widget iframe {
  max-width: 220px !important;
  width: 220px !important;
}

/* ── Mailing list widget override ─────────────────────────── */
#mailing-list-subscription {
  max-width: 460px;
  margin: 0 auto;
  text-align: left;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}
#mailing-list-subscription * {
  box-sizing: border-box;
}

/* ── Mailing list widget — strip white box, match dark theme ── */
#mailing-list-subscription > div,
#mailing-list-subscription > form,
#mailing-list-subscription > div > div {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
  border-radius: 0 !important;
  max-width: 100% !important;
}
/* Hide duplicate "Join Our Mailing List" heading from widget */
#mailing-list-subscription h1,
#mailing-list-subscription h2,
#mailing-list-subscription h3,
#mailing-list-subscription h4 {
  display: none !important;
}
/* Style email input to match dark theme */
#mailing-list-subscription input[type="text"],
#mailing-list-subscription input[type="email"] {
  background: #1a1a1a !important;
  border: 1px solid #444 !important;
  color: #fff !important;
  padding: 12px 16px !important;
  font-size: 1rem !important;
  width: 100% !important;
  max-width: 420px !important;
  border-radius: 0 !important;
  outline: none !important;
  display: block !important;
  margin: 0 auto 12px !important;
}
#mailing-list-subscription input[type="text"]::placeholder,
#mailing-list-subscription input[type="email"]::placeholder {
  color: #666 !important;
}
/* Style subscribe button to match site red */
#mailing-list-subscription button,
#mailing-list-subscription input[type="submit"],
#mailing-list-subscription button[type="submit"] {
  background: #e8192c !important;
  color: #fff !important;
  border: none !important;
  padding: 12px 40px !important;
  font-weight: 900 !important;
  font-size: .8rem !important;
  letter-spacing: 1.5px !important;
  text-transform: uppercase !important;
  cursor: pointer !important;
  border-radius: 0 !important;
  display: inline-block !important;
}
#mailing-list-subscription button:hover,
#mailing-list-subscription input[type="submit"]:hover {
  background: #c0121f !important;
}
