/* Shared Aesthetic shirt-grid styles used by the home page (and sourced from explore.html). */

/* Password UI */

/* Password UI — docked inside the clicked shirt / column (fills that cell only) */
#explore-password-pool {
    display: none;
}
.password-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    min-height: 100vh;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    box-sizing: border-box;
}
.password-overlay.password-overlay--docked {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    min-height: 100%;
    /* Below hero chrome; raised again when .active so clicks beat .explore-top-icons-bar (10020) */
    z-index: 35;
}
.password-overlay.password-overlay--docked.active {
    z-index: 10025;
}
.password-overlay.active {
    opacity: 1;
    pointer-events: auto;
}
.password-overlay.success {
    background: rgba(0, 255, 0, 0.85);
}
.password-modal.success {
    border: 2px solid #00ff00;
}
.password-input.success {
    border-bottom-color: #00ff00;
    color: #00ff00;
}
.password-modal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10001;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    text-align: center;
    width: min(92%, 18rem);
    max-width: 100%;
    box-sizing: border-box;
    padding: 0 0.5rem;
}
.password-modal.active {
    opacity: 1;
    pointer-events: auto;
}
.password-modal-label {
    color: #fff;
    font-size: clamp(0.75rem, 2.8vw, 1.5rem);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    display: block;
}
.password-input {
    background: transparent;
    border: none;
    border-bottom: 2px solid #fff;
    color: #fff;
    font-size: clamp(0.65rem, 2.2vw, 1.2rem);
    padding: 0.5rem 0;
    width: 100%;
    max-width: 16rem;
    margin: 0 auto;
    display: block;
    text-align: center;
    outline: none;
    font-family: inherit;
}
.password-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}
/* Close control: child of overlay (full cell), not modal — avoids label/stacking eating clicks */
.password-close-btn {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    z-index: 10030;
    color: #fff;
    font-size: 1.75rem;
    font-weight: 300;
    cursor: pointer;
    min-width: 44px;
    min-height: 44px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease, color 0.3s ease;
    line-height: 1;
    border: none;
    background: rgba(0, 0, 0, 0.25);
    border-radius: 6px;
    padding: 0;
    font-family: inherit;
    box-sizing: border-box;
}
.password-overlay.active .password-close-btn {
    opacity: 1;
    pointer-events: auto;
}
.password-close-btn:hover {
    transform: scale(1.2);
    color: #ff006e;
}
@keyframes screenShake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-20px); }
    20%, 40%, 60%, 80% { transform: translateX(20px); }
}
.password-overlay.shake {
    animation: screenShake 0.5s ease-in-out;
}
body.shake {
    animation: screenShake 0.5s ease-in-out;
}


/* Product cards + 3-column grid */

/* Explore: one hero section per shirt */
.explore-hero-section {
    position: relative;
    width: 100%;
    min-height: 85vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    cursor: pointer;
    overflow: hidden;
    border-bottom: 1px solid #eee;
    transition:
        background 0.35s ease,
        padding 0.5s cubic-bezier(0.33, 1, 0.68, 1),
        min-height 0.5s cubic-bezier(0.33, 1, 0.68, 1),
        border-color 0.35s ease,
        filter 0.4s ease;
}
.explore-hero-section:hover {
    background: transparent;
}
.explore-hero-bg {
    position: absolute;
    inset: 0;
    background: transparent;
    z-index: 0;
}
.explore-hero-img {
    position: relative;
    z-index: 2;
    max-width: 100%;
    max-height: 60vh;
    width: auto;
    height: auto;
    object-fit: contain;
    opacity: 1;
    transition:
        max-height 0.5s cubic-bezier(0.33, 1, 0.68, 1),
        max-width 0.5s cubic-bezier(0.33, 1, 0.68, 1),
        opacity 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}
