/* =========================================================
   BOOKBRAIDS — HOME PAGE
========================================================= */

body.search-page {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background: #faf4ec;
  color: #25150d;
}

.home-page {
  width: 100%;
}

.home-page *,
.public-home-header * {
  box-sizing: border-box;
}

.home-page img {
  display: block;
  max-width: 100%;
}


/* =========================================================
   HEADER
========================================================= */

.public-home-header {
  width: 100%;
  height: 88px;
  position: sticky;
  top: 0;
  z-index: 1200;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid #ead8ca;
  backdrop-filter: blur(14px);
}

.public-home-header-inner {
  width: 100%;
  max-width: 1280px;
  height: 100%;
  margin: 0 auto;
  padding: 0 26px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.public-home-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  color: #24140c;
  text-decoration: none;
  font-family: "Playfair Display", serif;
  font-size: 25px;
  font-weight: 900;
}

.public-home-logo img {
  width: 62px;
  height: 62px;
  object-fit: contain;
}

.public-home-logo strong {
  color: #a83d16;
}

.public-home-nav {
  display: flex;
  align-items: center;
  gap: 25px;
  margin-left: auto;
}

.public-home-nav a {
  color: #52301d;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
  transition: color 0.2s ease;
}

.public-home-nav a:hover {
  color: #b84e20;
}

.public-home-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.public-home-actions .btn-main,
.public-home-actions .secondary-btn {
  width: auto;
  min-height: 42px;
  margin: 0;
  padding: 0 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  text-decoration: none;
}


/* =========================================================
   LANGUAGE
========================================================= */

.public-home-lang {
  display: inline-flex;
  align-items: center;
  padding: 4px;
  gap: 3px;
  background: #fff7f0;
  border: 1px solid #e5cdbb;
  border-radius: 999px;
}

.public-home-lang .lang-btn {
  min-width: 42px;
  height: 36px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #783014;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.public-home-lang .lang-btn:hover {
  background: #f4dfcf;
}

.public-home-lang .lang-btn.active {
  background: #8a2f0b;
  color: #fff;
}


/* =========================================================
   HERO
========================================================= */

.home-hero {
  width: 100%;
  padding: 72px 28px 62px;
}

.home-hero-content {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(420px, 0.92fr);
  align-items: center;
  gap: 58px;
}

.home-hero-copy {
  min-width: 0;
}

.home-hero-eyebrow,
.home-hero .eyebrow {
  margin: 0 0 14px;
  color: #a85a2d;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 2px;
}

.home-hero h1 {
  max-width: 680px;
  margin: 0;
  color: #21130c;
  font-family: "Playfair Display", serif;
  font-size: clamp(48px, 5.8vw, 76px);
  line-height: 0.99;
  letter-spacing: -2px;
}

.home-hero-description {
  max-width: 650px;
  margin: 22px 0 0;
  color: #785f50;
  font-size: 18px;
  line-height: 1.7;
}


/* =========================================================
   HERO SEARCH
========================================================= */

.home-main-search {
  width: 100%;
  margin-top: 30px;
  padding: 14px;
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(150px, 0.8fr) auto;
  gap: 10px;
  align-items: end;
  background: #fff;
  border: 1px solid #e7d6c9;
  border-radius: 20px;
  box-shadow: 0 18px 48px rgba(73, 33, 13, 0.09);
}

.home-main-search .filter-group {
  min-width: 0;
}

