/* ===============================
   Oxtra Flux Motors - Modern Bold CSS
   - Mobile-first, flexbox-only layouts
   - Strong typography, bright accents, high contrast
   - Includes mobile menu + cookie banner
   =============================== */

/* RESET & NORMALIZE */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
img, picture, video, canvas, svg { display: block; max-width: 100%; height: auto; }
input, button, textarea, select { font: inherit; }
ul, ol { margin: 0; padding: 0; }
li { list-style: none; }
a { text-decoration: none; color: inherit; }
:focus { outline: none; }
:focus-visible { outline: 3px solid #C62828; outline-offset: 2px; }

/* THEME VARIABLES (fallbacks included) */
:root {
  --color-primary: #0B2A3A;
  --color-secondary: #C62828;
  --color-accent: #F5F7FA;
  --color-dark: #081C26;
  --color-muted: #6A7B85;
  --color-white: #FFFFFF;
  --shadow-md: 0 8px 24px rgba(11, 42, 58, 0.12);
  --shadow-lg: 0 14px 40px rgba(11, 42, 58, 0.18);
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 18px;
}

/* BASE TYPOGRAPHY */
body {
  font-family: Verdana, Geneva, Tahoma, sans-serif; /* body font */
  color: var(--color-primary);
  background: var(--color-accent);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: "Trebuchet MS", Verdana, Arial, sans-serif; /* display font */
  margin: 0 0 12px 0;
  font-weight: 800; /* bold, modern */
  letter-spacing: -0.3px;
}

h1 { font-size: 40px; line-height: 1.15; }
h2 { font-size: 28px; line-height: 1.2; }
h3 { font-size: 20px; line-height: 1.3; }
p { margin: 0 0 12px 0; font-size: 16px; color: var(--color-primary); }
strong { font-weight: 800; }

/* LINKS */
a { color: var(--color-primary); transition: color 0.2s ease, opacity 0.2s ease; }
a:hover { color: #5c0303; }

/* CONTAINERS & LAYOUT (Flexbox only) */
.container {
  display: flex;
  flex-direction: column;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  gap: 20px;
}

.content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Mandatory spacing and alignment patterns */
.section { margin-bottom: 60px; padding: 40px 20px; }
.card-container { display: flex; flex-wrap: wrap; gap: 24px; }
.card { margin-bottom: 20px; position: relative; }
.content-grid { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; }
.text-image-section { display: flex; align-items: center; gap: 30px; flex-wrap: wrap; }
.testimonial-card { display: flex; align-items: center; gap: 20px; padding: 20px; }
.feature-item { display: flex; flex-direction: column; align-items: flex-start; gap: 15px; }

/* Apply section spacing to HTML section elements */
main section { margin-bottom: 60px; padding: 40px 0; position: relative; }

/* Decorative geometric accents for hero sections */
main section:first-of-type::before {
  content: "";
  position: absolute; inset: 0 auto auto 0;
  width: 56%; height: 52%;
  background: var(--color-white);
  border-bottom-right-radius: 140px;
  z-index: 0; opacity: 0.8;
}
main section:first-of-type .container { position: relative; z-index: 1; }

/* ========================= HEADER & NAV ========================= */
header {
  background: var(--color-white);
  border-bottom: 4px solid var(--color-primary);
  position: sticky; top: 0; z-index: 1000;
}
header .container { flex-direction: row; align-items: center; justify-content: space-between; padding: 16px 20px; }
header img { height: 36px; }

.desktop-nav { display: none; }
.desktop-nav a {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 10px 14px; font-weight: 700; border-radius: 12px; color: var(--color-primary);
}
.desktop-nav a:hover { background: var(--color-accent); }
.desktop-nav .cta-primary, .desktop-nav .cta-secondary { margin-left: 6px; }

/* CTAs */
.cta-primary, .cta-secondary {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 18px; border-radius: 14px; font-weight: 800; letter-spacing: 0.3px;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.cta-primary { background: var(--color-secondary); color: var(--color-white); box-shadow: var(--shadow-md); }
.cta-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.cta-secondary { background: var(--color-white); color: var(--color-primary); border: 2px solid var(--color-primary); }
.cta-secondary:hover { background: var(--color-primary); color: var(--color-white); }

/* Mobile menu */
.mobile-menu-toggle {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 44px; height: 44px; border-radius: 12px; border: 2px solid var(--color-primary);
  background: var(--color-white); color: var(--color-primary); font-size: 22px; cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
}
.mobile-menu-toggle:hover { background: var(--color-primary); color: var(--color-white); transform: translateY(-1px); }

.mobile-menu {
  position: fixed; inset: 0 0 0 auto; width: 100%; height: 100%;
  background: var(--color-primary); color: var(--color-white);
  transform: translateX(100%); transition: transform 0.35s ease; z-index: 1500;
  display: flex; flex-direction: column; padding: 20px; gap: 20px;
}
.mobile-menu.open { transform: translateX(0); }
.mobile-menu-close {
  align-self: flex-end; width: 44px; height: 44px; border-radius: 12px; border: 2px solid var(--color-white);
  background: transparent; color: var(--color-white); font-size: 20px; cursor: pointer;
}
.mobile-nav { display: flex; flex-direction: column; gap: 14px; }
.mobile-nav a {
  display: flex; align-items: center; padding: 14px 12px; border-radius: 12px; font-weight: 800;
  background: rgba(255,255,255,0.06);
}
.mobile-nav a:hover { background: rgba(255,255,255,0.14); }

/* ========================= MAIN CONTENT ========================= */
/* Hero emphasis */
main section:first-of-type { background: var(--color-accent); }
main section:first-of-type h1 { font-size: 36px; }

/* Headings accents */
h2::after {
  content: ""; display: inline-flex; width: 42px; height: 6px; margin-left: 10px;
  background: var(--color-secondary); border-radius: 6px;
}

/* Trust row */
.trust-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.trust-row img { width: 36px; height: 36px; padding: 8px; background: var(--color-white); border-radius: 12px; box-shadow: var(--shadow-md); }

/* Quick stats */
.quick-stats { display: flex; flex-wrap: wrap; gap: 12px; }
.quick-stats li {
  display: flex; align-items: center; gap: 8px; padding: 12px 14px; background: var(--color-white);
  border: 2px solid var(--color-primary); border-radius: 14px; font-weight: 700; box-shadow: var(--shadow-md);
}

/* Features */
.feature-grid { display: flex; flex-wrap: wrap; gap: 20px; }
.feature-grid > div {
  display: flex; flex-direction: column; gap: 12px; flex: 1 1 260px; padding: 20px; background: var(--color-white);
  border-radius: var(--radius-md); box-shadow: var(--shadow-md); border-top: 6px solid var(--color-secondary);
}
.feature-grid img { width: 42px; height: 42px; }

/* Services */
.service-cards { display: flex; flex-wrap: wrap; gap: 20px; }
.service-cards > div {
  display: flex; flex-direction: column; gap: 10px; flex: 1 1 260px; padding: 20px;
  background: var(--color-white); border: 2px solid var(--color-primary); border-radius: var(--radius-md);
}

/* Testimonials - ensure high contrast (dark text on light background) */
.testimonial-card {
  background: var(--color-accent); color: var(--color-primary); border-left: 6px solid var(--color-secondary);
  border-radius: var(--radius-md); box-shadow: var(--shadow-md);
}
.testimonial-card p { margin: 0; }

/* Logos strip */
.logos-strip { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.logos-strip img { width: 80px; opacity: 0.8; filter: grayscale(100%); transition: filter 0.2s ease, opacity 0.2s ease; }
.logos-strip img:hover { opacity: 1; filter: grayscale(0%); }

/* KPIs */
.numbers-kpis { display: flex; flex-wrap: wrap; gap: 16px; }
.numbers-kpis p { display: flex; align-items: center; gap: 8px; padding: 14px 16px; background: var(--color-white); border-radius: var(--radius-md); box-shadow: var(--shadow-md); font-weight: 700; }
.numbers-kpis strong { font-size: 22px; color: var(--color-secondary); }

/* CTA row */
.cta-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

/* Social row */
.social-row { display: flex; align-items: center; gap: 12px; }
.social-row img { width: 36px; height: 36px; padding: 6px; background: var(--color-white); border-radius: 10px; box-shadow: var(--shadow-md); }

/* Footer */
footer { background: var(--color-primary); color: var(--color-white); padding: 30px 0; margin-top: 20px; }
footer .container { gap: 24px; }
footer .content-wrapper { gap: 24px; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 14px; }
.footer-nav a { color: var(--color-white); font-weight: 700; padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,0.06); }
.footer-nav a:hover { background: rgba(255,255,255,0.16); }
.footer-contact { display: flex; flex-direction: column; gap: 8px; }
.footer-contact li { display: flex; align-items: center; gap: 10px; }
.footer-contact img { width: 18px; height: 18px; filter: brightness(0) invert(1); }
.legal-links { color: var(--color-accent); opacity: 0.9; }
.newsletter-form { display: flex; flex-direction: column; gap: 6px; background: rgba(255,255,255,0.06); padding: 16px; border-radius: var(--radius-md); }

/* Lists, details */
ul, ol { display: flex; flex-direction: column; gap: 8px; }
details { background: var(--color-white); border-radius: var(--radius-md); border: 2px solid var(--color-primary); padding: 12px 14px; }
details + details { margin-top: 10px; }
summary { cursor: pointer; font-weight: 800; }

/* Tables (car list, pricing) */
.car-list-table, .pricing-table {
  width: 100%; border-collapse: collapse; background: var(--color-white); border-radius: var(--radius-md);
  box-shadow: var(--shadow-md); display: block; overflow-x: auto;
}
.car-list-table th, .car-list-table td, .pricing-table th, .pricing-table td {
  padding: 14px 16px; text-align: left; border-bottom: 1px solid #E2E8EE; font-size: 14px;
}
.car-list-table th, .pricing-table th { background: #0F3447; color: var(--color-white); position: sticky; top: 0; }
.car-list-table tr:nth-child(even) td, .pricing-table tr:nth-child(even) td { background: #FAFCFE; }

/* Contact list with icons */
.content-wrapper > ul li img { width: 18px; height: 18px; margin-right: 6px; }
.content-wrapper > ul li { display: flex; align-items: center; gap: 10px; }

/* Legal pages typography spacing */
.content-wrapper h3 { font-size: 18px; margin-top: 8px; }

/* Generic cards (if used) */
.card { background: var(--color-white); border-radius: var(--radius-md); box-shadow: var(--shadow-md); padding: 18px; }

/* ========================= COOKIE CONSENT ========================= */
.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 2000;
  background: var(--color-primary); color: var(--color-white);
  padding: 18px 16px; transform: translateY(100%); transition: transform 0.35s ease;
  display: flex; flex-direction: column; gap: 12px;
}
.cookie-banner.show { transform: translateY(0); }
.cookie-banner .cookie-content { display: flex; flex-direction: column; gap: 12px; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.cookie-btn { display: inline-flex; align-items: center; justify-content: center; padding: 12px 16px; border-radius: 12px; font-weight: 800; cursor: pointer; border: 2px solid transparent; }
.cookie-btn.accept { background: var(--color-secondary); color: var(--color-white); }
.cookie-btn.reject { background: var(--color-white); color: var(--color-primary); border-color: var(--color-white); }
.cookie-btn.settings { background: transparent; color: var(--color-white); border-color: var(--color-white); }
.cookie-btn:hover { opacity: 0.9; }

/* Cookie modal */
.cookie-modal { position: fixed; inset: 0; background: rgba(8,28,38,0.72); z-index: 2100; display: none; align-items: center; justify-content: center; padding: 20px; }
.cookie-modal.open { display: flex; }
.cookie-modal-content {
  display: flex; flex-direction: column; gap: 14px; width: 100%; max-width: 640px; background: var(--color-white);
  color: var(--color-primary); border-radius: var(--radius-lg); padding: 20px; box-shadow: var(--shadow-lg);
}
.cookie-modal-header { display: flex; align-items: center; justify-content: space-between; }
.cookie-modal-body { display: flex; flex-direction: column; gap: 10px; }
.cookie-toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px solid #E5EDF3; }
.cookie-toggle-row:last-child { border-bottom: 0; }
.cookie-modal-actions { display: flex; gap: 10px; justify-content: flex-end; }

/* ========================= INTERACTIONS & ANIMATIONS ========================= */
[data-animate] { opacity: 0; transform: translateY(12px); transition: opacity 0.4s ease, transform 0.4s ease; }
[data-animate].in-view { opacity: 1; transform: none; }

/* ========================= RESPONSIVE ========================= */
@media (min-width: 480px) {
  h1 { font-size: 44px; }
}

@media (min-width: 768px) {
  main section:first-of-type h1 { font-size: 48px; }
  .content-wrapper { gap: 24px; }
  .cta-row { gap: 16px; }
  .trust-row img { width: 44px; height: 44px; }
  .numbers-kpis p { padding: 16px 18px; }
  /* text-image sections horizontally on desktop */
  .text-image-section { flex-direction: row; }
}

@media (min-width: 992px) {
  .desktop-nav { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
  .mobile-menu-toggle { display: none; }
  header img { height: 40px; }
  .feature-grid > div, .service-cards > div { flex: 1 1 calc(33% - 20px); }
  .logos-strip { justify-content: space-between; }
  main section { padding: 56px 0; }
}

@media (min-width: 1200px) {
  h1 { font-size: 52px; }
  h2 { font-size: 32px; }
}

/* ========================= ACCESSIBILITY & UTILITIES ========================= */
.hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; clip: rect(0 0 0 0); overflow: hidden; }
.muted { color: var(--color-muted); }

/* ========================= PAGE-SPECIFIC REFINEMENTS ========================= */
/* "Filters:" label */
.content-wrapper p strong { font-weight: 900; }

/* Legal text blocks */
.legal-links a { color: var(--color-accent); font-weight: 700; }
.legal-links a:hover { color: var(--color-white); }

/* Tables caption-like paragraphs inside sections */
.content-wrapper > p em { background: var(--color-white); padding: 6px 10px; border-radius: 10px; font-style: normal; color: var(--color-primary); box-shadow: var(--shadow-md); }

/* Ensure adequate spacing between all cards/blocks */
.feature-grid > div, .service-cards > div, .testimonial-card, .card { margin-bottom: 20px; }

/* Prevent overlapping by adding consistent gaps */
main .container { gap: 24px; }

/* Ensure alignments per requirements */
.text-image-section { align-items: center; }
.card-content { display: flex; flex-direction: column; justify-content: center; gap: 10px; }

/* Make sure no content card uses absolute positioning - decorative only above. */

/* ========================= PRINT (basic) ========================= */
@media print {
  header, footer, .mobile-menu, .cookie-banner, .cookie-modal { display: none !important; }
  a { text-decoration: underline; }
}