/* Extra overlay layer for hero shirts (covers entire hero section, above shirt image) */
.explore-hero-extra {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 3;
    pointer-events: none;
}
.explore-hero-extra--white {
    display: none;
}
/* Loading spinner markup kept for structure; hidden on all product heroes */
.explore-hero-loader {
    display: none;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 5;
    pointer-events: none;
}
.explore-hero-loader img {
    width: 64px;
    height: 64px;
    animation: explore-loader-spin 1s linear infinite;
}
@keyframes explore-loader-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
.explore-hero-info {
    position: relative;
    z-index: 4;
    text-align: center;
    margin-top: 0.25rem;
}
.explore-hero-title {
    font-size: 0.6rem;
    font-weight: 600;
    color: #222;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}
.explore-hero-category {
    font-size: 0.45rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.explore-hero-price {
    font-size: 0.55rem;
    font-weight: 600;
    color: #222;
    margin-top: 0.35rem;
}

/* Two shirts side by side in one hero (x + y) */
/* One listing for both shirts — whole band is one clickable section */
.explore-hero-section--pair {
    cursor: pointer;
}
.explore-hero-pair-row {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 2rem 3rem;
    width: 100%;
    max-width: 1400px;
}
.explore-hero-pair-col {
    position: relative;
    flex: 1 1 260px;
    min-width: 0;
    max-width: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: inherit;
}
@media (max-width: 768px) {
    .explore-hero-pair-col {
        max-width: 100%;
    }
}
.explore-hero-info--pair {
    margin-top: 1rem;
    max-width: 56rem;
    padding: 0 1rem;
}
.explore-hero-info--pair .explore-hero-title {
    line-height: 1.35;
}

/* Product list wrapper + 3-column layout (toggle via toolbar) */
.explore-products {
    display: block;
    width: 100%;
}
.explore-products--columns-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    padding: 0 0.75rem 1rem;
    box-sizing: border-box;
    width: 100%;
    transition:
        gap 0.45s cubic-bezier(0.33, 1, 0.68, 1),
        padding 0.45s cubic-bezier(0.33, 1, 0.68, 1);
}
.explore-products--columns-3 .explore-hero-section {
    min-height: min(52vh, 480px);
    padding: 1.25rem 0.75rem;
    border-bottom: none;
}
.explore-products--columns-3 .explore-hero-img {
    max-height: 36vh;
}
.explore-products--columns-3 .explore-hero-section--pair {
    grid-column: 1 / -1;
    min-height: min(60vh, 560px);
}
.explore-products--columns-3 .explore-hero-section--pair .explore-hero-img {
    max-height: 40vh;
}
@media (max-width: 900px) {
    .explore-products--columns-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 520px) {
    .explore-products--columns-3 {
        grid-template-columns: 1fr;
    }
}
.explore-products--columns-3 .explore-grid-placeholder {
    min-height: min(52vh, 480px);
    padding: 1.25rem 0.75rem;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
}
.explore-products--columns-3 .explore-grid-placeholder .explore-hero-info {
    margin-top: 0.25rem;
    width: 100%;
    max-width: 100%;
    padding: 0 0.15rem;
}
.explore-products--columns-3 .explore-grid-placeholder .explore-hero-title {
    line-height: 1.3;
    hyphens: auto;
    overflow-wrap: break-word;
}
.explore-products--columns-3 .explore-grid-placeholder-img {
    max-width: 100%;
    max-height: 36vh;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    user-select: none;
    pointer-events: none;
    opacity: 1;
    transition:
        max-height 0.5s cubic-bezier(0.33, 1, 0.68, 1),
        max-width 0.5s cubic-bezier(0.33, 1, 0.68, 1),
        opacity 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}


/* Glitch text behind shirts */

/* Static text at top of each product hero only */
.explore-hero-text-fill {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1;
    padding: 8px 12px;
    pointer-events: none;
    background: #fff;
}

.explore-hero-text-line {
    margin: 0 0 2px;
    font-size: 7px;
    color: #111;
    font-weight: 400;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    line-height: 1.35;
}


.explore-hero-text-line.explore-text-glitch {
    text-transform: none;
    font-variant-ligatures: none;
    text-shadow: 0.4px 0 rgba(0, 255, 242, 0.28), -0.4px 0 rgba(255, 0, 60, 0.28);
}
.explore-hero-text-line.explore-text-glitch.is-rgb {
    text-shadow: -1.4px 0 #ff003c, 1.4px 0 #00fff2;
}
.explore-hero-text-line.explore-text-glitch.is-jitter {
    transform: translate(1px, 0) skewX(-9deg);
}
.explore-hero-text-line.explore-text-glitch.is-flicker {
    opacity: 0.42;
}
.explore-hero-text-fill {
    overflow: hidden;
}
@media (prefers-reduced-motion: reduce) {
    .explore-hero-text-line.explore-text-glitch {
        text-shadow: 0.3px 0 rgba(0, 255, 242, 0.16), -0.3px 0 rgba(255, 0, 60, 0.16);
    }
    .explore-hero-text-line.explore-text-glitch.is-jitter {
        transform: none;
    }
    .explore-hero-text-line.explore-text-glitch.is-rgb {
        text-shadow: 0.5px 0 rgba(0, 255, 242, 0.28), -0.5px 0 rgba(255, 0, 60, 0.28);
    }
    .explore-hero-text-line.explore-text-glitch.is-flicker {
        opacity: 0.82;
    }
}


@media (prefers-reduced-motion: reduce) {
    .explore-hero-section,
    .explore-hero-img,
    .explore-products--columns-3,
    .explore-products--columns-3 .explore-grid-placeholder-img {
        transition-duration: 0.01ms !important;
    }
}

@media (max-width: 768px) {
    .explore-hero-section {
        min-height: 60vh !important;
        padding: 2rem 1rem !important;
    }
    .explore-hero-img {
        max-height: 45vh !important;
        max-width: 85vw !important;
    }
    .explore-hero-info {
        margin-top: 1rem !important;
    }
    .explore-hero-title {
        font-size: 0.75rem !important;
    }
    .explore-hero-category {
        font-size: 0.55rem !important;
    }
    .explore-products--columns-3 {
        grid-template-columns: 1fr !important;
        gap: 0.5rem !important;
        padding: 0 0.5rem !important;
    }
    .explore-products--columns-3 .explore-hero-section {
        min-height: 50vh !important;
    }
    .explore-hero-pair-row {
        flex-direction: column !important;
        gap: 1.5rem !important;
    }
    .explore-hero-pair-col {
        max-width: 100% !important;
    }
    .explore-hero-text-fill {
        overflow: hidden !important;
        max-width: 100vw !important;
    }
    .explore-hero-text-line {
        font-size: 0.5rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
    }
    .password-modal {
        width: min(95%, 280px) !important;
    }
    .password-modal-label {
        font-size: 1rem !important;
    }
    .password-input {
        font-size: 0.9rem !important;
    }
}

/* Home page placement under the mannequin hero */
body.index-page #index-explore-grid {
    position: relative;
    z-index: 1;
    width: 100%;
    background: #000;
    color: #f2f2f2;
    color-scheme: dark;
    padding: 4.75rem 0 2.5rem;
    box-sizing: border-box;
}
body.index-page #index-explore-grid .explore-products,
body.index-page #exploreProducts {
    background-color: #000;
}
@media (max-width: 768px) {
    body.index-page #index-explore-grid {
        padding-top: 8rem;
    }
}

