/* ========================================
   Flatow Furniture — Styles
   ======================================== */

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

@font-face {
  font-family: 'Flatow Hand';
  src: url('/fonts/FlatowHand-Regular.woff2?v=16') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Flatow Hand';
  src: url('/fonts/FlatowHand-Regular.woff2?v=16') format('woff2');
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --color-bg: #f3efe8;
  --color-bg-white: #faf8f5;
  --color-text: #2c2825;
  --color-text-light: #8a7a5e;
  --color-border: rgba(100, 90, 70, 0.2);
  --color-accent: #8a7a5e;
  --font-display: 'Flatow Hand', Georgia, serif;
  --font-body: 'Crimson Pro', Georgia, serif;
  --header-height: 80px;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
}

body {
  font-family: var(--font-body);
  font-weight: 300;
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

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

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

/* --- Header --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: linear-gradient(180deg, rgba(40, 35, 30, 0.85) 0%, rgba(40, 35, 30, 0.4) 70%, transparent 100%);
  padding: 30px 40px 20px;
  transition: background 0.3s ease;
}

.header-inner {
  position: relative;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 1400px;
  margin: 0 auto;
}

.logo-link {
  position: absolute;
  left: 0;
  flex-shrink: 0;
}

.logo {
  height: 90px;
  width: auto;
}

.main-nav {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 28px;
  align-items: center;
}

.main-nav a {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: 1.6rem;
  color: #fff;
  letter-spacing: 0.02em;
  transition: opacity 0.3s ease;
}

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

.menu-toggle {
  display: none;
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
}

.menu-icon,
.menu-icon::before,
.menu-icon::after {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  transition: transform 0.3s ease;
}

.menu-icon {
  position: relative;
}

.menu-icon::before,
.menu-icon::after {
  content: '';
  position: absolute;
  left: 0;
}

.menu-icon::before {
  top: -7px;
}

.menu-icon::after {
  top: 7px;
}

.menu-toggle[aria-expanded="true"] .menu-icon {
  background: transparent;
}

.menu-toggle[aria-expanded="true"] .menu-icon::before {
  top: 0;
  transform: rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-icon::after {
  top: 0;
  transform: rotate(-45deg);
}

.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99;
  background: #2c2825;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
}

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

.mobile-nav a {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: 2.1rem;
  color: #fff;
}

body.menu-open {
  overflow: hidden;
}

/* --- Hero --- */
.hero {
  width: 100%;
  height: 100vh;
  overflow: visible;
  position: relative;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* --- Intro Section --- */
.intro {
  padding: 80px 40px;
  max-width: 1300px;
  margin: 0 auto;
}

.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.intro-text p {
  margin-bottom: 18px;
  font-size: 1rem;
  line-height: 1.8;
}

.intro-image img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

.email-link {
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 400;
  transition: opacity 0.3s ease;
}

.email-link:hover {
  opacity: 0.7;
}

/* The mailto link created after reveal — wraps long addresses on narrow screens */
.email-container .email-link {
  word-break: break-all;
}

/* --- Click-to-Reveal Email / Phone --- */
.email-container,
.phone-container {
  display: inline-flex;
  vertical-align: middle;
}

.email-reveal-btn,
.phone-reveal-btn {
  /* WCAG 2.5.5 / iOS HIG: 44px min tap target */
  min-height: 44px;
  min-width: 44px;
  padding: 10px 22px;
  cursor: pointer;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1rem;
  color: var(--color-text);
  background: var(--color-bg-white);
  border: 1px solid var(--color-border);
  border-radius: 2px;
  letter-spacing: 0.02em;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.email-reveal-btn:hover,
.phone-reveal-btn:hover,
.email-reveal-btn:focus-visible,
.phone-reveal-btn:focus-visible {
  background: #ede7dc;
  border-color: var(--color-accent);
}

.email-reveal-btn:focus-visible,
.phone-reveal-btn:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.email-reveal-btn:active,
.phone-reveal-btn:active {
  background: #e3dcce;
}

/* On the dark footer background, invert the colors */
.site-footer .email-reveal-btn,
.site-footer .phone-reveal-btn {
  color: var(--color-bg);
  background: transparent;
  border-color: rgba(243, 239, 232, 0.4);
}

.site-footer .email-reveal-btn:hover,
.site-footer .phone-reveal-btn:hover,
.site-footer .email-reveal-btn:focus-visible,
.site-footer .phone-reveal-btn:focus-visible {
  background: rgba(243, 239, 232, 0.1);
  border-color: var(--color-bg);
}

.site-footer .email-reveal-btn:focus-visible,
.site-footer .phone-reveal-btn:focus-visible {
  outline-color: var(--color-bg);
}

/* The tel: link rendered after reveal */
.phone-container .phone-link {
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 400;
}

/* Footer stacks the email + phone reveal buttons vertically and centers them. */
.site-footer .footer-reveal-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

/* --- Section Titles --- */
.section-title {
  font-weight: 400;
  font-style: normal;
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  line-height: 1.2;
  color: var(--color-text);
  letter-spacing: -0.01em;
}

/* --- Tagline Overlay --- */
.tagline {
  position: absolute;
  bottom: -1.2em;
  left: 0;
  right: 0;
  z-index: 2;
  text-align: center;
  font-family: var(--font-body);
  font-weight: 300;
  font-size: clamp(1.4rem, 3vw, 2.4rem);
  color: #fff;
  line-height: 1.5;
  letter-spacing: 0.04em;
  margin: 0;
  padding: 0 20px;
  text-shadow:
    0 0 20px rgba(0, 0, 0, 0.7),
    0 0 40px rgba(0, 0, 0, 0.5);
}

/* --- Gallery (Full-width Feature Layout) --- */
.gallery-full {
  padding: 0;
}

.gallery-feature {
  display: grid;
  grid-template-columns: 3fr 2fr;
  min-height: 70vh;
}

.gallery-feature.reverse {
  grid-template-columns: 2fr 3fr;
}

.gallery-feature.reverse .gallery-feature-image {
  order: 2;
}

.gallery-feature.reverse .gallery-feature-info {
  order: 1;
}

.gallery-feature-image {
  position: relative;
  overflow: hidden;
}

.gallery-feature-image .carousel-track {
  display: block;
  height: 100%;
}

.gallery-feature-image .carousel-slide {
  display: none;
  height: 100%;
}

.gallery-feature-image .carousel-slide.active {
  display: block;
}

.gallery-feature-image .carousel-slide picture {
  display: block;
  width: 100%;
  height: 100%;
}

.gallery-feature-image .carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gallery-feature-image .carousel-slide img:hover {
  transform: scale(1.02);
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  color: #fff;
  border: none;
  width: 44px;
  height: 44px;
  font-size: 1.4rem;
  cursor: pointer;
  transition: opacity 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
  opacity: 0.8;
}

.carousel-btn:hover {
  opacity: 1;
}

.carousel-btn.prev {
  left: 12px;
}

.carousel-btn.next {
  right: 12px;
}

.gallery-feature-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px 50px;
}

.gallery-feature-info h2 {
  font-weight: 400;
  font-style: normal;
  font-size: clamp(1.4rem, 2.2vw, 1.8rem);
  margin-bottom: 16px;
  color: var(--color-text);
  line-height: 1.2;
}

.gallery-feature-info p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--color-text);
}

