/*
Theme Name: FloorXMan
Theme URI: https://floorxman.com
Author: OpenAI
Description: Custom one-page flooring installation theme for FloorXMan.
Version: 1.7.0
Text Domain: floorxman-theme
*/

:root {
  --bg: #f6efe7;
  --bg-soft: #fbf7f2;
  --surface: #fffdfa;
  --surface-strong: #ffffff;
  --surface-dark: #1d1814;
  --surface-dark-soft: #2a241f;
  --text: #241a12;
  --muted: #6d5848;
  --muted-strong: #8a715d;
  --line: rgba(46, 29, 16, 0.12);
  --line-strong: rgba(255, 255, 255, 0.18);
  --accent: #c27f46;
  --accent-strong: #9d6234;
  --accent-soft: #ead5c0;
  --white: #ffffff;
  --shadow-xl: 0 30px 70px rgba(70, 38, 14, 0.18);
  --shadow-lg: 0 20px 48px rgba(74, 46, 24, 0.12);
  --shadow-md: 0 14px 30px rgba(74, 46, 24, 0.08);
  --radius-xl: 36px;
  --radius-lg: 28px;
  --radius-md: 22px;
  --radius-sm: 16px;
  --header-height: 92px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Manrope', sans-serif;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

section[id] {
  scroll-margin-top: calc(var(--header-height) + 18px);
}

/* Elementor section reset — remove default spacing */
.elementor-top-section {
  margin: 0;
  padding: 0;
}

.elementor-section-wrap > .elementor-top-section + .elementor-top-section {
  margin-top: 0;
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-shell {
  overflow: clip;
}

.fx-shell,
.fx-shell-wide {
  width: min(100%, 1240px);
  margin: 0 auto;
  padding: 0 28px;
}

.fx-shell-wide {
  width: min(100%, 1480px);
}

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 120;
  transition: background 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
  border-bottom: 1px solid transparent;
}

.site-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(12, 8, 6, 0.48), rgba(12, 8, 6, 0));
  opacity: 1;
  transition: opacity 220ms ease;
  pointer-events: none;
}

.site-header.is-scrolled {
  background: rgba(252, 248, 241, 0.88);
  border-color: var(--line);
  box-shadow: 0 14px 40px rgba(18, 12, 8, 0.08);
  backdrop-filter: blur(16px);
}

.site-header.is-scrolled::before {
  opacity: 0;
}

.header-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
  width: 100%;
  min-height: var(--header-height);
  padding: 18px 28px;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  max-width: 320px;
  padding: 0;
  background: none;
  border: 0;
  border-radius: 0;
  backdrop-filter: none;
  box-shadow: none;
}

.brand-logo {
  width: clamp(120px, 12vw, 180px);
  height: auto;
  filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.22));
}

.site-header.is-scrolled .site-brand {
  background: none;
  backdrop-filter: none;
}

.site-nav {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: clamp(18px, 2vw, 30px);
  justify-self: center;
}

.site-nav a {
  position: relative;
  color: rgba(255, 255, 255, 0.94);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: color 180ms ease, opacity 180ms ease;
}

.site-header.is-scrolled .site-nav a {
  color: var(--text);
}

.site-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -7px;
  height: 2px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 180ms ease;
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  transform: scaleX(1);
}

.nav-cta {
  display: none;
}

.header-actions {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.header-phone {
  color: rgba(255, 255, 255, 0.94);
  font-weight: 700;
  letter-spacing: 0.01em;
}

.site-header.is-scrolled .header-phone {
  color: var(--text);
}

.header-cta,
.fx-button,
.fx-button-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 24px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: transform 180ms ease, background 180ms ease, color 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.header-cta,
.fx-button {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
  color: var(--white);
  box-shadow: 0 18px 36px rgba(157, 98, 52, 0.28);
}

.header-cta:hover,
.fx-button:hover,
.fx-button:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 22px 42px rgba(157, 98, 52, 0.34);
}

.fx-button-ghost {
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.fx-button-ghost:hover,
.fx-button-ghost:focus-visible {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.16);
}

.nav-toggle {
  display: none;
  place-items: center;
  gap: 5px;
  width: 48px;
  height: 48px;
  padding: 0;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 14px;
  backdrop-filter: blur(10px);
}

.site-header.is-scrolled .nav-toggle {
  background: rgba(36, 26, 18, 0.05);
  border-color: var(--line);
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 999px;
  background: var(--white);
}

.site-header.is-scrolled .nav-toggle span {
  background: var(--text);
}

