/* =========================================================
   Peter Blackford Flooring — stylesheet
   ========================================================= */

/* ---------------------------------------------------------
   1. DESIGN TOKENS
   --------------------------------------------------------- */
:root {
  /* Brand colours */
  --brand-blue:       #1A5FB4;   /* Royal blue — primary brand */
  --brand-blue-dark:  #0E3B72;   /* Deep navy — header bg, footer */
  --brand-blue-mid:   #1F6FCC;   /* Mid blue — hover states */
  --accent-blue:      #3CADF0;   /* Azure — eyebrows, icons, highlights */
  --accent-blue-light:#70C5F8;   /* Light azure — subtle accents */

  /* Neutrals */
  --white:        #FFFFFF;
  --off-white:    #F7F9FC;
  --light-grey:   #EFF2F6;
  --mid-grey:     #DDE2EA;
  --border:       #CDD5DF;
  --text-dark:    #111827;
  --text-mid:     #4B5563;
  --text-light:   #6B7280;
  --text-muted:   #9CA3AF;

  /* Typography */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;

  /* Spacing scale */
  --space-xs:  8px;
  --space-sm:  16px;
  --space-md:  24px;
  --space-lg:  40px;
  --space-xl:  64px;
  --space-2xl: 96px;

  /* Layout */
  --max-width:       1200px;
  --gutter:          clamp(16px, 4vw, 32px);
  --section-pad:     clamp(64px, 8vw, 112px);

  /* Component sizes */
  --top-bar-h:    40px;
  --header-h:     80px;
  --header-h-sm:  64px;   /* shrunk on scroll */

  /* Effects */
  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  20px;
  --radius-xl:  28px;

  --shadow-sm:  0 1px 4px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md:  0 4px 20px rgba(0,0,0,.07), 0 2px 8px rgba(0,0,0,.04);
  --shadow-lg:  0 16px 48px rgba(0,0,0,.10), 0 4px 16px rgba(0,0,0,.06);
  --shadow-xl:  0 24px 64px rgba(0,0,0,.14), 0 8px 24px rgba(0,0,0,.08);

  --ease:       cubic-bezier(.22, 1, .36, 1);
  --t:          .28s;
  --t-slow:     .55s;
}


/* ---------------------------------------------------------
   2. RESET
   --------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html                   { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body                   { font-family: var(--font-body); font-size: 16px; line-height: 1.65; color: var(--text-dark); background: var(--white); overflow-x: hidden; }
img                    { display: block; max-width: 100%; height: auto; }
a                      { color: inherit; text-decoration: none; }
ul, ol                 { list-style: none; }
button                 { cursor: pointer; border: none; background: none; font: inherit; }
input, select, textarea{ font: inherit; }
h1, h2, h3, h4        { line-height: 1.2; }

/* Reduced-motion: disable all animations for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration:       0.01ms !important;
    animation-iteration-count: 1    !important;
    transition-duration:      0.01ms !important;
  }
  html            { scroll-behavior: auto; }
  .reveal         { opacity: 1 !important; transform: none !important; }
  .hero__img      { animation: none !important; }
}


/* ---------------------------------------------------------
   3. LAYOUT HELPERS
   --------------------------------------------------------- */
.container {
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section-header {
  text-align: center;
  max-width: 620px;
  margin-inline: auto;
  margin-bottom: var(--space-xl);
}

.eyebrow {
  display: block;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-blue);
  margin-bottom: 14px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 14px;
  letter-spacing: -.02em;
}

.section-sub {
  font-size: 1.0625rem;
  color: var(--text-mid);
  line-height: 1.75;
}


/* ---------------------------------------------------------
   4. BUTTONS
   --------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: var(--radius-sm);
  font-size: .9375rem;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  transition: background var(--t) var(--ease),
              color      var(--t) var(--ease),
              box-shadow var(--t) var(--ease),
              transform  var(--t) var(--ease),
              border-color var(--t) var(--ease);
  cursor: pointer;
}

/* Primary */
.btn--primary {
  background: var(--brand-blue);
  color: var(--white);
  box-shadow: 0 2px 10px rgba(26,95,180,.28);
}
.btn--primary:hover {
  background: var(--brand-blue-dark);
  box-shadow: 0 4px 20px rgba(26,95,180,.38);
  transform: translateY(-2px);
}
.btn--primary:active { transform: translateY(0); }