/* --- Reviews --- */
.reviews {
  padding: 40px 40px 80px;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.reviews .section-title {
  margin-bottom: 30px;
}

.google-reviews-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border: 1px solid var(--color-border);
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 400;
  transition: background 0.3s ease;
  margin-bottom: 40px;
}

.google-reviews-link:hover {
  background: rgba(0, 0, 0, 0.03);
}

.reviews-carousel {
  position: relative;
  padding: 0 50px;
}

.reviews-carousel > .carousel-btn {
  top: 40%;
  background: transparent;
  border: 1px solid var(--color-border);
  color: var(--color-text-light);
  width: 40px;
  height: 40px;
  font-size: 1.5rem;
}

.reviews-carousel > .carousel-btn.prev {
  left: 0;
}

.reviews-carousel > .carousel-btn.next {
  right: 0;
}

.reviews-carousel > .carousel-btn:hover {
  background: rgba(0, 0, 0, 0.03);
}

.reviews-track {
  overflow: hidden;
}

.review {
  display: none;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.review.active {
  display: flex;
}

.stars {
  color: var(--color-accent);
  font-size: 1.4rem;
  letter-spacing: 4px;
  margin-bottom: 20px;
}

.review-text {
  border: none;
  margin: 0;
  padding: 0;
  font-family: var(--font-body);
  font-style: italic;
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--color-text);
  max-height: 160px;
  overflow: hidden;
  position: relative;
  transition: max-height 0.5s ease;
}

