/* ─────────────────────────────────────────
   STAPLES WATERPROOFING CO. — STYLESHEET
   ───────────────────────────────────────── */

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Variables ── */
:root {
  --black:        #0a0a0a;
  --white:        #fafafa;
  --gray-100:     #f5f5f4;
  --gray-200:     #e7e5e4;
  --gray-300:     #d6d3d1;
  --gray-500:     #78716c;
  --gray-700:     #44403c;
  --teal:         #00979D;
  --teal-dark:    #007f85;
  --glass-bg:     rgba(255,255,255,0.6);
  --glass-border: rgba(255,255,255,0.4);
  --font:         'Inter', system-ui, -apple-system, sans-serif;
  --text-shadow:  0 1px 6px rgba(0,0,0,0.9), 0 0 20px rgba(0,0,0,0.6);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--white);
  color: var(--black);
  line-height: 1.6;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; }

:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
}

/* ── NAV ── */
nav {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 40px 0;
  background: transparent;
}

.nav-logo {
  text-decoration: none;
  flex-shrink: 0;
  display: block;
}

.nav-logo img {
  height: clamp(72px, 11vw, 176px);
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  gap: 34px;
  list-style: none;
  padding-top: 16px;
}

.nav-links a {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #fff;
  text-decoration: none;
  text-shadow: var(--text-shadow);
  transition: opacity 0.2s;
  padding: 6px 0;
  white-space: nowrap;
}

.nav-links a:hover { opacity: 0.7; }

/* ── HAMBURGER ── */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 12px 8px;
  margin-top: 6px;
  background: none;
  border: none;
}

.hamburger span {
  display: block;
  width: 26px;
  height: 2px;
  background: #fff;
  transition: all 0.3s;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.9));
}

/* ── MOBILE MENU ── */
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(10,10,10,0.97);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  overflow-y: auto;
}

.mobile-menu.open { display: flex; }

.mobile-menu-close {
  position: absolute;
  top: 16px;
  right: 20px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.6);
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
  padding: 10px;
  transition: color 0.2s;
}

.mobile-menu-close:hover { color: #fff; }

.mobile-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.mobile-links a {
  font-size: clamp(24px, 7vw, 30px);
  font-weight: 600;
  letter-spacing: -0.5px;
  color: #fff;
  text-decoration: none;
  padding: 12px 24px;
  display: block;
  transition: color 0.2s;
}

.mobile-links a:hover { color: var(--teal); }

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 22px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.03em;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.25s;
  white-space: nowrap;
  min-height: 44px;
}

.btn-dark {
  background: var(--teal);
  color: var(--white);
}

.btn-dark:hover {
  background: var(--teal-dark);
  transform: translateY(-1px);
}

.btn-lg {
  padding: 16px 34px;
  font-size: 15px;
}

/* ── HERO ── */
.hero {
  position: relative;
  height: 100svh;
  min-height: 520px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-image {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0;
  transition: opacity 2s ease;
}

.hero-slide.active { opacity: 1; }

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.55) 0%,
    rgba(0,0,0,0.25) 50%,
    rgba(0,0,0,0.30) 100%
  );
}

.hero-text {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 24px;
  max-width: 1100px;
  width: 100%;
}

.hero-title {
  font-size: clamp(30px, 5.2vw, 76px);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 18px rgba(0,0,0,0.55), 0 1px 3px rgba(0,0,0,0.5);
  text-wrap: balance;
}

.hero-subtitle {
  font-size: clamp(14px, 1.7vw, 23px);
  font-weight: 300;
  letter-spacing: 0.01em;
  color: rgba(255,255,255,0.95);
  margin-top: 14px;
  text-shadow: 0 2px 14px rgba(0,0,0,0.6), 0 1px 3px rgba(0,0,0,0.5);
}

/* ── HERO SLIDESHOW DOTS ── */
.hero-dots {
  position: absolute;
  bottom: 30px;
  right: 40px;
  z-index: 3;
  display: flex;
  gap: 2px;
}

.hero-dot {
  width: 22px;
  height: 22px;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  position: relative;
}

.hero-dot::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.45);
  transition: background 0.3s, transform 0.3s;
}

.hero-dot:hover::after { background: rgba(255,255,255,0.8); }

.hero-dot.active::after {
  background: #fff;
  transform: translate(-50%, -50%) scale(1.25);
}

/* ── MARQUEE ── */
.marquee-wrap {
  overflow: hidden;
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
  padding: 18px 0;
  background: var(--gray-100);
}