/* White (on dark/hero) */
.btn--white {
  background: var(--white);
  color: var(--brand-blue);
  box-shadow: 0 2px 10px rgba(0,0,0,.12);
}
.btn--white:hover {
  background: #f0f4fb;
  box-shadow: 0 4px 20px rgba(0,0,0,.18);
  transform: translateY(-2px);
}

/* Ghost white (on hero) */
.btn--outline-white {
  background: transparent;
  color: var(--white);
  border: 1.5px solid rgba(255,255,255,.55);
}
.btn--outline-white:hover {
  background: rgba(255,255,255,.12);
  border-color: rgba(255,255,255,.85);
}

/* Small variant */
.btn--sm   { padding: 10px 20px; font-size: .875rem; }

/* Full width */
.btn--full { width: 100%; justify-content: center; }


/* ---------------------------------------------------------
   5. SCROLL-REVEAL ANIMATIONS
   --------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity var(--t-slow) var(--ease),
              transform var(--t-slow) var(--ease);
}
.reveal--right {
  transform: translateX(28px);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

.reveal--delay   { transition-delay: .14s; }
.reveal--delay-2 { transition-delay: .28s; }


/* ---------------------------------------------------------
   6. TOP BAR
   --------------------------------------------------------- */
.top-bar {
  background: var(--brand-blue-dark);
  height: var(--top-bar-h);
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.top-bar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  width: 100%;
}

.top-bar__contact {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.top-bar__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .8125rem;
  font-weight: 500;
  color: rgba(255,255,255,.82);
  transition: color var(--t);
}
.top-bar__link .ph { font-size: .9rem; color: var(--accent-blue); }
.top-bar__link:hover { color: var(--white); }

.top-bar__right {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.top-bar__tagline {
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .04em;
  color: rgba(255,255,255,.5);
}

.top-bar__socials { display: flex; gap: 6px; }

.top-bar__social {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: rgba(255,255,255,.65);
  background: rgba(255,255,255,.07);
  font-size: .875rem;
  transition: color var(--t), background var(--t);
}
.top-bar__social:hover {
  color: var(--white);
  background: rgba(255,255,255,.15);
}


/* ---------------------------------------------------------
   7. HEADER
   --------------------------------------------------------- */
.header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: var(--white);
  height: var(--header-h);
  display: flex;
  align-items: center;
  transition: height var(--t-slow) var(--ease),
              box-shadow var(--t-slow) var(--ease);
}

.header.is-scrolled {
  height: var(--header-h-sm);
  box-shadow: var(--shadow-md);
}

.header__inner {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  width: 100%;
}


/* Logo ---------------------------------------------------- */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.logo__mark {
  color: var(--brand-blue);
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  transition: color var(--t);
}

.logo__text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.logo__name {
  font-family: var(--font-display);
  font-size: .9375rem;
  font-weight: 700;
  color: var(--brand-blue);
  letter-spacing: -.01em;
}

.logo__sub {
  font-size: .65rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-light);
}

.logo--light .logo__mark  { color: var(--accent-blue); }
.logo--light .logo__name  { color: var(--white); }
.logo--light .logo__sub   { color: rgba(255,255,255,.55); }


/* Nav ----------------------------------------------------- */
.nav {
  flex: 1;
  display: flex;
  justify-content: center;
}

.nav__list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav__link {
  position: relative;
  display: block;
  padding: 8px 13px;
  font-size: .875rem;
  font-weight: 500;
  color: var(--text-mid);
  border-radius: var(--radius-sm);
  transition: color var(--t);
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 13px;
  right: 13px;
  height: 2px;
  background: var(--brand-blue);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t) var(--ease);
}

.nav__link:hover,
.nav__link.is-active      { color: var(--brand-blue); }
.nav__link:hover::after,
.nav__link.is-active::after { transform: scaleX(1); }


/* Header actions ------------------------------------------ */
.header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-shrink: 0;
  margin-left: auto; /* push actions to far right when nav is hidden on mobile */
}

/* Phone number link in header */
.header__phone {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: .875rem;
  font-weight: 600;
  color: var(--brand-blue);
  white-space: nowrap;
  padding: 8px 0;
  border-radius: var(--radius-sm);
  transition: color var(--t);
  /* Vertical separator between phone and CTA button */
  padding-right: 18px;
  border-right: 1.5px solid var(--mid-grey);
}
.header__phone:hover { color: var(--brand-blue-dark); }

