@import url('https://fonts.googleapis.com/css2?family=Inter:wght@900&display=swap');

:root {
    --bg-color: #ffffff;
    --text-color: #000000;
    --font-main: 'Plus Jakarta Sans', sans-serif;
    --transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

html {
    scroll-behavior: smooth;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    font-weight: 200;
    font-style: italic;
    line-height: 1.5;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Header */
header {
    position: sticky;
    top: 0;
    width: 100%;
    height: 60px; /* Increased height for prominence */
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    background-color: var(--bg-color);
    border-bottom: 1px solid #000;
    padding: 0 2rem;
    z-index: 1000;
}

.header-logo-link {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

.header-logo {
    height: 30px; /* Enlarged logo to make it more noticeable */
    width: auto;
    filter: brightness(0); /* Reverted to solid black */
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.header-logo:hover {
    opacity: 1;
}

.header-left {
    display: flex;
    align-items: center;
}

.back-link {
    font-size: 0.65rem;
    text-transform: lowercase;
    text-decoration: none;
    color: #000;
    opacity: 0.6;
    font-weight: 400;
    font-style: italic;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

.back-link:hover {
    opacity: 1;
}

.header-right {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 1rem;
}

.info-link, .cart-link {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.65rem;
    font-weight: 600;
    font-style: italic;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #000; /* Reverted to black */
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.info-link {
    font-size: 0.75rem;
    letter-spacing: 0;
}

.info-link:hover, .cart-link:hover {
    opacity: 1;
}

/* Main Gallery - Index Page */
.main-index {
    padding: 0;
    width: 100%;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
    align-items: start;
}

.main-index .media-container {
    border-top: 1px solid #000;
    aspect-ratio: 1 / 1; 
    display: flex;
}

/* Vertical border only for the left items in paired rows (Items 2 and 4) */
.main-index .media-container:nth-child(2),
.main-index .media-container:nth-child(4) {
    border-right: 1px solid #000;
}

.main-index .hero-item {
    grid-column: span 2;
    border-right: none;
    aspect-ratio: auto;
}

.media-container {
    width: 100%;
    height: auto;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 1s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.media-container:first-child {
    grid-column: span 2;
}

.media-container.visible {
    opacity: 1;
    transform: none;
}

.media-container a {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.media-container img, 
.media-container video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    filter: grayscale(100%);
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), filter 0.8s ease;
}

.media-container:hover img, 
.media-container:hover video {
    transform: scale(1.02);
    filter: grayscale(0%);
}

.media-container a {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.category-label {
    position: absolute;
    bottom: 1.5rem;
    left: 1.5rem;
    color: #fff;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.75rem;
    font-weight: 500;
    font-style: italic;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    z-index: 10;
    pointer-events: none;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    background: rgba(0,0,0,0.2);
    padding: 0.5rem 1rem;
    backdrop-filter: blur(5px);
}

.media-container:hover .category-label {
    opacity: 1;
    transform: translateY(0);
}

.video-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}

/* Footer */
footer {
    border-top: 1px solid #000;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 400;
    font-style: italic;
    text-transform: uppercase;
}

.footer-top {
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    background: #f5f5f5;
}

.footer-main .footer-col h3,
.footer-main .footer-col p,
.footer-main .footer-col a,
.footer-bottom p {
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    line-height: 1.6;
    margin: 0;
    color: #000;
}

.footer-top .manifesto-section p {
    font-size: 2.5rem; /* Massive for high impact */
    font-weight: 700; /* Bold */
    line-height: 1;
    letter-spacing: -0.04em;
    text-align: right;
    margin-bottom: 0.5rem;
}

.footer-top h2 {
    font-weight: 400;
    font-style: italic;
    font-size: 1.2rem; /* Slightly larger for brand but same font/style */
}

.footer-main {
    display: grid;
    grid-template-columns: repeat(4, 1fr) auto;
    border-top: 1px solid #000;
}

.footer-col {
    padding: 2rem;
    border-right: 1px solid #000;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-col:last-child {
    border-right: none;
}

.footer-col h3 {
    margin-bottom: 1.5rem;
    opacity: 0.5; /* Keeping headers slightly distinct but same style */
}

.footer-col a {
    text-decoration: none;
}

.footer-col.logo-col {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
}

.footer-logo {
    max-width: 170px; /* Increased by 40% (from 120px) */
    height: auto;
    filter: brightness(0); /* Make it pure black if it's not */
    opacity: 0.8;
}

.footer-bottom {
    padding: 1.5rem 2rem;
    border-top: 1px solid #000;
    display: flex;
    justify-content: space-between;
}

/* Product Grid - Alexander Wang Style */
.product-gallery {
    padding: 0;
    width: 100%;
    border-top: 1px solid #000;
}

.product-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    border-bottom: 1px solid #000;
    font-family: 'Syne', sans-serif;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: lowercase;
}

.breadcrumb span {
    opacity: 0.4;
    margin: 0 0.5rem;
}

.controls-right {
    display: flex;
    gap: 2rem;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
}

.product-card {
    display: flex;
    flex-direction: column;
    border-right: 1px solid #000;
    border-bottom: 1px solid #000;
    text-decoration: none;
    color: inherit;
}

.product-card:nth-child(4n) {
    border-right: none;
}

.product-img-wrapper {
    width: 100%;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: #fff;
    border-bottom: 1px solid #000;
}

.product-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-info {
    padding: 1rem;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 400;
    font-style: italic;
    text-transform: lowercase;
    line-height: 1.2;
}

.product-name {
    font-size: 0.7rem;
    margin-bottom: 0.3rem;
}

.product-price {
    font-size: 0.7rem;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

/* Tablets & Small Laptops (up to 1024px) */
@media (max-width: 1024px) {
    .main-index {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .product-card:nth-child(2n) {
        border-right: none;
    }
    
    .product-card:nth-child(4n) {
        border-right: 1px solid #000;
    }

    .footer-main {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-col:nth-child(2n) {
        border-right: none;
    }

    .footer-col:nth-child(n+3) {
        border-top: 1px solid #000;
    }
}

/* Mobile Devices (up to 768px) */
@media (max-width: 768px) {
    header {
        padding: 0 1rem;
    }

    header h1 {
        font-size: 0.9rem;
        letter-spacing: 0.2em;
    }

    .main-index {
        grid-template-columns: 1fr;
        padding: 0;
    }

    .product-grid {
        grid-template-columns: 1fr;
    }

    .product-card {
        border-right: none !important;
    }

    .modal-content {
        padding: 2rem 1rem;
        width: 95%;
        margin: 1rem;
    }

    .modal-body {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-top {
        flex-direction: column;
        gap: 2rem;
        text-align: left;
    }

    .footer-top h2 {
        font-size: 2rem;
    }

    .footer-top .manifesto-section {
        text-align: left;
    }

    .footer-main {
        grid-template-columns: 1fr;
    }

    .footer-col {
        border-right: none !important;
        border-bottom: 1px solid #000;
        padding: 2rem 1rem;
    }

    .footer-col:last-child {
        border-bottom: none;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

/* Extra Small Devices (up to 480px) */
@media (max-width: 480px) {
    header h1 {
        font-size: 0.8rem;
    }

    .back-link, .info-link, .cart-link {
        font-size: 0.6rem;
    }

    .modal-right h2 {
        font-size: 1.1rem;
    }
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    display: none;
    z-index: 2000;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
}

.modal.visible {
    display: flex;
}

.modal-content {
    background: #fff;
    width: 100%;
    max-width: 1000px;
    position: relative;
    padding: 4rem 2rem;
}

.modal-header {
    margin-bottom: 2rem;
    display: flex;
    justify-content: flex-start;
}

.back-to-grid {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.85rem;
    font-weight: 500;
    font-style: italic;
    text-transform: lowercase;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.back-to-grid:hover {
    opacity: 1;
}

.modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.modal-left img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.modal-right {
    font-family: 'Plus Jakarta Sans', sans-serif;
    text-transform: lowercase;
    font-weight: 400;
    font-style: italic;
}

.modal-right h2 {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.modal-right #modal-price {
    font-size: 1.1rem;
    font-weight: 300;
    margin-bottom: 3rem;
    opacity: 0.6;
}

.size-selector {
    margin-bottom: 3rem;
}

.size-selector .label {
    font-size: 0.7rem;
    font-weight: 400;
    font-style: italic;
    margin-bottom: 1rem;
    opacity: 0.4;
}

.size-options {
    display: flex;
    gap: 1rem;
}

.size-options span {
    width: 35px;
    height: 35px;
    border: 1px solid #000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 400;
    font-style: italic;
    cursor: pointer;
    transition: background 0.3s ease, color 0.3s ease;
}

.size-options span.selected {
    background: #000;
    color: #fff;
}

.add-to-cart {
    width: 100%;
    padding: 1.2rem;
    background: #000;
    color: #fff;
    border: none;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 600;
    font-style: italic;
    text-transform: lowercase;
    font-size: 1rem;
    cursor: pointer;
    letter-spacing: 0.05em;
    transition: opacity 0.3s ease;
}

.add-to-cart:hover {
    opacity: 0.9;
}

@media (max-width: 768px) {
    .modal-body {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .modal-content {
        padding: 3rem 1rem;
    }
    
    .modal-right h2 {
        font-size: 1.2rem;
    }
}

/* Product Gallery & Interaction Styles */
.thumbnail-gallery {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.thumbnail-gallery img {
    width: 60px;
    height: 80px;
    object-fit: cover;
    cursor: pointer;
    border: 1px solid transparent;
    transition: border-color 0.3s ease;
}

.thumbnail-gallery img:hover {
    border-color: #000;
}

/* Selection Effect */
.product-card {
    transition: background-color 0.3s ease;
}

.product-card:hover {
    cursor: crosshair;
    background-color: #fbfbfb;
}

/* Floating Pulgita */
.floating-pulgita {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    width: 45px; /* Slightly larger as requested */
    height: 45px;
    z-index: 9999; /* Ensure it's above everything */
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.floating-pulgita img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.floating-pulgita:hover {
    transform: translateY(-5px) scale(1.1);
}

@media (max-width: 768px) {
    .floating-pulgita {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 40px;
        height: 40px;
    }
}
