/* --- Set global WP color variables to green/black --- */
:root {
  --wp--preset--color--primary: #4CAF50 !important;   /* modern green */
  --wp--preset--color--accent:  #4CAF50 !important;
  --wp--preset--color--contrast:#000000 !important;
}

/* --- Site background & text --- */
body, .wp-site-blocks {
  background:#ffffff !important;
  color:#000000 !important;
}

/* --- Header (template part) --- */
.wp-block-template-part[area="header"],
.wp-site-blocks > header,
.site-header,
header {
  background:#000000 !important;
}
.wp-block-navigation a,
.wp-block-site-title a,
.site-header a,
header a {
  color:#4CAF50 !important;
}
.wp-block-navigation__container .wp-block-navigation-item__content,
.wp-block-navigation__responsive-container .wp-block-navigation-item__content {
  color:#4CAF50 !important;
}

/* --- Footer (template part) --- */
.wp-block-template-part[area="footer"],
.wp-site-blocks > footer,
.site-footer,
footer {
  background:#000000 !important;
}
footer, footer a, footer p, footer span {
  color:#4CAF50 !important;
}

/* --- Buttons (all types) --- */
.wp-block-button .wp-block-button__link,
.wp-element-button,
button,
input[type="submit"],
.wp-block-search__button {
  background:#4CAF50 !important;
  color:#ffffff !important;
  border:1px solid #000000 !important;
}
.wp-block-button.is-style-outline .wp-block-button__link {
  background:transparent !important;
  color:#4CAF50 !important;
  border:2px solid #4CAF50 !important;
}

/* --- Headings in content --- */
.wp-site-blocks h1, .wp-site-blocks h2, .wp-site-blocks h3,
.wp-site-blocks h4, .wp-site-blocks h5, .wp-site-blocks h6 {
  color:#4CAF50 !important;
}