.fx-hero {
  position: relative;
  min-height: min(100svh, 900px);
  background: #1c1714;
  color: var(--white);
  overflow: hidden;
}

.fx-hero-slides,
.fx-hero-slide {
  position: absolute;
  inset: 0;
}

.fx-hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 760ms ease;
}

.fx-hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
}

.fx-hero-image,
.fx-hero-shade {
  position: absolute;
  inset: 0;
}

.fx-hero-image {
  background-image: var(--slide-image);
  background-position: center center;
  background-size: cover;
  transform: scale(1.08);
  transition: transform 6.2s ease;
}

.fx-hero-slide.is-active .fx-hero-image {
  transform: scale(1.01);
}

.fx-hero-shade {
  background:
    linear-gradient(90deg, rgba(9, 7, 5, 0.78) 0%, rgba(9, 7, 5, 0.42) 38%, rgba(9, 7, 5, 0.14) 70%, rgba(9, 7, 5, 0.32) 100%),
    linear-gradient(180deg, rgba(11, 8, 6, 0.16) 0%, rgba(11, 8, 6, 0.34) 100%);
}

.fx-hero-stage {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  min-height: min(100svh, 900px);
  padding: calc(var(--header-height) + 60px) 28px 100px;
}

.fx-hero-copy {
  max-width: 660px;
  overflow-wrap: break-word;
  word-break: break-word;
}

.fx-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

.fx-kicker::before {
  content: '';
  width: 54px;
  height: 1px;
  background: currentColor;
}

.fx-hero .fx-kicker {
  color: rgba(255, 241, 224, 0.82);
}

.fx-title,
.fx-section-title,
.fx-service-copy h3 {
  margin: 0;
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 0.96;
}

.fx-title {
  margin-top: 18px;
  font-size: clamp(2.2rem, 4vw, 3.6rem);
  max-width: 18ch;
}

.fx-copy,
.fx-section-copy,
.fx-service-copy p,
.footer-copy {
  font-size: clamp(1rem, 1.3vw, 1.08rem);
  color: rgba(255, 245, 236, 0.84);
}

.fx-copy {
  max-width: 38rem;
  margin: 16px 0 0;
  font-size: clamp(0.9rem, 1.2vw, 1.02rem);
}

.fx-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}

.fx-hero-note {
  margin: 18px 0 0;
  color: rgba(255, 241, 224, 0.78);
  font-size: 0.96rem;
}

.fx-hero-ui {
  position: absolute;
  inset: auto 0 28px;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.fx-hero-service-line {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: rgba(255, 245, 236, 0.88);
  font-size: 0.92rem;
  backdrop-filter: blur(14px);
}

.fx-hero-controls {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.fx-hero-arrow {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
  backdrop-filter: blur(12px);
}

.fx-hero-arrow:hover,
.fx-hero-arrow:focus-visible {
  background: rgba(255, 255, 255, 0.16);
}

.fx-hero-dots {
  display: inline-flex;
  gap: 10px;
  padding: 0 6px;
}

.fx-hero-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
}

.fx-hero-dot.is-active {
  background: var(--white);
  transform: scale(1.25);
}

.fx-section {
  position: relative;
  padding: 110px 0;
}

.fx-section-title {
  font-size: clamp(2.7rem, 5vw, 4.5rem);
  color: var(--text);
}

.fx-section-copy {
  max-width: 42rem;
  margin: 18px 0 0;
  color: var(--muted);
}

.fx-section-head {
  display: grid;
  gap: 18px;
  margin-bottom: 44px;
}

.fx-story {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 252, 247, 0.78) 100%);
}

.fx-story-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(32px, 6vw, 86px);
  align-items: center;
}

.fx-story-media,
.fx-service-media,
.fx-products-photo,
.fx-contact-photo {
  display: flex;
  overflow: hidden;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
}

.fx-story-media {
  aspect-ratio: auto;
}

.fx-story-media img,
.fx-service-media img,
.fx-products-photo img,
.fx-contact-photo img,
.fx-gallery-item img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.fx-story-copy {
  max-width: 520px;
}

.fx-story-list,
.fx-service-bullets {
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 14px;
}

.fx-story-list li,
.fx-service-bullets li {
  position: relative;
  padding-left: 22px;
  color: var(--text);
  font-weight: 500;
}

.fx-story-list li::before,
.fx-service-bullets li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
}

.fx-story-note {
  margin: 28px 0 0;
  color: var(--muted-strong);
  font-size: 0.98rem;
}

