/* ============================================================
   ASHWA RACING — SPONSORS PAGE
   System: Barlow Condensed + Barlow · dark motorsport-editorial
   Tier hierarchy: Executive → Platinum → Gold → Silver → Technical
   ============================================================ */

/* ─── Tokens ────────────────────────────────────────────────── */
:root {
  --red:          #e8001d;
  --black:        #0a0a0a;
  --charcoal:     #141414;
  --dark-grey:    #1c1c1c;
  --mid-grey:     #2a2a2a;
  --off-white:    #f7f6f4;
  --white:        #ffffff;
  --text-muted:   #888;
  --font-display: 'Barlow Condensed', sans-serif;
  --font-body:    'Barlow', sans-serif;
  --ease-expo:    cubic-bezier(0.16, 1, 0.3, 1);

  /* Tier accent colours */
  --exec-accent:    #e8001d;          /* Red — flagship */
  --plat-accent:    #c0c0c0;          /* Platinum silver */
  --gold-accent:    #f0b429;          /* Gold */
  --silver-accent:  #9ca3af;          /* Silver grey */
  --tech-accent:    rgba(255,255,255,0.25); /* Subtle white */
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-body); background: var(--charcoal); color: var(--white); overflow-x: hidden; }

/* ═══════════════════════════════════════════════════════════════
   HERO
═══════════════════════════════════════════════════════════════ */
.sp-hero {
  position: relative;
  height: 100%; min-height: 250px; max-height: 550px;
  background: var(--black);
  overflow: hidden;
  display: flex; flex-direction: column; justify-content: flex-end;
}

.sp-hero-bg {
  position: absolute; inset: 0;
  background-image: url('https://ashwaracing.org/cdn-cgi/image/width=1920,format=auto/https://assets.ashwaracing.org/images/team/Hyperloop.webp');
  background-size: cover; background-position: center 40%;
  filter: brightness(0.22) saturate(0.6);
  transform: scale(1.04);
  transition: transform 8s var(--ease-expo);
}
.sp-hero:hover .sp-hero-bg { transform: scale(1.0); }

.sp-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.93) 0%, rgba(0,0,0,0.3) 55%, rgba(0,0,0,0.05) 100%);
}

.sp-hero-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.022) 1px, transparent 1px);
  background-size: 64px 64px;
}

.sp-hero-stripe {
  position: absolute; top: 0; right: 9%; z-index: 2;
  width: 3px; height: 100%;
  background: var(--red);
}
.sp-hero-stripe::before {
  content: '';
  position: absolute; top: 0; left: -14px;
  width: 1px; height: 100%;
  background: var(--red); opacity: 0.28;
}

.sp-hero-content {
  position: relative; z-index: 3;
  padding: 0 7% 44px;
  max-width: 700px;
}

.sp-hero-title {
  font-family: var(--font-display);
  font-size: clamp(5rem, 13vw, 10rem);
  font-weight: 800; line-height: 0.86;
  letter-spacing: -0.02em; text-transform: uppercase;
  color: var(--white); margin-bottom: 20px;
  margin-top: 50px;
}
.sp-hero-title em { font-style: italic; color: var(--red); display: block; }

.sp-hero-desc {
  font-size: clamp(0.88rem, 1.3vw, 1rem);
  line-height: 1.7; color: rgba(255,255,255,0.75);
  font-weight: 300; max-width: 480px; margin-bottom: 28px;
}

.sp-cta {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-size: 0.9rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--red);
  border-bottom: 2px solid var(--red);
  padding-bottom: 3px;
  text-decoration: none;
  transition: gap 0.2s ease, opacity 0.2s ease;
}
.sp-cta:hover { gap: 16px; opacity: 0.8; }

/* ─── Tier quick-nav ────────────────────────────────────────── */
.tier-nav {
  position: relative; z-index: 3;
  display: flex; flex-wrap: wrap;
  border-top: 1px solid rgba(255,255,255,0.07);
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(10px);
}

.tier-nav-btn {
  flex: 1; min-width: 80px;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 16px 10px;
  background: transparent; border: none;
  border-right: 1px solid rgba(255,255,255,0.05);
  cursor: pointer; text-decoration: none;
  position: relative;
  transition: background 0.2s ease;
}
.tier-nav-btn:last-child { border-right: none; }

/* Always show bottom bar */
.tier-nav-btn::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0; height: 3px;
  transform: scaleX(1);
  transition: transform 0.3s var(--ease-expo);
}

