/*
Theme Name: Aliso Viejo Auto Center — Super Service
Theme URI: https://alisoviejoautocenter.com
Author: Rolando Cornejo
Description: Complete auto repair & fleet maintenance microsite for Super Service of Aliso Viejo. All service and menu links route to superserviceofalisoviejo.com.
Version: 1.2.0
Requires at least: 6.3
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: alisoviejoautocenter
*/

:root {
  --navy: #06173a;
  --navy-deep: #040e24;
  --navy-mid: #0d275e;
  --royal: #0b5fd9;
  --electric: #2a8cff;
  --magenta: #e6007e;
  --magenta-dark: #c5006b;
  --white: #ffffff;
  --surface-slate: #f4f6fa;
  --text-dark: #1b2533;
  --text-muted: #56657a;
  --text-on-navy: #cad5e2;
  --border-light: #e2e8f0;
  --font-main: 'Archivo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --transition: color .2s ease, background-color .2s ease, border-color .2s ease;
  --radius: 8px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-padding-top: 100px; }

body {
  font-family: var(--font-main);
  background-color: var(--white);
  color: var(--text-dark);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; transition: var(--transition); }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

.container { width: 90%; max-width: 1200px; margin: 0 auto; }

/* Accessibility */
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 1000;
  background: var(--magenta); color: var(--white);
  padding: 10px 16px; border-radius: 4px; font-weight: 700;
}
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--electric); outline-offset: 3px; }
.btn-primary:focus-visible { outline-color: var(--white); }

