/* =========================================================
   Alcon Roofing Repair & Cleaning — global styles
   Base resets + keyframes are carried over from the design's
   <helmet>. Everything below the "RESPONSIVE" banner is added
   to make the inline-styled design behave on small screens.
   ========================================================= */

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; padding: 0; background: #090C10; }
::selection { background: #1E6FE0; color: #fff; }
input, select, textarea, button { font-family: inherit; }
select option { background: #11161C; color: #fff; }
details summary::-webkit-details-marker { display: none; }
a { text-decoration: none; }

@keyframes kenburns { from { transform: scale(1.03); } to { transform: scale(1.16) translate(-1.4%, -1.1%); } }
@keyframes marquee  { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes floaty   { 0%,100% { transform: translateY(0); } 50% { transform: translateY(8px); } }
@keyframes glowpulse{ 0%,100% { opacity: 0.55; } 50% { opacity: 0.9; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* =========================================================
   HERO 3D — keep the WebGL canvas from "blowing out" the grid
   track on narrow screens. A grid item defaults to min-width:auto,
   so the canvas's intrinsic pixel width (~670px) forces the hero
   column wider than a phone screen — which pushed the 3D model
   off-screen and shifted the absolutely-positioned "Scroll" cue
   (left:50%) off-center. min-width:0 lets the track size to the
   viewport instead; hero3d.js's ResizeObserver then fits the
   canvas to it.
   ========================================================= */
.hero-grid > * { min-width: 0; }
#hero3d { width: 100%; max-width: 100%; overflow: hidden; }
#hero3d canvas { max-width: 100%; display: block; }

/* =========================================================
   MOBILE NAVIGATION (added — not in original design)
   ========================================================= */

/* Hamburger button — hidden on desktop, shown < 860px */
.nav-hamburger {
  display: none;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 12px;
  background: rgba(255,255,255,0.05);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}
.nav-hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform .3s ease, opacity .2s ease;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Slide-down mobile menu panel */
.mobile-menu {
  position: fixed;
  top: 78px;
  left: 0;
  right: 0;
  z-index: 99;
  background: rgba(9,12,16,0.96);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 18px 40px rgba(0,0,0,0.5);
  padding: 14px 26px 26px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transform: translateY(-12px);
  opacity: 0;
  visibility: hidden;
  transition: transform .3s ease, opacity .3s ease, visibility .3s ease;
}
.mobile-menu.open { transform: translateY(0); opacity: 1; visibility: visible; }
.mobile-menu a.m-link {
  color: rgba(255,255,255,0.82);
  font-size: 17px;
  font-weight: 600;
  padding: 14px 4px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.mobile-menu a.m-link:last-of-type { border-bottom: none; }
.mobile-menu .m-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 16px;
}
.mobile-menu .m-call {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #CE2029;
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  padding: 12px 20px;
  border-radius: 999px;
  box-shadow: 0 6px 22px rgba(206,32,41,0.4);
}

/* =========================================================
   RESPONSIVE — override inline styles where the fixed
   desktop layout would break on tablet / phone.
   ========================================================= */

/* Hero: collapse the two-column grid */
@media (max-width: 980px) {
  .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
    padding-top: 120px !important;
  }
  .hero-3dwrap { max-width: 520px; margin: 0 auto !important; }
  #hero3d { margin-right: 0 !important; height: clamp(340px, 70vw, 480px) !important; }
}

/* Header: swap desktop links for the hamburger menu */
@media (max-width: 860px) {
  .nav-links { display: none !important; }
  .nav-lang  { display: none !important; }
  .nav-hamburger { display: flex !important; }
  /* with the desktop links gone, push the call button + hamburger to the right */
  .nav-call { margin-left: auto !important; }
}

/* Very small phones: trim the call button to its icon */
@media (max-width: 520px) {
  .nav-call-text { display: none !important; }
  .nav-call { padding: 11px !important; }
}

/* Keep generous section rhythm from feeling cramped on phones */
@media (max-width: 600px) {
  .hero-cta { width: 100%; }
  .hero-cta > a { flex: 1; justify-content: center; }
}
