/*
Theme Name: Poinx Furniture Theme
Theme URI: https://poinx.com
Author: Poinx
Author URI: https://poinx.com
Description: Responsive furniture WordPress theme for Poinx with editable product management.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 8.0
Text Domain: poinx
*/

:root {
  --bg: #f5f2ea;
  --surface: #ffffff;
  --ink: #181716;
  --muted: #6b625b;
  --accent: #ba7a3a;
  --accent-dark: #8b5928;
  --radius: 16px;
  --radius-sm: 10px;
  --max: 1720px;
  --shadow: 0 12px 35px rgba(24, 23, 22, 0.08);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Lora", Georgia, serif;
  color: var(--ink);
  background: radial-gradient(circle at 20% 10%, #fff 0%, var(--bg) 55%, #ece6db 100%);
  line-height: 1.5;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: clamp(12px, 2.2vw, 34px);
}

.btn {
  display: inline-block;
  border: 1px solid var(--ink);
  border-radius: 999px;
  padding: 0.72rem 1.2rem;
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: all 220ms ease;
}

.btn:hover,
.btn:focus-visible {
  border-color: var(--accent-dark);
  color: #fff;
  background: var(--accent-dark);
}

.btn--solid {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.btn--solid:hover,
.btn--solid:focus-visible {
  border-color: var(--accent-dark);
  background: var(--accent-dark);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(10px);
  background: rgba(245, 242, 234, 0.88);
  border-bottom: 1px solid rgba(24, 23, 22, 0.08);
}

.site-header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 1rem;
}

.brand-mark {
  font-size: 1.2rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.1rem;
  font-size: 0.88rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.menu-toggle {
  display: none;
  border: 0;
  background: transparent;
  font-size: 1.5rem;
}

.hero {
  padding: clamp(2.5rem, 8vw, 7rem) 0 2.5rem;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(1rem, 3vw, 2.5rem);
  align-items: stretch;
}

.hero__content {
  background: linear-gradient(160deg, #fff6ec 0%, #f2e2cf 100%);
  border-radius: var(--radius);
  padding: clamp(1.4rem, 5vw, 3rem);
  box-shadow: var(--shadow);
}

.hero__eyebrow {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  margin-bottom: 0.8rem;
}

.hero h1 {
  font-size: clamp(2rem, 6vw, 4rem);
  margin: 0;
  line-height: 1.05;
}

.hero p {
  font-size: clamp(1rem, 2vw, 1.2rem);
  max-width: 54ch;
  color: #3e3731;
}

.hero__media img {
  height: 100%;
  width: 100%;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.section {
  padding: clamp(2rem, 7vw, 5.2rem) 0;
}

.quick-find--edge {
  padding: 0;
}

.section h2 {
  font-size: clamp(1.5rem, 3.8vw, 2.7rem);
  margin: 0 0 0.8rem;
}

.section__head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.section__head p {
  margin: 0;
  color: var(--muted);
}

.slideshow {
  position: relative;
  min-height: 500px;
  width: 100%;
}

.slide {
  position: absolute;
  inset: 0;
  display: block;
  background: #111;
  border-radius: 0;
  overflow: hidden;
  box-shadow: none;
  opacity: 0;
  pointer-events: none;
  transform: translateX(16px);
  transition: opacity 420ms ease, transform 420ms ease;
}

.slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 14, 12, 0.62) 0%, rgba(17, 14, 12, 0.34) 36%, rgba(17, 14, 12, 0.1) 62%, rgba(17, 14, 12, 0.06) 100%);
  z-index: 1;
}

.slide.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

.slide__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.slide__media {
  margin: 0;
  width: 100%;
  height: 100%;
  line-height: 0;
}

.slide__content {
  position: absolute;
  left: clamp(1rem, 4vw, 3rem);
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  max-width: min(90vw, 540px);
  padding: clamp(1rem, 3vw, 2rem);
  display: grid;
  align-content: center;
  gap: 0.9rem;
}

.slide__content h3 {
  margin: 0;
  font-size: clamp(1.4rem, 3.5vw, 2.2rem);
  color: #fff;
}

.slide__content p {
  margin: 0;
  color: rgba(255, 255, 255, 0.9);
}

.slide__content .hero__eyebrow {
  color: rgba(255, 255, 255, 0.78);
}

.slide__link {
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.85rem;
  text-decoration: underline;
  text-underline-offset: 4px;
  width: fit-content;
}

.slide__link:hover,
.slide__link:focus-visible {
  color: #f3cf9f;
}

.slideshow__arrows {
  position: absolute;
  inset: 50% 0 auto 0;
  transform: translateY(-50%);
  padding: 0 0.8rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 3;
}

.slideshow__arrow {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(20, 16, 13, 0.45);
  color: #fff;
  font-size: 1.2rem;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease;
}

.slideshow__arrow:hover,
.slideshow__arrow:focus-visible {
  background: rgba(20, 16, 13, 0.76);
  border-color: #fff;
}

.slideshow__arrows[aria-label] {
  display: flex;
  width: 100%;
}

.category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-bottom: 1.4rem;
}