.header__phone .ph {
  font-size: 1rem;
  color: var(--accent-blue);
  flex-shrink: 0;
  transition: color var(--t);
}
.header__phone:hover .ph { color: var(--brand-blue); }

/* Hamburger button */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 8px 6px;
  border-radius: var(--radius-sm);
  transition: background var(--t);
}
.nav-toggle:hover  { background: var(--light-grey); }

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--text-dark);
  border-radius: 2px;
  transition: transform var(--t) var(--ease), opacity var(--t);
  transform-origin: center;
}

.nav-toggle.is-active span:nth-child(1) { transform: translateY(7px)  rotate(45deg); }
.nav-toggle.is-active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }


/* ---------------------------------------------------------
   8. HERO
   --------------------------------------------------------- */
.hero {
  position: relative;
  min-height: calc(100svh - var(--top-bar-h) - var(--header-h));
  display: flex;
  align-items: center;
  overflow: hidden;
}

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

.hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 60%;
  animation: kenBurns 24s ease-in-out alternate infinite;
}

@keyframes kenBurns {
  from { transform: scale(1);    }
  to   { transform: scale(1.06); }
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    108deg,
    rgba(10,28,58,.88) 0%,
    rgba(14,59,114,.64) 45%,
    rgba(26,95,180,.32) 100%
  );
}

.hero .container {
  position: relative;
  z-index: 1;
  padding-block: clamp(64px, 10vw, 120px);
}

.hero__content {
  max-width: 660px;
}

.hero__eyebrow {
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent-blue);
  margin-bottom: 22px;
}

.hero__headline {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5.5vw, 4.375rem);
  font-weight: 700;
  line-height: 1.08;
  color: var(--white);
  letter-spacing: -.025em;
  margin-bottom: 24px;
}

.hero__body {
  font-size: clamp(1rem, 1.5vw, 1.125rem);
  line-height: 1.75;
  color: rgba(255,255,255,.8);
  margin-bottom: 40px;
  max-width: 540px;
}

.hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero__scroll {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  color: rgba(255,255,255,.55);
  transition: color var(--t);
}
.hero__scroll:hover { color: var(--white); }

.hero__scroll-ring {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  font-size: 1rem;
  animation: scrollBounce 2.2s ease-in-out infinite;
}

@keyframes scrollBounce {
  0%, 100% { transform: translateY(0);   }
  55%       { transform: translateY(7px); }
}


/* ---------------------------------------------------------
   9. ABOUT
   --------------------------------------------------------- */
.about {
  padding-block: var(--section-pad);
  background: var(--white);
}

.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(48px, 6vw, 96px);
}

.about__content .section-title,
.about__content .eyebrow { text-align: left; }

.about__lead {
  font-family: var(--font-display);
  font-size: clamp(1.0625rem, 1.5vw, 1.25rem);
  font-weight: 400;
  font-style: italic;
  line-height: 1.65;
  color: var(--text-dark);
  margin-bottom: 18px;
}

.about__body {
  color: var(--text-mid);
  line-height: 1.8;
  margin-bottom: 32px;
}

/* Stats grid */
.about__stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.stat {
  background: var(--off-white);
  border: 1px solid var(--mid-grey);
  border-radius: var(--radius-md);
  padding: clamp(24px, 3vw, 36px) 24px;
  text-align: center;
  transition: box-shadow var(--t), transform var(--t);
}
.stat:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.stat__num {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--brand-blue);
  line-height: 1;
  margin-bottom: 8px;
}

.stat__sup {
  font-size: 60%;
  color: var(--accent-blue);
  vertical-align: super;
}

.stat__label {
  font-size: .8125rem;
  font-weight: 500;
  color: var(--text-mid);
  line-height: 1.45;
}


/* ---------------------------------------------------------
   10. SERVICES
   --------------------------------------------------------- */
.services {
  padding-block: var(--section-pad);
  background: var(--light-grey);
}