.fx-services {
  background: var(--bg-soft);
}

.fx-service-stack {
  display: grid;
  gap: 74px;
}

.fx-service-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 68px);
  align-items: center;
}

.fx-service-row.is-reverse .fx-service-media {
  order: 2;
}

.fx-service-row.is-reverse .fx-service-copy {
  order: 1;
}

.fx-service-media {
  aspect-ratio: auto;
}

.fx-service-copy {
  padding: 14px 0;
}

.fx-service-label {
  display: inline-block;
  margin-bottom: 12px;
  color: var(--accent-strong);
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.fx-service-copy h3 {
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  color: var(--text);
  max-width: 12ch;
}

.fx-service-copy p {
  margin: 16px 0 0;
  color: var(--muted);
}

.fx-tier-table {
  margin-top: 28px;
  border-top: 1px solid var(--line);
}

.fx-tier-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}

.fx-tier-row strong {
  color: var(--text);
  font-size: 1rem;
}

.fx-tier-row--3col,
.fx-tier-row--header {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 8px;
}

.fx-tier-row--header {
  border-bottom: 0;
  padding-bottom: 8px;
}

.fx-tier-row--header strong {
  font-size: 0.78rem;
  color: var(--muted-strong);
  font-weight: 700;
  letter-spacing: 0.06em;
}

.fx-tier-note {
  margin-top: 10px;
  color: var(--muted-strong);
  font-size: 0.82rem;
  font-style: italic;
}

.fx-services-note {
  display: grid;
  gap: 10px;
  margin-top: 54px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}

.fx-services-note strong {
  color: var(--text);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.fx-services-note p {
  margin: 0;
  max-width: 58rem;
  color: var(--muted);
}

.fx-products {
  background: linear-gradient(180deg, rgba(233, 218, 205, 0.24) 0%, rgba(255, 255, 255, 0) 100%);
}

.fx-products-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.7fr) minmax(0, 0.7fr);
  gap: 22px;
  align-items: stretch;
}

.fx-products-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 100%;
  padding-right: clamp(0px, 2vw, 28px);
}

.fx-products-copy .fx-section-copy {
  color: var(--muted);
}

.fx-coming-soon {
  display: inline-flex;
  width: fit-content;
  margin-top: 24px;
  padding: 12px 18px;
  border-radius: 999px;
  background: rgba(194, 127, 70, 0.1);
  color: var(--accent-strong);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.77rem;
}

.fx-products-photo {
  position: relative;
  aspect-ratio: 4 / 5;
  min-height: 420px;
}

/* ── Projects Section ── */

.fx-projects {
  background: var(--bg-soft);
}

.fx-projects-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 32px;
}

.fx-filter-btn {
  padding: 10px 20px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: all 180ms ease;
}

.fx-filter-btn:hover,
.fx-filter-btn.is-active {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
  color: var(--white);
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(157, 98, 52, 0.22);
}

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

.fx-projects-card {
  cursor: pointer;
  transition: transform 220ms ease, opacity 320ms ease;
}

.fx-projects-card:hover {
  transform: translateY(-4px);
}

.fx-projects-card.is-hidden {
  display: none;
}

.fx-projects-frame {
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  margin: 0;
  line-height: 0;
  font-size: 0;
}

.fx-projects-frame img {
  display: block;
  width: 100%;
  border-radius: var(--radius-lg);
  transition: transform 320ms ease;
}

.fx-projects-card:hover .fx-projects-frame img {
  transform: scale(1.04);
}

.fx-projects-label {
  display: inline-block;
  margin-top: 10px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(36, 26, 18, 0.06);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ── Lightbox ── */

.fx-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.fx-lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: 16px;
  object-fit: contain;
}

.fx-lightbox-close,
.fx-lightbox-prev,
.fx-lightbox-next {
  position: absolute;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  border-radius: 999px;
  backdrop-filter: blur(8px);
  font-size: 1.4rem;
  cursor: pointer;
  transition: background 180ms ease;
}

.fx-lightbox-close:hover,
.fx-lightbox-prev:hover,
.fx-lightbox-next:hover {
  background: rgba(255, 255, 255, 0.24);
}

.fx-lightbox-close {
  top: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
}

.fx-lightbox-prev,
.fx-lightbox-next {
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
}

.fx-lightbox-prev { left: 20px; }
.fx-lightbox-next { right: 20px; }

