:root {
    --primary-color: #3b66f5;
    --bg-color: #f8f9fb;
    --text-color: #1a1d23;
    --text-muted: #6b7280;
    --border-color: #e5e7eb;
    --card-bg: #ffffff;
    --header-bg: rgba(255, 255, 255, 0.8);
    --white: #ffffff;
    --input-bg: #f3f4f6;
    --sub-header-bg: #ffffff;
}

[data-theme="dark"] {
    --primary-color: #4f7aff;
    --bg-color: #0f1115;
    --text-color: #f3f4f6;
    --text-muted: #9ca3af;
    --border-color: #262a33;
    --card-bg: #1a1d23;
    --header-bg: rgba(26, 29, 35, 0.8);
    --white: #1a1d23;
    --input-bg: #262a33;
    --sub-header-bg: #1a1d23;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.5;
}

.container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background: var(--header-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.header-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--text-color);
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none;
}

.header-logo span {
    margin-top: -2px;
}

.header-logo-icon {
    width: 60px;
    height: 60px;
}

.search-bar {
    flex: 1;
    max-width: 500px;
}

.search-bar form {
    display: flex;
    align-items: center;
    width: 100%;
    position: relative;
}

.search-bar input {
    width: 100%;
    padding: 14px 25px;
    padding-right: 120px;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    background: var(--input-bg);
    color: var(--text-color);
    outline: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1rem;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}

.search-bar input:focus {
    background: #fff;
    box-shadow: 0 10px 25px rgba(59, 102, 245, 0.1), 0 0 0 4px rgba(59, 102, 245, 0.05);
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.search-submit-btn {
    position: absolute;
    right: 8px;
    top: 8px;
    bottom: 8px;
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0 22px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(59, 102, 245, 0.2);
}

.search-submit-btn:hover {
    background: #2a52d9;
    transform: scale(1.02);
    box-shadow: 0 6px 15px rgba(59, 102, 245, 0.3);
}

.clear-search {
    position: absolute;
    right: 95px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    text-decoration: none;
    font-size: 22px;
    font-weight: 300;
    line-height: 1;
    padding: 5px;
    transition: color 0.2s;
}

.clear-search:hover {
    color: #333;
}

.header-actions {
    display: flex;
    gap: 10px;
}

.action-btn {
    padding: 12px 24px;
    border-radius: 14px;
    font-weight: 700;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    transition: all 0.2s;
    border: none;
    cursor: pointer;
}

.action-btn svg {
    width: 20px;
    height: 20px;
    stroke-width: 2.5px;
}

.action-btn:hover {
    transform: translateY(-2px);
}

.btn-blue { background: var(--primary-color); color: white; }
.btn-gray { background: var(--border-color); color: var(--text-color); }

/* Sub-header */
.sub-header {
    background: var(--sub-header-bg);
    padding: 12px 0;
    font-size: 0.95rem;
    border-bottom: 1px solid var(--border-color);
}

.sub-header-content {
    display: flex;
    gap: 30px;
    align-items: center;
    color: var(--text-muted);
    font-weight: 600;
}

.sub-header-content div {
    cursor: pointer;
    transition: color 0.2s;
}

.sub-header-content div:hover {
    color: var(--primary-color);
}

/* Banner */
.banner {
    background: linear-gradient(rgba(59, 102, 245, 0.85), rgba(30, 59, 179, 0.85)), url('../img/5787579104537284047.jpg');
    background-size: cover;
    background-position: center;
    border-radius: 30px;
    padding: 60px 60px 50px;
    color: white;
    margin-top: 30px;
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(59, 102, 245, 0.15);
}

.banner-content {
    position: relative;
    z-index: 2;
    max-width: 700px;
}

@media (max-width: 992px) {
    .banner {
        text-align: center;
        padding: 36px 20px 32px;
    }
    
    .banner-content {
        max-width: 100%;
    }
}

.banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(59, 102, 245, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 1;
}

.banner::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -5%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(147, 51, 234, 0.3) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 1;
}



