/* =====================================================
   FAHARI FURNITURE — STYLESHEET
   ===================================================== */

/* --- Google Font import --- */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500;600;700;800;900&display=swap');

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

:root {
  --black:    #0A0A0A;
  --gold:     #C9A96E;
  --white:    #FFFFFF;
  --light-bg: #F8F6F2;
  --gray:     #777777;
  --font:     'Montserrat', system-ui, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  color: var(--black);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

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

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

/* =====================================================
   NAVBAR
   ===================================================== */

.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  overflow: hidden;
  justify-content: space-between;
  padding: 1rem 2.5rem;
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.nav-logo a {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.nav-logo-img {
  height: clamp(60px, 7vw, 90px);
  width: auto;
  display: block;
  object-fit: contain;
  margin: -15px -10px;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.logo-name {
  font-size: 1.35rem;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.logo-sub {
  font-size: 0.46rem;
  letter-spacing: 0.22em;
  color: var(--gray);
  text-transform: uppercase;
  margin-top: 3px;
  line-height: 1.5;
}

/* Desktop nav links */
.nav-links {
  display: flex;
  gap: 2.8rem;
  align-items: center;
}

.nav-links a {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--black);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--gold);
}

/* Hamburger button */
.hamburger {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 6px;
}

.hamburger span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--black);
  border-radius: 2px;
  transition: opacity 0.2s;
}

.hamburger:hover span {
  opacity: 0.6;
}

@media (min-width: 901px) {
  .hamburger { display: none; }
}

/* =====================================================
   MOBILE MENU OVERLAY
   ===================================================== */

.mobile-menu {
  position: fixed;
  top: 0; left: 0;
  width: min(420px, 80vw);
  height: 100%;
  background: var(--gold);
  z-index: 300;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 3rem 3.5rem;
  transform: translateX(-100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 4px 0 30px rgba(0,0,0,0.15);
}

.mobile-menu.open {
  transform: translateX(0);
}

.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 299;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s;
}

.mobile-menu-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.menu-close {
  position: absolute;
  top: 1.5rem;
  right: 1.8rem;
  background: none;
  border: none;
  color: white;
  font-size: 1.8rem;
  cursor: pointer;
  line-height: 1;
  font-family: var(--font);
}