.marquee-wrap-logos {
  padding: 36px 0;
  border-top-color: #000;
  border-bottom-color: #000;
}

.marquee-track {
  display: flex;
  gap: 64px;
  white-space: nowrap;
  animation: marquee 60s linear infinite;
  width: max-content;
}

.marquee-track-logos { animation: marquee 50s linear infinite; }

.marquee-track span {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gray-500);
  flex-shrink: 0;
}

.marquee-track .dot {
  color: var(--gray-300);
  font-weight: 300;
}

.marquee-track .logo-item {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.marquee-track .logo-item img {
  height: 72px;
  width: auto;
  display: block;
}

/* ── SECTIONS ── */
section { padding: 120px 80px; }

.section-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray-500);
  margin-bottom: 16px;
}

.section-title {
  font-size: clamp(28px, 3.5vw, 52px);
  font-weight: 300;
  letter-spacing: -1.5px;
  line-height: 1.1;
  color: var(--black);
  margin-bottom: 24px;
}

.section-title strong { font-weight: 700; }

.section-body {
  font-size: 17px;
  color: var(--gray-500);
  line-height: 1.7;
  max-width: 560px;
}

/* ── ABOUT ── */
.about {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.about-image {
  position: relative;
  aspect-ratio: 4/5;
  overflow: hidden;
  background: var(--gray-100);
}

.about-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ── SERVICES ── */
.collection { background: var(--gray-100); }

.collection-header { margin-bottom: 60px; }

/* Cards stretch to a common height so the row bottoms line up; the service
   descriptions vary by ~60 words and would otherwise sit ragged. */
.collection-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  align-items: stretch;
}

.collection-card {
  background: var(--white);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.4s cubic-bezier(0.25,0.46,0.45,0.94), box-shadow 0.4s;
}

.collection-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 60px rgba(0,0,0,0.12);
}

.card-image {
  aspect-ratio: 3/4;
  overflow: hidden;
  background: var(--gray-200);
  position: relative;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.card-body { padding: 24px; }

.card-body h3 {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.4px;
  color: var(--black);
  margin-bottom: 10px;
  line-height: 1.25;
}

.card-body p {
  font-size: 14px;
  color: var(--gray-500);
  line-height: 1.65;
}

/* ── GALLERY / PROJECTS ── */
.projects-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 48px;
  flex-wrap: wrap;
  gap: 24px;
}

.slider-nav {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

.slider-btn {
  width: 48px;
  height: 48px;
  border: 1.5px solid var(--gray-300);
  background: transparent;
  color: var(--black);
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, opacity 0.2s;
}

.slider-btn:hover:not(:disabled) {
  background: var(--black);
  border-color: var(--black);
  color: var(--white);
}

.slider-btn:disabled { opacity: 0.25; cursor: default; }

.projects-slider {
  display: flex;
  gap: 32px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 4px;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.projects-slider::-webkit-scrollbar { display: none; }

.project-card {
  flex: 0 0 clamp(260px, 29vw, 400px);
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
}

.project-media {
  position: relative;
  aspect-ratio: 3/2;
  overflow: hidden;
  background: var(--gray-200);
  margin-bottom: 20px;
}

.project-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.project-media.has-slider img {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.project-media.has-slider img.active { opacity: 1; }

.media-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--black);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.25s, background 0.2s;
  z-index: 2;
}

.media-prev { left: 12px; }
.media-next { right: 12px; }

.project-media:hover .media-btn,
.media-btn:focus-visible { opacity: 1; }

.media-btn:hover { background: #fff; }

.media-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 2;
}

.media-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  transition: background 0.3s;
}

.media-dot.active { background: #fff; }

.project-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.4px;
  color: var(--black);
  margin-bottom: 10px;
  line-height: 1.3;
}

.project-body {
  font-size: 14px;
  color: var(--gray-500);
  line-height: 1.65;
}

/* ── OUR TEAM ── */
.showroom {
  background: var(--black);
  color: var(--white);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  padding: 0;
}

.showroom-content {
  padding: 100px 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.showroom .section-title { color: var(--white); }

.showroom-body {
  color: rgba(255,255,255,0.65);
  font-size: 17px;
  line-height: 1.75;
  max-width: 560px;
}

.showroom-image {
  position: relative;
  overflow: hidden;
  min-height: 500px;
}

.showroom-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: brightness(0.75);
}

/* ── CONTACT ── */
.cta-section {
  text-align: center;
  padding: 140px 80px;
  background: var(--white);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(ellipse, rgba(0,0,0,0.04) 0%, transparent 70%);
  pointer-events: none;
}