.home-main-search label {
  display: block;
  margin: 0 0 7px;
  color: #754122;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.home-main-search input,
.home-main-search select {
  width: 100%;
  height: 50px;
  padding: 0 14px;
  border: 1.5px solid #e3d4c8;
  border-radius: 13px;
  background: #fffaf6;
  color: #27170f;
  font: inherit;
  outline: none;
}

.home-main-search input:focus,
.home-main-search select:focus {
  border-color: #b84e20;
  box-shadow: 0 0 0 4px rgba(184, 78, 32, 0.08);
}

.home-main-search .search-btn {
  width: auto;
  min-width: 128px;
  height: 50px;
  margin: 0;
}


/* =========================================================
   QUICK LINKS
========================================================= */

.home-quick-links {
  margin-top: 17px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.home-quick-links button {
  padding: 8px 13px;
  border: 1px solid #e1c9b6;
  border-radius: 999px;
  background: transparent;
  color: #78401e;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.home-quick-links button:hover {
  background: #fff;
  transform: translateY(-1px);
}


/* =========================================================
   HERO IMAGES
========================================================= */

.home-hero-gallery {
  min-width: 0;
  height: 580px;
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  grid-template-rows: 1fr 1fr;
  gap: 12px;
}

.hero-image {
  min-width: 0;
  min-height: 0;
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #e9d6c5;
  box-shadow: 0 20px 55px rgba(48, 22, 10, 0.13);
}

.hero-image-large {
  grid-row: 1 / 3;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.hero-image:hover img {
  transform: scale(1.035);
}

.hero-image::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 40%;
  pointer-events: none;
  background: linear-gradient(to top, rgba(18, 8, 3, 0.72), transparent);
}

.hero-image span {
  position: absolute;
  left: 18px;
  bottom: 17px;
  z-index: 2;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}


/* =========================================================
   SHARED SECTION
========================================================= */

.home-inspiration-section,
.home-popular-section,
.home-ranking-section,
.home-how-section,
.home-provider-section {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding-left: 28px;
  padding-right: 28px;
}

.home-inspiration-section,
.home-popular-section,
.home-ranking-section,
.home-how-section {
  margin-bottom: 92px;
}

.home-section-heading {
  margin-bottom: 25px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

.home-section-heading .eyebrow {
  margin: 0 0 9px;
  color: #a75d31;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.home-section-heading h2 {
  margin: 0;
  color: #21130c;
  font-family: "Playfair Display", serif;
  font-size: clamp(34px, 4vw, 49px);
  line-height: 1.08;
}


/* =========================================================
   MOVING STYLE BANNER
========================================================= */

.home-inspiration-section {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

.home-inspiration-section .home-section-heading {
  width: calc(100% - 56px);
  max-width: 1184px;
  margin-left: auto;
  margin-right: auto;
}

.home-image-marquee {
  width: 100%;
  overflow: hidden;
  position: relative;
  padding: 4px 0 8px;
}

.home-image-marquee::before,
.home-image-marquee::after {
  content: "";
  width: 80px;
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 5;
  pointer-events: none;
}

.home-image-marquee::before {
  left: 0;
  background: linear-gradient(to right, #faf4ec, transparent);
}

.home-image-marquee::after {
  right: 0;
  background: linear-gradient(to left, #faf4ec, transparent);
}

.home-image-track {
  --card-width: 220px;
  --card-gap: 14px;

  width: max-content;
  display: flex;
  align-items: stretch;
  gap: var(--card-gap);
  padding-right: var(--card-gap);
  animation: bookbraids-marquee 70s linear infinite;
  will-change: transform;
}

.home-image-marquee:hover .home-image-track {
  animation-play-state: paused;
}

@keyframes bookbraids-marquee {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-66.666%);
  }
}

.home-style-card {
  width: var(--card-width);
  height: 310px;
  flex: 0 0 var(--card-width);
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  background: #e4d1c0;
  color: #fff;
  text-decoration: none;
  box-shadow: 0 12px 30px rgba(60, 27, 12, 0.1);
}

.home-style-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.home-style-card:hover img {
  transform: scale(1.045);
}

.home-style-card::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 42%;
  background: linear-gradient(to top, rgba(23, 10, 4, 0.82), transparent);
}

.home-style-card span {
  position: absolute;
  left: 15px;
  right: 15px;
  bottom: 14px;
  z-index: 2;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}


/* =========================================================
   VISUAL CATEGORIES
========================================================= */

.home-category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.home-category-card {
  min-width: 0;
  height: 370px;
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #e8d8c9;
  color: #fff;
  text-decoration: none;
  box-shadow: 0 16px 38px rgba(55, 25, 11, 0.08);
}

.home-category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.home-category-card:hover img {
  transform: scale(1.04);
}

.home-category-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(21, 9, 4, 0.85) 0%, rgba(21, 9, 4, 0.08) 65%);
}

.home-category-card > div {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 2;
}

.home-category-card h3 {
  margin: 0 0 5px;
  color: #fff;
  font-family: "Playfair Display", serif;
  font-size: 27px;
}

.home-category-card span {
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
  font-weight: 700;
}


/* =========================================================
   RANKING
========================================================= */

.home-ranking-section[hidden] {
  display: none !important;
}

.home-ranking-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.home-ranking-card {
  min-width: 0;
  overflow: hidden;
  background: #fff;
  border: 1px solid #ead9cd;
  border-radius: 22px;
  box-shadow: 0 12px 34px rgba(59, 27, 13, 0.07);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.home-ranking-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 42px rgba(59, 27, 13, 0.11);
}

.home-ranking-photo {
  width: 100%;
  height: 250px;
  display: block;
  overflow: hidden;
  background: #f0dfd2;
  text-decoration: none;
}

.home-ranking-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.home-ranking-photo-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  background: #8a2f0b;
  color: #fff;
  font-family: "Playfair Display", serif;
  font-size: 40px;
  font-weight: 900;
}