.banner h1 {
    font-size: 3.8rem;
    font-weight: 900;
    margin-bottom: 15px;
    line-height: 1.1;
    text-transform: uppercase;
    letter-spacing: -1px;
}

.banner .badge {
    background: linear-gradient(90deg, #ffd700, #ffae00);
    color: #000;
    padding: 4px 16px;
    border-radius: 12px;
    font-size: 0.95em;
    font-weight: 800;
    display: inline-block;
    transform: rotate(-2deg);
    box-shadow: 0 8px 25px rgba(255, 174, 0, 0.4);
    position: relative;
    overflow: hidden;
    margin: 0 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.banner .badge::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -60%;
    width: 20%;
    height: 200%;
    background: rgba(255, 255, 255, 0.4);
    transform: rotate(30deg);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% { left: -60%; }
    20% { left: 120%; }
    100% { left: 120%; }
}

.banner p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 500px;
    margin-bottom: 30px;
}

.banner-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 10px;
    position: relative;
    z-index: 2;
}

.stat-item {
    background: rgba(255,255,255,0.05);
    backdrop-filter: blur(12px);
    padding: 12px 24px;
    border-radius: 16px;
    font-size: 0.95rem;
    font-weight: 500;
    border: 1px solid rgba(255,255,255,0.1);
    transition: all 0.3s ease;
}

.stat-item:hover {
    background: rgba(255,255,255,0.1);
    transform: translateY(-3px);
    border-color: rgba(255,255,255,0.2);
}

/* Categories Nav */
.categories-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 30px;
}

.cat-nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    background: linear-gradient(0deg, rgba(59,102,245,0.12), rgba(59,102,245,0.12)), var(--card-bg);
    border-radius: 15px;
    text-decoration: none;
    color: var(--text-color);
    font-weight: 700;
    border: 1px solid rgba(59, 102, 245, 0.35);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 3px 10px rgba(59,102,245,0.15), 0 0 0 4px rgba(59, 102, 245, 0.1) inset;
    position: relative;
    overflow: hidden;
}

.cat-nav-item::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255,255,255,0.5), transparent);
    opacity: 0.35;
    transform: skewX(-20deg);
    animation: catNavSheen 4s linear infinite;
}

.cat-nav-item:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: var(--bg-color);
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(59, 102, 245, 0.18), 0 0 0 4px rgba(59, 102, 245, 0.14) inset;
}

.cat-nav-item.active {
    background: linear-gradient(135deg, var(--primary-color) 0%, #6f8eff 100%);
    color: #fff;
    border-color: var(--primary-color);
    box-shadow: 0 14px 32px rgba(59, 102, 245, 0.3), 0 0 0 5px rgba(59, 102, 245, 0.28) inset;
    transform: translateY(-3px);
}

.cat-nav-item:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(59, 102, 245, 0.4);
}

[data-theme="dark"] .cat-nav-item {
    background: linear-gradient(0deg, rgba(79,122,255,0.18), rgba(79,122,255,0.18)), var(--card-bg);
    border-color: rgba(79,122,255,0.5);
    box-shadow: 0 6px 14px rgba(0,0,0,0.35), 0 0 0 4px rgba(79,122,255,0.18) inset;
}

@keyframes catNavSheen {
    0% { left: -100%; }
    60% { left: 130%; }
    100% { left: 130%; }
}
/* Home Promos */
.home-promos .home-promos-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}
.ads-cta-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, #3b66f5 0%, #1e3bb3 100%);
    border: none;
    border-radius: 18px;
    padding: 20px 22px;
    color: #fff;
    box-shadow: 0 10px 30px rgba(59,102,245,0.25);
    width: 100%;
    max-width: 900px;
}
.ads-cta-text h3 {
    margin: 0 0 6px 0;
    font-size: 1.15rem;
    display: inline-block;
    background: #ffc107;
    color: #111;
    font-weight: 900;
    padding: 6px 12px;
    border-radius: 12px;
    letter-spacing: .5px;
    text-transform: uppercase;
    box-shadow: 0 6px 14px rgba(0,0,0,0.12);
    transform: rotate(-1deg);
}
.ads-cta-text p {
    margin: 6px 0 0 0;
    color: rgba(255,255,255,0.9);
    font-size: 0.95rem;
}
.partner-banner {
    display: block;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    width: 100%;
    max-width: 900px;
}
.partner-banner img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* CTA button on dark blue background */
.ads-cta-card .action-btn.btn-blue {
    background: #ffffff;
    color: #1e3bb3;
    border: none;
}
.ads-cta-card .action-btn.btn-blue:hover {
    background: #f2f5ff;
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .home-promos .home-promos-wrap {
        grid-template-columns: 1fr;
    }
    .ads-cta-card {
        flex-direction: column;
        align-items: flex-start;
    }
}
/* Product Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 50px;
}

/* Category limiting and View All button */
.products-grid.limit-rows .product-card:nth-child(n+13) {
    display: none;
}

