/* product.css — страница товара */

@import 'variables.css';

/* ========== Основной блок ========== */
.product-page {
    background: linear-gradient(180deg, #f8fafc 0%, #fff 12%);
    min-height: 60vh;
}

/* ========== Хлебные крошки ========== */
.product-breadcrumb {
    font-size: 13px;
    color: var(--color-gray-dark);
}

.product-breadcrumb a {
    color: var(--main-blue);
    text-decoration: none;
    transition: color 0.2s;
}

.product-breadcrumb a:hover {
    color: var(--main-light);
}

.product-breadcrumb-sep {
    margin: 0 6px;
    opacity: 0.5;
}

/* ========== Галерея ========== */
.product-gallery-wrap {
    background: var(--color-white);
    border-radius: 12px !important;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    padding: 20px;
    border: 1px solid var(--color-gray);
}

.product-gallery-main {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fafafa;
    border-radius: 8px !important;
    overflow: hidden;
}

.product-gallery-main img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.product-gallery-thumbs {
    margin-top: 12px;
}

.product-thumb-btn {
    width: 56px;
    height: 56px;
    padding: 4px;
    border: 2px solid transparent;
    background: #f5f5f5;
    border-radius: 8px !important;
    cursor: pointer;
    transition: all 0.2s;
    overflow: hidden;
}

.product-thumb-btn:hover {
    border-color: var(--main-light);
    background: #fff;
}

.product-thumb-btn.active {
    border-color: var(--main-blue);
    background: #e3f2fd;
}

.product-thumb-btn img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-no-image {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #f0f0f0;
    border-radius: 8px !important;
    color: #999;
}

.product-no-image i {
    font-size: 3rem;
    margin-bottom: 8px;
}

/* ========== Заголовок и описание ========== */
.product-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-black);
    line-height: 1.35;
    margin-bottom: 12px;
}

.product-desc {
    font-size: 15px;
    color: var(--color-gray-dark);
    line-height: 1.6;
    margin-bottom: 20px;
}

/* ========== Цена ========== */
.product-price-block {
    display: flex;
    align-items: baseline;
    gap: 4px;
}

.product-price {
    font-size: 2rem;
    font-weight: 800;
    color: var(--main-blue);
    letter-spacing: -0.02em;
}

.product-price-currency {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--main-blue);
}

/* ========== Кнопки и счётчик ========== */
.product-btn-add {
    padding: 14px 32px;
    font-size: 16px;
    font-weight: 600;
    background: var(--main-blue);
    color: var(--color-white) !important;
    border: none;
    border-radius: 10px !important;
    cursor: pointer;
    transition: all 0.25s;
    box-shadow: 0 4px 14px rgba(21, 101, 192, 0.35);
}

.product-btn-add:hover {
    background: #0d47a1;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(21, 101, 192, 0.4);
}

.product-qty-control {
    display: inline-flex;
    align-items: center;
    gap: 0;
    border: 2px solid var(--color-gray);
    border-radius: 10px !important;
    overflow: hidden;
}

.product-qty-btn {
    width: 44px;
    height: 44px;
    padding: 0;
    font-size: 1.25rem;
    font-weight: 600;
    background: var(--color-white);
    border: none;
    color: var(--main-blue);
    cursor: pointer;
    transition: all 0.2s;
}

.product-qty-btn:hover:not(:disabled) {
    background: #e3f2fd;
    color: var(--main-light);
}

.product-qty-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.product-qty-num {
    min-width: 48px;
    text-align: center;
    font-size: 1.1rem;
    font-weight: 600;
}

.product-stock {
    font-size: 14px;
}

.product-stock i {
    margin-right: 6px;
}

/* ========== Характеристики ========== */
.product-specs {
    border-radius: 12px !important;
    overflow: hidden;
}

.product-specs .card-header {
    font-weight: 600;
    font-size: 1.05rem;
}

.product-specs-table tr {
    border-bottom: 1px solid #f0f0f0;
}

.product-specs-table tr:last-child {
    border-bottom: none;
}

.product-specs-table td {
    padding: 10px 0;
    font-size: 14px;
}

.product-specs-table td:first-child {
    color: var(--color-gray-dark);
    width: 140px;
}

.product-specs-table td:last-child {
    font-weight: 500;
}

/* ========== Отзывы ========== */
.product-reviews h4 {
    font-weight: 700;
    color: var(--color-black);
}

.product-review-item {
    border-radius: 12px !important;
    transition: box-shadow 0.2s;
}

.product-review-item:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
}

.product-review-date {
    font-size: 13px;
    color: var(--color-gray-dark);
}

.product-review-rating .fa-star {
    font-size: 0.9rem;
}

/* ========== Похожие товары ========== */
.product-similar h4 {
    font-weight: 700;
    color: var(--color-black);
}

.product-similar-card {
    border-radius: 12px !important;
    overflow: hidden;
    transition: all 0.3s;
}

.product-similar-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12) !important;
    border-color: transparent !important;
}

.product-similar-img {
    aspect-ratio: 1;
    background: #fafafa;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-similar-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-similar-name {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-similar-price {
    font-size: 1rem;
    font-weight: 700;
    color: var(--main-blue);
}

@media (max-width: 767px) {
    .product-title {
        font-size: 1.25rem;
    }
    .product-price {
        font-size: 1.6rem;
    }
}