/* Black theme for the home grid (same as Aesthetic) */
body.index-page .explore-hero-section {
    border-bottom-color: rgba(255, 255, 255, 0.08);
    background: #000;
}
body.index-page .explore-hero-section:hover {
    background: #000;
}
body.index-page .explore-hero-bg {
    background: transparent;
}
body.index-page .explore-hero-title,
body.index-page .explore-hero-price {
    color: #f4f4f4;
}
body.index-page .explore-hero-category {
    color: #b8b8b8;
}
body.index-page .explore-hero-text-fill {
    background: transparent;
}
body.index-page .explore-hero-text-line {
    color: #dedede;
}
body.index-page .explore-hero-text-line.explore-text-glitch {
    text-shadow: 0.55px 0 rgba(0, 255, 242, 0.55), -0.55px 0 rgba(255, 0, 60, 0.55);
}
body.index-page .explore-hero-text-line.explore-text-glitch.is-rgb {
    text-shadow: -1.5px 0 #ff003c, 1.5px 0 #00fff2;
}
body.index-page .explore-hero-img,
body.index-page .explore-grid-placeholder-img {
    filter: none;
}
@media (prefers-reduced-motion: reduce) {
    body.index-page .explore-hero-text-line.explore-text-glitch {
        text-shadow: 0.35px 0 rgba(0, 255, 242, 0.3), -0.35px 0 rgba(255, 0, 60, 0.3);
    }
    body.index-page .explore-hero-img,
    body.index-page .explore-grid-placeholder-img {
        filter: none;
    }
}
