/* ==============================================
   GCT Race Tracker — Superhero / Athletic Theme
   ============================================== */
@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Inter:wght@400;700;900&display=swap');

:root {
  --bg-deep: #0a0a14;
  --bg-card: #13132a;
  --fire: #ff3d00;
  --electric: #00c6ff;
  --gold: #ffd700;
  --white: #ffffff;
  --text-muted: #8899bb;
  --border-subtle: rgba(255,255,255,0.12);
  --border-strong: rgba(255,255,255,0.25);
  --shadow-card: 0 4px 30px rgba(0,0,0,0.6);
  --shadow-glow: 0 0 40px rgba(255,61,0,0.25);
  --font-head: 'Bebas Neue', Impact, sans-serif;
  --font-body: Inter, -apple-system, BlinkMacSystemFont, sans-serif;
  --transition: 0.25s ease;
  --clip-angle: polygon(0 0, 100% 0, 100% 88%, 0 100%);
}

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

body {
  font-family: var(--font-body);
  font-size: 16px; line-height: 1.6;
  color: var(--white); background: var(--bg-deep);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}

body::before {
  content: ''; position: fixed; inset: 0;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(255,61,0,0.06) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 80%, rgba(0,198,255,0.04) 0%, transparent 60%);
  pointer-events: none; z-index: 0;
}

a { color: var(--electric); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--fire); text-decoration: none; }

h1, h2, h3 { font-family: var(--font-head); font-weight: 400; text-transform: uppercase; letter-spacing: 0.04em; }
h1 { font-size: clamp(2.5rem, 6vw, 4rem); line-height: 0.95; }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.8rem); }

.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; position: relative; z-index: 1; }
.section { padding: 3rem 0; }

/* ===== HEADER ===== */
.site-header {
  background: linear-gradient(135deg, #1a1a3e 0%, #0d0d28 100%);
  text-align: center; padding: 3rem 0 2.5rem;
  clip-path: var(--clip-angle); position: relative; z-index: 2;
  border-bottom: 3px solid var(--fire);
}
.site-header::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--fire), var(--gold), var(--electric));
}
.site-header__logo {
  font-family: var(--font-head); font-size: clamp(2.8rem, 7vw, 5rem); font-weight: 400;
  text-transform: uppercase; letter-spacing: 0.06em; color: var(--white);
  text-shadow: 3px 3px 0 var(--fire), 6px 6px 0 rgba(0,0,0,0.4); line-height: 1;
}
.site-header__sub {
  font-size: 1rem; text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--gold); margin-top: 0.5rem;
}

/* ===== CARDS (hero-card + legacy recipe-card) ===== */
.hero-card, .recipe-card {
  background: var(--bg-card);
  border: 2px solid var(--border-strong);
  border-radius: 6px;
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
  position: relative;
}
.hero-card:hover, .recipe-card:hover {
  box-shadow: var(--shadow-glow);
  border-color: var(--fire);
  transform: translateY(-4px);
}
.hero-card__header {
  background: linear-gradient(135deg, var(--fire), #cc2b00);
  height: 140px;
  display: flex; align-items: center; justify-content: center;
  color: white; font-size: 3rem; position: relative; overflow: hidden;
  border-bottom: 2px solid var(--gold);
}
.hero-card__header::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 40px;
  background: linear-gradient(to top, var(--bg-card), transparent);
}
.hero-card__header--alt { background: linear-gradient(135deg, #1a3a5c, #0d2040); }
.hero-card__body, .recipe-card__body { padding: 1.5rem; }
.hero-card__title, .recipe-card__title {
  font-family: var(--font-head); font-size: 1.5rem; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--white); margin-bottom: 0.5rem;
}
.hero-card__description, .recipe-card__description {
  font-size: 0.9rem; color: var(--text-muted); margin-bottom: 1rem; line-height: 1.5;
}

.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; }
.centered-card { max-width: 480px; margin: 0 auto; }

/* ===== BUTTONS (btn-power + legacy) ===== */
.btn-power, .btn-pill, .btn-wine, .btn-outline-wine, .btn-olive, .btn-gold {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.7rem 1.6rem;
  border: 2px solid var(--border-strong);
  font-family: var(--font-body); font-weight: 700; font-size: 0.9rem;
  text-transform: uppercase; letter-spacing: 0.06em;
  cursor: pointer; transition: all var(--transition);
  text-decoration: none; border-radius: 4px; color: white;
}
.btn-power:hover, .btn-pill:hover { transform: translateY(-3px); text-decoration: none; filter: brightness(1.2); }

.btn-power { clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%); }