.cta-section .section-title {
  font-size: clamp(32px, 5vw, 72px);
  max-width: 800px;
  margin: 0 auto 24px;
}

.cta-section .section-body {
  max-width: 480px;
  margin: 0 auto 48px;
}

.cta-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
}

/* ── FOOTER ── */
footer {
  background: var(--black);
  color: var(--white);
  padding: 80px 80px 40px;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1.4fr 1fr;
  gap: 60px;
  padding-bottom: 60px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 40px;
}

.footer-brand h2 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: var(--white);
  margin-bottom: 12px;
}

.footer-brand p {
  font-size: 14px;
  color: rgba(255,255,255,0.4);
  line-height: 1.7;
  max-width: 280px;
}

.footer-brand-logo {
  height: 64px;
  width: auto;
  margin-top: 24px;
  display: block;
}

.footer-col h4 {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
  margin-bottom: 20px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-col a {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-col a:hover { color: var(--white); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-bottom p {
  font-size: 13px;
  color: rgba(255,255,255,0.3);
}

.social-links { display: flex; gap: 20px; }

.social-links a {
  font-size: 13px;
  color: rgba(255,255,255,0.4);
  text-decoration: none;
  transition: color 0.2s;
}

.social-links a:hover { color: var(--white); }

/* ── MISSING IMAGE PLACEHOLDER ──
   Shown when a referenced job photo has not been supplied yet. Drop the file
   in at the path referenced in the markup and this disappears on its own. */
.img-missing { background: var(--gray-200); }
.img-missing img { visibility: hidden; }

.img-missing::after {
  content: 'Photo to come';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gray-500);
}

/* ── SCROLL REVEAL ── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s cubic-bezier(0.25,0.46,0.45,0.94),
              transform 0.7s cubic-bezier(0.25,0.46,0.45,0.94);
}

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

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ── ZOOM PARALLAX ── */
.zoom-inner {
  will-change: transform;
  transform-origin: center center;
}

/* ── ANIMATIONS ── */
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-25%); }
}

/* ── RESPONSIVE: DESKTOP DOWN (≤1180px) ── */
@media (max-width: 1180px) {
  .collection-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── RESPONSIVE: TABLET (≤1024px) ── */
@media (max-width: 1024px) {
  section { padding: 80px 48px; }
  .cta-section { padding: 100px 48px; }
  .about { grid-template-columns: 1fr; gap: 48px; }
  .about-image { aspect-ratio: 16/9; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 48px; }
  .showroom-content { padding: 80px 48px; }
  footer { padding: 72px 48px 36px; }
}

/* ── RESPONSIVE: NAV COLLAPSE (≤900px) ── */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .nav-logo img { height: clamp(56px, 13vw, 104px); }
  nav { padding: 14px 20px 0; align-items: center; }
}

/* ── RESPONSIVE: MOBILE (≤768px) ── */
@media (max-width: 768px) {
  section { padding: 60px 24px; }
  .cta-section { padding: 80px 24px; }

  .hero-dots { right: 0; left: 0; bottom: 22px; justify-content: center; gap: 0; }
  .hero-dot { width: 18px; height: 18px; }

  .collection-grid { grid-template-columns: 1fr; gap: 20px; }
  .card-image { aspect-ratio: 4/3; }

  .projects-header { margin-bottom: 32px; }
  .projects-slider { gap: 20px; }
  .project-card { flex: 0 0 82vw; }
  .media-btn { opacity: 1; background: rgba(255,255,255,0.75); }

  .showroom { grid-template-columns: 1fr; }
  .showroom-content { padding: 60px 24px; }
  .showroom-image { min-height: 260px; max-height: 60vw; }

  footer { padding: 60px 24px 32px; }
  .footer-top { grid-template-columns: 1fr; gap: 40px; padding-bottom: 40px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 12px; }

  .marquee-track { gap: 40px; }
  .marquee-track .logo-item img { height: 56px; }
  .marquee-wrap-logos { padding: 26px 0; }
}

/* ── RESPONSIVE: SMALL MOBILE (≤480px) ── */
@media (max-width: 480px) {
  .nav-logo img { height: 52px; }
  .hero-text { padding: 0 20px; }
  .project-card { flex: 0 0 86vw; }
  .slider-btn { width: 44px; height: 44px; }
}

/* ── REDUCED MOTION ── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .marquee-track { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-slide, .project-media.has-slider img { transition: none; }
  .collection-card { transition: none; }
}