.services__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.service-card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--mid-grey);
  border-radius: var(--radius-md);
  padding: clamp(28px, 3vw, 40px) clamp(24px, 2.5vw, 32px);
  overflow: hidden;
  transition: box-shadow var(--t-slow) var(--ease),
              transform  var(--t-slow) var(--ease),
              border-color var(--t-slow) var(--ease);
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-blue), var(--accent-blue));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t-slow) var(--ease);
}

.service-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px);
  border-color: transparent;
}
.service-card:hover::before { transform: scaleX(1); }

.service-card__icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--brand-blue);
  background: linear-gradient(135deg, rgba(26,95,180,.1), rgba(60,173,240,.1));
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
  transition: background var(--t-slow), color var(--t-slow);
}
.service-card:hover .service-card__icon {
  background: linear-gradient(135deg, var(--brand-blue), var(--accent-blue));
  color: var(--white);
}

.service-card h3 {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 12px;
}

.service-card p {
  font-size: .9375rem;
  color: var(--text-mid);
  line-height: 1.72;
}


/* ---------------------------------------------------------
   11. MATERIALS
   --------------------------------------------------------- */
.materials {
  padding-block: var(--section-pad);
  background: var(--white);
}

.materials__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.material-card {
  border: 1px solid var(--mid-grey);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: box-shadow var(--t-slow) var(--ease),
              transform  var(--t-slow) var(--ease);
}
.material-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px);
}

.material-card__img-wrap {
  height: 200px;
  overflow: hidden;
}
.material-card__img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .65s var(--ease);
}
.material-card:hover .material-card__img-wrap img { transform: scale(1.08); }

.material-card__body {
  padding: clamp(18px, 2vw, 26px);
  background: var(--white);
}
.material-card__body h3 {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 8px;
}
.material-card__body p {
  font-size: .875rem;
  color: var(--text-mid);
  line-height: 1.7;
}


/* ---------------------------------------------------------
   12. GALLERY
   --------------------------------------------------------- */
.gallery {
  padding-block: var(--section-pad);
  background: var(--off-white);
}

.gallery__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: clamp(280px, 36vw, 440px);
  gap: 14px;
}

.gallery__item {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  background: var(--mid-grey); /* placeholder colour while images load */
}

.gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%; /* show upper-mid of portrait shots — captures floor and room */
  display: block;
  transition: transform .7s var(--ease);
}
.gallery__item:hover img { transform: scale(1.06); }

.gallery__item figcaption {
  position: absolute;
  inset-block-end: 0;
  inset-inline: 0;
  padding: 56px 18px 18px;
  background: linear-gradient(transparent, rgba(0,0,0,.7));
  color: var(--white);
  font-size: .8125rem;
  font-weight: 500;
  letter-spacing: .02em;
  display: flex;
  align-items: center;
  gap: 8px;
  transform: translateY(100%);
  transition: transform var(--t-slow) var(--ease);
}
.gallery__item:hover figcaption { transform: translateY(0); }

/* Before / After pill tags */
.gallery__tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 20px;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  flex-shrink: 0;
  background: rgba(255,255,255,.22);
  border: 1px solid rgba(255,255,255,.3);
}

.gallery__tag--after {
  background: rgba(60,173,240,.45);
  border-color: rgba(60,173,240,.6);
}

/* Focus styles for keyboard nav */
.gallery__item:focus-within img { transform: scale(1.06); }
.gallery__item:focus-within figcaption { transform: translateY(0); }

/* Portfolio grid — 6 standalone photos, 3 columns */
.gallery__grid--portfolio {
  margin-top: 14px; /* same as the inter-item gap */
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: clamp(240px, 28vw, 380px);
}


/* ---------------------------------------------------------
   13. TRUST / WHY CHOOSE US
   --------------------------------------------------------- */
.trust {
  padding-block: var(--section-pad);
  background: var(--brand-blue-dark);
}

.trust .eyebrow   { color: var(--accent-blue-light); }
.trust .section-title { color: var(--white); }

.trust__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 36px;
}

.trust-item {
  text-align: center;
  padding: 4px;
}

.trust-item__icon {
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--accent-blue);
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 50%;
  margin: 0 auto 20px;
  transition: background var(--t), transform var(--t);
}
.trust-item:hover .trust-item__icon {
  background: rgba(60,173,240,.18);
  transform: scale(1.08);
}

.trust-item h3 {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 12px;
}

.trust-item p {
  font-size: .9rem;
  color: rgba(255,255,255,.68);
  line-height: 1.72;
}


