/* Uyana — product carousel + "Our approach" (shared, theme fonts/colours) */
:root {
    --jad-primary: var(--e-global-color-secondary, #111111);
    --jad-secondary: var(--e-global-color-primary, #1a1a1a);
    --jad-muted: #8a8a8a;
    --jad-line: #e7e4de;
    --jad-bg-soft: #f6f4f0;
}

/* ── Our approach ── */
.uyana-approach { max-width: 1280px; margin: 40px auto 10px; padding: 0 24px; text-align: center; }
.uyana-approach-title { font-size: 36px; line-height: 1.1; color: var(--jad-secondary); margin: 0 0 36px; }
.uyana-approach-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.uyana-approach-col { text-align: center; }

/* Hide focus ring on mouse click, keep for keyboard (a11y). */
.uyana-carousel :focus:not(:focus-visible),
.uyana-collection :focus:not(:focus-visible) { outline: none; }

/* ── Collection pages (New Arrivals / Bestsellers / Last Chance / Sale) ── */
.uyana-collection-banner { width: 100vw; max-width: 100vw; margin-left: calc(50% - 50vw); height: 300px; background-size: cover; background-position: center; }
.uyana-collection-header { text-align: center; max-width: 760px; margin: 40px auto; padding: 0 20px; }
.uyana-collection-title { font-size: 46px; line-height: 1.1; color: var(--jad-secondary); margin: 0 0 16px; }
.uyana-collection-intro { font-size: 16px; line-height: 1.7; color: var(--jad-muted); }
.uyana-collection-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px 24px; max-width: 1440px; margin: 0 auto; padding: 0 32px 64px; }
.uyana-collection-empty { text-align: center; color: var(--jad-muted); padding: 40px 0 80px; }
@media (max-width: 1100px) { .uyana-collection-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 700px) {
    .uyana-collection-banner { height: 180px; }
    .uyana-collection-title { font-size: 32px; }
    .uyana-collection-grid { grid-template-columns: repeat(2, 1fr); gap: 22px 14px; padding: 0 16px 56px; }
}

/* ── Carousel ── */
.uyana-carousel { margin: 0; width: 100%; }
/* Single-product "You'll also love" needs side padding (it's not in a box). */
.uyana-youll-love { padding: 0 32px; }
@media (max-width: 700px) { .uyana-youll-love { padding: 0 16px; } }
.uyana-carousel-head { display: flex; align-items: center; gap: 24px; margin-bottom: 6px; }
.uyana-carousel-title { font-size: 40px; line-height: 1; color: var(--jad-secondary); margin: 0; }
/* Arrows aligned left (next to the title) on laptop. */
.uyana-carousel-nav { display: flex; gap: 18px; margin-right: auto; }
.uyana-carousel-arrow { width: auto; height: auto; border: none; border-radius: 0; background: none; color: var(--jad-secondary); cursor: pointer; padding: 4px; display: grid; place-items: center; transition: opacity .15s; }
.uyana-carousel-arrow:hover { opacity: .6; }
.uyana-carousel-arrow svg { width: 34px; height: 22px; }
.uyana-carousel-arrow[disabled] { opacity: .3; cursor: default; }

/* 5 cards + ~20% peek of the next; track bleeds past the box to the viewport's right edge. */
.uyana-carousel-track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - var(--uy-gaps, 5) * 16px) / var(--uy-per, 5.2)); gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; margin-right: calc((100% - 100vw) / 2); padding: 10px 4px 30px; }
.uyana-carousel-track::-webkit-scrollbar { display: none; }
/* Mouse drag-to-swipe affordance */
.uyana-carousel-track { cursor: grab; }
.uyana-carousel-track.is-dragging { cursor: grabbing; scroll-behavior: auto; }
.uyana-carousel-track.is-dragging .uyana-ccard { pointer-events: none; }
.uyana-carousel-track img { -webkit-user-drag: none; user-select: none; }

