:root {
  --bg: #ffffff;
  --bg-alt: #f4f4f6;
  --text: #121318;
  --text-dim: #5c5f68;
  --accent: #e2231a;
  --accent-dim: #ff4136;
  --card: #ffffff;
  --border: #e3e4e8;
  --radius: 10px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
}

h1, h2, h3, h4 {
  font-weight: 800;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
}

a { color: inherit; text-decoration: none; }

.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.btn:hover { transform: translateY(-1px); opacity: 0.92; }

.btn-primary { background: var(--accent); color: #fff; }
.btn-secondary { background: transparent; color: var(--text); border: 1px solid var(--border); }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  font-size: 1.1rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.logo span { color: var(--accent); }
.logo-mark { flex-shrink: 0; height: 40px; width: auto; }
.main-nav {
  display: flex;
  gap: 24px;
  margin-left: auto;
  font-weight: 600;
  font-size: 0.9rem;
}
.main-nav a { color: var(--text-dim); }
.main-nav a:hover { color: var(--text); }
.call-btn {
  background: var(--accent);
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.85rem;
  white-space: nowrap;
}
.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  font-size: 1.4rem;
  cursor: pointer;
}

/* Hero */
.hero {
  position: relative;
  padding: 110px 24px 90px;
  text-align: center;
  overflow: hidden;
  background:
    radial-gradient(ellipse at top, rgba(226,35,26,0.08), transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-alt) 100%);
}
.hero-inner { max-width: 720px; margin: 0 auto; position: relative; }
.hero-mark { width: 220px; height: auto; margin-bottom: 18px; }
.eyebrow {
  color: var(--accent-dim);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-weight: 700;
  font-size: 0.8rem;
}
.hero h1 { font-size: clamp(2.4rem, 6vw, 4rem); margin: 12px 0 18px; }
.hero-sub { color: var(--text-dim); font-size: 1.1rem; margin-bottom: 32px; }