/* Tier-specific bottom colours */
.tier-nav-btn[data-tier="executive"]::after  { background: var(--exec-accent); }
.tier-nav-btn[data-tier="platinum"]::after   { background: var(--plat-accent); }
.tier-nav-btn[data-tier="gold"]::after       { background: var(--gold-accent); }
.tier-nav-btn[data-tier="silver"]::after     { background: var(--silver-accent); }
.tier-nav-btn[data-tier="technical"]::after  { background: rgba(255,255,255,0.35); }

.tier-nav-label {
  font-family: var(--font-display);
  font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--white);
}

.tier-nav-count {
  font-family: var(--font-display);
  font-size: 1.1rem; font-weight: 800;
  line-height: 1;
}

/* Always use tier colors */
.tier-nav-btn[data-tier="executive"] .tier-nav-count { color: var(--exec-accent); }
.tier-nav-btn[data-tier="platinum"]  .tier-nav-count { color: var(--plat-accent); }
.tier-nav-btn[data-tier="gold"]      .tier-nav-count { color: var(--gold-accent); }
.tier-nav-btn[data-tier="silver"]    .tier-nav-count { color: var(--silver-accent); }
.tier-nav-btn[data-tier="technical"] .tier-nav-count { color: rgba(255,255,255,0.6); }

/* ═══════════════════════════════════════════════════════════════
   SECTION WRAPPER (per tier)
═══════════════════════════════════════════════════════════════ */
.sp-tier-section {
  padding: 24px 7%;
  border-top: 1px solid rgba(255,255,255,0.05);
  opacity: 0; transform: translateY(28px);
  transition: opacity 0.55s var(--ease-expo), transform 0.55s var(--ease-expo);
}
.sp-tier-section.visible { opacity: 1; transform: translateY(0); }

/* Alternating bg */
.sp-tier-section:nth-child(even) { background: var(--off-white); }
.sp-tier-section:nth-child(odd)  { background: var(--white); }

.sp-tier-section[data-tier="gold"] {
  padding: 50px 7%;
}

.sp-tier-section[data-tier="silver"] {
  padding: 40px 7%;
}

/* Section header */
.sp-tier-header {
  display: flex; align-items: center;
  flex-direction: column;
  text-align: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.sp-tier-label-group { display: flex; flex-direction: column; gap: 6px; }

.sp-tier-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.02em; line-height: 1;
  color: var(--black);
}

/* ═══════════════════════════════════════════════════════════════
   EXECUTIVE
═══════════════════════════════════════════════════════════════ */

.sp-grid-executive {
  display: grid;
  grid-template-columns: repeat(2, 1fr);

  gap: 12px 48px;

  max-width: 1100px;
  margin: 0 auto;
}

.sp-card-executive {
  display: flex;
  align-items: center;
  justify-content: center;

  min-height: 110px;
  padding: 8px 12px;

  overflow: hidden;

  transition:
    transform 0.3s var(--ease-expo),
    opacity 0.4s var(--ease-expo);

  opacity: 0;
  transform: translateY(16px);
}

.sp-card-executive.visible {
  opacity: 1;
  transform: translateY(0);
}

.sp-card-executive:hover {
  transform: translateY(-3px) scale(1.015);
}

.sp-card-exec-logo {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 100%;
  height: 100%;
}

.sp-card-exec-logo a {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 100%;
  text-decoration: none;
}

.sp-card-exec-logo img {
  width: 100%;
  max-width: 320px;
  max-height: 110px;

  object-fit: contain;
}

.sp-card-exec-body,
.sp-card-exec-name,
.sp-card-exec-desc,
.sp-card-exec-link {
  display: none;
}

/* ═══════════════════════════════════════════════════════════════
   PLATINUM
═══════════════════════════════════════════════════════════════ */

.sp-grid-platinum {
  display: grid;
  grid-template-columns: repeat(3, 1fr);

  gap: 10px 40px;

  max-width: 1200px;
  margin: 0 auto;
}

.sp-card-platinum {
  height: 120px;
  padding: 10px;

  display: flex;
  align-items: center;
  justify-content: center;

  position: relative;
  overflow: hidden;

  transition:
    transform 0.3s var(--ease-expo),
    opacity 0.4s var(--ease-expo);

  opacity: 0;
  transform: translateY(16px);
}