@media (max-width: 1160px) {
  .fx-projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .fx-projects-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .fx-projects-frame {
    border-radius: var(--radius-md);
  }

  .fx-lightbox {
    padding: 16px;
  }

  .fx-lightbox-prev,
  .fx-lightbox-next {
    width: 40px;
    height: 40px;
    font-size: 1.1rem;
  }
}

.fx-gallery {
  padding-bottom: 128px;
  overflow: hidden;
}

.fx-gallery-marquee {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 8px 28px 0;
  mask-image: linear-gradient(90deg, transparent 0%, #000 7%, #000 93%, transparent 100%);
}

.fx-gallery-track {
  display: flex;
  gap: 22px;
  width: max-content;
  animation: fx-gallery-scroll 42s linear infinite;
  will-change: transform;
}

.fx-gallery-marquee:hover .fx-gallery-track {
  animation-play-state: paused;
}

.fx-gallery-slide {
  display: grid;
  gap: 14px;
  flex: 0 0 clamp(310px, 29vw, 430px);
}

.fx-gallery-frame {
  display: flex;
  overflow: hidden;
  border-radius: 30px;
  background: #d8cbbb;
  box-shadow: var(--shadow-md);
  min-height: 220px;
  max-height: 320px;
}

.fx-gallery-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.fx-gallery-meta {
  display: grid;
  gap: 4px;
  padding: 0 8px;
}

.fx-gallery-meta strong {
  color: var(--text);
  font-size: 1.05rem;
  line-height: 1.2;
}

.fx-gallery-meta span {
  color: var(--muted);
  font-size: 0.92rem;
}

@keyframes fx-gallery-scroll {
  from {
    transform: translate3d(0, 0, 0);
  }

  to {
    transform: translate3d(-50%, 0, 0);
  }
}

.fx-contact {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(234, 221, 210, 0.34) 100%);
  padding-top: 56px;
}

.fx-contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: clamp(28px, 5vw, 70px);
  align-items: start;
}

.fx-contact-side {
  display: grid;
  gap: 28px;
}

.fx-contact-intro {
  max-width: 520px;
}

.fx-contact-list {
  display: grid;
  gap: 16px;
  margin: 28px 0 0;
}

