/* Nelson Bay E-Bikes — site styles. Tokens match Brand/brand-tokens.css. */
:root {
  --deep: #0E3B4C;
  --teal: #167A8C;
  --orange: #F58A2A;
  --orange-dark: #D8731B;
  --sand: #E6DCC8;
  --mist: #F4F6F5;
  --white: #FFFFFF;
  --ink: #1B2426;
  --slate: #3A4648;
  --rule: #D7DEDD;
  --teal-tint: #9CC9D3;

  --font-display: 'Sora', 'Segoe UI', Arial, sans-serif;
  --font-body: 'Nunito Sans', 'Segoe UI', Arial, sans-serif;

  --radius-card: 12px;
  --radius-button: 6px;
  --measure: 62ch;
  --gutter: max(20px, 4vw);
  --wrap: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
}

img, svg { max-width: 100%; display: block; }
img { height: auto; } /* width/height attributes reserve space but must never stretch the picture */
a { color: var(--teal); }
a:hover { color: var(--deep); }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; }

h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--deep);
  line-height: 1.1;
  margin: 0;
  text-wrap: balance;
}
h1 { font-size: clamp(40px, 6vw, 64px); font-weight: 800; letter-spacing: -0.02em; line-height: 1; }
h2 { font-size: clamp(28px, 3.6vw, 40px); font-weight: 700; letter-spacing: -0.01em; }
h3 { font-size: 22px; font-weight: 600; line-height: 1.3; }
p { margin: 0; max-width: var(--measure); }
ul { margin: 0; padding: 0; list-style: none; }

.label {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--teal);
}
.on-dark .label { color: var(--teal-tint); }
.muted { color: var(--slate); }
.small { font-size: 15px; line-height: 1.55; }
.tabular { font-variant-numeric: tabular-nums; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.stack { display: flex; flex-direction: column; gap: 16px; }
.stack-lg { display: flex; flex-direction: column; gap: 28px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: var(--radius-button);
  border: 2px solid transparent;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 120ms ease, color 120ms ease, border-color 120ms ease;
}
.btn-primary { background: var(--orange); color: var(--ink); }
.btn-primary:hover { background: var(--orange-dark); color: var(--ink); }
.btn-secondary { background: transparent; color: var(--deep); border-color: var(--deep); }
.btn-secondary:hover { background: var(--deep); color: var(--mist); }
.on-dark .btn-secondary { color: var(--mist); border-color: var(--mist); }
.on-dark .btn-secondary:hover { background: var(--mist); color: var(--deep); }
.btn[disabled], .btn[aria-busy="true"] { opacity: 0.6; cursor: wait; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--white);
  border-bottom: 1px solid var(--rule);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  min-height: 72px;
  padding-block: 10px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand svg { width: 38px; height: 38px; flex: none; }
.brand-words { display: flex; flex-direction: column; line-height: 1; }
.brand-words .label { font-size: 9px; letter-spacing: 0.22em; }
.brand-words strong {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--deep);
}
.site-nav { display: flex; align-items: center; gap: 6px 18px; flex-wrap: wrap; }
.site-nav a {
  color: var(--deep);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  padding: 8px 4px;
}
.site-nav a:hover { color: var(--teal); }
.site-nav .btn { min-height: 42px; padding: 8px 16px; font-size: 14px; }

/* Hero */
.hero {
  background: var(--deep);
  color: var(--mist);
}
.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
  padding-block: clamp(48px, 8vw, 96px);
}
.hero h1 { color: var(--mist); }
.hero .tagline { color: var(--orange); font-family: var(--font-display); font-size: clamp(22px, 2.6vw, 30px); font-weight: 500; }
.hero p { color: #C9DEE3; font-size: 18px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Photo placeholders: replace with <img> once photos arrive */
.photo {
  position: relative;
  width: 100%;
  max-width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-card);
  background: repeating-linear-gradient(135deg, var(--sand) 0 14px, #DCD0B8 14px 28px);
  display: flex;
  align-items: flex-end;
  padding: 14px 16px;
  overflow: hidden;
}
.photo.wide { aspect-ratio: 16 / 9; }
.photo.square { aspect-ratio: 1 / 1; }
.photo span {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--deep);
  background: rgba(255,255,255,0.88);
  padding: 6px 10px;
  border-radius: 4px;
}

/* Product photos (supplier images on white, so they sit in a white frame) */
.photo-img {
  width: 100%;
  max-width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--white);
  border-radius: var(--radius-card);
  border: 1px solid var(--rule);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  box-sizing: border-box;
}
.photo-img img { width: 100%; height: 100%; object-fit: contain; }
.photo-img.square { aspect-ratio: 1 / 1; }
.hero .photo-img { border: 0; }
.model-card .photo-img { border-radius: 0; border: 0; border-bottom: 1px solid var(--rule); }
.photo-credit { font-size: 13px; color: var(--slate); }

