/* Grid Layout */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

/* Card */
.brand-card {
    position: relative;
    display: block;
    text-decoration: none;
    color: inherit;
    height: 452px;
    border-radius: 24px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.brand-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

/* Card Background Colors */
.brand-card.royal-d { background-color: #ffffff; }
.brand-card.hikari   { background-color: #0382E3; }
.brand-card.regen-d  { background-color: #e9f029; }

/* ── Default State (Logo) ── */
.card-default {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease;
    z-index: 2;
}

.card-default img {
    max-width: 95%;
    max-height: auto;
    object-fit: contain;
}

/* ── Hover State Container ── */
.card-hover {
    position: absolute;
    inset: 0;
    z-index: 1;
    overflow: hidden;
}

/* Animated Background Circle */
.hover-circle {
    position: absolute;
    /* Start: hidden below card */
    bottom: -100vh;
    left: 50%;
    transform: translateX(-50%);
    width: 120%;
    aspect-ratio: 1;
    border-radius: 50%;
    transition: bottom 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
    z-index: 1;
}

/* Circle Colors per brand */
.brand-card.royal-d .hover-circle { background-color: #8acb9e; }
.brand-card.hikari  .hover-circle { background-color: #5db8f0; }
.brand-card.regen-d .hover-circle { background-color: #d8de5b; }

/* Bottle Image */
.bottle-img {
    position: absolute;
    bottom: -110%;
    left: 50%;
    transform: translateX(-50%);
    height: 82%;
    object-fit: contain;
    transition: bottom 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
    z-index: 2;
}

/* Details Box */
.details-box {
    position: absolute;
    bottom: -120px;
    left: 16px;
    right: 16px;
    background-color: #ffffff;
    border-radius: 16px;
    padding: 18px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    opacity: 0;
    transition: bottom 0.5s cubic-bezier(0.25, 0.8, 0.25, 1),
                opacity 0.4s ease;
    z-index: 3;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.10);
}

.details-box h2 {
    color: var(--color-500);
}

/* Details Button */
.details-btn {
    background: transparent;
    border: 1.5px solid #1AA44A;
    color: #1AA44A;
    padding: 14px 16px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 500;
    transition: background-color 0.2s ease;
    display: inline-block;
    white-space: nowrap;
}

.details-btn.Royal-D  { color: var(--royal); border-color: var(--royal); }
.details-btn.Hikari { color: var(--hikari); border-color: var(--hikari); }
.details-btn.Regen-D  { color: var(--regen); border-color: var(--regen); }

.details-box:hover .details-btn {
    background-color: #f5f5f5;
}

/* ── Hover / Touch-Active Animations ── */

/* 1. Fade out logo */
.brand-card:hover .card-default,
.brand-card.hover  .card-default {
    opacity: 0;
}

/* 2. Slide circle up — bottom edge sits ~30% up from card base */
.brand-card:hover .hover-circle,
.brand-card.hover  .hover-circle {
    bottom: -28%;
}

/* 3. Slide bottle up — sits above details box */
.brand-card:hover .bottle-img,
.brand-card.hover  .bottle-img {
    bottom: 90px;
}

/* 4. Slide details box up + fade in */
.brand-card:hover .details-box,
.brand-card.hover  .details-box {
    bottom: 18px;
    opacity: 1;
}

/* ── HERO SHELL ── */
.brand {
  position: relative;
  width: 100%;
  height: 890px;
  overflow: hidden;
}

/* ── BACKGROUND LAYERS (Smooth Fade) ── */
.brand-bg {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  transition: opacity 1s cubic-bezier(.4, 0, .2, 1);
  pointer-events: none;
  overflow: hidden;
}

.brand-bg.active {
  opacity: 1;
}

/* ── FIXED DESIGN ANCHORED FLUIDLY TO BOTTOM RIGHT ── */
.brand-blob {
  position: absolute;
  bottom: 0;
  right: 0;
  max-width: 50%;
  height: auto;
  max-height: 520px;
  pointer-events: none;
  z-index: 1;
  transform-origin: bottom right;
}

/* ── CONTENT WRAPPERS ── */
.brand-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  pointer-events: none;
  z-index: 2;
}

.brand-content.active {
  pointer-events: auto;
  z-index: 3;
}

/* LEFT SIDE (Text - Smooth Fade) */
.content-left {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 50%;
  flex-shrink: 0;
  position: relative;
  z-index: 5;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.brand-content.active .content-left {
  opacity: 1;
}

.brand-logo {
  width: 277px;
  height: auto;
  display: flex;
  align-items: flex-start;
}

.brand-logo img {
  width: 100%;
  height: 100%;
}

.content-title {
  font-size: 40px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.5px;
  line-height: 48px;
}

.content-desc p+p {
  margin-top: 14px;
}

/* RIGHT SIDE (Image Slider Placement) */
.brand-area {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 50%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  pointer-events: none;
  transform: translateY(100%) scale(0.85);
  opacity: 0;
  transition: transform 1.2s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.8s ease;
}

.brand-content.active .brand-area {
  transform: translateY(0) scale(1);
  opacity: 1;
  transition-delay: 0.1s;
}

.brand-content.exit .brand-area {
  transform: translateY(-80%) scale(0.85);
  opacity: 0;
  transition: transform 1s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.6s ease;
  transition-delay: 0s;
}

.brand-img {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  height: 707px;
  width: auto;
}

.brand-img img {
  height: 100%;
  width: 100%;
  object-fit: contain;
  display: block;
  animation: floatImg 5s ease-in-out infinite;
  will-change: transform;
}

@keyframes floatImg {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-18px);
  }
}

/* ── DOTS ── */
.brand-dots {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 20;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .45);
  border: 1.5px solid rgba(255, 255, 255, .7);
  cursor: pointer;
  transition: background .3s, transform .3s;
}

.dot.active {
  background: rgba(255, 255, 255, .95);
  transform: scale(1.4);
}

.hikari .section-label {
  color: var(--hikari);
}

.hikari .faq-item:hover .faq-q-icon,
.hikari .faq-item:hover .faq-question-left,
.hikari .faq-item:hover .faq-toggle {
    color: var(--hikari);
}

.hikari .faq-item:hover .faq-toggle {
  border: 1.5px solid var(--hikari);
}

.hikari .faq-item.open .faq-q-icon,
.hikari .faq-item.open .faq-question-left,
.hikari .faq-item.open .faq-toggle  {
    color: var(--hikari);
}

.hikari .faq-item.open .faq-toggle {
  border: 1.5px solid var(--hikari);
}

.hikari .product-category {
  color: var(--hikari);
}

.hikari .section-label {
  color: var(--hikari);
}

.regen-d .faq-item:hover .faq-q-icon,
.regen-d .faq-item:hover .faq-question-left,
.regen-d .faq-item:hover .faq-toggle {
    color: var(--regen);
}

.regen-d .faq-item:hover .faq-toggle {
  border: 1.5px solid var(--regen);
}

.regen-d .faq-item.open .faq-q-icon,
.regen-d .faq-item.open .faq-question-left,
.regen-d .faq-item.open .faq-toggle  {
    color: var(--regen);
}

.regen-d .faq-item.open .faq-toggle {
  border: 1.5px solid var(--regen);
}

.regen-d .product-category {
  color: var(--regen);
}

.regen-d .section-label {
  color: var(--regen);
}

.royal-d .faq-item:hover .faq-q-icon,
.royal-d .faq-item:hover .faq-question-left,
.royal-d .faq-item:hover .faq-toggle {
    color: var(--royal);
}

.royal-d .faq-item:hover .faq-toggle {
  border: 1.5px solid var(--royal);
}

.royal-d .faq-item.open .faq-q-icon,
.royal-d .faq-item.open .faq-question-left,
.royal-d .faq-item.open .faq-toggle  {
    color: var(--royal);
}

.royal-d .faq-item.open .faq-toggle {
  border: 1.5px solid var(--royal);
}

.royal-d .product-category {
  color: var(--royal);
}

.royal-d .section-label {
  color: var(--royal);
}

/* Products */

.products-section {
  padding-block: var(--space-y);
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

/* ===========================================================
     PRODUCT CARD
     =========================================================== */
.product-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-white);
  border: 1px solid var(--color-200);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  padding: 12px;
  overflow: hidden;
  transition: transform 0.32s var(--ease), box-shadow 0.32s var(--ease);
  opacity: 0;
  transform: translateY(18px);
}

.product-card.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease),
    box-shadow 0.32s var(--ease);
}

