/*
 * redesign.css — Roofing Crew Redesign overrides
 * Loads after theme.css. All changes isolated here.
 */

/* ============================================================
   LOGO — bigger, not square-constrained
   ============================================================ */
.nav-logo-img,
img.nav-logo-img {
  height: auto !important;
  width: 160px !important;
  max-width: 160px !important;
  object-fit: contain !important;
  border-radius: 0 !important;
}

/* ============================================================
   TOPBAR — hide entirely on mobile
   ============================================================ */
@media (max-width: 768px) {
  #topbar {
    display: none !important;
  }
}

/* ============================================================
   HEADER — mobile layout: logo left, hamburger center, CTA right
   ============================================================ */
@media (max-width: 768px) {
  .nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0;
  }

  /* Logo: bigger on mobile */
  .nav-logo-img,
  img.nav-logo-img {
    width: 130px !important;
    max-width: 130px !important;
  }

  /* Hide desktop nav */
  #site-navigation {
    display: none !important;
  }

  /* Hamburger — push to middle naturally via flex */
  .menu-toggle {
    order: 2;
  }

  /* Call Now CTA */
  .nav-cta-mobile {
    order: 3;
    display: inline-flex !important;
    background: #FF8200 !important;
    color: #fff !important;
    font-family: var(--font-display, 'Barlow Condensed', sans-serif);
    font-weight: 800;
    font-size: 15px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 10px 20px;
    white-space: nowrap;
  }

  .nav-cta-desktop {
    display: none !important;
  }
}

/* ============================================================
   HERO SLIDER — mobile: static single view, no carousel UI
   ============================================================ */
@media (max-width: 768px) {

  /* Hide slider navigation elements */
  .slider-nav,
  .slider-dot,
  .slider-arrow,
  .slider-arrow-prev,
  .slider-arrow-next,
  .slider-phone-card {
    display: none !important;
  }

  /* Only show the first (active) slide — stack inactive ones out */
  .slide:not(.active) {
    display: none !important;
  }

  /* Hero height — full-bleed on mobile */
  #hero-slider {
    height: 92vh !important;
    min-height: 580px !important;
    max-height: 780px !important;
  }

  /* Active slide fills full container */
  .slide.active {
    position: relative !important;
    inset: unset !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 580px !important;
  }

  /* Slide background covers full area */
  .slide-bg {
    position: absolute !important;
    inset: 0 !important;
    background-size: cover !important;
    background-position: center top !important;
  }

  /* Content: left-aligned, starts lower so image is visible above */
  .slide-content {
    padding: 0 20px !important;
    padding-top: 48px !important;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding-bottom: 40px;
    height: 100%;
    box-sizing: border-box;
  }

  /* Eyebrow — smaller on mobile */
  .slide-eyebrow {
    font-size: 11px !important;
    letter-spacing: 0.14em !important;
    margin-bottom: 12px !important;
  }

  /* Headline — bold and big but fits screen */
  .slide-title {
    font-size: clamp(36px, 10vw, 54px) !important;
    line-height: 0.95 !important;
    margin-bottom: 16px !important;
    max-width: 100% !important;
  }

  /* Subtitle — readable on mobile */
  .slide-subtitle {
    font-size: 15px !important;
    line-height: 1.55 !important;
    margin-bottom: 24px !important;
    max-width: 100% !important;
  }

  /* Slide actions — stack vertically */
  .slide-actions {
    flex-direction: column !important;
    gap: 12px !important;
    width: 100% !important;
  }

  .slide-actions .btn-primary,
  .slide-actions .slide-estimate-btn {
    width: 100% !important;
    justify-content: center !important;
    text-align: center !important;
    font-size: 15px !important;
    padding: 15px 20px !important;
  }

  /* Estimate button — outline style on mobile */
  .slide-estimate-btn {
    background: transparent !important;
    border: 2px solid rgba(255,255,255,0.7) !important;
    color: #fff !important;
    clip-path: none !important;
  }

  /* Trust badges — inline row below CTAs */
  .slide-trust-badges {
    margin-top: 16px !important;
    gap: 16px !important;
  }

  .slide-trust-item {
    font-size: 12px !important;
  }
}

/* ============================================================
   ORANGE BAR — mobile sizing
   ============================================================ */
