/* ==========================================================================
   Xyra Noir — Elementor custom widget styles
   ========================================================================== */

.xn-section-title {
    position: relative;
    letter-spacing: 0.12em;
    margin-bottom: 36px;
}
.xn-section-title.text-center::after {
    content: "";
    display: block;
    width: 48px; height: 1px;
    background: var(--xn-gold);
    margin: 14px auto 0;
}
.xn-notice {
    background: var(--xn-bg-secondary);
    border-left: 3px solid var(--xn-gold);
    padding: 14px 18px;
    color: var(--xn-muted);
}

/* ---------- Hero Split ---------- */
.xn-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    min-height: 620px;
    background: linear-gradient(120deg, #000 0%, #0b0b0b 60%, #14110d 100%);
    overflow: hidden;
}
.xn-hero__text { padding: 60px clamp(24px, 6vw, 90px); }
.xn-hero__logo {
    font-family: var(--xn-font-head);
    font-size: clamp(2.6rem, 6vw, 4.6rem);
    letter-spacing: 0.16em;
    color: var(--xn-gold);
    text-transform: uppercase;
    line-height: 1;
    margin: 0 0 18px;
}
.xn-hero__title {
    font-family: var(--xn-font-body);
    font-weight: 400;
    font-size: clamp(0.95rem, 1.6vw, 1.25rem);
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--xn-white);
    margin-bottom: 34px;
    line-height: 1.7;
}
.xn-hero__media { height: 100%; }
.xn-hero__media img {
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center;
}
@media (max-width: 820px) {
    .xn-hero { grid-template-columns: 1fr; }
    .xn-hero__media { order: -1; max-height: 60vh; }
}

/* ---------- Category Tiles ---------- */
.xn-tiles {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}
.xn-tile {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 200px;
    padding: 28px 24px;
    background-color: var(--xn-bg-secondary);
    background-size: cover;
    background-position: center;
    color: var(--xn-white);
    overflow: hidden;
    isolation: isolate;
}
.xn-tile::before {
    content: "";
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.25) 0%, rgba(0,0,0,0.75) 100%);
    z-index: -1;
    transition: background 0.3s ease;
}
.xn-tile:hover::before { background: linear-gradient(180deg, rgba(0,0,0,0.15) 0%, rgba(0,0,0,0.6) 100%); }
.xn-tile__icon { color: var(--xn-gold); font-size: 1.6rem; margin-bottom: 12px; }
.xn-tile__icon svg { width: 28px; height: 28px; fill: var(--xn-gold); }
.xn-tile__label {
    font-family: var(--xn-font-body);
    font-size: 1rem; letter-spacing: 0.12em; text-transform: uppercase;
    margin-bottom: 6px;
}
.xn-tile__cta {
    font-size: 0.7rem; letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--xn-muted);
}
.xn-tile:hover .xn-tile__cta { color: var(--xn-gold); }

/* ---------- Products block ---------- */
.xn-products-block .products { margin-top: 0 !important; }
.xn-products-block li.product .price ins,
.xn-products-block li.product .price { color: var(--xn-gold); }

/* ---------- Story Split ---------- */
.xn-story {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
    background: var(--xn-bg-secondary);
    border: 1px solid var(--xn-border);
}
.xn-story--reverse .xn-story__media { order: 2; }
.xn-story__media img { width: 100%; height: 100%; object-fit: cover; min-height: 320px; }
.xn-story__text { padding: clamp(32px, 5vw, 64px); text-align: center; align-self: center; }
.xn-story__copy { color: var(--xn-muted); max-width: 460px; margin: 0 auto 28px; }
@media (max-width: 760px) {
    .xn-story, .xn-story--reverse { grid-template-columns: 1fr; }
    .xn-story--reverse .xn-story__media { order: -1; }
}

/* ---------- Instagram Grid ---------- */
.xn-insta__handle {
    color: var(--xn-muted);
    letter-spacing: 0.18em;
    font-size: 0.78rem;
    margin: -22px 0 28px;
}
.xn-insta-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 4px;
}
.xn-insta-cell {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--xn-bg-secondary);
    display: block;
}
.xn-insta-cell img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease, opacity 0.3s ease; }
.xn-insta-cell:hover img { transform: scale(1.08); opacity: 0.85; }

/* ---------- Newsletter ---------- */
.xn-newsletter__text { color: var(--xn-muted); font-size: 0.85rem; margin-bottom: 14px; }
.xn-newsletter__form { display: flex; max-width: 360px; }
.xn-newsletter__form input[type="email"] {
    flex: 1;
    border-right: none;
    border-radius: 0;
}
.xn-newsletter__form button {
    width: 48px;
    padding: 0;
    border-radius: 0;
    font-size: 1.1rem;
}

/* ---------- Products carousel (Swiper) ---------- */
.xn-products-block--carousel .xn-products-carousel { position: relative; }
.xn-products-carousel .swiper-slide { height: auto; }
/* product cards inside slides shouldn't keep the grid's width math */
.xn-products-carousel .swiper-slide li.product,
.xn-products-carousel .swiper-slide ul.products li.product {
    width: 100% !important;
    margin: 0 !important;
    float: none !important;
}
/* Swiper arrows in brand colours */
.xn-products-carousel .swiper-button-prev,
.xn-products-carousel .swiper-button-next {
    color: var(--xn-gold);
    width: 40px;
    height: 40px;
}
.xn-products-carousel .swiper-button-prev:after,
.xn-products-carousel .swiper-button-next:after { font-size: 22px; font-weight: 700; }
.xn-products-carousel .swiper-button-prev:hover,
.xn-products-carousel .swiper-button-next:hover { color: var(--xn-gold-hover); }
/* Pagination dots */
.xn-products-carousel .swiper-pagination { position: static; margin-top: 22px; }
.xn-products-carousel .swiper-pagination-bullet {
    background: var(--xn-muted);
    opacity: 0.5;
    width: 9px; height: 9px;
}
.xn-products-carousel .swiper-pagination-bullet-active {
    background: var(--xn-gold);
    opacity: 1;
}
/* Give arrows room so they don't overlap cards on smaller widths */
@media (max-width: 1024px) {
    .xn-products-carousel .swiper-button-prev,
    .xn-products-carousel .swiper-button-next { display: none; }
}

/* Products grid: ensure sale price (<ins>) isn't underlined by default */
.xn-products-block ul.products li.product .price ins { text-decoration: none; }