.option-list { display: grid; gap: 12px; }
.option-list li { display: grid; gap: 2px; }
.option-list strong { color: var(--deep); }

/* Sections */
.section { padding-block: clamp(48px, 7vw, 88px); }
.section-head {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 36px;
}
.section-sand { background: var(--sand); }
.section-white { background: var(--white); }
.section-deep { background: var(--deep); color: var(--mist); }
.section-deep h2, .section-deep h3 { color: var(--mist); }
.section-deep p { color: #C9DEE3; }

/* Model cards */
.models {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
}
.model-card {
  background: var(--white);
  border: 1px solid var(--rule);
  border-radius: var(--radius-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.model-card .photo { border-radius: 0; }
.model-card .body { padding: 24px 28px 28px; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.badge { display: flex; flex-direction: column; }
.badge .label { font-size: 13px; letter-spacing: 0.26em; }
.badge strong {
  font-family: var(--font-display);
  font-size: 44px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--deep);
}
.price { font-family: var(--font-display); font-size: 20px; font-weight: 600; color: var(--deep); }
.price small { font-family: var(--font-body); font-size: 14px; font-weight: 400; color: var(--slate); margin-left: 6px; }
.card-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: auto; padding-top: 8px; }

/* Feature grid */
.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}
.feature { display: flex; flex-direction: column; gap: 10px; }
.feature svg { width: 40px; height: 40px; color: var(--teal); }
.section-deep .feature svg { color: var(--orange); }

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 36px;
  align-items: start;
}
.contact-list { display: grid; grid-template-columns: auto 1fr; gap: 10px 20px; }
.contact-list dt { font-weight: 700; color: var(--deep); }
.contact-list dd { margin: 0; }
.hours { display: grid; grid-template-columns: auto 1fr; gap: 6px 20px; }

/* Product page */
.product-hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
  padding-block: clamp(40px, 6vw, 72px);
}
.product-hero .badge strong { font-size: clamp(56px, 8vw, 88px); }
.buy-box {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 22px 24px;
  background: var(--white);
  border: 1px solid var(--rule);
  border-radius: var(--radius-card);
}
.buy-box .price { font-size: 30px; }
.pay-methods { display: flex; flex-wrap: wrap; gap: 8px; }
.pay-methods li {
  font-size: 13px;
  font-weight: 600;
  color: var(--deep);
  background: var(--mist);
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 4px 10px;
}
.checkout-error {
  color: #8A2E0B;
  background: #FDEBDD;
  border-radius: 6px;
  padding: 10px 12px;
  font-size: 15px;
}
.checkout-error:empty { display: none; }

.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.spec-table-wrap { overflow-x: auto; }
.spec-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border: 1px solid var(--rule);
  border-radius: var(--radius-card);
  overflow: hidden;
}
.spec-table th, .spec-table td {
  text-align: left;
  padding: 14px 18px;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: 0; }
.spec-table th { width: 32%; font-weight: 700; color: var(--deep); background: var(--mist); }
.spec-table td { color: var(--slate); }

.checklist { display: grid; gap: 10px; }
.checklist li { display: flex; gap: 12px; align-items: flex-start; }
.checklist svg { width: 22px; height: 22px; flex: none; color: var(--teal); margin-top: 3px; }

.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px;
  align-items: start;
}

/* Footer */
.site-footer {
  background: var(--deep);
  color: #C9DEE3;
  padding-block: 48px 32px;
}
.site-footer .wrap {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 36px;
}
.site-footer a { color: var(--mist); text-decoration: none; }
.site-footer a:hover { color: var(--orange); }
.site-footer .label { color: var(--teal-tint); margin-bottom: 10px; }
.site-footer ul { display: grid; gap: 8px; }
.footer-bottom {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(244,246,245,0.18);
  font-size: 14px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
}

/* Responsive */
@media (max-width: 900px) {
  .hero .wrap, .product-hero .wrap, .contact-grid, .two-col { grid-template-columns: 1fr; gap: 32px; }
  .features { grid-template-columns: 1fr; }
  .site-footer .wrap { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .models, .gallery { grid-template-columns: 1fr; }
  .site-nav a:not(.btn) { padding: 6px 2px; }
  .site-nav .btn { display: none; } /* the page's own Buy / Shop buttons are a swipe away on a phone */
  .site-header .wrap { min-height: 60px; }
}