/* ---------------------------------------------------------
   14. TESTIMONIALS
   --------------------------------------------------------- */
.testimonials {
  padding-block: var(--section-pad);
  background: var(--white);
}

.testimonials__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.testimonial {
  display: flex;
  flex-direction: column;
  gap: 20px;
  background: var(--off-white);
  border: 1px solid var(--mid-grey);
  border-radius: var(--radius-md);
  padding: clamp(24px, 3vw, 32px);
  transition: box-shadow var(--t-slow) var(--ease),
              transform  var(--t-slow) var(--ease),
              border-color var(--t-slow) var(--ease);
}
.testimonial:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  border-color: transparent;
}

.testimonial__stars {
  display: flex;
  gap: 3px;
  color: #F59E0B;
  font-size: .875rem;
}

.testimonial__quote {
  font-family: var(--font-display);
  font-size: .9875rem;
  font-weight: 400;
  font-style: italic;
  line-height: 1.72;
  color: var(--text-dark);
  flex: 1;
  quotes: "\201C" "\201D";
}
.testimonial__quote::before { content: open-quote;  }
.testimonial__quote::after  { content: close-quote; }

.testimonial__author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.testimonial__avatar {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-blue), var(--accent-blue));
  color: var(--white);
  font-size: .75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.testimonial__name {
  font-weight: 600;
  font-size: .875rem;
  color: var(--text-dark);
  font-style: normal;
  display: block;
}

.testimonial__location {
  font-size: .8rem;
  color: var(--text-light);
}


/* ---------------------------------------------------------
   15. CONTACT
   --------------------------------------------------------- */
.contact {
  padding-block: var(--section-pad);
  background: var(--light-grey);
}

.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1.45fr;
  gap: clamp(40px, 6vw, 96px);
  align-items: start;
}

.contact__info .section-title,
.contact__info .eyebrow { text-align: left; }

.contact__intro {
  color: var(--text-mid);
  line-height: 1.75;
  margin-bottom: 40px;
}

.contact__details {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.contact__detail {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  transition: color var(--t);
}
a.contact__detail:hover .contact__detail-value { color: var(--brand-blue); }

.contact__detail-icon {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  background: var(--white);
  border: 1px solid var(--mid-grey);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
  color: var(--brand-blue);
}

.contact__detail-label {
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 4px;
  display: block;
}

.contact__detail-value {
  font-size: .9375rem;
  font-weight: 600;
  color: var(--text-dark);
  transition: color var(--t);
}


/* Form ---------------------------------------------------- */
.contact-form {
  background: var(--white);
  border: 1px solid var(--mid-grey);
  border-radius: var(--radius-xl);
  padding: clamp(28px, 4vw, 48px);
  box-shadow: var(--shadow-lg);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-bottom: 20px;
}
.form-group:last-of-type { margin-bottom: 0; }

.form-group label {
  font-size: .8125rem;
  font-weight: 600;
  color: var(--text-dark);
}

.required { color: var(--brand-blue); }

.form-group input,
.form-group select,
.form-group textarea {
  padding: 12px 15px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--white);
  color: var(--text-dark);
  font-size: .9375rem;
  transition: border-color var(--t), box-shadow var(--t);
  -webkit-appearance: none;
  appearance: none;
}

.form-group select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24'%3E%3Cpath fill='%236B7280' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
  cursor: pointer;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(26,95,180,.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-muted); }

.form-group textarea { resize: vertical; min-height: 96px; }

.contact-form .btn--primary { margin-top: 22px; margin-bottom: 12px; }

.form-note {
  text-align: center;
  font-size: .8rem;
  color: var(--text-light);
}


/* ---------------------------------------------------------
   16. FOOTER
   --------------------------------------------------------- */
.footer { background: var(--brand-blue-dark); }

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.4fr;
  gap: clamp(32px, 4vw, 56px);
  padding-block: clamp(48px, 6vw, 72px);
  border-bottom: 1px solid rgba(255,255,255,.1);
}

.footer__strapline {
  margin-top: 18px;
  font-size: .875rem;
  line-height: 1.75;
  color: rgba(255,255,255,.55);
  max-width: 320px;
}

.footer__socials { display: flex; gap: 8px; margin-top: 22px; }

