/* ════════════════════════════════════════════════════════════════════════
   BACKYARD ROO — HOMEPAGE SPECIFIC LEGACY STYLES
   Restores original homepage layout (index.html uses custom classes not in design system)
   ════════════════════════════════════════════════════════════════════════ */

/* ── Hero / Homepage Structure ──────────────────────────────────────────── */
.scroll-container {
  position: relative;
  width: 100%;
  overflow-x: hidden;
}

section {
  position: relative;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(2.25rem, 4.5vw, 4rem) clamp(1rem, 4vw, 3rem);
  overflow: hidden;
}

#hero {
  min-height: min(92vh, 780px);
  padding-top: clamp(9.5rem, 15vw, 14.5rem);
}

.bg-layer {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: -2;
}

.bg-layer::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 20%, rgba(88,196,107,0.18), transparent 35%),
              linear-gradient(180deg, rgba(7,17,13,0.62), rgba(7,17,13,0.88));
}

.glass-card {
  width: min(100%, 1200px);
  margin: auto;
  padding: clamp(1.25rem, 4vw, 3rem);
  border-radius: var(--radius-xl);
  background: linear-gradient(145deg, rgba(14,28,20,0.82), rgba(9,18,14,0.68));
  border: 1px solid var(--card-border);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(18px);
}

.page-header {
  text-align: center;
  margin: 0 auto 3rem;
  max-width: 780px;
}

.page-header p {
  font-size: 1.15rem;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-accent);
  background: rgba(88,196,107,0.12);
  border: 1px solid rgba(88,196,107,0.28);
  border-radius: var(--radius-full);
  padding: var(--space-1) var(--space-3);
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: var(--space-4);
}

.status-dot {
  position: relative;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--color-accent);
  box-shadow: 0 0 0 6px rgba(88,196,107,0.15);
}

.hero-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: all var(--duration-slower) var(--ease-out);
}

.hero-reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Grid Systems (Homepage) ───────────────────────────────────────────── */
.services-cards-grid,
.gallery-grid,
.ethics-grid,
.testimonial-grid,
.trust-grid,
.why-grid,
.step-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.service-card-item,
.ethics-card,
.testimonial-card,
.trust-badge,
.why-card,
.step-card,
details,
.service-detail-card {
  background: rgba(16,30,22,0.78);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.service-card-img-wrap {
  position: relative;
  height: 210px;
}

.service-card-img,
.gallery-item {
  height: 210px;
  background-size: cover;
  background-position: center;
}

.service-card-badge {
  position: absolute;
  bottom: 0.75rem;
  left: 0.75rem;
  width: 2.75rem;
  height: 2.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0,0,0,0.4);
  color: white;
  font-size: 1.25rem;
}

.service-card-body {
  padding: 1.35rem 1.15rem;
}

.service-card-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  background: var(--color-primary);
  color: var(--text-inverse);
  transition: all var(--duration-fast) var(--ease-out);
}

.service-card-btn:hover {
  background: var(--color-primary-hover);
  transform: translateY(-1px);
}

/* ── Gallery / Background Images ───────────────────────────────────────── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.gallery-item {
  position: relative;
  height: 280px;
  background-size: cover;
  background-position: center;
  border-radius: 18px;
  overflow: hidden;
}

.bg-gallery {
  position: relative;
  aspect-ratio: 16/9;
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.bg-layer {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity var(--duration-slower) var(--ease-out);
}

.bg-layer.active {
  opacity: 1;
}

.bg-hero {
  background-image: var(--hero-bg-image, url('/images/hero-backyard-finished.jpg'));
}

.bg-lawn {
  background-image: var(--lawn-bg-image, url('/images/bg-lawn.jpg'));
}

.bg-labour {
  background-image: var(--labour-bg-image, url('/images/bg-labour.jpg'));
}

.bg-why {
  background: radial-gradient(ellipse at center, rgba(88,196,107,0.08) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.bg-ethics {
  background: radial-gradient(ellipse at center, rgba(176,138,98,0.06) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}

/* ── Scroll / Section Reveal ───────────────────────────────────────────── */
.section-3d-reveal {
  opacity: 0;
  transform: translateY(40px) rotateX(10deg);
  transition: all var(--duration-slower) var(--ease-out);
}

.section-3d-reveal.visible {
  opacity: 1;
  transform: translateY(0) rotateX(0);
}

.section-3d-reveal > .glass-card {
  transform: translateY(40px) scale(0.98);
}

.section-3d-reveal.visible > .glass-card {
  transform: translateY(0) scale(1);
}

.section-3d-reveal .bg-layer {
  transform: scale(1.05);
}

.section-3d-reveal.visible .bg-layer {
  transform: scale(1);
}

/* ── Hero Info Strip ───────────────────────────────────────────────────── */
.hero-info-strip {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 90px;
  gap: 1rem;
  align-items: center;
  margin-top: 2rem;
  padding: 1rem;
  border-radius: 18px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
}