.home-ranking-body {
  padding: 18px;
}

.home-ranking-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.home-ranking-top h3 {
  margin: 0;
  color: #24150d;
  font-size: 18px;
  line-height: 1.25;
}

.home-ranking-score {
  flex-shrink: 0;
  color: #9b4a17;
  font-size: 14px;
  white-space: nowrap;
}

.home-ranking-reviews,
.home-ranking-location,
.home-ranking-specialty {
  margin: 7px 0 0;
  color: #785e50;
  font-size: 13px;
  line-height: 1.45;
}

.home-ranking-body .secondary-btn {
  width: 100%;
  min-height: 42px;
  margin: 17px 0 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}


/* =========================================================
   HOW IT WORKS
========================================================= */

.home-how-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.home-step-card {
  min-height: 220px;
  padding: 27px;
  background: #fff;
  border: 1px solid #ead9cd;
  border-radius: 23px;
  box-shadow: 0 12px 30px rgba(58, 27, 12, 0.06);
}

.home-step-number {
  width: 50px;
  height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #8a2f0b;
  color: #fff;
  font-size: 14px;
  font-weight: 900;
}

.home-step-card h3 {
  margin: 24px 0 9px;
  color: #25150d;
  font-size: 21px;
}

.home-step-card p {
  margin: 0;
  color: #785f50;
  line-height: 1.65;
}


/* =========================================================
   PROFESSIONAL CTA
========================================================= */

.home-provider-section {
  margin-bottom: 90px;
}

.home-provider-card {
  min-height: 450px;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(330px, 0.9fr);
  overflow: hidden;
  border-radius: 30px;
  background: #281207;
  box-shadow: 0 24px 55px rgba(41, 18, 7, 0.17);
}

.home-provider-content {
  padding: 56px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.home-provider-content .eyebrow {
  margin: 0 0 12px;
  color: #e8ad63;
}

.home-provider-content h2 {
  max-width: 650px;
  margin: 0;
  color: #fff;
  font-family: "Playfair Display", serif;
  font-size: clamp(35px, 4vw, 50px);
  line-height: 1.08;
}

.home-provider-content > p:not(.eyebrow) {
  max-width: 630px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.74);
  font-size: 16px;
  line-height: 1.7;
}