.view-all-btn {
    display: inline-block;
    padding: 10px 25px;
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
    cursor: pointer;
}

.view-all-btn:hover {
    background: var(--border-color);
    transform: translateY(-2px);
}

.category-footer {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
}

.transition-transform {
    transition: transform 0.3s ease;
}

.category-header:hover h2 {
    color: var(--primary-color);
}

.collapse-toggle-btn:hover {
    color: var(--primary-color) !important;
}

@media (max-width: 768px) {
    .products-grid.limit-rows .product-card:nth-child(n+7) {
        display: none;
    }
}

/* Responsive Adaptation */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .container {
        max-width: 960px;
    }
}

@media (max-width: 992px) {
    .header-top {
        flex-wrap: wrap;
        gap: 15px;
    }
    .search-bar {
        order: 3;
        max-width: 100%;
    }
    .banner {
        padding: 40px;
        min-height: auto;
    }
    .banner h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    .header-actions {
        gap: 8px;
    }
    .action-btn {
        padding: 10px 15px;
        font-size: 0.85rem;
        gap: 8px;
    }
    .banner h1 {
        font-size: 2rem;
    }
    .banner p {
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .products-grid {
        grid-template-columns: 1fr;
    }
    .header-top {
        justify-content: center;
    }
    .header-logo {
        margin-bottom: 10px;
    }
    .header-actions {
        width: 100%;
        justify-content: center;
    }
    .action-btn {
        flex: 1;
        justify-content: center;
    }
    .banner {
        padding: 30px 20px;
    }
    .banner-stats {
        flex-direction: column;
    }
    .stat-item {
        width: 100%;
        text-align: center;
    }
    .categories-nav {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 10px;
        -webkit-overflow-scrolling: touch;
    }
    .cat-nav-item {
        flex-shrink: 0;
    }
}

.product-card {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 0;
    border: 1px solid var(--border-color);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    width: 100%;
    cursor: pointer;
    text-decoration: none;
    overflow: hidden;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
    border-color: var(--primary-color);
}

.product-card-header {
    display: flex;
    justify-content: center;
    align-items: center;
    background: #f8f9fb;
    height: 180px;
    padding: 0;
    overflow: hidden;
    position: relative;
}

[data-theme="dark"] .product-card-header {
    background: #262a33;
}

.product-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-card-img {
    transform: scale(1.1);
}

.product-card-title {
    font-size: 0.95rem;
    font-weight: 600;
    text-align: center;
    color: var(--text-color);
    margin: 15px 15px 5px 15px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
    min-height: 2.8em;
}

.product-card-price {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: var(--primary-color);
    color: white;
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 800;
    z-index: 2;
    box-shadow: 0 4px 12px rgba(59, 102, 245, 0.3);
}

.product-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.stock-info {
    color: var(--text-muted);
}

.price-tag {
    color: var(--text-color);
}

.buy-btn-full {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s;
    width: 100%;
}

.buy-btn-full:hover {
    background: #2b55e0;
}

.cart-icon-svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* Modal Styling Update */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal-content {
    background: var(--card-bg);
    padding: 40px;
    border-radius: 28px;
    width: 95%;
    max-width: 1100px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 35px 70px -15px rgba(0, 0, 0, 0.3);
    animation: modalSlide 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    color: var(--text-color);
}

.modal-product-info {
    display: flex;
    gap: 40px;
    margin-bottom: 30px;
    align-items: flex-start;
}

.modal-product-img {
    width: 300px;
    height: 300px;
    object-fit: contain;
    border-radius: 20px;
    background: var(--bg-color);
    padding: 25px;
    flex-shrink: 0;
    border: 1px solid var(--border-color);
}

.modal-product-details {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.modal-header h2 {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-color);
    line-height: 1.2;
    padding-right: 40px;
    margin: 0;
}

.modal-description {
    font-size: 1.05rem;
    color: var(--text-color);
    line-height: 1.8;
    margin-bottom: 25px;
    white-space: pre-line;
    max-height: 500px;
    overflow-y: auto;
    padding-right: 15px;
    padding: 20px;
    background: var(--bg-color);
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

/* Custom Scrollbar for description */
.modal-description::-webkit-scrollbar {
    width: 6px;
}
.modal-description::-webkit-scrollbar-track {
    background: var(--bg-color);
    border-radius: 10px;
}
.modal-description::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 10px;
}
.modal-description::-webkit-scrollbar-thumb:hover {
    background: #bbb;
}

.modal-external-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    background: var(--primary-color);
    color: white;
    padding: 18px;
    border-radius: 16px;
    font-size: 1.2rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 12px 25px rgba(59, 102, 245, 0.25);
}