.product-card:hover,
.product-card:focus-visible {
  transform: translateY(-6px);
  box-shadow: var(--shadow-card-hover);
}

.product-card:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
}

.product-media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  background: var(--bg-white);
  overflow: hidden;
  opacity: 1;
}

.product-media img {
  width: 100%;
  height: 100%;
  transform-origin: center;
  transition: transform 0.5s var(--ease);
}


.product-card:hover .product-media img {
  transform: scale(1.05);
}

.product-content {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  gap: 9px;
  padding: 12px;
  border: 1px solid var(--color-200);
  border-radius: var(--radius-sm);
}

.product-title {
  margin: 0;
  color: var(--color-500);
}


/* ── RESPONSIVE TWEAKS ── */
@media(max-width: 1200px) {
    
  .brand {
      height: 80vh;
  }
}

@media(max-width: 1024px) {
  .brand-area {
    width: 40%;
  }

  .brand-img img {
    max-height: 50vh;
  }

  .brand-blob {
    max-width: 55%;
  }
}



@media (max-width: 900px) {
  
	.brand {
		height: 100vh;
	}
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}


@media(max-width: 820px) {
  

    .brand-card {
        height: 420px;
    }

    .bottle-img {
        height: 74%;
    }
  .brand {
    height: auto;
    min-height: 100vh;
  }

  .brand-content {
    flex-direction: column;
    align-items: flex-start;
    padding: 10rem 0 2rem;
    gap: 24px;
  }

  .brand-logo {
    width: 30vw;
    height: auto;
  }

  .content-left {
    width: 100%;
    gap: 14px;
  }

  .content-title {
    font-size: 26px;
  }

  .brand-area {
    width: 100%;
  }

  .brand-img img {
    opacity: 0.5;
  }

  .brand-blob {
    max-width: 100%;
    width: 100%;
    max-height: 240px;
  }
}


@media (max-width: 580px) {
  
  .brand-img img {
    height: 80vh;
    max-width: 90%;
    opacity: 0.5;
  }
  
  .products-grid {
    grid-template-columns: 1fr;
  }
  
}


/* ===========================================================
     MOTION
     =========================================================== */
@media (prefers-reduced-motion: reduce) {
  .product-card {
    opacity: 1;
    transform: none;
    transition: box-shadow 0.2s ease;
  }

  .product-card:hover,
  .product-card:focus-visible {
    transform: none;
  }

  .product-media svg,
  .product-card:hover .product-media svg {
    transition: none;
    transform: none;
  }
}