/* Top utility bar */
.top-bar {
  background: var(--navy);
  color: var(--white);
  font-size: 0.85rem;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.top-bar-content { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.top-bar-left, .top-bar-right { display: flex; gap: 14px; align-items: center; }
.heritage { color: var(--electric); font-weight: 700; }
.formerly, .hours-short { color: var(--text-on-navy); }
.top-bar-right a { color: var(--white); font-weight: 700; }

/* Header */
.site-header {
  background: var(--navy);
  color: var(--white);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}
.header-inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 14px 0; }
.site-logo img { height: 60px; width: auto; }
.logo-text { font-weight: 900; font-style: italic; font-size: 1.25rem; line-height: 1.1; }
.nav-menu { display: flex; gap: 24px; align-items: center; }
.nav-link { font-weight: 600; font-size: 0.95rem; color: var(--text-on-navy); }
.nav-link:hover { color: var(--white); }
.nav-toggle { display: none; }
.nav-menu > li { position: relative; }
.panel-toggle { background: none; border: 0; font: inherit; font-weight: 600; font-size: 0.95rem; color: var(--text-on-navy); cursor: pointer; padding: 0; display: inline-flex; align-items: center; gap: 6px; }
.panel-toggle::after { content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform .2s ease; }
.panel-toggle[aria-expanded="true"] { color: var(--white); }
.panel-toggle[aria-expanded="true"]::after { transform: translateY(2px) rotate(-135deg); }
.nav-link--topic { color: var(--white); border-bottom: 2px solid var(--magenta); padding-bottom: 2px; }
.mega-panel { display: none; position: absolute; top: calc(100% + 22px); left: 50%; transform: translateX(-50%); width: min(880px, 92vw); background: var(--white); color: var(--text-dark); border-radius: var(--radius); box-shadow: 0 24px 50px rgba(0,0,0,0.25); padding: 28px; border-top: 4px solid var(--magenta); }
.mega-panel--narrow { width: min(480px, 92vw); }
.has-panel.is-open .mega-panel { display: block; }
.mega-cols { display: grid; grid-template-columns: repeat(3, 1fr) 1.2fr; gap: 26px; }
.mega-cols--3 { grid-template-columns: repeat(3, 1fr); }
.mega-cols--2 { grid-template-columns: repeat(2, 1fr); }
.mega-panel h3 { font-size: 0.95rem; color: var(--navy); margin-bottom: 10px; }
.mega-panel li { margin-bottom: 8px; }
.mega-panel li a { color: var(--text-muted); font-weight: 600; }
.mega-panel li a:hover { color: var(--royal); }
.mega-card { background: var(--navy); color: var(--white); border-radius: 6px; padding: 18px; font-size: 0.9rem; }
.mega-card-title { font-weight: 900; font-style: italic; font-size: 1.05rem; margin-bottom: 6px; }
.mega-card p { margin-bottom: 12px; color: var(--text-on-navy); }
.mega-card .btn { padding: 9px 14px; }
.mega-all { display: inline-block; margin-top: 18px; font-weight: 700; color: var(--royal); text-decoration: underline; text-underline-offset: 3px; }
.header-cta { display: flex; align-items: center; gap: 18px; }
.header-phone { font-weight: 700; white-space: nowrap; }

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 4px;
  border: 2px solid transparent;
  font-family: inherit;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  cursor: pointer;
  text-align: center;
}
.btn-lg { padding: 16px 34px; font-size: 1rem; }
.btn-primary { background: var(--magenta); color: var(--white); }
.btn-primary:hover { background: var(--magenta-dark); }
.btn-secondary { background: var(--royal); color: var(--white); }
.btn-secondary:hover { background: #094fb5; }
.btn-outline { border-color: rgba(255,255,255,0.55); color: var(--white); }
.btn-outline:hover { border-color: var(--white); background: rgba(255,255,255,0.08); }

/* Hero */
.hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  color: var(--white);
  padding: 80px 0 100px;
}
.hero-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 50px; align-items: center; }
.badge-tag {
  display: inline-block;
  background: rgba(42, 140, 255, 0.15);
  color: var(--electric);
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 20px;
  border: 1px solid var(--electric);
}
.hero h1 { font-size: 3rem; line-height: 1.12; font-weight: 900; font-style: italic; margin-bottom: 20px; max-width: 16ch; }
.hero-lede { font-size: 1.2rem; color: #d0d7e5; margin-bottom: 30px; max-width: 34em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 15px; }
.hero-cta--center { justify-content: center; }
.hero-visual {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-left: 4px solid var(--magenta);
  border-radius: var(--radius);
  padding: 30px;
}
.trust-metric + .trust-metric { margin-top: 20px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.1); }
.trust-metric h2 { color: var(--white); font-size: 1.15rem; line-height: 1.3; margin-bottom: 4px; }
.trust-metric p { color: var(--text-on-navy); font-size: 0.92rem; }

/* Sections */
.section { padding: 80px 0; }
.bg-slate { background: var(--surface-slate); }
.section-title { text-align: center; margin: 0 auto 50px; max-width: 46em; }
.section-title h2 { font-size: 2.3rem; line-height: 1.15; font-weight: 900; font-style: italic; color: var(--navy); margin-bottom: 12px; }
.section-title p { color: var(--text-muted); font-size: 1.1rem; }

/* Symptom helper */
.diagnostic-widget {
  background: var(--surface-slate);
  border-radius: var(--radius);
  padding: 35px;
  border: 1px solid var(--border-light);
}
.triage-pills { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 30px; justify-content: center; }
.pill-btn {
  background: var(--white);
  color: var(--navy);
  border: 2px solid var(--border-light);
  padding: 10px 20px;
  border-radius: 50px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}
.pill-btn:hover { border-color: var(--royal); }
.pill-btn.active, .pill-btn[aria-pressed="true"] { background: var(--royal); color: var(--white); border-color: var(--royal); }
.triage-card {
  background: var(--white);
  padding: 30px;
  border-radius: var(--radius);
  border-left: 6px solid var(--royal);
  max-width: 960px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 30px;
  align-items: start;
}
.triage-note { text-align: center; color: var(--text-muted); font-size: 0.9rem; margin-top: 18px; }
.triage-note a { color: var(--royal); font-weight: 700; }

