/* product.css */

/* --- Product Layout --- */
/* Override navbar shadow specifically for this page */
.app-navbar {
    box-shadow: none !important;
    border-bottom: 1px solid var(--border-color);
}

.product-page {
    font-family: 'Plus Jakarta Sans', sans-serif;
    padding-top: 1rem;
    min-height: calc(100vh - 300px);
    background-color: #ffffff;
}

.product-container {
    max-width: 1536px;
    margin: 0 auto;
    padding: 2rem 4%;
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

@media (min-width: 1024px) {
    .product-container {
        grid-template-columns: 1.2fr 1fr;
        align-items: start;
        gap: 4rem;
    }
}

/* --- Image Gallery --- */
.product-gallery-vertical {
    display: flex;
    flex-direction: column-reverse;
    gap: 1rem;
}

@media (min-width: 768px) {
    .product-gallery-vertical {
        flex-direction: row;
        align-items: flex-start;
    }
}

.product-thumbnails {
    display: flex;
    flex-direction: row;
    gap: 0.5rem;
    overflow-x: auto;
    scrollbar-width: none;
}
.product-thumbnails::-webkit-scrollbar {
    display: none;
}

@media (min-width: 768px) {
    .product-thumbnails {
        flex-direction: column;
        gap: 1rem;
        width: 70px;
        flex-shrink: 0;
        overflow-y: auto;
    }
}

.thumbnail-wrapper {
    width: 60px;
    height: 75px;
    flex-shrink: 0;
    cursor: pointer;
    border-radius: 0;
    overflow: hidden;
    border: 2px solid transparent;
    transition: border-color 0.2s;
}

@media (min-width: 768px) {
    .thumbnail-wrapper {
        width: 100%;
        height: 90px;
    }
}

.thumbnail-wrapper.active {
    border-color: var(--text-color);
}

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

.product-main-image {
    flex-grow: 1;
    border-radius: 0;
    overflow: hidden;
    background-color: #f7f6f2;
    aspect-ratio: 4/5;
}

@media (min-width: 768px) {
    .product-main-image {
        aspect-ratio: auto;
        height: auto;
    }
}

.product-main-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* --- Product Info --- */
.product-info {
    position: sticky;
    top: 100px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.product-breadcrumbs {
    font-size: 0.875rem;
    color: #888888;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.product-breadcrumbs a {
    color: #555555;
    transition: color 0.2s ease;
    text-decoration: none;
}

.product-breadcrumbs a:hover {
    color: var(--primary-color);
}

.product-title {
    font-family: 'Mona Sans', sans-serif;
    font-size: 2.2rem;
    font-weight: 600;
    color: var(--text-color);
    line-height: 1.15;
    margin: 0;
    letter-spacing: -0.02em;
}

.product-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.875rem;
}

.product-reviews-badge {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: #eab308;
}

.product-reviews-badge i {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

.product-reviews-count {
    color: #888888;
    margin-left: 0.25rem;
    cursor: pointer;
}
.product-reviews-count:hover {
    text-decoration: underline;
}

.product-price-container {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    margin-top: 0.5rem;
}

.product-price {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--text-color);
}

.product-original-price {
    font-size: 1.25rem;
    text-decoration: line-through;
    color: #aaaaaa;
}

.product-discount {
    font-size: 0.85rem;
    font-weight: 600;
    color: #e53935;
    background-color: #ffebee;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
}

.product-description {
    color: #555555;
    line-height: 1.7;
    font-size: 1rem;
}

.product-options {
    margin-top: 1rem;
}

.option-title {
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-color);
    display: block;
}

.color-options {
    display: flex;
    gap: 0.75rem;
}

.color-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 3px;
    background-clip: content-box;
}

.color-btn.selected {
    border-color: var(--primary-color);
}

.product-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.btn-add-to-cart {
    flex: 1;
    padding: 1.25rem;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    border-radius: 9999px;
    text-decoration: none;
}

.btn-wishlist {
    width: 58px;
    height: 58px;
    border: 1px solid var(--border-color);
    border-radius: 50%;
    background: transparent;
    color: var(--text-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-wishlist:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.product-accordion {
    margin-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.accordion-item {
    border-bottom: 1px solid var(--border-color);
}

.accordion-header {
    width: 100%;
    padding: 1.25rem 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: transparent;
    border: none;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
    cursor: pointer;
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.accordion-content-inner {
    padding-bottom: 1.25rem;
    color: #555555;
    line-height: 1.6;
}

.accordion-item.active .accordion-content {
    max-height: 500px;
}

.accordion-item.active .accordion-header i {
    transform: rotate(180deg);
}

/* --- Features List --- */
.feature-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
    padding: 1.5rem;
    background-color: #f9f9f9;
    border-radius: 8px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #555555;
    font-size: 0.875rem;
}

.feature-item i {
    color: var(--primary-color);
    width: 20px;
    height: 20px;
}

/* --- Reviews Section --- */
.reviews-section {
    max-width: 1536px;
    margin: 4rem auto;
    padding: 0 4%;
}

.reviews-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: 3rem;
}

.reviews-title {
    font-family: 'Mona Sans', sans-serif;
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 1rem;
    letter-spacing: -0.01em;
}

.overall-rating {
    display: flex;
    align-items: baseline;
    gap: 1rem;
}

.rating-score {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--text-color);
}

.rating-stars {
    display: flex;
    color: #eab308;
}

.rating-stars i {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.reviews-count-text {
    color: #888888;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

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

@media (min-width: 768px) {
    .reviews-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .reviews-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.review-card {
    background: #ffffff;
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.reviewer-name {
    font-weight: 600;
    color: var(--text-color);
}

.review-date {
    font-size: 0.75rem;
    color: #888888;
}

.review-stars {
    display: flex;
    color: #eab308;
    margin-bottom: 0.75rem;
}

.review-stars i {
    width: 14px;
    height: 14px;
    fill: currentColor;
}

.review-body {
    color: #555555;
    font-size: 0.875rem;
    line-height: 1.6;
}

/* --- You May Also Like Section --- */
.related-section {
    max-width: 1536px;
    margin: 3rem auto 2rem;
    padding: 0 4%;
}

.related-title {
    font-family: 'Mona Sans', sans-serif;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-color);
    text-align: left;
    margin-bottom: 3rem;
    letter-spacing: -0.01em;
}

@media (max-width: 640px) {
    .product-title {
        font-size: 1.6rem;
    }
    
    .product-price {
        font-size: 1.4rem;
    }
    
    .reviews-title {
        font-size: 1.75rem;
    }
    
    .related-title {
        font-size: 1.4rem;
    }
}