.btn-fire { background: var(--fire); border-color: var(--fire); color: white; }
.btn-fire:hover, .btn-wine:hover { box-shadow: 0 0 25px rgba(255,61,0,0.5); }

.btn-electric { background: var(--electric); color: #0a0a14; border-color: var(--electric); }
.btn-electric:hover { box-shadow: 0 0 25px rgba(0,198,255,0.5); }

.btn-gold { background: var(--gold); color: #0a0a14; border-color: var(--gold); }
.btn-gold:hover { box-shadow: 0 0 25px rgba(255,215,0,0.5); }

.btn-outline, .btn-outline-wine { background: transparent; border-color: var(--fire); color: var(--fire); }
.btn-outline:hover, .btn-outline-wine:hover { background: var(--fire); color: white; box-shadow: 0 0 25px rgba(255,61,0,0.4); }

.btn-wine { background: var(--fire); border-color: var(--fire); }
.btn-olive { background: var(--electric); color: #0a0a14; }

/* ===== SPEECH BUBBLE ===== */
.power-bubble, .speech-bubble {
  background: var(--bg-card);
  border: 2px solid var(--border-strong);
  border-left: 4px solid var(--gold);
  padding: 1.2rem 1.5rem;
  margin: 0 auto; max-width: 650px;
  font-size: 0.95rem; color: var(--text-muted);
  border-radius: 4px;
}

/* ===== TABLES ===== */
.table-wrapper {
  overflow-x: auto; margin: 1.5rem 0;
  border: 2px solid var(--border-strong);
  background: var(--bg-card); border-radius: 4px;
}
table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
thead { background: linear-gradient(180deg, #1a1a3e, #13132a); }
th {
  padding: 1rem; text-align: left;
  font-family: var(--font-head); font-size: 1rem;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--gold); border-bottom: 2px solid var(--fire);
}
td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-strong);
  color: var(--white);
}
tbody tr:hover { background: rgba(255,61,0,0.08); }

@media (max-width: 768px) {
  table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
  table tr { display: block; margin-bottom: 1rem; border: 1px solid var(--border-strong); }
  table td { display: flex; justify-content: space-between; padding: 0.5rem 1rem; border-bottom: 1px solid var(--border-strong); }
  table td::before { content: attr(data-label); font-weight: 700; color: var(--gold); }
}

/* ===== FOOTER ===== */
.site-footer {
  margin-top: 3rem;
  padding: 1.5rem 0 2rem;
  border-top: 1px solid var(--border-subtle);
  background: rgba(10, 10, 20, 0.8);
}
.site-footer__text {
  text-align: center;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
}
.site-footer__links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
}
.site-footer__links a {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.6rem 0.95rem;
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  color: var(--white);
  background: rgba(255,255,255,0.04);
}
.site-footer__links a:hover {
  color: var(--gold);
  border-color: var(--gold);
  transform: translateY(-2px);
}

/* ==============================================
   Race Reach Widget: 3-Column Grid (Compact)
   ============================================== */
.rr-events-widget {
  background: transparent;
  width: 100%;
  margin: 0 auto 1.5rem auto;
}

.rr-events-widget ul {
  list-style: none;
  display: grid;
  /* Reduced min-width from 280px to 220px to allow narrower cards */
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem; /* Tighter gap between cards */
}

.rr-events-widget li {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--electric);
  border-radius: 6px;
  padding: 0.8rem; /* Reduced from 1.2rem for a tighter box */
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.rr-events-widget li:hover {
  background: rgba(255, 61, 0, 0.05);
  border-color: var(--border-strong);
  border-left-color: var(--fire);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.rr-events-widget strong {
  color: var(--gold);
  font-family: var(--font-head);
  font-size: 1.15rem; /* Scaled down from 1.4rem */
  letter-spacing: 0.05em;
  margin-bottom: 0.2rem;
}

/* Force the event title text to be a bit smaller */
.rr-events-widget li span {
  font-size: 0.85rem !important; 
  line-height: 1.3;
}

/* Scaled down the button slightly */
.rr-events-widget a {
  margin-top: 0.75rem;
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.6rem;
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  color: var(--white);
  font-size: 0.7rem; /* Smaller font */
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: rgba(10, 10, 20, 0.8);
  transition: all var(--transition);
}

.rr-events-widget a:hover {
  color: var(--fire);
  border-color: var(--fire);
}

/* ===== UTILITIES ===== */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-gold { color: var(--gold); }
.text-fire { color: var(--fire); }
.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.flex { display: flex; }
.flex-center { align-items: center; justify-content: center; }
.flex-wrap { flex-wrap: wrap; }
.gap-1 { gap: 1rem; }
.gap-2 { gap: 2rem; }