/* --- Catch theme utility classes that may still be orange --- */
.has-accent-color, .has-primary-color { color:#4CAF50 !important; }
.has-accent-background-color, .has-primary-background-color { background:#4CAF50 !important; }

/* Force header bar background */
.wp-block-template-part[area="header"],
.site-header,
header {
  background-color: #000000 !important;
  border: none !important;
}

/* Force header bar text + nav links */
.wp-block-navigation a,
header nav a {
  color: #4CAF50 !important;
}

/* Force top bar accents (currently orange strip) */
.wp-block-group,
.wp-block-cover,
[class*="wp-block"],
div[class*="header"] {
  border-color: #4CAF50 !important;
  background-image: none !important;
}
/* Stop horizontal scrolling */
html, body {
    overflow-x: hidden !important;
    width: 100% !important;
}
.car-dealer-shop-slider .swiper-wrapper {
  transform: none !important;
}
.car-dealer-shop-slider .swiper-slide {
  opacity: 1 !important;
  position: relative !important;
}


/* Hide any duplicate nav bars */
.site-header nav:nth-of-type(n+2),
header .wp-block-navigation:nth-of-type(n+2) {
  display: none !important;
}

/* Make header span edge-to-edge */
.site-header,
.wp-site-blocks > header {
  max-width: 100% !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Shorten hero image height on mobile */
@media (max-width: 767px) {
  .wp-block-cover:first-of-type {
    min-height: 280px !important;
    max-height: 340px !important;
    padding-top: 10px !important;
    padding-bottom: 10px !important;
  }
  .wp-block-cover img {
    height: 100% !important;
    width: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
  }
}

/* --- Keep ONE hamburger, hide the duplicate --- */
header .wp-block-navigation__responsive-container-open {
  display: inline-flex !important; /* ensure primary toggle shows */
}
header .wp-block-navigation__responsive-container-open + .wp-block-navigation__responsive-container-open {
  display: none !important; /* hide second toggle placed after first */
}
header .wp-block-group .wp-block-navigation__responsive-container-open {
  display: none !important; /* hide toggle rendered inside inner group/row */
}
header .menu-toggle:nth-of-type(n+2),
header button.menu-toggle:nth-of-type(n+2) {
  display: none !important; /* fallback for classic-theme toggles */
}

/* --- Shorter hero on mobile only (targets hero-cover only) --- */
@media (max-width: 767px){
  .hero-cover {
    min-height: 280px !important;
    max-height: 340px !important;
    padding-top: 10px !important;
    padding-bottom: 10px !important;
  }
  .hero-cover img {
    height: 100% !important;
    width: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
  }
}

/* --- Full-width header container --- */
.site-header,
.wp-site-blocks > header {
  max-width: 100% !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Keep one hamburger only */
header .wp-block-navigation__responsive-container-open,
header button.menu-toggle { display:none !important; }
header .keep-toggle .wp-block-navigation__responsive-container-open,
header .keep-toggle button.menu-toggle { display:inline-flex !important; }

/* Header full width */
.site-header,
.wp-site-blocks > header,
header.wp-block-template-part {
  max-width:100% !important; width:100% !important; margin:0 !important;
  padding-left:0 !important; padding-right:0 !important;
}

/* Shorter hero on mobile */
@media (max-width: 767px){
  .hero-cover{
    min-height:260px !important; max-height:320px !important;
    padding-top:8px !important; padding-bottom:8px !important;
    margin-bottom:6px !important;
  }
  .hero-cover img{
    height:100% !important; width:100% !important;
    object-fit:cover !important; object-position:center !important;
  }
}

/* Tighten gap above fleet and remove spacer after hero */
.fleet-section{ margin-top:6px !important; padding-top:4px !important; }
@media (max-width:767px){
  .hero-cover + .wp-block-spacer{ display:none !important; }
}

/* Safety: ensure inner header rows don't re-constrain on mobile */
@media (max-width:767px){
  header .alignwide, header .is-layout-constrained { max-width:100% !important; width:100% !important; }
}


/* ===== HEADER: REMOVE ALL SIDE PADDING / CONSTRAINTS ===== */
html, body { margin:0 !important; padding:0 !important; }
.wp-site-blocks { padding-left:0 !important; padding-right:0 !important; }
:root { --wp--custom--spacing--outer:0px !important; }
.site-header,
.wp-site-blocks > header,
header.wp-block-template-part,
header .wp-block-group,
header .wp-block-group.is-layout-constrained {
  margin:0 !important;
  padding-left:0 !important;
  padding-right:0 !important;
  max-width:100% !important;
  width:100% !important;
}
/* If inner rows use "wide" or container classes, lift them on mobile */
@media (max-width:767px){
  header .alignwide,
  header .is-layout-constrained,
  header .wp-container,
  header .wp-block-columns { max-width:100% !important; width:100% !important; padding-left:0 !important; padding-right:0 !important; }
}

/* ===== NAV: KEEP ONLY THE TOGGLE INSIDE keep-toggle ===== */
header .wp-block-navigation__responsive-container-open,
header button.menu-toggle { display:none !important; }
header .keep-toggle .wp-block-navigation__responsive-container-open,
header .keep-toggle button.menu-toggle { display:inline-flex !important; }

/* ===== HERO: SHORTER ON MOBILE ===== */
@media (max-width:767px){
  .hero-cover{
    min-height:240px !important;   /* tighter than before */
    max-height:300px !important;
    padding-top:8px !important;
    padding-bottom:8px !important;
    margin-bottom:4px !important;  /* collapse space under hero */
  }
  .hero-cover img{
    height:100% !important; width:100% !important;
    object-fit:cover !important; object-position:center !important;
  }
}

/* ===== FLEET: PULL SECTION UP; KILL ANY SPACER AFTER HERO ===== */
.fleet-section{ margin-top:4px !important; padding-top:2px !important; }
@media (max-width:767px){ .hero-cover + .wp-block-spacer{ display:none !important; } }

/* ===== SAFETY: SOME THEMES ADD WHITE STRIPS VIA CONTAINER BACKGROUNDS ===== */
header, .site-header { background-color:#000 !important; }


/* Mobile-only: collapse gap between hero and fleet */
@media (max-width: 767px) {
  .hero-cover {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
  }

  .hero-cover + .wp-block-spacer,
  .hero-cover + .wp-block-group {
    margin-top: 0 !important;
    padding-top: 0 !important;
  }

  .fleet-section {
    margin-top: 0 !important;
    padding-top: 0 !important;
  }

  /* Safety: hide any spacer blocks inside fleet section */
  .fleet-section .wp-block-spacer {
    display: none !important;
  }
}

/* Mobile-only: collapse hero → fleet spacing (force) */
@media (max-width: 767px){
  .hero-cover{ margin-bottom:0 !important; padding-bottom:0 !important; }
  .hero-cover + *{ margin-top:0 !important; padding-top:0 !important; }
  .hero-cover + * .wp-block-spacer{ display:none !important; }
  .fleet-section{ margin-top:0 !important; padding-top:0 !important; }
  .fleet-section .wp-block-spacer{ display:none !important; }
  /* last-resort clamp in case a theme wrapper still adds space */
  .hero-cover + *{ margin-top:-10px !important; }
}


/* Mobile-only: collapse hero → fleet spacing */
@media (max-width: 767px){
  .hero-cover { margin-bottom: 0 !important; padding-bottom: 0 !important; }
  .hero-cover + * { margin-top: 0 !important; padding-top: 0 !important; }
  .hero-cover + * .wp-block-spacer,
  .hero-cover + * .wp-block-separator { display: none !important; height: 0 !important; margin: 0 !important; }
  .fleet-section { margin-top: 0 !important; padding-top: 0 !important; }
  .fleet-section .wp-block-spacer { display: none !important; }
  /* last-resort clamp */
  .hero-cover + * { margin-top: -10px !important; }
}

/* Emergency override: replace heading text */
.fleet-section h2::after {
  content: "Caged, Tipper & Motorbike Trailer Hire Available in Auckland";
  display: block;
  font-size: inherit;
  font-weight: inherit;
  color: inherit;
}
.fleet-section h2 {
  font-size: 0 !important; /* visually hides original text */
}


/* Mobile-only: ensure no gap under hero even if an empty group/spacer exists */
@media (max-width: 767px){
  .hero-cover{ margin-bottom:0 !important; padding-bottom:0 !important; }
  .hero-cover + *{ margin-top:0 !important; padding-top:0 !important; }
  .hero-cover + * .wp-block-spacer{ display:none !important; height:0 !important; margin:0 !important; }
  /* If an empty group slips in under the hero, collapse it */
  .hero-cover + .wp-block-group:empty{
    margin:0 !important; padding:0 !important; min-height:0 !important;
  }
}
/* Remove white gap below hero section on small screens */
@media only screen and (max-width: 767px) {
  /* Adjust these selectors to match your site's blocks */
  .your-hero-section-class, 
  .your-hero-wrapper, 
  .site-header + .site-content {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
  }

  .your-next-section-class {
    margin-top: 0 !important;
    padding-top: 0 !important;
}






