/* ===================================
   Product Details Page
   =================================== */

.product-details-wrapper {
    background-color: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    margin: 2rem auto;
}

.product-details-header {
    background: linear-gradient(135deg, var(--gray-800) 0%, var(--gray-900) 100%);
    padding: 2rem;
    text-align: center;
    border-bottom: 3px solid var(--primary-color);
}

.product-details-header h2 {
    color: var(--white);
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.product-details-header p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.125rem;
    margin: 0;
}

.product-details-header p strong {
    color: var(--primary-color);
    font-weight: 600;
}

.product-details-body {
    padding: 3rem 2rem;
}

.back-button {
    display: inline-flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    background: var(--white);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    margin-bottom: 2rem;
}

.back-button:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateX(-5px);
}

.back-button i {
    margin-right: 0.5rem;
}

.product-main-image {
    text-align: center;
    background: var(--gray-50);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    border: 2px solid var(--gray-200);
}

.product-main-image img {
    max-width: 100%;
    height: auto;
    max-height: 500px;
    object-fit: contain;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
}

.product-info {
    padding-left: 2rem;
}

.product-category-badge {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--white);
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
}

.product-category-name {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--gray-900);
    margin-bottom: 1.5rem;
}

.product-price-area {
    background: var(--gray-50);
    padding: 1.5rem;
    border-radius: var(--border-radius-lg);
    border: 2px solid var(--gray-200);
    margin-bottom: 2rem;
}

.product-old-price {
    color: var(--gray-400);
    font-size: 1.125rem;
    text-decoration: line-through;
    margin-bottom: 0.5rem;
}

.product-new-price {
    color: var(--accent-color);
    font-size: 2.5rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
}

.product-tax-notice {
    color: var(--gray-600);
    font-size: 0.875rem;
    font-style: italic;
    margin: 0;
}

.product-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.add-to-cart-button {
    flex: 1;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--white);
    border: none;
    padding: 1rem 2rem;
    border-radius: var(--border-radius);
    font-size: 1.125rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 6px 20px rgba(124, 58, 237, 0.4);
    transition: var(--transition);
    cursor: pointer;
}

.add-to-cart-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(124, 58, 237, 0.6);
}

.add-to-cart-button i {
    margin-right: 0.75rem;
}

.add-to-cart-button:disabled,
.add-to-cart-button.out-of-stock {
    background: linear-gradient(135deg, #9ca3af, #6b7280) !important;
    color: white !important;
    cursor: not-allowed !important;
    opacity: 0.7 !important;
    pointer-events: none !important;
    border: 2px solid #ef4444;
    position: relative;
}

.add-to-cart-button:disabled:hover,
.add-to-cart-button.out-of-stock:hover {
    background: linear-gradient(135deg, #9ca3af, #6b7280) !important;
    transform: none !important;
    box-shadow: none !important;
}

.add-to-cart-button:disabled::before,
.add-to-cart-button.out-of-stock::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 10px,
        rgba(239, 68, 68, 0.1) 10px,
        rgba(239, 68, 68, 0.1) 20px
    );
    border-radius: 8px;
    pointer-events: none;
}

.product-quantity-input {
    width: 120px;
    padding: 1rem;
    font-size: 1.125rem;
    font-weight: 700;
    text-align: center;
    border: 2px solid var(--gray-300);
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.product-quantity-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.product-details-section {
    background: var(--gray-50);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    border: 2px solid var(--gray-200);
}

.product-details-title {
    color: var(--primary-color);
    font-size: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
    border-bottom: 3px solid var(--primary-color);
    padding-bottom: 0.75rem;
}

.product-description {
    color: var(--gray-700);
    font-size: 1.063rem;
    line-height: 1.8;
}

.product-description p {
    margin-bottom: 1rem;
}

/* Responsive Design */
@media (max-width: 992px) {
    .product-info {
        padding-left: 0;
        margin-top: 2rem;
    }

    .product-details-body {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 768px) {
    .product-details-header {
        padding: 1.5rem;
    }

    .product-details-header h2 {
        font-size: 1.5rem;
    }

    .product-details-body {
        padding: 1.5rem 1rem;
    }

    .product-main-image {
        padding: 1.5rem;
    }

    .product-main-image img {
        max-height: 350px;
    }

    .product-new-price {
        font-size: 2rem;
    }

    .product-actions {
        flex-direction: column;
    }

    .add-to-cart-button {
        width: 100%;
    }

    .product-quantity-input {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .product-details-header h2 {
        font-size: 1.25rem;
    }

    .product-details-header p {
        font-size: 1rem;
    }

    .product-category-name {
        font-size: 1.5rem;
    }

    .product-new-price {
        font-size: 1.75rem;
    }

    .add-to-cart-button {
        font-size: 1rem;
        padding: 0.875rem 1.5rem;
    }
}

/* Product Details Carousel */
.product-details-carousel {
    width: 100%;
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
}

.product-details-carousel .carousel-inner {
    background: var(--gray-50);
    padding: 2rem;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-details-carousel .carousel-item {
    text-align: center;
    margin-right: 0;
}

.product-details-carousel .carousel-item img {
    max-width: 100%;
    max-height: 500px;
    height: auto;
    object-fit: contain;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
}

.product-details-carousel .carousel-control-prev,
.product-details-carousel .carousel-control-next {
    width: 50px;
    height: 50px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    opacity: 0.7;
    transition: opacity 0.3s ease, background 0.3s ease;
}

.product-details-carousel:hover .carousel-control-prev,
.product-details-carousel:hover .carousel-control-next {
    opacity: 1;
    background: rgba(0, 0, 0, 0.7);
}

.product-details-carousel .carousel-control-prev:hover,
.product-details-carousel .carousel-control-next:hover {
    background: rgba(0, 0, 0, 0.9);
}

.product-details-carousel .carousel-control-prev-icon,
.product-details-carousel .carousel-control-next-icon {
    width: 24px;
    height: 24px;
}

.product-details-carousel .carousel-indicators {
    margin-bottom: 1rem;
    bottom: 0;
}

.product-details-carousel .carousel-indicators button {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.8);
    margin: 0 4px;
    opacity: 0.6;
    transition: all 0.3s ease;
}

.product-details-carousel .carousel-indicators button.active {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    opacity: 1;
    transform: scale(1.2);
}

.product-details-carousel .carousel-indicators button:hover {
    opacity: 1;
}

@media (max-width: 768px) {
    .product-details-carousel .carousel-inner {
        min-height: 300px;
        padding: 1.5rem;
    }

    .product-details-carousel .carousel-item img {
        max-height: 350px;
    }

    .product-details-carousel .carousel-control-prev,
    .product-details-carousel .carousel-control-next {
        width: 40px;
        height: 40px;
    }

    .product-details-carousel .carousel-control-prev-icon,
    .product-details-carousel .carousel-control-next-icon {
        width: 20px;
        height: 20px;
    }

    .product-details-carousel .carousel-indicators button {
        width: 8px;
        height: 8px;
        margin: 0 3px;
    }
}