.fx-contact-list dt {
  margin-bottom: 2px;
  color: var(--muted-strong);
  font-size: 0.77rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.fx-contact-list dd {
  margin: 0;
  color: var(--text);
  font-weight: 600;
}

.fx-contact-photo {
  aspect-ratio: auto;
}

.fx-contact-header {
  max-width: 680px;
  margin-bottom: 32px;
}

.fx-contact-title {
  margin: 0;
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(3.2rem, 8vw, 5.5rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 0.96;
  color: var(--text);
}

.fx-contact-form-card {
  padding: clamp(26px, 3vw, 38px);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-xl);
  backdrop-filter: blur(14px);
}

.fx-form-fallback {
  padding: 24px;
  border-radius: var(--radius-md);
  background: rgba(194, 127, 70, 0.08);
  color: var(--text);
}

/* ── Estimate Form ── */

.fx-estimate-form {
  display: grid;
  gap: 16px;
}

.fx-form-row {
  display: grid;
  gap: 8px;
}

.fx-form-row--half {
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.fx-form-label {
  display: grid;
  gap: 8px;
  color: var(--text);
  font-size: 0.94rem;
  font-weight: 700;
}

.fx-optional {
  font-weight: 400;
  color: var(--muted-strong);
  font-size: 0.88rem;
}

.fx-estimate-form input,
.fx-estimate-form textarea,
.fx-estimate-form select {
  width: 100%;
  padding: 15px 16px;
  border: 1px solid rgba(46, 29, 16, 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  outline: 0;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.fx-estimate-form textarea {
  min-height: 120px;
  resize: vertical;
}

.fx-estimate-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%236d5848' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 42px;
}

.fx-estimate-form input:focus,
.fx-estimate-form textarea:focus,
.fx-estimate-form select:focus {
  border-color: rgba(157, 98, 52, 0.4);
  box-shadow: 0 0 0 4px rgba(194, 127, 70, 0.12);
  background: var(--surface-strong);
}

.fx-estimate-form input::placeholder,
.fx-estimate-form textarea::placeholder {
  color: var(--muted-strong);
  opacity: 0.6;
}

/* ── Conditional fields ── */

.fx-conditional {
  display: grid;
  gap: 16px;
  animation: fxSlideIn 320ms ease;
}

@keyframes fxSlideIn {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── Calculator ── */

.fx-calculator {
  animation: fxSlideIn 420ms ease;
}

.fx-calculator-inner {
  display: grid;
  gap: 14px;
  padding: 24px 28px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(194, 127, 70, 0.08) 0%, rgba(194, 127, 70, 0.04) 100%);
  overflow: visible;
  border: 1px solid rgba(194, 127, 70, 0.18);
}

.fx-calculator-label {
  color: var(--accent-strong);
  font-size: 0.77rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.fx-calculator-price {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
  white-space: nowrap;
}

.fx-calculator-removal {
  color: var(--muted);
  font-size: 1rem;
  font-weight: 600;
}

.fx-calculator-total {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.6rem, 3.5vw, 2rem);
  font-weight: 700;
  color: var(--accent-strong);
  line-height: 1.2;
  white-space: nowrap;
  padding-top: 8px;
  margin-top: 8px;
  border-top: 1px solid rgba(194, 127, 70, 0.2);
}

.fx-calculator-note {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

/* ── Submit ── */

.fx-form-submit {
  appearance: none;
  border: 0;
  width: 100%;
  min-height: 56px;
  padding: 0 24px;
  margin-top: 4px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
  color: var(--white);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  box-shadow: 0 18px 34px rgba(157, 98, 52, 0.26);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.fx-form-submit:hover,
.fx-form-submit:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 22px 42px rgba(157, 98, 52, 0.34);
}

.fx-form-submit:disabled {
  opacity: 0.6;
  pointer-events: none;
}

/* ── Response ── */

.fx-form-response {
  padding: 16px 20px;
  border-radius: 16px;
  font-size: 0.94rem;
  font-weight: 600;
}

.fx-form-response.is-success {
  background: rgba(46, 160, 67, 0.1);
  color: #1a7f37;
  border: 1px solid rgba(46, 160, 67, 0.2);
}

.fx-form-response.is-error {
  background: rgba(207, 34, 46, 0.08);
  color: #cf222e;
  border: 1px solid rgba(207, 34, 46, 0.18);
}

@media (max-width: 720px) {
  .fx-form-row--half {
    grid-template-columns: 1fr;
  }
}

.site-footer {
  background: linear-gradient(180deg, #1c1713 0%, #110d0b 100%);
  color: rgba(255, 245, 236, 0.86);
  padding: 70px 0 28px;
}

.footer-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.7fr) minmax(0, 0.85fr);
  gap: 36px;
  align-items: start;
}

.footer-brand {
  display: inline-flex;
  width: fit-content;
  padding: 0;
  border-radius: 0;
  background: none;
  border: 0;
  backdrop-filter: none;
  box-shadow: none;
}

.footer-brand .brand-logo {
  width: clamp(190px, 18vw, 300px);
}

.footer-copy {
  max-width: 34rem;
  margin: 18px 0 0;
  color: rgba(255, 245, 236, 0.72);
}

.footer-heading {
  display: inline-block;
  margin-bottom: 16px;
  color: rgba(255, 245, 236, 0.62);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.footer-links,
.footer-contact-list {
  display: grid;
  gap: 12px;
}

.footer-links a,
.footer-contact-list a,
.footer-contact-list span {
  color: rgba(255, 245, 236, 0.88);
  font-weight: 600;
}

.footer-cta-block .fx-button {
  margin-top: 22px;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 34px;
  padding-top: 22px;
  border-top: 1px solid var(--line-strong);
  color: rgba(255, 245, 236, 0.56);
  font-size: 0.88rem;
}

.reveal-on-scroll {
  opacity: 0;
  transform: translateY(42px);
  transition: opacity 720ms ease, transform 720ms ease;
  transition-delay: var(--reveal-delay, 0ms);
}

.reveal-on-scroll.is-revealed {
  opacity: 1;
  transform: translateY(0);
}

.has-motion .fx-hero-copy > * {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 650ms ease, transform 650ms ease;
}

.is-loaded .fx-hero-slide.is-active .fx-hero-copy > * {
  opacity: 1;
  transform: translateY(0);
}

.is-loaded .fx-hero-slide.is-active .fx-hero-copy > *:nth-child(1) {
  transition-delay: 120ms;
}

.is-loaded .fx-hero-slide.is-active .fx-hero-copy > *:nth-child(2) {
  transition-delay: 190ms;
}

.is-loaded .fx-hero-slide.is-active .fx-hero-copy > *:nth-child(3) {
  transition-delay: 260ms;
}

.is-loaded .fx-hero-slide.is-active .fx-hero-copy > *:nth-child(4) {
  transition-delay: 330ms;
}

.is-loaded .fx-hero-slide.is-active .fx-hero-copy > *:nth-child(5) {
  transition-delay: 400ms;
}

@media (max-width: 1160px) {
  .site-nav {
    gap: 18px;
  }

  .header-phone {
    display: none;
  }

  .fx-products-grid {
    grid-template-columns: 1fr 1fr;
  }

  .fx-products-copy {
    grid-column: 1 / -1;
    padding-right: 0;
  }

  .fx-gallery-slide {
    flex-basis: clamp(280px, 40vw, 360px);
  }
}

@media (max-width: 980px) {
  :root {
    --header-height: 82px;
  }

  .header-inner {
    grid-template-columns: auto auto;
    justify-content: space-between;
  }

  .nav-toggle {
    display: grid;
  }

  .site-nav {
    position: fixed;
    top: calc(var(--header-height) + 14px);
    left: 18px;
    right: 18px;
    display: grid;
    justify-items: start;
    gap: 14px;
    padding: 22px;
    border-radius: 26px;
    background: rgba(255, 252, 248, 0.96);
    border: 1px solid rgba(46, 29, 16, 0.1);
    box-shadow: var(--shadow-xl);
    transform: translateY(-18px);
    opacity: 0;
    pointer-events: none;
  }

  .site-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .site-nav a,
  .site-header.is-scrolled .site-nav a {
    color: var(--text);
    font-size: 1rem;
  }

  .nav-cta {
    display: inline-flex;
    margin-top: 8px;
    padding: 0 18px;
    min-height: 48px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
    color: var(--white) !important;
  }

  .header-actions {
    display: none;
  }

  .fx-hero-stage {
    align-items: flex-end;
    padding: calc(var(--header-height) + 74px) 28px 138px;
  }

  .fx-title {
    max-width: 12ch;
  }

  .fx-story-grid,
  .fx-service-row,
  .fx-contact-layout,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .fx-service-row.is-reverse .fx-service-media,
  .fx-service-row.is-reverse .fx-service-copy {
    order: initial;
  }

  .fx-contact-header {
    margin-bottom: 22px;
  }

  .fx-contact-title {
    font-size: clamp(2.8rem, 12vw, 4rem);
  }

  .fx-contact-intro,
  .fx-story-copy {
    max-width: none;
  }

  .fx-contact-photo {
    display: none;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 720px) {
  .fx-shell,
  .fx-shell-wide,
  .fx-gallery-marquee {
    padding-left: 20px;
    padding-right: 20px;
  }

  .header-inner {
    padding: 16px 20px;
  }

  .site-brand {
    max-width: 180px;
  }

  .brand-logo {
    width: min(150px, 39vw);
  }

  .fx-hero {
    min-height: 100svh;
  }

  .fx-hero-stage {
    min-height: min(100svh, 700px);
    padding: calc(var(--header-height) + 28px) 20px 80px;
  }

  .fx-title {
    max-width: 14ch;
    font-size: clamp(1.8rem, 7vw, 2.6rem);
  }

  .fx-copy,
  .fx-section-copy,
  .fx-service-copy p,
  .footer-copy {
    font-size: 0.98rem;
  }

  .fx-copy {
    max-width: 20ch;
    margin-top: 16px;
  }

  .fx-hero-note,
  .fx-hero-service-line,
  .fx-hero-arrow {
    display: none;
  }

  .fx-hero-actions {
    flex-direction: column;
    align-items: stretch;
    max-width: 240px;
    margin-top: 24px;
  }

  .fx-button,
  .fx-button-ghost {
    width: 100%;
  }

  .fx-hero-ui {
    display: none;
  }

  .fx-hero-controls {
    justify-content: center;
  }

  .fx-contact .fx-section-title {
    font-size: clamp(2.2rem, 9.5vw, 3.2rem);
  }

  .fx-section {
    padding: 56px 0;
  }

  .fx-service-stack {
    gap: 56px;
  }

  .fx-products-grid {
    grid-template-columns: 1fr;
  }

  .fx-products-photo {
    min-height: 320px;
  }

  .fx-gallery-track {
    gap: 16px;
    animation-duration: 34s;
  }

  .fx-gallery-slide {
    flex-basis: 280px;
  }

  .fx-gallery-frame {
    min-height: 180px;
    max-height: 260px;
  }

  .fx-gallery-meta {
    padding: 0 6px;
  }

  .fx-contact-form-card {
    padding: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