.modal-external-btn:hover {
    background: #2b55e0;
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(59, 102, 245, 0.35);
}

@media (max-width: 768px) {
    .modal-content {
        padding: 30px 20px;
    }
    .modal-product-info {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 25px;
    }
    .modal-product-img {
        width: 220px;
        height: 220px;
    }
    .modal-header h2 {
        font-size: 1.5rem;
        text-align: center;
        padding-right: 0;
    }
    .modal-header {
        justify-content: center;
        position: relative;
    }
    .close-modal {
        position: absolute;
        right: 0;
        top: -10px;
    }
}

.theme-toggle {
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    padding: 10px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.theme-toggle:hover {
    background: var(--border-color);
}

.theme-toggle svg {
    width: 20px;
    height: 20px;
}

[data-theme="dark"] .theme-toggle .sun-icon { display: block; }
[data-theme="dark"] .theme-toggle .moon-icon { display: none; }
.theme-toggle .sun-icon { display: none; }
.theme-toggle .moon-icon { display: block; }

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.modal-header h2 {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-color);
    line-height: 1.2;
    padding-right: 20px;
    margin: 0;
}

.close-modal {
    font-size: 28px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    line-height: 1;
}

.close-modal:hover { color: #333; }

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.form-group input, .form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}

.form-group input:focus, .form-group select:focus {
    border-color: var(--primary-color);
}

