/* Hero Section */
.hero {
    position: relative;
    height: 48vh;
    max-height: 580px;
    min-height: 360px;
    background: linear-gradient(to right,
            rgba(0, 0, 0, 0.4) 0%,
            rgba(0, 0, 0, 0.2) 50%,
            rgba(0, 0, 0, 0) 100%), url("../images/hero-running-track.3c8918739004.jpg") center/cover no-repeat;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to right,
            rgba(0, 0, 0, 0.3) 0%,
            rgba(0, 0, 0, 0) 100%);
    z-index: 1;
}

.hero-content {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 4rem;
    position: relative;
    z-index: 2;
}

.hero-text {
    max-width: 600px;
    color: white;
    position: relative;
    padding-top: 2rem;
}

.hero-text h1 {
    font-size: 2.65rem;
    font-weight: 700;
    /* Use Bold weight for hero title */
    line-height: 1.1;
    margin-bottom: 1rem;
    letter-spacing: -0.015em;
    /* Adjust for regular Montserrat */
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-text p {
    font-size: 1.05rem;
    line-height: 1.4;
    margin-bottom: 1.3rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    font-weight: 300;
}

.shop-button {
    display: inline-block;
    padding: 0.75rem 1.95rem;
    background: white;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.1em;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.shop-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    background: #f8f8f8;
}

/* Search Box */
.search-box {
    margin-bottom: 1.5rem;
    width: 100%;
    max-width: 500px;
}

.search-box form {
    display: flex;
}

.search-box input[type="search"] {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    border-radius: 2px 0 0 2px;
    font-size: 1rem;
    outline: none;
}

.search-box button {
    padding: 1rem 1.5rem;
    background: var(--secondary);
    color: white;
    border: none;
    border-radius: 0 2px 2px 0;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}

.search-box button:hover {
    background: #236d7d;
}

.diagonal-overlay {
    position: absolute;
    top: 0;
    right: 0;
    width: 32%;
    height: 100%;
    background: var(--secondary);
    clip-path: polygon(100% 0, 100% 100%, 0 100%, 100% 0);
    opacity: 0.85;
    z-index: 1;
}

/* Featured Sections */
.featured-sections {
    padding: 4rem 0;
    background: var(--background);
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
}

.featured-section {
    background: white;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border);
}

.section-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary);
    letter-spacing: 0.05em;
}

.view-all {
    text-decoration: none;
    color: var(--secondary);
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    transition: color 0.2s;
}

.view-all:hover {
    color: var(--primary);
}

.shoe-list {
    padding: 1rem;
}

.shoe-item {
    display: grid;
    grid-template-columns: 80px 1fr 60px;
    align-items: center;
    padding: 1rem;
    text-decoration: none;
    color: var(--text);
    transition: all 0.2s ease;
    border-radius: 4px;
}

.shoe-item:hover {
    background: rgba(0, 0, 0, 0.02);
    transform: translateX(4px);
}

.shoe-image {
    width: 80px;
    height: 80px;
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    margin-right: 1rem;
    background: #f8f8f8;
    contain: layout style paint;
    /* Chrome optimization */
    display: flex;
    align-items: center;
    justify-content: center;
}

.shoe-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0s linear 0.2s, opacity 0.2s ease;
    will-change: opacity, visibility;
    /* Chrome optimization */
    content-visibility: auto;
    /* Modern Chrome optimization */
}

.shoe-image img.loaded {
    visibility: visible;
    opacity: 1;
    transition: visibility 0s linear 0s, opacity 0.2s ease;
}

/* NEW badge styling for homepage thumbnails */
.shoe-image .badge {
    position: absolute;
    top: 0.375rem;
    left: 0.375rem;
    padding: 0.1rem 0.3rem;
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    border-radius: 3px;
    z-index: 2;
}

.shoe-image .badge.new {
    background: var(--secondary);
    color: #ffffff;
}

.shoe-info h3 {
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 0.25rem;
    color: var(--primary);
}

/* Right-aligned critics score circle (reuse styles) */
.home-title-price-row {
    grid-template-columns: 80px 1fr 60px;
}

.home-title-price-left {
    min-width: 0;
}

.home-title-price-right {
    display: flex;
    align-items: center;
    justify-content: center;
}

.critics-score {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    color: #ffffff;
    text-align: center;
    padding: 0.4rem;
}

.critics-score .value {
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1;
}

.critics-score .label {
    font-size: 0.6rem;
    font-weight: 600;
    margin-top: 0.125rem;
    letter-spacing: 0.03em;
}

.critics-score.low {
    background: #dc2626;
}

.critics-score.mid {
    background: #e6b50a;
}

.critics-score.high {
    background: #16a34a;
}

.critics-score.na {
    background: #9ca3af;
}

.shoe-price,
.shoe-release {
    font-size: 0.875rem;
    color: var(--light-text);
}

/* Responsive Design */
@media (max-width: 1200px) {
    .hero-text h1 {
        font-size: 4rem;
    }

    .hero-content {
        padding: 0 3rem;
    }

    .diagonal-overlay {
        width: 50%;
    }
}

@media (max-width: 1024px) {
    .hero-text h1 {
        font-size: 2.5rem;
    }

    .hero-text p {
        font-size: 1rem;
    }

    .diagonal-overlay {
        width: 55%;
    }

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

@media (max-width: 768px) {
    .hero {
        height: 56vh;
        min-height: 420px;
    }

    .hero-content {
        padding: 0 2rem;
    }

    .hero-text {
        max-width: 100%;
    }

    .hero-text h1 {
        font-size: 2.3rem;
    }

    .hero-text p {
        font-size: 0.95rem;
        margin-bottom: 1.75rem;
    }

    .shop-button {
        padding: 0.7rem 1.6rem;
        font-size: 0.85rem;
    }

    .search-box {
        max-width: 100%;
    }

    .search-box input[type="search"] {
        padding: 0.875rem 1.25rem;
    }

    .search-box button {
        padding: 0.875rem 1.25rem;
    }

    .diagonal-overlay {
        width: 65%;
    }

    .container {
        padding: 0 1rem;
    }

    .section-header {
        padding: 1rem;
    }

    .section-header h2 {
        font-size: 1.125rem;
    }

    .shoe-image {
        width: 60px;
        height: 60px;
    }

    .shoe-info h3 {
        font-size: 0.875rem;
    }
}

@media (max-width: 480px) {
    .hero-text h1 {
        font-size: 2.25rem;
    }

    .hero-content {
        padding: 0 1.5rem;
    }

    .diagonal-overlay {
        width: 75%;
    }

    .search-box form {
        flex-direction: column;
    }

    .search-box input[type="search"] {
        border-radius: 2px 2px 0 0;
    }

    .search-box button {
        border-radius: 0 0 2px 2px;
        padding: 0.75rem;
    }
}