/* Sheila Hair Studio — Editorial V5
   Home refinements based on production visual QA:
   balanced specialties, readable FAQ, and a more editorial curated-product treatment. */

/* ──────────────────────────────────────────────────────────────
   SPECIALTIES — four equal editorial panels instead of 1 + 3
   ────────────────────────────────────────────────────────────── */
@media (min-width: 1024px) {
  main > section:has(a[href="/color"]):has(a[href="/metodo-curly"]):has(a[href="/tratamientos"]):has(a[href="/alisados"]) .mt-14.grid {
    grid-auto-rows: 22rem !important;
  }

  main > section:has(a[href="/color"]):has(a[href="/metodo-curly"]):has(a[href="/tratamientos"]):has(a[href="/alisados"]) .mt-14.grid > * {
    grid-column: span 6 / span 6 !important;
    grid-row: span 1 / span 1 !important;
  }
}

main > section:has(a[href="/color"]):has(a[href="/metodo-curly"]):has(a[href="/tratamientos"]):has(a[href="/alisados"]) .mt-14.grid a.group {
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 22px 60px rgba(5, 12, 24, 0.16) !important;
}

main > section:has(a[href="/color"]):has(a[href="/metodo-curly"]):has(a[href="/tratamientos"]):has(a[href="/alisados"]) .mt-14.grid a.group img {
  filter: saturate(0.9) contrast(0.98);
}

/* ──────────────────────────────────────────────────────────────
   FAQ — the V3 dark palette needs light answer text as well
   ────────────────────────────────────────────────────────────── */
main section[class~="bg-[#ebe4d7]"] [class~="text-[#4f5560]"] {
  color: rgba(243, 240, 233, 0.82) !important;
}

main section[class~="bg-[#ebe4d7]"] [class~="text-[#60666f]"] {
  color: rgba(243, 240, 233, 0.72) !important;
}

main section[class~="bg-[#ebe4d7]"] [class~="border-[#10192a]/15"] {
  border-color: rgba(243, 240, 233, 0.16) !important;
}

main section[class~="bg-[#ebe4d7]"] button[aria-expanded="true"] {
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 3px 0 0 rgba(208, 169, 51, 0.92);
  padding-left: 1rem;
  padding-right: 1rem;
}

main section[class~="bg-[#ebe4d7]"] button[aria-expanded="true"] + div p {
  padding-left: 1rem;
}

/* ──────────────────────────────────────────────────────────────
   CURATED PRODUCTS — salon edit, not catalogue cards
   ────────────────────────────────────────────────────────────── */
[aria-label="Productos destacados"] {
  counter-reset: sheila-product;
}

[aria-label="Productos destacados"] > div:last-child {
  gap: clamp(1.25rem, 2.4vw, 2.5rem) !important;
}

[aria-label="Productos destacados"] article {
  position: relative;
  counter-increment: sheila-product;
}

[aria-label="Productos destacados"] article::before {
  content: "0" counter(sheila-product);
  position: absolute;
  z-index: 5;
  top: 1.15rem;
  left: 1.15rem;
  display: inline-flex;
  min-width: 2rem;
  height: 2rem;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(243, 240, 233, 0.18);
  border-radius: 9999px;
  background: rgba(13, 21, 36, 0.72);
  color: #ddc36f;
  font-family: "Jost", sans-serif;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  backdrop-filter: blur(12px);
}

[aria-label="Productos destacados"] article > a:first-child > div {
  aspect-ratio: 4 / 5;
  border: 1px solid rgba(243, 240, 233, 0.11) !important;
  border-radius: 1.4rem !important;
  background:
    radial-gradient(circle at 50% 32%, rgba(255,255,255,0.07), transparent 34%),
    linear-gradient(155deg, #17263c 0%, #0d1728 100%) !important;
  box-shadow: 0 26px 70px rgba(2, 7, 16, 0.22);
}

[aria-label="Productos destacados"] article > a:first-child > div img {
  width: 100% !important;
  height: 100% !important;
  aspect-ratio: auto !important;
  object-fit: contain !important;
  padding: clamp(1rem, 2.1vw, 1.65rem);
  filter: saturate(0.72) contrast(0.96) brightness(0.96);
  transition: transform 500ms ease, filter 300ms ease !important;
}

[aria-label="Productos destacados"] article:hover > a:first-child > div img {
  transform: scale(1.018) !important;
  filter: saturate(0.82) contrast(0.98) brightness(0.99);
}

/* Homepage curation should invite discovery, not look like a quick-add grid. */
[aria-label="Productos destacados"] article > a:first-child button,
[aria-label="Productos destacados"] article > button {
  display: none !important;
}

[aria-label="Productos destacados"] article > div.mt-3:not(.flex) {
  display: none !important;
}

[aria-label="Productos destacados"] article > div.mt-3.flex {
  margin-top: 1.15rem !important;
  padding-top: 1rem;
  border-top: 1px solid rgba(243, 240, 233, 0.1);
  gap: 1rem !important;
}

[aria-label="Productos destacados"] article h3 {
  max-width: 24ch;
  font-size: clamp(1.05rem, 1.25vw, 1.28rem) !important;
  line-height: 1.18 !important;
  color: rgba(243, 240, 233, 0.96) !important;
}

[aria-label="Productos destacados"] article p {
  max-width: 34ch;
  margin-top: 0.45rem !important;
  font-size: 0.76rem !important;
  line-height: 1.55 !important;
  color: rgba(243, 240, 233, 0.55) !important;
}

[aria-label="Productos destacados"] article > div.mt-3.flex > div:last-child span:last-child {
  color: #ddc36f !important;
  font-size: 0.92rem;
  font-weight: 500;
}

main section:has([aria-label="Productos destacados"]) a[href="/tienda"] {
  border: 1px solid rgba(243, 240, 233, 0.18);
  border-radius: 9999px;
  padding: 0.7rem 1.1rem 0.7rem 1.3rem;
  color: rgba(243, 240, 233, 0.9) !important;
  transition: border-color 180ms ease, background-color 180ms ease, color 180ms ease;
}

main section:has([aria-label="Productos destacados"]) a[href="/tienda"]:hover {
  border-color: rgba(208, 169, 51, 0.7);
  background: rgba(208, 169, 51, 0.08);
  color: #f3f0e9 !important;
}

@media (max-width: 767.98px) {
  [aria-label="Productos destacados"] article > a:first-child > div {
    aspect-ratio: 1 / 1.08;
  }

  [aria-label="Productos destacados"] article > a:first-child > div img {
    padding: 1rem;
  }
}