.category-tab {
  border: 1px solid rgba(24, 23, 22, 0.22);
  border-radius: 999px;
  background: transparent;
  padding: 0.5rem 0.9rem;
  font: inherit;
  font-size: 0.83rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.category-tab.is-active {
  background: var(--ink);
  color: #fff;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(0.8rem, 2vw, 1.4rem);
}

.product-card {
  background: var(--surface);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 220ms ease;
}

.product-card:hover {
  transform: translateY(-4px);
}

.product-card__image {
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.product-card__body {
  padding: 1rem;
}

.product-card__type {
  margin: 0;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
}

.product-card h3 {
  margin: 0.42rem 0 0.2rem;
  font-size: 1.12rem;
}

.product-card__price {
  margin: 0;
  font-weight: 600;
  color: var(--accent-dark);
}

.story {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.story__card {
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
}

.story__card img {
  width: 100%;
  height: clamp(280px, 30vw, 420px);
  object-fit: cover;
}

.story__label {
  position: absolute;
  inset: auto 12px 12px 12px;
  padding: 0.5rem 0.7rem;
  background: rgba(24, 23, 22, 0.72);
  color: #fff;
  border-radius: 7px;
  font-size: 0.8rem;
}

.virtual-tour-grid {
  display: grid;
  gap: 1rem;
}

.virtual-tour-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  gap: 0;
  background: #f8f1e7;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.virtual-tour-media {
  margin: 0;
}

.virtual-tour-media img {
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
}

.virtual-tour-content {
  padding: clamp(1rem, 3vw, 2rem);
  display: grid;
  align-content: center;
  gap: 0.75rem;
}

.virtual-tour-content h3 {
  margin: 0;
  font-size: clamp(1.3rem, 2.8vw, 2rem);
}

.virtual-tour-content p {
  margin: 0;
  color: #4e443b;
}

.virtual-tour-modal {
  position: fixed;
  inset: 0;
  display: none;
  z-index: 96;
}

.virtual-tour-modal.is-open {
  display: block;
}

.virtual-tour-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 8, 7, 0.7);
  backdrop-filter: blur(2px);
}

.virtual-tour-modal__panel {
  position: relative;
  margin: min(5vh, 34px) auto;
  width: min(96vw, 1200px);
  max-height: 90vh;
  overflow: auto;
  background: #17120f;
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: 0 24px 55px rgba(14, 12, 11, 0.44);
}

.virtual-tour-modal__close {
  border: 0;
  background: #fff;
  color: #17120f;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  font-size: 1.2rem;
  margin-left: auto;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.virtual-tour-modal__title {
  margin: 0.45rem 0 0.7rem;
  color: #fff;
  font-size: clamp(1.3rem, 3vw, 2rem);
}

.virtual-tour-viewer {
  width: 100%;
  height: min(72vh, 640px);
  border-radius: 10px;
  overflow: hidden;
  background: #000;
}

.virtual-tour-modal__hint {
  margin: 0.65rem 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.9rem;
}

.gallery-rows {
  display: grid;
  gap: 0;
}

.gallery-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  align-items: stretch;
}

.gallery-thumb {
  margin: 0;
  border-radius: 0;
  overflow: hidden;
  box-shadow: none;
  background: #ddd;
}

.gallery-thumb img {
  width: 100%;
  height: 280px;
  object-fit: cover;
}

.gallery-link {
  border: 0;
  border-radius: 0;
  background: #fff;
  padding: 0.72rem 0.85rem;
  text-align: left;
  font: inherit;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 220ms ease;
}

.gallery-link:hover,
.gallery-link:focus-visible {
  background: var(--ink);
  color: #fff;
}

.gallery-link--row {
  height: 280px;
  font-size: clamp(1.1rem, 3vw, 1.7rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  display: grid;
  place-items: center;
  background: #fff8ef;
}

.gallery-modal {
  position: fixed;
  inset: 0;
  display: none;
  z-index: 90;
}

.gallery-modal.is-open {
  display: block;
}

.gallery-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(24, 23, 22, 0.62);
  backdrop-filter: blur(3px);
}

.gallery-modal__panel {
  position: relative;
  margin: min(6vh, 42px) auto;
  width: min(92vw, 980px);
  max-height: 88vh;
  overflow: auto;
  background: #faf4eb;
  border-radius: var(--radius);
  padding: 1.1rem;
  box-shadow: 0 24px 55px rgba(14, 12, 11, 0.32);
}

.gallery-modal__close {
  position: sticky;
  top: 0;
  margin-left: auto;
  display: block;
  border: 0;
  background: #1f1b17;
  color: #fff;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  font-size: 1.2rem;
  cursor: pointer;
}

.gallery-modal__title {
  margin: 0.2rem 0 1rem;
  font-size: clamp(1.4rem, 3vw, 2.2rem);
}

.gallery-modal__toolbar {
  margin-bottom: 0.9rem;
}

.gallery-modal__search {
  width: 100%;
  border: 1px solid rgba(24, 23, 22, 0.2);
  border-radius: 10px;
  background: #fff;
  padding: 0.72rem 0.85rem;
  font: inherit;
  color: var(--ink);
}