.review-text::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 50px;
  background: linear-gradient(transparent, var(--color-bg));
  transition: opacity 0.3s ease;
}

.review:hover .review-text {
  max-height: 600px;
}

.review:hover .review-text::after {
  opacity: 0;
}

.review:hover .hover-hint {
  opacity: 0;
}

.hover-hint {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-light);
  margin-top: 12px;
  transition: opacity 0.3s ease;
}

cite {
  display: block;
  font-style: normal;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-light);
  margin-top: 16px;
}

.review-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 30px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  background: var(--color-border);
  cursor: pointer;
  transition: background 0.3s ease;
  padding: 0;
}

.dot.active {
  background: var(--color-text-light);
}

/* --- About --- */
.about {
  padding: 80px 40px;
  max-width: 1300px;
  margin: 0 auto;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.about-text .section-title {
  margin-bottom: 30px;
}

.about-text p {
  margin-bottom: 18px;
  font-size: 1rem;
  line-height: 1.8;
}

.about-image-mobile {
  display: none;
}

.about-image-mobile img {
  width: 100%;
  height: auto;
}

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

/* --- Social --- */
.social {
  padding: 80px 40px;
  text-align: center;
}

.social .section-title {
  margin-bottom: 20px;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 40px;
}

.social-links a {
  font-style: normal;
  font-size: 1.6rem;
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: opacity 0.3s ease;
}

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

.social-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  max-width: 1200px;
  margin: 0 auto;
}

.social-item {
  aspect-ratio: 1;
  overflow: hidden;
  display: block;
}

.social-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease, opacity 0.3s ease;
}

.social-item:hover img {
  transform: scale(1.05);
  opacity: 0.9;
}

/* --- Gradient Divider --- */
.gradient-divider {
  height: 200px;
  background: linear-gradient(180deg, var(--color-bg) 0%, #d4c9b8 50%, #5a4f42 100%);
}

/* --- Footer --- */
.site-footer {
  background: var(--color-bg-white);
  padding: 60px 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 40px;
  align-items: center;
  max-width: 1000px;
  margin: 0 auto;
  text-align: center;
}

.footer-grid p {
  font-size: 0.95rem;
  line-height: 1.6;
}

.footer-grid .footer-heading {
  font-weight: 400;
  font-style: normal;
  font-size: 1.4rem;
  margin-bottom: 16px;
}

.footer-logo img {
  max-height: 60px;
  width: auto;
  margin: 0 auto;
}

.footer-contact a {
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: opacity 0.3s ease;
}

.footer-contact a:hover {
  opacity: 0.7;
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .main-nav {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .site-header {
    padding: 30px 24px 16px;
  }

  .intro-grid,
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-image {
    display: none;
  }

  .about-image-mobile {
    display: block;
    margin: 10px 0 18px;
  }

  .intro,
  .about,
  .reviews,
  .social {
    padding-left: 24px;
    padding-right: 24px;
  }

  .gallery-feature,
  .gallery-feature.reverse {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .gallery-feature.reverse .gallery-feature-image {
    order: 0;
  }

  .gallery-feature.reverse .gallery-feature-info {
    order: 0;
  }

  .gallery-feature-info {
    padding: 30px 24px;
  }

  .gallery-feature-image .carousel-slide {
    aspect-ratio: 4/3;
  }

  .social-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .footer-logo {
    order: -1;
  }

  .reviews-carousel {
    padding: 0 30px;
  }
}

@media (max-width: 600px) {
  .hero {
    height: 60vh;
  }

  .header-inner {
    justify-content: center;
  }

  .logo-link {
    position: static;
  }

  .logo {
    height: 60px;
  }

  .section-title {
    font-size: 1.6rem;
  }

  .social-grid {
    grid-template-columns: 1fr 1fr;
  }
}