.hero-photo {
  padding: 150px 24px 110px;
  background:
    linear-gradient(180deg, rgba(10,11,14,0.78) 0%, rgba(10,11,14,0.55) 55%, rgba(10,11,14,0.85) 100%),
    url('assets/hero/hero.jpg') center/cover no-repeat;
}
.hero-photo .eyebrow { color: #ffb3af; }
.hero-photo h1, .hero-photo .hero-sub { color: #fff; }
.hero-photo .hero-sub { color: rgba(255,255,255,0.85); }
.hero-logo-watermark {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(620px, 70vw);
  opacity: 0.14;
  pointer-events: none;
}

/* Features */
.features {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 24px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.feature {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.feature h3 { font-size: 1.05rem; }
.feature p { color: var(--text-dim); font-size: 0.92rem; margin: 0; }

/* Sections */
.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 24px;
  text-align: center;
}
.section h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.section-sub { color: var(--text-dim); max-width: 560px; margin: 0 auto 40px; }

/* Cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  text-align: left;
}
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.card-art {
  aspect-ratio: 3 / 2;
  border-radius: 8px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--accent) 0%, #241417 100%);
}
.card-art-2 { background: linear-gradient(135deg, #3a7d44 0%, #15201a 100%); }
.card-art-3 { background: linear-gradient(135deg, #2a6fb0 0%, #121a24 100%); }
.card-art img { width: 92px; height: 92px; filter: drop-shadow(0 4px 10px rgba(0,0,0,0.4)); }
.card-art.has-photo { overflow: hidden; }
.card-art.has-photo img { width: 100%; height: 100%; object-fit: cover; filter: none; }
.card h3 { font-size: 1.05rem; }
.card p { color: var(--text-dim); font-size: 0.9rem; }
.link-cta { color: var(--accent-dim); font-weight: 700; font-size: 0.88rem; }

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.gallery-tile {
  aspect-ratio: 4/3;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: repeating-linear-gradient(45deg, #f4f4f6, #f4f4f6 10px, #ebebee 10px, #ebebee 20px);
}
.tile-1, .tile-4 { background-color: rgba(226,35,26,0.08); }
.tile-2, .tile-5 { background-color: rgba(42,111,176,0.08); }
.tile-3, .tile-6 { background-color: rgba(58,125,68,0.08); }
.gallery-tile img { width: 100%; height: 100%; object-fit: cover; }
.gallery-tile.placeholder img { width: 64%; height: 64%; object-fit: contain; filter: drop-shadow(0 6px 14px rgba(0,0,0,0.25)); }

/* Brands */
.brand-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 48px;
}
.brand-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 26px;
  height: 84px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.brand-chip img {
  max-height: 46px;
  max-width: 170px;
  width: auto;
  height: auto;
  object-fit: contain;
}
.brands-note { color: var(--text-dim); font-size: 0.85rem; margin-top: -24px; }

/* Visualizer */
.visualizer-section { text-align: left; }
.visualizer-section h2, .visualizer-section > .section-sub { text-align: center; }
.viz-picker {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: flex-end;
  max-width: 780px;
  margin: 0 auto 14px;
}
.viz-picker .field { flex: 1 1 160px; }
.viz-picker label { display: block; font-size: 0.8rem; color: var(--text-dim); margin-bottom: 6px; }
.viz-picker select {
  width: 100%; font: inherit; padding: 12px 14px; border-radius: 8px;
  border: 1px solid var(--border); background: var(--card); color: var(--text);
}
.viz-picker select:disabled { opacity: 0.5; }
.viz-status {
  max-width: 780px;
  margin: 0 auto 20px;
  color: var(--text-dim);
  font-size: 0.9rem;
}
.viz-status.ok { color: #1f7a4d; font-weight: 600; }
.viz-status.err { color: var(--accent); font-weight: 600; }
.viz-status.load { color: var(--text-dim); font-style: italic; }
.viz-stage {
  position: relative;
  max-width: 1000px;
  margin: 0 auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
}
.viz-stage .vvse { width: 100%; min-height: 420px; }
/* Same footprint as the render area (vvse height: 60vh), whole photo visible. */
.viz-splash {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 60vh;
  object-fit: contain;
  background: #fff;
  z-index: 5;
  pointer-events: none;
}
.viz-splash.hide { display: none; }
.viz-wheels { max-width: 1000px; margin: 28px auto 0; }
.viz-wheels h3 { font-size: 1.1rem; margin-bottom: 14px; }
.wheel-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.wcard {
  position: relative;
  display: block;
  width: 100%;
  font: inherit;
  color: var(--text);
  text-align: center;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 12px 12px;
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.1s, transform 0.1s;
}
.wcard:hover { border-color: var(--accent); transform: translateY(-1px); }
.wcard.active { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
/* Every line in the card has a fixed height so images and text line up
   across a row no matter what the wheel's data looks like. */
.wcard { height: 100%; display: flex; flex-direction: column; }
.wcard .band {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  margin: 0 -12px;
  padding: 0 10px;
  font-weight: 800;
  font-size: 1rem;
  white-space: nowrap;
  overflow: hidden;
  color: #fff;
  background: var(--text);
}
.wcard .band.plus { background: var(--accent); }
.wcard .band em {
  margin-left: auto;
  font-style: normal;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.9;
}
.wcard .off {
  height: 22px;
  line-height: 22px;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-dim);
}
.wcard img { width: 100%; height: 130px; object-fit: contain; flex-shrink: 0; }
.wcard .nm {
  font-weight: 600;
  font-size: 0.85rem;
  line-height: 1.25;
  height: 2.5em;
  margin-top: 6px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.wcard .fin, .wcard .pn {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.wcard .fin { color: var(--text-dim); font-size: 0.72rem; height: 1.3em; margin-top: 2px; }
.wcard .pn { color: var(--text-dim); font-size: 0.68rem; height: 1.3em; margin-top: 4px; }
.wheel-more { text-align: center; margin-top: 16px; }
@media (max-width: 860px) { .viz-splash { height: 38vh; } }
.viz-fallback {
  max-width: 1000px;
  margin: 20px auto 0;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--card); padding: 24px; text-align: left;
}
.viz-fallback h3 { margin-top: 0; }
.viz-fallback p { color: var(--text-dim); }
.viz-note { color: var(--text-dim); font-size: 0.85rem; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Financing */
.financing-section { background: var(--bg-alt); border-radius: var(--radius); }

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  text-align: center;
  margin-top: 20px;
}
.contact-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.contact-card h3 { font-size: 0.95rem; color: var(--accent-dim); text-transform: uppercase; letter-spacing: 0.08em; }
.contact-card p { color: var(--text-dim); margin: 0; }
.contact-card a { color: var(--text); font-weight: 600; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 60px 24px 24px;
}
.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}
.footer-grid h4 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); }
.footer-grid a { display: block; color: var(--text-dim); padding: 4px 0; font-size: 0.9rem; }
.footer-grid a:hover { color: var(--text); }
.footer-bottom {
  max-width: 1200px;
  margin: 40px auto 0;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 0.82rem;
  text-align: center;
}

/* Responsive */
@media (max-width: 860px) {
  .main-nav { display: none; }
  .nav-toggle { display: block; margin-left: auto; }
  .call-btn { display: none; }
  .features { grid-template-columns: 1fr; }
  .card-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }

  .main-nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-alt);
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
  }
}