@media (max-width: 768px) {
  .rc-orange-bar {
    padding: 18px 16px !important;
  }

  .rc-orange-bar-text {
    font-size: 20px !important;
    line-height: 1.2 !important;
  }

  .rc-orange-bar-text span {
    font-size: 13px !important;
  }
}

/* ============================================================
   SERVICE CARDS — mobile single column
   ============================================================ */
@media (max-width: 768px) {
  .rc-services-section {
    padding: 40px 0 36px !important;
  }

  .rc-services-heading {
    font-size: 22px !important;
    margin-bottom: 24px !important;
  }

  .rc-services-cards {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
    max-width: 340px !important;
    margin: 0 auto !important;
  }

  .rc-svc-card {
    padding: 24px 20px 22px !important;
  }
}

/* ============================================================
   BEFORE / AFTER — mobile height
   ============================================================ */
@media (max-width: 600px) {
  .rc-before-after,
  .rc-before-after img {
    height: 240px !important;
    max-height: 240px !important;
  }
}

/* ============================================================
   GAP FIXES — eliminate brown #231F20 gaps around hero
   ============================================================ */

/* 1. WordPress admin bar pushes html down on mobile (46px).
      This exposes body background above the masthead.
      We fix by making html/body background match the masthead. */
html,
body,
body.home,
body.front-page {
  background: #231F20 !important;
}

/* 2. Reset any admin-bar margin that creates space */
html { margin-top: 0 !important; }
body { margin-top: 0 !important; padding-top: 0 !important; }

/* 3. Admin bar: on frontend preview, push masthead down to sit below it */
body.admin-bar #masthead {
  top: 32px !important;
}
@media screen and (max-width: 782px) {
  body.admin-bar #masthead {
    top: 46px !important;
  }
}

/* 4. Topbar: fully collapsed on mobile */
@media (max-width: 768px) {
  #topbar {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
    border: none !important;
    line-height: 0 !important;
    font-size: 0 !important;
  }
}

/* 5. Hero slider: zero margin/padding, flush on all sides */
#hero-slider {
  margin: 0 !important;
  padding: 0 !important;
  display: block !important;
}

/* 6. Orange bar: zero gap against hero */
.rc-orange-bar {
  margin: 0 !important;
}

/* 7. Restore explicit backgrounds on all sections so #231F20 body
      doesn't bleed through anywhere it shouldn't */
#cost-estimator               { background: #f1f1f1 !important; }
#services                     { background: #fff    !important; }
#materials                    { background: var(--orange) !important; }
#emergency-bar                { background: #F4F4F4 !important; }
#why-us                       { background: #fff    !important; }
#service-areas                { background: #fff    !important; }
#about                        { background: #fff    !important; }
#reviews                      { background: #fff    !important; }
#blog-preview                 { background: #fff    !important; }
#faq-section .faq-grid-wrap   { background: #f1f1f1 !important; }
#contact                      { background: #fff    !important; }
.hero-stats-bar               { background: #f1f1f1 !important; }
#trust-bar                    { background: #fff    !important; }

/* Cost estimator left panel: theme.css forces #fff !important — override it */
.rc-est-card > div:first-child,
#cost-estimator > .container > div > div:first-child {
  background: #f1f1f1 !important;
}

/* Footer logo — remove 90×90 square constraint, display at natural size */
.footer-logo-img,
img.footer-logo-img {
  width: auto !important;
  max-width: 200px !important;
  height: auto !important;
  min-height: unset !important;
  object-fit: contain !important;
  border-radius: 0 !important;
}


@media (min-width: 769px) {
  .nav-logo-img,
  img.nav-logo-img {
    width: 160px !important;
    height: auto !important;
  }

  /* Keep enough space in nav */
  #masthead .container {
    gap: 20px;
  }
}

/* ============================================================
   DESKTOP — logo larger than original 72px
   ============================================================ */
@media (min-width: 769px) {
  .nav-logo-img,
  img.nav-logo-img {
    width: 160px !important;
    height: auto !important;
  }

  /* Keep enough space in nav */
  #masthead .container {
    gap: 20px;
  }
}

/* ============================================================
   STROKE / OUTLINE TEXT — global fix
   theme.css only scopes .stroke to .slide-title
   These rules extend it to service page h1s and section-title
   ============================================================ */
h1 .stroke,
.section-title .stroke,
.slide-title .stroke {
  -webkit-text-stroke: 2px rgba(255, 255, 255, 0.45) !important;
  color: transparent !important;
  text-shadow: none !important;
}
