/* ==========================================================================
   AC International Motors LLC — Editorial Magazine design system
   Shared across every page. Colors and type pulled from the brand blueprint.
   ========================================================================== */

:root {
  --black: #0a0a0a;
  --white: #ffffff;
  --red: #e30613;
  --red-dark: #b8050f;
  --gray: #6e6e6e;
  --gray-light: #f2f2f2;
  --gray-border: #e2e2e2;

  --font-display: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1240px;
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2.5rem;
  --space-5: 4rem;
  --space-6: 6rem;
  --space-7: 9rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--black);
  background: var(--white);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, .serif {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.08;
  margin: 0;
  letter-spacing: -0.01em;
}

p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}
@media (min-width: 768px) {
  .container { padding: 0 2.5rem; }
}

/* Skip link */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--red);
  color: var(--white);
  padding: 0.75rem 1.25rem;
  z-index: 200;
  font-weight: 600;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

/* Focus states — WCAG AA visible focus */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 2px;
}

/* ==========================================================================
   Nav
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--gray-border);
}
.site-header.on-dark {
  background: rgba(10, 10, 10, 0.9);
  border-bottom: 1px solid rgba(255,255,255,0.12);
  color: var(--white);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 0;
}
.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.logo .mark { display: inline-flex; gap: 3px; }
.logo .mark span {
  display: inline-block;
  width: 7px;
  height: 22px;
  background: var(--red);
  transform: skewX(-18deg);
}
.logo .intl { color: var(--black); }
.site-header.on-dark .logo .intl { color: var(--white); }
.logo .motors { color: var(--red); }

.nav-links {
  display: none;
  align-items: center;
  gap: 2.1rem;
  font-size: 0.92rem;
  font-weight: 500;
}
.nav-links a {
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
}
.nav-links a:hover,
.nav-links a[aria-current="page"] {
  border-bottom-color: var(--red);
}
@media (min-width: 900px) {
  .nav-links { display: flex; }
  .nav-cta { display: inline-flex !important; }
  .nav-toggle { display: none !important; }
}

.nav-cta {
  display: none;
  background: var(--red);
  color: var(--white);
  padding: 0.65rem 1.3rem;
  font-size: 0.88rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  white-space: nowrap;
}
.nav-cta:hover { background: var(--red-dark); }

.nav-toggle {
  background: none;
  border: 1px solid currentColor;
  width: 42px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: inherit;
}
.nav-toggle svg { width: 20px; height: 20px; }

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.5rem 0 1.5rem;
  border-top: 1px solid var(--gray-border);
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  padding: 0.85rem 0;
  font-size: 1rem;
  font-weight: 500;
  border-bottom: 1px solid var(--gray-border);
}
.mobile-menu .nav-cta { display: inline-flex; margin-top: 0.75rem; text-align: center; justify-content: center; }
@media (min-width: 900px) { .mobile-menu { display: none !important; } }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.95rem 1.9rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}
.btn-primary { background: var(--red); color: var(--white); }
.btn-primary:hover { background: var(--red-dark); }
.btn-outline-light { border-color: var(--white); color: var(--white); }
.btn-outline-light:hover { background: var(--white); color: var(--black); }
.btn-outline-dark { border-color: var(--black); color: var(--black); }
.btn-outline-dark:hover { background: var(--black); color: var(--white); }
.btn-text { font-weight: 600; border-bottom: 2px solid var(--red); padding: 0.2rem 0; }

/* ==========================================================================
   Type utilities
   ========================================================================== */