/* How-soon meter */
.urgency { background: var(--surface-slate); border-radius: 6px; padding: 18px; }
.urgency-label { color: var(--navy); margin-bottom: 10px; }
.urgency-meter { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-bottom: 10px; }
.urgency-meter span { height: 10px; border-radius: 2px; background: var(--border-light); transition: background-color .25s ease; }
.urgency[data-level="1"] .urgency-meter span:nth-child(-n+1) { background: var(--royal); }
.urgency[data-level="2"] .urgency-meter span:nth-child(-n+2) { background: #d98a00; }
.urgency[data-level="3"] .urgency-meter span:nth-child(-n+3) { background: var(--magenta); }
.urgency-text { color: var(--text-muted); font-size: 0.9rem; margin: 0; }
.triage-card h3 { color: var(--navy); font-size: 1.35rem; margin-bottom: 8px; }
.triage-card p { color: var(--text-muted); margin-bottom: 18px; max-width: 65ch; }

/* Shared helpers */
.h2-left { font-size: 2.1rem; line-height: 1.15; font-weight: 900; font-style: italic; color: var(--navy); margin-bottom: 14px; }
.muted { color: var(--text-muted); }
.text-link { display: inline-block; margin-top: 16px; color: var(--royal); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

/* Process */
.process-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.step-card {
  background: var(--white);
  padding: 25px;
  border-radius: var(--radius);
  border: 1px solid var(--border-light);
}
.step-number {
  display: block;
  font-size: 2.4rem;
  line-height: 1;
  font-weight: 900;
  font-style: italic;
  color: var(--magenta);
  margin-bottom: 14px;
}
.step-card h3 { color: var(--navy); font-size: 1.1rem; margin-bottom: 8px; }
.step-card p { color: var(--text-muted); font-size: 0.95rem; }

/* Services */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.service-box {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-top: 4px solid var(--royal);
  border-radius: var(--radius);
  padding: 30px;
  display: flex;
  flex-direction: column;
}
.service-box h3 { color: var(--navy); margin-bottom: 12px; }
.service-box p { color: var(--text-muted); margin-bottom: 20px; flex: 1; }
.service-box a { color: var(--royal); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.service-box a:hover { color: var(--magenta); }

/* See what we see */
.see-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center; }
.see-copy p { color: var(--text-muted); font-size: 1.08rem; max-width: 36em; margin-bottom: 20px; }
.see-copy img { border-radius: var(--radius); }
.report-example { background: var(--white); border: 1px solid var(--border-light); border-radius: var(--radius); padding: 26px; position: relative; box-shadow: 0 16px 40px rgba(6,23,58,0.10); }
.report-flag { position: absolute; top: -13px; left: 22px; background: var(--navy); color: var(--white); font-weight: 700; font-size: 0.8rem; padding: 4px 12px; border-radius: 50px; }
.report-vehicle { color: var(--text-muted); font-size: 0.9rem; margin: 6px 0 16px; }
.report-list { display: grid; gap: 10px; }
.report-item { display: grid; grid-template-columns: 118px 1fr; gap: 12px; align-items: baseline; padding: 12px; border-radius: 6px; background: var(--surface-slate); border-left: 4px solid var(--border-light); font-size: 0.95rem; }
.report-status { font-weight: 700; }
.report-item--urgent { border-left-color: var(--magenta); }
.report-item--urgent .report-status { color: var(--magenta-dark); }
.report-item--rec { border-left-color: #d98a00; }
.report-item--rec .report-status { color: #8a5800; }
.report-item--wait { border-left-color: var(--royal); }
.report-item--wait .report-status { color: var(--royal); }
.report-item--ok { border-left-color: #1f8a4c; }
.report-item--ok .report-status { color: #1a7a42; }
.report-foot { margin-top: 16px; font-weight: 700; color: var(--navy); }

/* Vehicles & fleet */
.vehicles-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 50px; align-items: center; }
.make-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.make-chips a { display: inline-block; padding: 8px 16px; border: 2px solid var(--border-light); border-radius: 50px; font-weight: 700; color: var(--navy); }
.make-chips a:hover { border-color: var(--royal); color: var(--royal); }
.fleet-card { background: var(--navy); color: var(--white); padding: 34px; border-radius: var(--radius); border-left: 5px solid var(--magenta); }
.fleet-card h3 { font-size: 1.4rem; font-style: italic; font-weight: 900; margin-bottom: 12px; }
.fleet-card p { color: var(--text-on-navy); margin-bottom: 22px; }

/* Legacy */
.legacy-grid { display: grid; grid-template-columns: auto 1fr; gap: 50px; align-items: center; }
.legacy-year { font-size: clamp(5rem, 12vw, 9rem); font-weight: 900; font-style: italic; line-height: 0.9; color: transparent; -webkit-text-stroke: 2px var(--royal); letter-spacing: -2px; }
.legacy p { color: var(--text-muted); max-width: 62ch; margin-bottom: 14px; }

/* Visit */
.visit-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; }
.visit-nap { font-style: normal; margin-bottom: 22px; }
.visit-nap p { margin-bottom: 10px; }
.visit-phone { font-size: 1.5rem; font-weight: 900; color: var(--royal); }
.visit-sub { color: var(--navy); font-size: 1.3rem; margin-bottom: 8px; }
.area-links { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 16px; }
.area-links a { color: var(--royal); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

/* Trust strip */
.trust-badges { background: var(--navy); color: var(--white); padding: 36px 0; }
.badges-flex { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px 36px; }
.badge-item { font-weight: 700; font-size: 0.98rem; display: flex; align-items: baseline; gap: 10px; line-height: 1.4; }
.badge-item::before { content: "✓"; color: var(--electric); }
.badge-item a { text-decoration: underline; text-underline-offset: 3px; }

/* Reviews */
.review-card {
  max-width: 800px;
  margin: 0 auto 60px;
  background: var(--white);
  padding: 35px;
  border-radius: var(--radius);
  border-left: 5px solid var(--magenta);
}
.review-card blockquote p { font-style: italic; font-size: 1.15rem; color: var(--navy); margin-bottom: 12px; }
.review-card figcaption { font-weight: 700; }
.review-card--link { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.review-card--link p { font-size: 1.15rem; color: var(--navy); font-weight: 600; }

/* FAQ */
.faq-list { max-width: 800px; margin: 0 auto; display: grid; gap: 12px; }
.faq-item { background: var(--white); border-radius: 6px; border: 1px solid var(--border-light); }
.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 20px 56px 20px 22px;
  font-weight: 700;
  color: var(--navy);
  position: relative;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  position: absolute; right: 22px; top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem; font-weight: 400; color: var(--royal);
}
.faq-item[open] summary::after { content: "–"; }
.faq-item p { padding: 0 22px 20px; color: var(--text-muted); max-width: 65ch; }

/* Final CTA */
.final-cta { background: var(--navy); color: var(--white); text-align: center; }
.final-cta h2 { font-size: 2.4rem; line-height: 1.15; font-weight: 900; font-style: italic; margin-bottom: 15px; }
.final-cta p { color: var(--text-on-navy); max-width: 600px; margin: 0 auto 30px; font-size: 1.1rem; }

/* Fallback pages */
.prose { max-width: 760px; }
.prose h1 { color: var(--navy); font-weight: 900; font-style: italic; font-size: 2.2rem; margin-bottom: 20px; }
.prose p, .prose ul, .prose ol { margin-bottom: 1em; }
.prose ul { list-style: disc; padding-left: 1.4em; }
.prose a { color: var(--royal); text-decoration: underline; }

/* Footer */
.site-footer { background: var(--navy-deep); color: #9aa9c0; padding: 60px 0 30px; font-size: 0.92rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-heading { color: var(--white); font-size: 1.05rem; margin-bottom: 16px; }
.footer-lede { margin-bottom: 15px; max-width: 42ch; }
.site-footer address { font-style: normal; }
.site-footer address p { margin-bottom: 6px; }
.footer-phone { color: var(--white); font-weight: 700; }
.footer-col li { margin-bottom: 10px; }
.site-footer a:hover { color: var(--white); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.08); padding-top: 20px; text-align: center; font-size: 0.85rem; }
.footer-bottom a { text-decoration: underline; text-underline-offset: 3px; }

/* Mobile sticky bar */
.mobile-sticky-bar {
  display: none;
  position: fixed;
  bottom: 0; left: 0;
  width: 100%;
  background: var(--navy);
  padding: 12px 15px calc(12px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
  z-index: 999;
}
.mobile-sticky-inner { display: flex; gap: 10px; }
.mobile-sticky-inner a { flex: 1; padding: 12px 10px; }

/* Responsive */
@media (max-width: 1100px) {
  .process-grid { grid-template-columns: repeat(2, 1fr); }
  .header-phone { display: none; }
}

@media (max-width: 900px) {
  .hero-grid, .grid-3, .footer-grid { grid-template-columns: 1fr; }
  .hero { padding: 56px 0 64px; }
  .hero h1 { font-size: 2.2rem; }
  .section { padding: 60px 0; }
  .section-title h2, .final-cta h2 { font-size: 1.8rem; }
  .diagnostic-widget { padding: 20px; }
  .triage-pills { justify-content: flex-start; }

  .formerly, .hours-short { display: none; }
  .header-cta { display: none; }

  .nav-toggle {
    display: inline-flex; align-items: center; gap: 10px;
    background: transparent; color: var(--white);
    border: 2px solid rgba(255,255,255,0.4); border-radius: 4px;
    padding: 8px 12px; font: inherit; font-weight: 700; cursor: pointer;
  }
  .nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
    display: block; width: 18px; height: 2px; background: currentColor; position: relative;
  }
  .nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
  .nav-toggle-bars::before { top: -6px; }
  .nav-toggle-bars::after { top: 6px; }

  .primary-nav {
    display: none;
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--navy);
    border-top: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 12px 24px rgba(0,0,0,0.25);
  }
  .primary-nav.is-open { display: block; }
  .nav-menu { flex-direction: column; align-items: stretch; gap: 0; width: 90%; margin: 0 auto; padding: 8px 0 16px; }
  .nav-link { display: block; padding: 12px 0; font-size: 1.05rem; border-bottom: 1px solid rgba(255,255,255,0.08); }

  .triage-card, .see-grid, .vehicles-grid, .legacy-grid, .visit-grid { grid-template-columns: 1fr; gap: 28px; }
  .legacy-year { font-size: 5rem; }
  .h2-left { font-size: 1.8rem; }
  .report-item { grid-template-columns: 1fr; gap: 2px; }
  .panel-toggle { display: flex; width: 100%; justify-content: space-between; padding: 12px 0; font-size: 1.05rem; border-bottom: 1px solid rgba(255,255,255,0.08); }
  .nav-link--topic { border-bottom: 1px solid rgba(255,255,255,0.08); padding-bottom: 12px; }
  .mega-panel { position: static; transform: none; width: 100%; box-shadow: none; border-radius: 0; border-top: 0; padding: 12px 0 16px; background: transparent; color: var(--white); }
  .mega-cols, .mega-cols--3, .mega-cols--2 { grid-template-columns: 1fr 1fr; gap: 16px; }
  .mega-panel h3 { color: var(--electric); }
  .mega-panel li a { color: var(--text-on-navy); }
  .mega-card { grid-column: 1 / -1; background: rgba(255,255,255,0.06); }
  .mega-all { color: var(--electric); }
  .primary-nav { max-height: calc(100vh - 140px); overflow-y: auto; }

  .mobile-sticky-bar { display: block; }
  body { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  html { scroll-behavior: auto; }
}

@media (max-width: 560px) {
  .process-grid { grid-template-columns: 1fr; }
  .area-links { grid-template-columns: 1fr; }
}
