/* Eastport Racing — main stylesheet */

:root {
  --bg: #0a0c0f;
  --surface: #12151b;
  --surface-2: #191d25;
  --text: #eef1f4;
  --muted: #9aa3ad;
  --accent: #e10600;
  --accent-2: #ff2b1f;
  --line: rgba(255, 255, 255, 0.08);
  --radius: 14px;
  --maxw: 1120px;
  --header-h: 68px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img,
svg {
  display: block;
  max-width: 100%;
}

.container {
  width: min(var(--maxw), 100% - 2.5rem);
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--accent);
  color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: 0 0 8px 0;
  text-decoration: none;
  font-weight: 600;
}

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

:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 12, 15, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease;
}

.site-header.scrolled {
  border-bottom-color: var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
  font-style: italic;
  letter-spacing: 0.02em;
  font-size: 1.15rem;
  white-space: nowrap;
}

.brand em {
  color: var(--accent-2);
}

.brand svg {
  width: 30px;
  height: 30px;
  flex: none;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-menu a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-menu a:hover {
  color: var(--text);
}

.nav-menu .btn {
  color: #fff;
}

.nav-menu .btn:hover {
  color: #fff;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: 0;
  padding: 10px;
  cursor: pointer;
}

.nav-toggle-bar {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(4) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 0.85rem 1.9rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.98rem;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  background: var(--accent-2);
  transform: translateY(-2px);
}

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

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--muted);
}

.btn-small {
  padding: 0.5rem 1.2rem;
  font-size: 0.88rem;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  padding: 5rem 0 4rem;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(60% 50% at 72% 18%, rgba(225, 6, 0, 0.18), transparent 70%),
    radial-gradient(50% 40% at 18% 85%, rgba(225, 6, 0, 0.08), transparent 70%);
  pointer-events: none;
}

.hero .container {
  position: relative;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-2);
  margin: 0 0 1.25rem;
}

.hero-kicker::before {
  content: "";
  width: 34px;
  height: 2px;
  background: var(--accent);
}

.hero h1 {
  margin: 0 0 1.25rem;
  font-size: clamp(2.6rem, 6vw + 1rem, 5.25rem);
  line-height: 1.02;
  font-weight: 800;
  letter-spacing: -0.025em;
}

.hero h1 em {
  font-style: italic;
  color: var(--accent-2);
}

.hero-lede {
  color: var(--muted);
  font-size: clamp(1.05rem, 1.5vw, 1.3rem);
  max-width: 52ch;
  margin: 0 0 2.25rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.checker-strip {
  height: 14px;
  margin-top: 4.5rem;
  background-image: repeating-conic-gradient(
    rgba(255, 255, 255, 0.16) 0% 25%,
    transparent 0% 50%
  );
  background-size: 28px 28px;
  mask-image: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent);
}

/* ---------- Sections ---------- */

.section {
  padding: 5rem 0;
}

.section-alt {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

.section h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.section-sub {
  color: var(--muted);
  margin: 0 0 2.5rem;
  max-width: 60ch;
}

/* ---------- Cards ---------- */

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

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.section-alt .card {
  background: var(--surface-2);
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(225, 6, 0, 0.45);
}

.card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.2rem;
  letter-spacing: -0.01em;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.97rem;
}

.card-num {
  display: block;
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--accent-2);
  letter-spacing: 0.12em;
  margin-bottom: 1rem;
}

.card-placeholder {
  border-style: dashed;
}

.placeholder-tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-2);
  border: 1px solid rgba(225, 6, 0, 0.4);
  border-radius: 999px;
  padding: 0.25rem 0.6rem;
  margin-bottom: 1rem;
}

/* ---------- Testimonials ---------- */

figure.card {
  margin: 0;
}

figure.card blockquote {
  margin: 0 0 1rem;
  font-size: 1.02rem;
  font-style: italic;
  color: var(--text);
}

figure.card figcaption {
  color: var(--muted);
  font-size: 0.9rem;
}

/* ---------- Contact ---------- */

.contact-card {
  margin: 0;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem;
  display: grid;
  gap: 1.4rem;
  font-style: normal;
  max-width: 560px;
}

.contact-row {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.contact-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
  font-weight: 700;
}

.contact-value {
  font-size: 1.15rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.contact-value a {
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.25);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.contact-value a:hover {
  color: var(--accent-2);
  border-color: var(--accent-2);
}

.noscript-note {
  color: var(--muted);
  font-size: 0.95rem;
}

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.site-footer .container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  justify-content: space-between;
  align-items: center;
}

.site-footer p {
  margin: 0;
}

.footer-tag {
  font-style: italic;
}

/* ---------- 404 ---------- */

.notfound {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 6rem 0;
}

.nf-code {
  font-size: clamp(4rem, 12vw, 7rem);
  font-weight: 800;
  line-height: 1;
  color: var(--accent-2);
  margin: 0;
}

.notfound h1 {
  margin: 0;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
}

.notfound p {
  color: var(--muted);
  margin: 0 0 1rem;
}

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

@media (max-width: 720px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav-menu {
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    padding: 0.5rem 1.25rem 1rem;
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.25s ease, opacity 0.25s ease, visibility 0.25s;
  }

  .nav-menu.open {
    transform: none;
    opacity: 1;
    visibility: visible;
  }

  .nav-menu li {
    border-bottom: 1px solid var(--line);
  }

  .nav-menu li:last-child {
    border-bottom: 0;
  }

  .nav-menu a {
    display: block;
    padding: 0.9rem 0;
    font-size: 1.05rem;
  }

  .nav-menu .btn {
    display: inline-block;
    padding: 0.7rem 1.4rem;
    margin-top: 0.5rem;
  }

  .hero {
    padding: 3.5rem 0 3rem;
  }

  .checker-strip {
    margin-top: 3rem;
  }

  .section {
    padding: 3.5rem 0;
  }

  .contact-card {
    padding: 1.5rem;
  }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}