.eyebrow {
  display: inline-block;
  color: var(--red);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.h1 { font-size: clamp(2.4rem, 6vw, 5.4rem); }
.h2 { font-size: clamp(1.9rem, 4vw, 3rem); }
.h3 { font-size: clamp(1.3rem, 2.4vw, 1.7rem); }
.lede {
  font-size: 1.15rem;
  color: var(--gray);
  max-width: 46ch;
}
.rule {
  width: 64px;
  height: 3px;
  background: var(--red);
  border: none;
  margin: 0 0 1.5rem;
}
.rule.center { margin-inline: auto; }

/* ==========================================================================
   Sections
   ========================================================================== */
section { padding: var(--space-6) 0; }
.section-tight { padding: var(--space-5) 0; }
.section-dark { background: var(--black); color: var(--white); }
.section-red { background: var(--red); color: var(--black); }
.section-gray { background: var(--gray-light); }

.pull-quote {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2.6vw, 2.15rem);
  line-height: 1.4;
  max-width: 30ch;
  margin: 0 auto;
  text-align: center;
  text-wrap: balance;
}
@media (min-width: 768px) {
  .pull-quote { max-width: 62ch; }
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: flex-end;
  color: var(--white);
  background: linear-gradient(180deg, rgba(10,10,10,0.15) 0%, rgba(10,10,10,0.75) 100%), var(--black) center/cover no-repeat;
}
.hero-inner { width: 100%; max-width: none; margin: 0; padding-top: var(--space-6); padding-bottom: var(--space-5); padding-left: clamp(1.25rem, 4vw, 5rem); padding-right: clamp(1.25rem, 4vw, 5rem); text-align: left; }
.hero-inner .h1 { font-size: clamp(2.2rem, 5vw, 4.6rem); max-width: 17em; line-height: 1.22; }
.hero-inner .lede { max-width: 44ch; margin-left: 0; }
.hero .lede { color: rgba(255,255,255,0.82); }
.page-hero {
  padding: var(--space-6) 0 var(--space-5);
  border-bottom: 1px solid var(--gray-border);
}

/* ==========================================================================
   Grid / cards
   ========================================================================== */
.grid {
  display: grid;
  gap: var(--space-4);
}
@media (min-width: 768px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

.feature-card { display: flex; flex-direction: column; gap: 1rem; }
.feature-card img { aspect-ratio: 4/5; object-fit: cover; width: 100%; height: auto; background: var(--gray-light); }
.lot-tag {
  display: inline-block;
  background: var(--red);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 0.3rem 0.6rem;
  width: fit-content;
}
.status-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.3rem 0.65rem;
  border: 1px solid currentColor;
  width: fit-content;
}
.status-available { color: #0a7a3d; border-color: #0a7a3d; }
.status-reserved { color: var(--gray); border-color: var(--gray); }

.numeral {
  font-family: var(--font-display);
  font-size: 3.2rem;
  color: var(--red);
  line-height: 1;
}

.stage {
  display: grid;
  gap: var(--space-4);
  align-items: center;
  padding: var(--space-5) 0;
  border-bottom: 1px solid var(--gray-border);
}
@media (min-width: 860px) {
  .stage { grid-template-columns: 1fr 1fr; }
  .stage.reverse .stage-media { order: 2; }
}
.stage-media img { width: 100%; height: auto; aspect-ratio: 4/5; object-fit: cover; background: var(--gray-light); }

/* Any image sized by an inline aspect-ratio must ignore its height attribute,
   otherwise the width/height attrs override aspect-ratio and stretch the box. */
img[style*="aspect-ratio"] { height: auto; }

/* ==========================================================================
   Forms
   ========================================================================== */
label {
  display: block;
  font-weight: 600;
  font-size: 0.88rem;
  margin-bottom: 0.4rem;
}
.field { margin-bottom: 1.3rem; }
input, textarea, select {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--gray-border);
  background: var(--white);
  color: var(--black);
}
input:focus, textarea:focus, select:focus { border-color: var(--red); }
.required::after { content: " *"; color: var(--red); }
.field-hint { font-size: 0.82rem; color: var(--gray); margin-top: 0.35rem; }

/* ==========================================================================
   Accordion (FAQ, legal TOC use plain anchors)
   ========================================================================== */