.sp-card-platinum.visible {
  opacity: 1;
  transform: translateY(0);
}

.sp-card-platinum:hover {
  transform: translateY(-3px);
}

.sp-card-platinum a {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 100%;
  height: 100%;

  text-decoration: none;
}

.sp-card-platinum img {
  width: 100%;
  max-width: 180px;
  max-height: 70px;

  object-fit: contain;
}

/* ═══════════════════════════════════════════════════════════════
   GOLD
═══════════════════════════════════════════════════════════════ */

.sp-grid-gold {
  display: grid;
  grid-template-columns: repeat(4, max-content);

  justify-content: center;
  justify-items: center;

  gap: 64px 128px;

  max-width: 1100px;
  margin: 0 auto;
}

.sp-card-gold {
  height: 90px;

  display: flex;
  align-items: center;
  justify-content: center;

  opacity: 0;
  transform: translateY(16px);

  transition:
    transform 0.3s var(--ease-expo),
    opacity 0.4s var(--ease-expo);
}

.sp-card-gold.visible {
  opacity: 1;
  transform: translateY(0);
}

.sp-card-gold:hover {
  transform: translateY(-2px);
}

.sp-card-gold a {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 100%;
  height: 100%;
}

.sp-card-gold img {
  width: 100%;
  max-width: 160px;
  max-height: 160px;

  object-fit: contain;
}

/* ═══════════════════════════════════════════════════════════════
   SILVER
═══════════════════════════════════════════════════════════════ */

.sp-grid-silver {
  display: grid;
  grid-template-columns: repeat(5, max-content);

  justify-content: center;
  justify-items: center;

  gap: 128px 128px;

  max-width: 1100px;
  margin: 0 auto;
}

.sp-card-silver {
  height: 70px;

  display: flex;
  align-items: center;
  justify-content: center;

  opacity: 0;
  transform: translateY(16px);

  transition:
    transform 0.3s var(--ease-expo),
    opacity 0.4s var(--ease-expo);
}

.sp-card-silver.visible {
  opacity: 1;
  transform: translateY(0);
}

.sp-card-silver:hover {
  transform: translateY(-2px);
}

.sp-card-silver a {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 100%;
  height: 100%;
}

.sp-card-silver img {
  width: 100%;
  max-width: 120px;
  max-height: 90px;

  object-fit: contain;
}

/* ═══════════════════════════════════════════════════════════════
   TECHNICAL
═══════════════════════════════════════════════════════════════ */

.sp-grid-technical {
  display: grid;
  grid-template-columns: repeat(6, 1fr);

  gap: 8px 18px;

  max-width: 1200px;
  margin: 0 auto;
}

.sp-card-technical {
  height: 120px;

  display: flex;
  align-items: center;
  justify-content: center;

  opacity: 0;
  transform: translateY(12px);

  transition:
    transform 0.25s var(--ease-expo),
    opacity 0.35s var(--ease-expo);
}

.sp-card-technical.visible {
  opacity: 1;
  transform: translateY(0);
}

.sp-card-technical:hover {
  transform: translateY(-2px);
}

.sp-card-technical a {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 100%;
  height: 100%;
}

.sp-card-technical img {
  width: 100%;
  max-width: 120px;
  max-height: 90px;

  object-fit: contain;
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════════ */

@media (max-width: 1100px) {

  .sp-grid-platinum {
    grid-template-columns: repeat(2, 1fr);
  }

  .sp-grid-gold {
    grid-template-columns: repeat(3, 1fr);
  }

  .sp-grid-silver {
    grid-template-columns: repeat(4, 1fr);
  }

  .sp-grid-technical {
    grid-template-columns: repeat(5, 1fr);
  }
}

@media (max-width: 768px) {

  .sp-grid-executive {
    grid-template-columns: 1fr;
  }

  .sp-grid-platinum {
    grid-template-columns: repeat(2, 1fr);
  }

  .sp-grid-gold {
    grid-template-columns: repeat(2, 1fr);
  }

  .sp-grid-silver {
    grid-template-columns: repeat(3, 1fr);
  }

  .sp-grid-technical {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 520px) {

  .sp-grid-platinum,
  .sp-grid-gold,
  .sp-grid-silver {
    grid-template-columns: repeat(2, 1fr);
  }

  .sp-grid-technical {
    grid-template-columns: repeat(3, 1fr);
  }

  .sp-tier-section {
    padding: 32px 5%;
  }
}