/* Sliding progress line under the track (rounded grey track + darker thumb). */
.uyana-carousel-progress { position: relative; height: 5px; background: #e6e3dd; border-radius: 99px; margin-top: 0px; overflow: hidden; }
.uyana-carousel-progress-bar { position: absolute; top: 0; left: 0; height: 5px; width: 20%; background: #b7b3ac; border-radius: 99px; transition: left .15s ease, width .15s ease; }

.uyana-ccard { scroll-snap-align: start; text-decoration: none; color: inherit; display: block; }
/* Cream card container */
.uyana-ccard-inner { position: relative; background: #f3efe7; border-radius: 22px; padding: 16px; transition: box-shadow .25s ease, transform .25s ease; }
.uyana-ccard:hover .uyana-ccard-inner { box-shadow: 0 14px 34px rgba(60, 45, 30, .12); transform: translateY(-2px); }
/* NEW badge */
.uyana-ccard-badge { position: absolute; top: 26px; left: 26px; z-index: 2; background: #7c1f1f; color: #fff; font-size: 12px; font-weight: 600; letter-spacing: .08em; padding: 7px 16px; border-radius: 99px; }
.uyana-ccard-media { position: relative; aspect-ratio: 4 / 5; background: var(--jad-bg-soft); overflow: hidden; border-radius: 14px; }
/* square="yes" → standardise every image to a 1:1 box */
.uyana-carousel--sq .uyana-ccard-media { aspect-ratio: 1 / 1; }
.uyana-ccard-media .uyana-ccard-img { position: absolute; inset: 0; width: 100% !important; height: 100% !important; max-width: none; object-fit: cover; transition: opacity .4s ease; }
.uyana-ccard-img--2 { opacity: 0; }
.uyana-ccard:hover .uyana-ccard-img--2 { opacity: 1; }
/* Body: name + subtitle, then "See more" (on hover) below */
.uyana-ccard-body { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 16px 6px 6px; }
.uyana-ccard-title { font-size: 15px; font-weight: 500; line-height: 1.3; color: var(--jad-secondary); margin: 0 0 4px; }
.uyana-ccard-sub { font-size: 13px; color: var(--jad-muted); }
.uyana-ccard-more { font-size: 13px; letter-spacing: .03em; color: var(--jad-secondary); text-decoration: underline; text-underline-offset: 3px; opacity: 0; transform: translateY(4px); transition: opacity .2s ease, transform .2s ease; }
.uyana-ccard:hover .uyana-ccard-more { opacity: 1; transform: translateY(0); }
@media (max-width: 700px) {
    .uyana-ccard-badge { top: 24px; left: 24px; }
    /* Touch devices have no hover — always show See more. */
    .uyana-ccard-more { opacity: 1; transform: none; }
}

@media (max-width: 1100px) {
    /* Setting the vars on the track overrides the per-instance section values. */
    .uyana-carousel-track { --uy-gaps: 3; --uy-per: 3.3; }
    .uyana-approach-grid { grid-template-columns: repeat(2, 1fr); gap: 28px 24px; }
}
@media (max-width: 700px) {
    .uyana-carousel-track { --uy-gaps: 1; --uy-per: 1.3; gap: 14px; }
    .uyana-carousel-title { font-size: 28px; }
    .uyana-carousel-arrow svg { width: 30px; height: 20px; }
    .uyana-approach-grid { grid-template-columns: 1fr 1fr; }
    .uyana-approach-title { font-size: 28px; }
    /* Arrows split to the left and right edges below the title on mobile. */
    .uyana-carousel-head { flex-wrap: wrap; }
    .uyana-carousel-nav { width: 100%; justify-content: space-between; margin: 0; }
}

/* ── Card actions: "Login / Register" pill + round WhatsApp button ──
   --uy-cta-h is the single source of truth: it is the pill's height AND the
   circle's diameter, and the glyph is half of it. Change that one value to
   resize the whole row. Sizes are explicit (not aspect-ratio / stretch) so a
   theme's own img/svg rules can't stretch the icon.  */
.uyana-carousel, .uyana-cta-modal {
    --uy-cta: #282726;
    --uy-cta-hover: #B3842E;
    --uy-cta-h: 34px;   /* pill height = circle diameter */
    --uy-cta-gap: 8px;
}
.uyana-ccard--cta .uyana-ccard-inner { cursor: pointer; }
.uyana-ccard .uyana-ccard-actions { display: flex; flex-direction: row; align-items: center; flex-wrap: nowrap; gap: var(--uy-cta-gap, 8px); width: auto; }

.uyana-ccard .uyana-ccard-cta { box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center; height: var(--uy-cta-h, 34px); padding: 6px 22px; font-size: 13px; font-weight: 600; line-height: 1; letter-spacing: .04em; color: #fff; background: var(--uy-cta, #282726); border-radius: 99px; white-space: nowrap; cursor: pointer; transition: background .2s ease; }
.uyana-ccard .uyana-ccard-cta:hover, .uyana-ccard .uyana-ccard-cta:focus-visible { background: var(--uy-cta-hover, #B3842E); }

.uyana-ccard .uyana-ccard-wa { box-sizing: border-box; flex: 0 0 auto; width: var(--uy-cta-h, 34px); height: var(--uy-cta-h, 34px); min-width: var(--uy-cta-h, 34px); padding: 0; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; color: #fff; background: var(--uy-cta, #282726); cursor: pointer; transition: background .2s ease; }
.uyana-ccard .uyana-ccard-wa:hover, .uyana-ccard .uyana-ccard-wa:focus-visible { background: var(--uy-cta-hover, #B3842E); }
/* Glyph = half the circle. Explicit px + max-width:none beats theme svg rules. */
.uyana-ccard .uyana-ccard-wa svg { display: block; flex: none; width: calc(var(--uy-cta-h, 34px) / 2); height: calc(var(--uy-cta-h, 34px) / 2); max-width: none; max-height: none; fill: currentColor; }
.uyana-ccard .uyana-ccard-cta:focus-visible, .uyana-ccard .uyana-ccard-wa:focus-visible { outline: 2px solid var(--uy-cta, #282726); outline-offset: 2px; }

/* ── Login / Register / WhatsApp modal ── */
.uyana-cta-modal { position: fixed; inset: 0; z-index: 99999; display: flex; align-items: center; justify-content: center; padding: 20px; background: rgba(22, 17, 12, .6); opacity: 0; transition: opacity .2s ease; }
.uyana-cta-modal[hidden] { display: none; }
.uyana-cta-modal.is-open { opacity: 1; }
.uyana-cta-box { position: relative; width: 100%; max-width: 400px; background: #fff; border-radius: 20px; padding: 34px 30px 30px; text-align: center; box-shadow: 0 24px 70px rgba(30, 22, 14, .3); transform: translateY(12px); transition: transform .22s ease; }
.uyana-cta-modal.is-open .uyana-cta-box { transform: translateY(0); }
.uyana-cta-close { position: absolute; top: 10px; right: 14px; background: none; border: none; font-size: 30px; line-height: 1; color: var(--jad-muted); cursor: pointer; padding: 4px 8px; }
.uyana-cta-close:hover { color: var(--jad-secondary); }
.uyana-cta-heading { font-size: 24px; line-height: 1.2; color: var(--uy-cta); margin: 0 0 8px; }
.uyana-cta-product { font-size: 15px; font-weight: 600; color: var(--uy-cta); margin: 0 0 8px; }
.uyana-cta-product[hidden] { display: none; }
.uyana-cta-intro { font-size: 13px; line-height: 1.6; color: var(--jad-muted); margin: 0 0 22px; }
.uyana-cta-actions { display: flex; flex-direction: column; gap: 10px; }
.uyana-cta-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; width: 100%; padding: 14px 20px; border-radius: 99px; font-size: 14px; font-weight: 600; letter-spacing: .03em; text-decoration: none; transition: background .2s ease, color .2s ease, border-color .2s ease; }
.uyana-cta-btn--primary { background: var(--uy-cta); color: #fff; }
.uyana-cta-btn--primary:hover { background: var(--uy-cta-hover); color: #fff; }
.uyana-cta-btn--ghost { background: #fff; color: var(--uy-cta); border: 1px solid var(--jad-line); }
.uyana-cta-btn--ghost:hover { background: #fff; color: var(--uy-cta-hover); border-color: var(--uy-cta-hover); }
.uyana-cta-btn--wa { background: #075E54; color: #fff; }
.uyana-cta-btn--wa:hover { background: #0a7367; color: #fff; }
.uyana-cta-btn--wa svg { width: 18px; height: 18px; flex: none; }
.uyana-cta-or { position: relative; margin: 18px 0; color: var(--jad-muted); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.uyana-cta-or::before { content: ""; position: absolute; top: 50%; left: 0; right: 0; height: 1px; background: var(--jad-line); }
.uyana-cta-or span { position: relative; background: #fff; padding: 0 12px; }
.uyana-cta-view { display: inline-block; margin-top: 18px; font-size: 13px; color: var(--jad-muted); text-decoration: underline; text-underline-offset: 3px; }
.uyana-cta-view:hover { color: var(--uy-cta-hover); }
.uyana-cta-view[hidden] { display: none; }
@media (max-width: 700px) {
    .uyana-cta-box { padding: 30px 22px 24px; border-radius: 18px; }
    .uyana-cta-heading { font-size: 21px; }
    .uyana-carousel { --uy-cta-h: 32px; }
    .uyana-ccard .uyana-ccard-cta { font-size: 12px; padding: 6px 18px; }
}

/* ── Image carousel + lightbox ── */
.uyana-icard { cursor: zoom-in; }
.uyana-carousel--img .uyana-ccard-inner { padding: 10px; }
/* Image carousel: same viewport bleed as product carousel so the 4th card
   peeks outside the boxed container on the right, exactly like product carousel does.
   Mobile always snaps to 1 card + peek via !important. */
@media (max-width: 700px) {
    .uyana-carousel--img .uyana-carousel-track { --uy-per: 1.2 !important; --uy-gaps: 1 !important; gap: 14px; }
}

.uyana-lightbox { position: fixed; inset: 0; z-index: 99999; display: none; align-items: center; justify-content: center; background: rgba(22, 17, 12, .92); }
.uyana-lightbox.is-open { display: flex; }
.uyana-lb-img { max-width: 90vw; max-height: 88vh; object-fit: contain; border-radius: 8px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.uyana-lb-btn { position: absolute; background: none; border: none; color: #fff; cursor: pointer; line-height: 1; opacity: .85; transition: opacity .15s; }
.uyana-lb-btn:hover { opacity: 1; }
.uyana-lb-close { top: 22px; right: 30px; font-size: 38px; }
.uyana-lb-prev, .uyana-lb-next { top: 50%; transform: translateY(-50%); font-size: 60px; padding: 8px 18px; }
.uyana-lb-prev { left: 18px; }
.uyana-lb-next { right: 18px; }
.uyana-lightbox.uyana-lb-solo .uyana-lb-prev, .uyana-lightbox.uyana-lb-solo .uyana-lb-next { display: none; }
@media (max-width: 700px) {
    .uyana-lb-prev, .uyana-lb-next { font-size: 40px; padding: 6px 12px; }
    .uyana-lb-close { top: 14px; right: 18px; }
}