.footer__social {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: rgba(255,255,255,.6);
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.11);
  font-size: 1rem;
  transition: color var(--t), background var(--t), border-color var(--t);
}
.footer__social:hover {
  color: var(--white);
  background: rgba(255,255,255,.12);
  border-color: rgba(255,255,255,.22);
}

.footer__heading {
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.38);
  margin-bottom: 22px;
}

.footer__nav ul,
.footer__contact-col ul {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer__nav a {
  font-size: .875rem;
  color: rgba(255,255,255,.65);
  transition: color var(--t);
}
.footer__nav a:hover { color: var(--white); }

.footer__contact-col ul a {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .875rem;
  color: rgba(255,255,255,.65);
  transition: color var(--t);
}
.footer__contact-col ul a:hover { color: var(--white); }
.footer__contact-col .ph { color: var(--accent-blue); flex-shrink: 0; font-size: .875rem; }

.footer__cta { margin-top: 24px; }

.footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 24px;
  font-size: .8rem;
  color: rgba(255,255,255,.38);
  flex-wrap: wrap;
  gap: 8px 24px;
}
.footer__bottom a { color: rgba(255,255,255,.48); transition: color var(--t); }
.footer__bottom a:hover { color: rgba(255,255,255,.85); }


/* ---------------------------------------------------------
   17. RESPONSIVE
   --------------------------------------------------------- */

/* ---- 1050px: footer collapses to 2-col ---- */
@media (max-width: 1050px) {
  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer__brand {
    grid-column: span 2;
  }
}

/* ---- 900px: tablet ---- */
@media (max-width: 900px) {
  /* Show hamburger, hide desktop nav */
  .nav-toggle { display: flex; }

  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border-top: 1px solid var(--mid-grey);
    box-shadow: var(--shadow-lg);
    padding: var(--space-md) var(--gutter) var(--space-lg);
    z-index: 99;
  }
  .nav.is-open { display: block; }

  .nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }
  .nav__link {
    font-size: 1rem;
    padding: 12px 14px;
    width: 100%;
  }
  .nav__link::after {
    bottom: 6px;
  }

  /* Header position:sticky makes the nav absolute child visible */
  .header { overflow: visible; }

  /* Top bar: hide tagline */
  .top-bar__tagline { display: none; }

  /* Grids: 2 columns */
  .services__grid,
  .trust__grid,
  .testimonials__grid,
  .materials__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .about__grid { grid-template-columns: 1fr; gap: 48px; }

  /* Gallery: before/after stays 2-col; portfolio drops to 2-col at tablet */
  .gallery__grid--portfolio {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact__grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

/* ---- 640px: mobile ---- */
@media (max-width: 640px) {
  :root {
    --top-bar-h: 36px;
    --header-h:  68px;
  }

  /* Top bar: hide link text, show icons only */
  .top-bar__link span { display: none; }
  .top-bar__link .ph  { font-size: 1rem; color: rgba(255,255,255,.9); }
  .top-bar__contact   { gap: var(--space-sm); }

  /* Header: hide CTA button, keep phone link (it becomes the primary action on mobile) */
  .header__cta        { display: none; }
  .header__phone      { border-right: none; padding-right: 0; font-size: .9375rem; }
  .header__phone .ph  { font-size: 1.125rem; }

  .hero__headline { font-size: clamp(2rem, 9vw, 2.8rem); }
  .hero__body     { font-size: .9375rem; }
  .hero__ctas     { flex-direction: column; }
  .hero__ctas .btn { justify-content: center; }

  .services__grid,
  .trust__grid,
  .testimonials__grid,
  .materials__grid {
    grid-template-columns: 1fr;
  }

  /* Gallery: both grids go single-column on small phones */
  .gallery__grid,
  .gallery__grid--portfolio {
    grid-template-columns: 1fr;
    grid-auto-rows: clamp(260px, 70vw, 340px);
  }

  .about__stats { gap: 14px; }

  .footer__grid {
    grid-template-columns: 1fr;
  }
  .footer__brand { grid-column: span 1; }

  .footer__bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .form-row { grid-template-columns: 1fr; }

  .contact-form {
    padding: 24px 20px;
    border-radius: var(--radius-lg);
  }
}

/* ---- 400px: very small phones ---- */
@media (max-width: 400px) {
  .about__stats {
    grid-template-columns: 1fr 1fr;
  }
}