.modal-footer {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.total-price-block {
    font-size: 1.2rem;
    font-weight: 800;
    text-align: center;
    padding: 15px;
    background: #f8f9fb;
    border-radius: 12px;
}

.checkout-btn {
    width: 100%;
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

.checkout-btn:hover {
    background: #2b55e0;
    transform: translateY(-2px);
}

/* Scroll to Top Button */
.scroll-top-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), #5c85ff);
    color: white;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 8px 25px rgba(59, 102, 245, 0.4);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform: translateY(20px) scale(0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.scroll-top-btn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.scroll-top-btn:hover {
    transform: translateY(-8px) scale(1.05);
    box-shadow: 0 15px 35px rgba(59, 102, 245, 0.5);
    background: linear-gradient(135deg, #2b55e0, var(--primary-color));
}

.scroll-top-btn i {
    transition: transform 0.3s ease;
}

.scroll-top-btn:hover i {
    transform: translateY(-2px);
}

@media (max-width: 992px) {
    .header-top {
        flex-direction: column;
        gap: 15px;
        align-items: center;
    }
    .header-logo {
        flex-direction: row;
        justify-content: center;
        width: 100%;
    }
    .header-logo-icon {
        width: 40px;
        height: 40px;
    }
    .search-bar {
        order: 3;
        width: 100%;
        max-width: none;
    }
    .header-actions {
        width: 100%;
        justify-content: center;
        gap: 8px;
        flex-wrap: wrap;
    }
    .action-btn {
        padding: 10px 15px;
        font-size: 0.85rem;
        flex: 0 1 auto;
        white-space: nowrap;
    }
}

@media (max-width: 768px) {
    .scroll-top-btn {
        bottom: 25px;
        right: 25px;
        width: 48px;
        height: 48px;
    }
    .banner h1 { font-size: 2rem; }
    .blog-page h1 { font-size: 2.2rem !important; }
    .blog-grid { grid-template-columns: 1fr !important; }
    .reviews-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 20px;
    }
    .reviews-nav {
        display: none; /* Скрываем стрелки на мобильных, так как есть свайп */
    }
    .review-card {
        flex: 0 0 280px;
        padding: 20px;
    }
}

@media (max-width: 576px) {
    .header-actions {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 6px;
    }
    .action-btn {
        padding: 8px 12px;
        font-size: 0.8rem;
        flex: 0 1 auto;
    }
    .action-btn span {
        display: inline; /* Возвращаем текст, но кнопки будут переноситься */
    }
    .theme-toggle {
        padding: 8px;
    }
    .review-card {
        flex: 0 0 85vw;
    }
    .section-title {
        font-size: 1.5rem;
    }
}
.reviews-section {
    padding: 60px 0;
    background: var(--bg-color);
}

.reviews-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
}

.reviews-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.reviews-slider {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 20px;
    padding: 10px 5px 30px 5px;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none;  /* IE and Edge */
    scroll-behavior: smooth;
    cursor: grab;
    user-select: none;
    -webkit-overflow-scrolling: touch;
}

.reviews-slider:active {
    cursor: grabbing;
}

.reviews-slider::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.review-card {
    flex: 0 0 350px;
    scroll-snap-align: start;
    background: var(--card-bg);
    border-radius: 20px;
    padding: 25px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
}

/* Reviews Navigation Arrows */
.reviews-nav {
    display: flex;
    gap: 10px;
}

.nav-arrow {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.nav-arrow:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.nav-arrow:active {
    transform: translateY(0);
}

.nav-arrow i {
    font-size: 0.9rem;
}

.review-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.review-author {
    font-weight: 700;
    color: var(--text-color);
}

.review-rating {
    color: #ffc107;
}

.review-text {
    color: var(--text-color);
    opacity: 0.8;
    line-height: 1.6;
    font-size: 0.95rem;
}

.review-date {
    display: block;
    margin-top: 15px;
    font-size: 0.8rem;
    opacity: 0.5;
}

/* Review Form */
.review-form-container {
    max-width: 600px;
    margin: 40px auto 0;
    background: var(--card-bg);
    border-radius: 20px;
    padding: 30px;
    border: 1px solid var(--border-color);
}

.review-form h3 {
    text-align: center;
    margin-bottom: 25px;
}

.review-form .form-group {
    margin-bottom: 20px;
}

.review-form input, 
.review-form textarea {
    width: 100%;
    padding: 12px 15px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    color: var(--text-color);
    outline: none;
}

.review-form textarea {
    height: 120px;
    resize: none;
}

.rating-input {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 20px;
}

.rating-input i {
    cursor: pointer;
    font-size: 2rem;
    color: #ddd;
    transition: all 0.2s;
}

.rating-input i.active {
    color: #ffc107;
}

.rating-input i.hover {
    color: #ffae00; /* Более насыщенный оранжевый при наведении */
    transform: scale(1.2);
}

.submit-review-btn {
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    border: none;
    background: var(--primary-color);
    color: white;
    font-weight: 700;
    cursor: pointer;
    transition: 0.3s;
}

.submit-review-btn:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.theme-btn {
    padding: 12px 24px;
    border-radius: 14px;
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    transition: all 0.2s;
    border: none;
    cursor: pointer;
    background: var(--primary-color);
    color: white;
}

.theme-btn:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}