.mobile-menu nav {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mobile-menu a {
  font-size: 2.4rem;
  font-weight: 700;
  color: white;
  padding: 0.4rem 0;
  transition: opacity 0.2s;
  display: inline-block;
}

.mobile-menu a:hover {
  opacity: 0.75;
}

/* =====================================================
   BUTTONS
   ===================================================== */

.btn {
  display: inline-block;
  padding: 0.85rem 2.2rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.9rem;
  font-family: var(--font);
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.15s;
  border: none;
}

.btn:hover {
  opacity: 0.88;
  transform: translateY(-1px);
}

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

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

.btn-outline {
  background: transparent;
  border: 2px solid var(--gold);
  color: var(--black);
}

/* =====================================================
   HERO SECTION  (index.html)
   ===================================================== */

.hero {
  min-height: 100vh;
  padding-top: 74px;
  display: flex;
  align-items: center;
  padding-left: 6%;
  padding-right: 4%;
  gap: 2rem;
}

.hero-content {
  flex: 1;
  max-width: 580px;
}

.hero-tagline {
  font-size: 1.05rem;
  color: var(--gray);
  margin-bottom: 1rem;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.hero-title {
  font-size: clamp(2.8rem, 5vw, 4.5rem);
  font-weight: 600;
  line-height: 1.05;
  margin-bottom: 2.5rem;
  letter-spacing: -0.01em;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-call {
  margin-top: 1.8rem;
  font-size: 0.88rem;
  color: var(--gray);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.hero-social {
  display: flex;
  gap: 0.75rem;
  margin-top: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

.hero-social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: opacity 0.2s;
}

.hero-social-link:hover {
  opacity: 0.7;
}

.hero-social-link svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.hero-image {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 60vh;
}

.hero-image img {
  max-height: 72vh;
  max-width: 100%;
  object-fit: contain;
  filter: drop-shadow(0 20px 40px rgba(0,0,0,0.12));
}

/* =====================================================
   ABOUT SECTION  (about.html)
   ===================================================== */

.about-section {
  background: var(--black);
  color: white;
  display: grid;
  grid-template-columns: 1fr 1fr;
  height: 65vh;
}

.about-content {
  padding: 6rem 5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.about-content h2 {
  font-size: 2.6rem;
  font-weight: 400;
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

.about-content p {
  font-size: 0.95rem;
  line-height: 1.85;
  color: #c8c8c8;
}

.about-contact-bar {
  margin-top: 2.2rem;
  padding-top: 1.8rem;
  border-top: 1px solid rgba(255,255,255,0.12);
  display: flex;
  align-items: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.about-call {
  font-size: 0.82rem;
  color: #aaa;
  font-weight: 500;
}

.about-social {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.about-social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: white;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: opacity 0.2s;
}

.about-social-link:hover {
  opacity: 0.7;
}

.about-social-link svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.about-image {
  overflow: hidden;
}

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

/* =====================================================
   SHOP BY CATEGORY  (about.html)
   ===================================================== */

.categories-section {
  padding: 5rem 5%;
}

.section-title {
  text-align: center;
  font-size: 2rem;
  font-weight: 400;
  margin-bottom: 3rem;
  letter-spacing: -0.01em;
}

/* Top row: 4 cards */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

/* Bottom row: 3 cards centred */
.categories-grid-bottom {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 76%;
  margin: 0 auto;
}

.category-card {
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 3px 16px rgba(0,0,0,0.09);
  cursor: pointer;
  transition: transform 0.25s, box-shadow 0.25s;
  display: block;
  background: var(--gold);
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 28px rgba(0,0,0,0.14);
}

.category-card img {
  width: 100%;
  height: 155px;
  object-fit: cover;
  display: block;
  background: var(--gold);
}

.category-card-body {
  background: var(--gold);
  padding: 0.85rem 1rem;
  text-align: center;
}

.category-card-body h3 {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--black);
  margin-bottom: 0.3rem;
}

.category-card-body p {
  font-size: 0.68rem;
  color: var(--black);
  line-height: 1.4;
}

.shop-all-wrap {
  display: flex;
  justify-content: center;
  margin-top: 3rem;
}

/* Full grid for shop.html (all categories view) */
.all-categories-section {
  padding: 1rem 5% 5rem;
}

.categories-grid-full {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

/* =====================================================
   FEATURED SHOWCASE SECTION  (index.html)
   ===================================================== */

.showcase-section {
  background: var(--white);
  padding-bottom: 2rem;
}

.showcase-header {
  padding: 5rem 6% 3rem;
  text-align: center;
}

.showcase-header h2 {
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 900;
  letter-spacing: 0.05em;
  margin-bottom: 1.5rem;
}

/* =====================================================
   SITE FOOTER
   ===================================================== */

.site-footer {
  background: var(--black);
  color: white;
  padding: 4rem 6% 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  padding-bottom: 3rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer-col h4 {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.4rem;
}

.footer-col a {
  display: block;
  font-size: 0.85rem;
  color: #888;
  margin-bottom: 0.75rem;
  transition: color 0.2s;
  letter-spacing: 0.01em;
}

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

.footer-bottom {
  text-align: center;
}

.footer-bottom p {
  color: #444;
  font-size: 0.75rem;
  letter-spacing: 0.02em;
}

/* =====================================================
   SHOP PAGE  (shop.html)
   ===================================================== */

.shop-header {
  padding: 7rem 6% 3rem;
  text-align: center;
}

.shop-header h1 {
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 900;
  letter-spacing: 0.05em;
  margin-bottom: 1.5rem;
}

/* "PRICE STARTS $100.00" dark badge */
.price-badge {
  display: inline-flex;
  align-items: center;
  gap: 1.1rem;
  background: var(--black);
  color: white;
  padding: 0.85rem 2.2rem;
  border-radius: 50px;
}

.price-badge .label {
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  line-height: 1.4;
  text-align: left;
}

.price-badge .amount {
  font-size: 1.9rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* Products section */
.products-section {
  padding: 0 6% 5rem;
}

/* Featured (first) product */
.product-featured {
  margin-bottom: 3.5rem;
  padding-bottom: 3.5rem;
  border-bottom: 1px solid #eee;
}

.product-featured-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.product-featured-info {
  flex: 1;
  min-width: 250px;
}

.product-featured-info h2 {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  margin-bottom: 0.6rem;
}

.product-featured-info p {
  font-size: 0.85rem;
  color: var(--gray);
  line-height: 1.7;
  max-width: 420px;
}

.product-featured-actions {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  flex-shrink: 0;
}

.product-featured img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
  border-radius: 10px;
}

/* Price pill — gold with PRICE label */
.price-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--gold);
  color: white;
  padding: 0.55rem 1.2rem;
  border-radius: 50px;
}

.price-pill .p-label {
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.price-pill .p-amount {
  font-size: 1rem;
  font-weight: 700;
}

/* Product description — parsed paragraphs and bullets */
.product-featured-info p,
.product-featured-info ul,
.product-card > p,
.product-card > ul {
  font-size: 0.85rem;
  color: var(--gray);
  line-height: 1.7;
  max-width: 420px;
  margin-bottom: 0.5rem;
}

.product-featured-info ul,
.product-card > ul {
  padding-left: 1.2rem;
}

.product-featured-info ul li,
.product-card > ul li {
  margin-bottom: 0.25rem;
}

/* Request Quote link */
.request-quote-btn {
  background: none;
  border: none;
  font-size: 0.85rem;
  color: var(--gray);
  cursor: pointer;
  font-family: var(--font);
  transition: color 0.2s;
  padding: 0;
  display: inline-block;
}

.request-quote-btn:hover {
  color: var(--black);
  text-decoration: underline;
}

/* 2-column products grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3rem 2rem;
}

.product-card h3 {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  margin-bottom: 0.6rem;
}

.product-card > p {
  font-size: 0.82rem;
  color: var(--gray);
  line-height: 1.7;
  margin-bottom: 0.9rem;
}

.product-card-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.product-card img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: 10px;
}

/* =====================================================
   CONTACT PAGE  (contact.html)
   ===================================================== */

.contact-section {
  height: 65vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding-top: 74px;
}

.contact-image {
  overflow: hidden;
}

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

.contact-info {
  background: var(--black);
  color: white;
  padding: 2.5rem 4.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0;
}

.contact-logo-img {
  height: clamp(60px, 7vw, 90px);
  width: auto;
  object-fit: contain;
  margin-bottom: 1.8rem;
  filter: brightness(0) invert(1);
  align-self: flex-start;
}

.contact-tagline {
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1.55;
  margin-bottom: 2.2rem;
}

.contact-items {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  margin-bottom: 2.5rem;
}

.contact-item {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  border: 1.5px solid white;
  border-radius: 50px;
  padding: 0.65rem 1.4rem;
  font-size: 0.92rem;
  width: fit-content;
  transition: background 0.2s, color 0.2s;
}

.contact-item:hover {
  background: white;
  color: var(--black);
}

.contact-item svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.social-icons {
  display: flex;
  gap: 0.9rem;
}

.social-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  color: white;
}

.social-icon:hover {
  background: white;
  color: var(--black);
}

.social-icon svg {
  width: 18px;
  height: 18px;
}

/* =====================================================
   IMAGE ZOOM MODAL  (shop.html)
   ===================================================== */

.img-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.88);
  z-index: 400;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.img-modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.img-modal {
  position: fixed;
  inset: 0;
  z-index: 401;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.img-modal.open {
  opacity: 1;
  pointer-events: auto;
}

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

.img-modal-close {
  position: fixed;
  top: 1.2rem;
  right: 1.8rem;
  background: none;
  border: none;
  color: white;
  font-size: 2.8rem;
  cursor: pointer;
  line-height: 1;
  font-family: var(--font);
  z-index: 402;
  transition: opacity 0.2s;
}

.img-modal-close:hover {
  opacity: 0.7;
}

.product-img-clickable {
  cursor: zoom-in;
}

/* =====================================================
   FOOTER
   ===================================================== */

.footer {
  background: var(--black);
  color: #888;
  text-align: center;
  padding: 1.4rem 2rem;
  font-size: 0.78rem;
  letter-spacing: 0.03em;
}

/* =====================================================
   PLACEHOLDER IMAGE (shown when no image is set)
   ===================================================== */

img[src="images/placeholder.jpg"],
img:not([src]),
img[src=""] {
  background: #e8e3db;
  min-height: 160px;
}

/* =====================================================
   RESPONSIVE
   ===================================================== */

@media (max-width: 1100px) {
  .categories-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .categories-grid-bottom {
    grid-template-columns: repeat(2, 1fr);
    max-width: 100%;
  }
  .categories-grid-full {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  /* Hide desktop nav links on mobile */
  .nav-links { display: none; }

  /* Hero */
  .hero {
    flex-direction: column-reverse;
    min-height: 100svh;
    padding-top: 90px;
    padding-bottom: 3rem;
    padding-left: 5%;
    padding-right: 5%;
    text-align: center;
    gap: 1.5rem;
    justify-content: center;
  }
  .hero-buttons { justify-content: center; }
  .hero-social { justify-content: center; }
  .hero-image {
    min-height: unset;
    flex: 0 0 auto;
  }
  .hero-image img { max-height: 38vh; }
  .hero-content { flex: 0 0 auto; }

  /* About */
  .about-section {
    grid-template-columns: 1fr;
    height: auto;
  }
  .about-content { padding: 3.5rem 2rem; }
  .about-image { height: 320px; }

  /* Contact */
  .contact-section {
    grid-template-columns: 1fr;
    height: auto;
  }
  .contact-image { height: 300px; }
  .contact-info { padding: 3rem 2rem; }

  /* Shop */
  .products-grid { grid-template-columns: 1fr; }
  .product-featured-top { flex-direction: column; }
}

@media (max-width: 700px) {
  .navbar { padding: 1rem 1.2rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; }

  .categories-grid,
  .categories-grid-bottom,
  .categories-grid-full {
    grid-template-columns: repeat(2, 1fr);
    max-width: 100%;
  }

  .hero-title { font-size: 2.4rem; }
  .shop-header h1 { font-size: 2.2rem; }
  .shop-header { padding: 5.5rem 5% 2rem; }
  .products-section { padding: 0 5% 4rem; }

}

@media (max-width: 420px) {
  .categories-grid,
  .categories-grid-bottom,
  .categories-grid-full {
    grid-template-columns: 1fr;
  }
  .footer-grid { grid-template-columns: 1fr; }
}

/* =====================================================
   SCROLL ANIMATIONS
   ===================================================== */

/* Prevent horizontal overflow from slide-in animations */
body { overflow-x: hidden; }
main { overflow-x: hidden; }

/* Base hidden state */
.reveal {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 0.75s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.75s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-48px);
  transition: opacity 0.85s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.85s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-right {
  opacity: 0;
  transform: translateX(48px);
  transition: opacity 0.85s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.85s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Visible state — added by JS */
.reveal.revealed,
.reveal-left.revealed,
.reveal-right.revealed {
  opacity: 1;
  transform: translate(0, 0);
}

/* Category cards — subtle scale on reveal */
.category-card.reveal {
  transform: translateY(28px) scale(0.97);
}
.category-card.revealed {
  transform: translateY(0) scale(1);
}

/* Prevent transition on elements inside about/contact
   that already have their own transitions (hover etc.) */
.about-image.reveal-left,
.contact-image.reveal-left {
  overflow: hidden;
}