.info-col {
  display: flex;
  flex-direction: column;
}

.info-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.info-value {
  font-weight: 800;
  color: var(--text-primary);
  text-decoration: none;
}

.info-divider {
  width: 1px;
  height: 44px;
  background: rgba(255,255,255,0.14);
}

.info-thumb {
  height: 70px;
  border-radius: 14px;
  background-size: cover;
  background-position: center;
}

/* ── Utility Bar ───────────────────────────────────────────────────────── */
.utility-bar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: var(--z-utility);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.4rem 1.5rem;
  background: rgba(4,10,7,0.78);
  backdrop-filter: blur(10px);
  font-size: 0.78rem;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.utility-bar .u-left,
.utility-bar .u-right,
.utility-bar .u-social {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.utility-bar a {
  text-decoration: none;
  color: var(--text-muted);
}

.utility-bar a:hover {
  color: var(--color-accent);
}

/* ── Homepage Site Nav (Fixed Position) ────────────────────────────────── */
.site-nav {
  position: fixed;
  top: 30px;
  left: 0;
  right: 0;
  z-index: var(--z-nav);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem clamp(1rem, 4vw, 3rem);
  background: linear-gradient(180deg, rgba(7,17,13,0.78), rgba(7,17,13,0.25));
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}

.site-nav.scrolled {
  top: 0;
  background: rgba(7,17,13,0.94);
  box-shadow: 0 8px 24px rgba(0,0,0,0.35);
}

.site-nav.scrolled::after {
  content: "";
  position: absolute;
  inset: auto 0 -2px 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--color-accent), transparent);
  opacity: 0.65;
}

.brand-lockup {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.brand-lockup img {
  width: clamp(114px, 15.6vw, 195px);
  height: clamp(114px, 15.6vw, 195px);
  object-fit: contain;
  filter: drop-shadow(0 10px 24px rgba(0,0,0,0.4));
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.mobile-menu-toggle {
  display: none;
  min-width: 48px;
  min-height: 48px;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 12px;
  background: rgba(20,30,25,0.88);
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
}

/* ── Trust / Why / Step Grids ──────────────────────────────────────────── */
.trust-grid,
.why-grid,
.step-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.trust-badge,
.why-card,
.step-card {
  background: rgba(16,30,22,0.78);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  padding: 1.5rem;
  text-align: center;
  transition: transform var(--duration-normal) var(--ease-out);
}

.trust-badge:hover,
.why-card:hover,
.step-card:hover,
.service-card-item:hover,
.ethics-card:hover,
.testimonial-card:hover {
  transform: translateY(-4px);
}

/* ── Floating CTA (Homepage) ───────────────────────────────────────────── */
.floating-cta {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: var(--z-floating-cta);
  display: inline-flex;
  align-items: center;
  box-shadow: var(--shadow-xl), var(--shadow-glow-strong);
  animation: slideUp var(--duration-slower) var(--ease-out);
}

/* ── Responsive Homepage Adjustments ───────────────────────────────────── */
@media (max-width: 768px) {
  .hero-info-strip {
    grid-template-columns: 1fr;
    gap: 0.8rem;
  }
  
  .info-divider,
  .info-thumb {
    display: none;
  }
  
  .form-row,
  .service-detail-card,
  .service-detail-card.reverse {
    grid-template-columns: 1fr;
  }
  
  .service-detail-card.reverse .service-img-col {
    order: 0;
  }
  
  .service-img-col {
    min-height: 230px;
  }
  
  .floating-cta {
    left: 1rem;
    right: 1rem;
    justify-content: center;
  }
  
  .site-nav {
    padding: 0.5rem 0.75rem;
  }
  
  .brand-lockup img {
    width: 92px;
    height: 92px;
  }
}

@media (max-width: 480px) {
  .service-card-img-wrap,
  .service-card-img,
  .gallery-item {
    height: 190px;
  }
  
  .site-nav {
    padding: 0.5rem 0.75rem;
  }
  
  .brand-lockup img {
    width: 92px;
    height: 92px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
  
  #hero .hero-word,
  #hero .status-badge.hero-reveal,
  #hero p.hero-reveal,
  #hero .btn-group.hero-reveal,
  #hero .hero-info-strip.hero-reveal,
  .section-3d-reveal > .glass-card,
  .section-3d-reveal .services-cards-grid > *,
  .section-3d-reveal .gallery-grid > *,
  .section-3d-reveal .ethics-grid > *,
  .section-3d-reveal .testimonial-grid > *,
  .section-3d-reveal .trust-grid > *,
  .section-3d-reveal .why-grid > *,
  .section-3d-reveal .step-grid > * {
    opacity: 1 !important;
    transform: none !important;
  }
  
  .section-3d-reveal .bg-layer {
    transform: none !important;
  }
}