.gallery-modal__search:focus-visible {
  outline: 2px solid rgba(139, 89, 40, 0.4);
  outline-offset: 1px;
}

.gallery-modal__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
}

.gallery-modal__item {
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 10px 28px rgba(24, 23, 22, 0.09);
}

.gallery-modal__item img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.gallery-modal__copy {
  padding: 0.7rem 0.78rem 0.9rem;
}

.gallery-modal__copy h4 {
  margin: 0;
  font-size: 1rem;
}

.gallery-modal__copy p {
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.support-fab {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 85;
  border: 0;
  border-radius: 999px;
  padding: 0.65rem 0.95rem;
  background: #1f1b17;
  color: #fff;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  box-shadow: 0 14px 30px rgba(12, 10, 8, 0.28);
}

.support-fab--appointment {
  bottom: 76px;
  background: var(--accent-dark);
}

.support-fab__icon {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #fff;
  color: #1f1b17;
  font-size: 0.86rem;
}

.support-fab__text {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
}

.support-drawer {
  position: fixed;
  inset: 0;
  display: none;
  z-index: 95;
}

.support-drawer.is-open {
  display: block;
}

.support-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(24, 23, 22, 0.45);
}

.support-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(96vw, 430px);
  height: 100%;
  background: #f7f0e6;
  padding: 1.2rem;
  box-shadow: -14px 0 32px rgba(20, 16, 13, 0.22);
  overflow: auto;
}

.support-drawer__close {
  border: 0;
  background: #1f1b17;
  color: #fff;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  font-size: 1.15rem;
  display: grid;
  place-items: center;
  margin-left: auto;
  cursor: pointer;
}

.support-drawer__title {
  margin: 0.5rem 0 0.45rem;
  font-size: clamp(1.2rem, 2.8vw, 1.7rem);
}

.support-drawer__copy,
.support-drawer__meta {
  margin: 0 0 0.8rem;
  color: #4c433a;
}

.support-form {
  display: grid;
  gap: 0.72rem;
}

.support-form input,
.support-form textarea {
  width: 100%;
  border: 1px solid rgba(31, 27, 23, 0.2);
  border-radius: 8px;
  background: #fff;
  color: #1f1b17;
  padding: 0.74rem 0.8rem;
  font: inherit;
}

.contact-panel {
  background: #1f1b17;
  color: #f6f0e8;
  border-radius: var(--radius);
  padding: clamp(1.2rem, 4vw, 2.2rem);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}

.contact-panel form {
  display: grid;
  gap: 0.8rem;
}

.contact-panel input,
.contact-panel textarea {
  width: 100%;
  border: 1px solid rgba(246, 240, 232, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  padding: 0.74rem 0.8rem;
  font: inherit;
}

.site-footer {
  padding: 2.4rem 0 1.2rem;
  margin-top: 2.2rem;
  background: linear-gradient(180deg, #201b16 0%, #15110e 100%);
  color: #efe5d8;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 0.8fr;
  gap: clamp(1rem, 3vw, 2rem);
  padding-bottom: 1.2rem;
}

.footer-brand h3 {
  margin: 0 0 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-brand p {
  margin: 0;
  color: rgba(239, 229, 216, 0.82);
}

.footer-grid h4 {
  margin: 0 0 0.6rem;
  font-size: 0.92rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #f7efe3;
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}

.footer-links li,
.footer-links a {
  color: rgba(239, 229, 216, 0.84);
  font-size: 0.92rem;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  color: #fff;
}

.footer-meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  color: rgba(239, 229, 216, 0.62);
  font-size: 0.9rem;
  padding-top: 0.8rem;
  border-top: 1px solid rgba(239, 229, 216, 0.18);
}

[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 500ms ease, transform 500ms ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 992px) {
  .hero__grid {
    grid-template-columns: 1fr;
  }

  .slideshow {
    min-height: 520px;
  }

  .slide__media img {
    height: 100%;
  }

  .slide__content {
    max-width: min(90vw, 620px);
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .story {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .virtual-tour-row {
    grid-template-columns: 1fr;
  }

  .gallery-row {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .gallery-modal__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-panel {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .menu-toggle {
    display: inline-block;
  }

  .site-nav {
    display: none;
    width: 100%;
  }

  .site-nav.is-open {
    display: block;
    padding-bottom: 0.9rem;
  }

  .site-nav ul {
    flex-direction: column;
    gap: 0.6rem;
  }

  .site-header__bar {
    flex-wrap: wrap;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .story {
    grid-template-columns: 1fr;
  }

  .virtual-tour-media img {
    min-height: 230px;
  }

  .virtual-tour-viewer {
    height: 56vh;
  }

  .slideshow {
    min-height: 560px;
  }

  .slide__content {
    left: 0.8rem;
    right: 0.8rem;
    max-width: none;
    gap: 0.7rem;
    padding: 1rem;
  }

  .slideshow__arrow {
    width: 36px;
    height: 36px;
  }

  .gallery-link--row,
  .gallery-thumb img {
    height: 220px;
  }

  .gallery-modal__grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .support-fab {
    right: 10px;
    bottom: 12px;
  }

  .support-fab--appointment {
    bottom: 66px;
  }
}