.accordion-item { border-bottom: 1px solid var(--gray-border); }
.accordion-trigger {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 1.4rem 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.05rem;
  cursor: pointer;
  color: var(--black);
}
.accordion-trigger .plus { flex-shrink: 0; font-size: 1.3rem; color: var(--red); transition: transform 0.2s ease; }
.accordion-trigger[aria-expanded="true"] .plus { transform: rotate(45deg); }
.accordion-panel {
  display: none;
  padding: 0 0 1.5rem;
  color: var(--gray);
  max-width: 68ch;
}
.accordion-panel.open { display: block; }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { background: var(--black); color: rgba(255,255,255,0.75); padding: var(--space-6) 0 var(--space-3); }
.footer-grid {
  display: grid;
  gap: var(--space-4);
  padding-bottom: var(--space-5);
  border-bottom: 1px solid rgba(255,255,255,0.14);
}
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
}
.footer-grid h4 {
  color: var(--white);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 1.1rem;
}
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.7rem; }
.footer-grid a:hover { color: var(--white); }
.footer-bottom {
  padding-top: var(--space-3);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  font-size: 0.82rem;
}
.footer-bottom ul { list-style: none; display: flex; flex-wrap: wrap; gap: 1.3rem; margin: 0; padding: 0; }

/* ==========================================================================
   Legal pages
   ========================================================================== */
.legal-layout { display: grid; gap: var(--space-4); }
@media (min-width: 900px) {
  .legal-layout { grid-template-columns: 260px 1fr; align-items: start; }
}
.toc {
  position: sticky;
  top: 100px;
  border-left: 2px solid var(--gray-border);
  padding-left: 1.2rem;
}
.toc a { display: block; padding: 0.4rem 0; color: var(--gray); font-size: 0.9rem; }
.toc a:hover { color: var(--red); }
.legal-body { max-width: 72ch; }
.legal-body h2 { font-size: 1.4rem; margin-top: var(--space-5); scroll-margin-top: 100px; }
.legal-body h2:first-child { margin-top: 0; }
.legal-body p, .legal-body li { color: var(--gray); font-size: 1rem; line-height: 1.7; }
.legal-body table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; }
.legal-body th, .legal-body td { border: 1px solid var(--gray-border); padding: 0.7rem; text-align: left; font-size: 0.92rem; }
.notice-box {
  background: var(--gray-light);
  border-left: 3px solid var(--red);
  padding: 1.2rem 1.4rem;
  margin-bottom: var(--space-5);
  font-size: 0.95rem;
}
.entity-table td:first-child { color: var(--black); font-weight: 600; width: 40%; }

/* ==========================================================================
   Misc utilities
   ========================================================================== */
/* ==========================================================================
   Image placeholders — until real photography / Higgsfield renders are dropped in
   ========================================================================== */
.ph {
  position: relative;
  background:
    repeating-linear-gradient(-18deg, rgba(227,6,19,0.16) 0 2px, transparent 2px 34px),
    linear-gradient(160deg, #1a1a1a, #0a0a0a);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  min-height: 220px;
}
.ph::after {
  content: attr(data-label);
  display: block;
  width: 100%;
  padding: 0.85rem 1rem;
  background: rgba(10,10,10,0.72);
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  line-height: 1.4;
}
.ph.light {
  background:
    repeating-linear-gradient(-18deg, rgba(227,6,19,0.10) 0 2px, transparent 2px 34px),
    linear-gradient(160deg, #f2f2f2, #e2e2e2);
}
.ph.light::after { background: rgba(255,255,255,0.85); color: #0a0a0a; }

.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.small { font-size: 0.88rem; color: var(--gray); }
.mono { font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.85em; }

/* ==========================================================================
   PHP build additions — real logo image + hero video
   ========================================================================== */
.logo img { height: 40px; width: auto; display: block; }
@media (min-width: 900px) { .logo img { height: 46px; } }
.site-footer .logo img { height: 52px; }

.hero-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; z-index: 0;
}
.hero.has-video::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(10,10,10,0.28) 0%, rgba(10,10,10,0.74) 100%);
}
.hero.has-video .hero-inner { position: relative; z-index: 2; }

/* Contact form alerts */
.form-alert { padding: 0.9rem 1.1rem; margin-bottom: 1.5rem; font-size: 0.92rem; border-left: 3px solid; }
.form-alert-ok { background: #f0f7f0; border-color: #2e7d32; color: #1b4d1e; }
.form-alert-err { background: #fdf0f0; border-color: var(--red); color: #7a1b1b; }
.form-alert a { text-decoration: underline; }