.home-provider-actions {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.home-provider-actions .btn-main,
.home-provider-actions .secondary-btn {
  width: auto;
  min-height: 48px;
  margin: 0;
  padding: 0 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.home-provider-actions .secondary-btn {
  border-color: rgba(255, 255, 255, 0.35);
  background: transparent;
  color: #fff;
}

.home-provider-photo {
  min-width: 0;
  min-height: 450px;
}

.home-provider-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}


/* =========================================================
   FOOTER
========================================================= */

body.search-page .site-footer {
  margin-top: 0;
}

body.search-page .footer-logo img {
  width: 88px !important;
  height: auto !important;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 1080px) {

  .public-home-nav {
    gap: 16px;
  }

  .professional-header-btn {
    display: none !important;
  }

  .home-hero-content {
    grid-template-columns: minmax(0, 1fr) minmax(360px, 0.8fr);
    gap: 35px;
  }

  .home-hero-gallery {
    height: 520px;
  }

  .home-category-grid,
  .home-ranking-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}


/* =========================================================
   TABLET / SMALL DESKTOP
========================================================= */

@media (max-width: 900px) {

  .public-home-header {
    height: auto;
    position: relative;
  }

  .public-home-header-inner {
    min-height: 78px;
    padding: 10px 18px;
    flex-wrap: wrap;
  }

  .public-home-nav {
    order: 3;
    width: 100%;
    margin: 0;
    padding: 10px 0 2px;
    justify-content: center;
    border-top: 1px solid #eee1d8;
  }

  .public-home-actions {
    margin-left: auto;
  }

  .home-hero {
    padding-top: 52px;
  }

  .home-hero-content {
    grid-template-columns: 1fr;
  }

  .home-hero-copy {
    max-width: 760px;
  }

  .home-hero-gallery {
    height: 560px;
  }

  .home-main-search {
    max-width: 760px;
  }

  .home-provider-card {
    grid-template-columns: 1fr;
  }

  .home-provider-photo {
    min-height: 390px;
  }
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 680px) {

  .public-home-header-inner {
    padding: 9px 12px 12px;
    gap: 8px;
  }

  .public-home-logo {
    font-size: 18px;
  }

  .public-home-logo img {
    width: 48px;
    height: 48px;
  }

  .public-home-actions {
    gap: 5px;
  }

  .public-home-actions .btn-main,
  .public-home-actions .secondary-btn {
    min-height: 38px;
    padding: 0 9px;
    border-radius: 10px;
    font-size: 11px;
  }

  .public-home-actions a[href*="mode=register"] {
    display: none;
  }

  .public-home-lang {
    padding: 3px;
  }

  .public-home-lang .lang-btn {
    min-width: 34px;
    height: 32px;
    padding: 0 7px;
    font-size: 11px;
  }

  .public-home-nav {
    justify-content: flex-start;
    gap: 20px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .public-home-nav::-webkit-scrollbar {
    display: none;
  }

  .public-home-nav a {
    flex: 0 0 auto;
  }

  .home-hero {
    padding: 44px 16px 50px;
  }

  .home-hero h1 {
    font-size: clamp(43px, 13vw, 58px);
    letter-spacing: -1.2px;
  }

  .home-hero-description {
    font-size: 16px;
  }

  .home-main-search {
    grid-template-columns: 1fr;
    padding: 13px;
  }

  .home-main-search .search-btn {
    width: 100%;
  }

  .home-hero-gallery {
    height: 470px;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 8px;
  }

  .hero-image {
    border-radius: 17px;
  }

  .hero-image span {
    left: 12px;
    bottom: 11px;
    font-size: 12px;
  }

  .home-inspiration-section,
  .home-popular-section,
  .home-ranking-section,
  .home-how-section,
  .home-provider-section {
    padding-left: 16px;
    padding-right: 16px;
  }

  .home-inspiration-section {
    padding-left: 0;
    padding-right: 0;
  }

  .home-inspiration-section .home-section-heading {
    width: calc(100% - 32px);
  }

  .home-inspiration-section,
  .home-popular-section,
  .home-ranking-section,
  .home-how-section {
    margin-bottom: 62px;
  }

  .home-section-heading {
    align-items: flex-start;
  }

  .home-section-heading h2 {
    font-size: 32px;
  }

  .home-section-heading > .secondary-btn {
    min-width: auto;
    padding: 0 13px;
    font-size: 11px;
  }

  .home-image-marquee::before,
  .home-image-marquee::after {
    width: 25px;
  }

  .home-image-track {
    --card-width: 170px;
    --card-gap: 10px;
    animation-duration: 62s;
  }

  .home-style-card {
    height: 245px;
    border-radius: 17px;
  }

  .home-category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .home-category-card {
    height: 285px;
    border-radius: 18px;
  }

  .home-category-card > div {
    left: 14px;
    right: 14px;
    bottom: 14px;
  }

  .home-category-card h3 {
    font-size: 21px;
  }

  .home-category-card span {
    font-size: 11px;
  }

  .home-ranking-grid {
    grid-template-columns: 1fr;
  }

  .home-ranking-card {
    display: grid;
    grid-template-columns: 135px minmax(0, 1fr);
  }

  .home-ranking-photo {
    height: 100%;
    min-height: 210px;
  }

  .home-ranking-body {
    padding: 16px;
  }

  .home-how-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .home-step-card {
    min-height: 0;
    padding: 22px;
  }

  .home-provider-section {
    margin-bottom: 60px;
  }

  .home-provider-card {
    border-radius: 24px;
  }

  .home-provider-content {
    padding: 32px 22px;
  }

  .home-provider-content h2 {
    font-size: 34px;
  }

  .home-provider-actions {
    flex-direction: column;
  }

  .home-provider-actions .btn-main,
  .home-provider-actions .secondary-btn {
    width: 100%;
  }

  .home-provider-photo {
    min-height: 320px;
  }
}


/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 430px) {

  .public-home-logo span {
    display: none;
  }

  .public-home-logo img {
    width: 46px;
    height: 46px;
  }

  .home-hero h1 {
    font-size: 42px;
  }

  .home-hero-gallery {
    height: 420px;
  }

  .home-category-card {
    height: 245px;
  }

  .home-ranking-card {
    grid-template-columns: 112px minmax(0, 1fr);
  }

  .home-ranking-photo {
    min-height: 200px;
  }

  .home-ranking-top {
    display: block;
  }

  .home-ranking-score {
    display: block;
    margin-top: 5px;
  }
}


/* =========================================================
   REDUCED MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {

  .home-image-track {
    animation: none;
  }

  .hero-image img,
  .home-style-card img,
  .home-category-card img,
  .home-ranking-card {
    transition: none;
  }
}