/* ===== SHOP.CSS — White & Sky Blue Premium ===== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --blue: #0ea5e9;
    --blue-light: #38bdf8;
    --blue-pale: #e0f2fe;
    --blue-bg: #f0f9ff;
    --blue-dark: #0284c7;
    --blue-deep: #0369a1;
    --blue-glow: rgba(14, 165, 233, .2);

    --white: #ffffff;
    --bg: #f8fbff;
    --border: #e2edf5;
    --border-light: #f0f6fc;

    --text: #1e293b;
    --text-2: #475569;
    --text-3: #94a3b8;

    --success: #10b981;
    --danger: #ef4444;

    --r: 14px;
    --r-sm: 10px;
    --r-xs: 6px;
    --shadow: 0 1px 4px rgba(14, 165, 233, .06), 0 4px 16px rgba(14, 165, 233, .06);
    --shadow-lg: 0 8px 32px rgba(14, 165, 233, .1);
    --shadow-xl: 0 16px 48px rgba(14, 165, 233, .12);
    --t: .22s cubic-bezier(.4, 0, .2, 1);
    --max-w: 1320px;
    --font: 'Inter', system-ui, -apple-system, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: 1.65;
    font-size: 15px;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a {
    color: var(--blue);
    text-decoration: none;
    transition: color var(--t);
}

a:hover {
    color: var(--blue-dark);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul,
ol {
    list-style: none;
}

input,
button,
textarea,
select {
    font-family: inherit;
    font-size: inherit;
}

.container {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 24px;
}

[x-cloak] {
    display: none !important;
}

/* Animations */
@keyframes up {
    from {
        opacity: 0;
        transform: translateY(20px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

@keyframes fadeIn {
    from {
        opacity: 0
    }

    to {
        opacity: 1
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-8px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

@keyframes pop {
    0% {
        transform: scale(.95);
        opacity: 0
    }

    100% {
        transform: scale(1);
        opacity: 1
    }
}

@keyframes glow {

    0%,
    100% {
        box-shadow: 0 0 0 0 var(--blue-glow)
    }

    50% {
        box-shadow: 0 0 16px 4px var(--blue-glow)
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% 0
    }

    100% {
        background-position: 200% 0
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0)
    }

    50% {
        transform: translateY(-12px)
    }
}

@keyframes wave {
    0% {
        transform: rotate(0deg)
    }

    15% {
        transform: rotate(14deg)
    }

    30% {
        transform: rotate(-8deg)
    }

    40% {
        transform: rotate(0deg)
    }

    100% {
        transform: rotate(0deg)
    }
}

/* === HEADER === */
.site-header {
    background: var(--white);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 1px 8px rgba(14, 165, 233, .04);
}

.header-top {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 7px 0;
    border-bottom: 1px solid var(--border-light);
    font-size: 12px;
    color: var(--text-3);
}

.header-top a {
    color: var(--text-2);
    font-weight: 500;
}

.header-top a:hover {
    color: var(--blue);
}

.header-top .spacer {
    flex: 1;
}

.header-main {
    display: flex;
    align-items: center;
    gap: 28px;
    padding: 14px 0;
}

.header-logo {
    font-size: 22px;
    font-weight: 800;
    color: var(--text);
    white-space: nowrap;
    letter-spacing: -.5px;
}

.header-logo span {
    color: var(--blue);
}

.header-logo:hover {
    color: var(--text);
}

.header-search {
    flex: 1;
    position: relative;
    max-width: 540px;
}

.header-search input {
    width: 100%;
    padding: 11px 48px 11px 18px;
    border: 2px solid var(--border);
    border-radius: 12px;
    outline: none;
    background: var(--white);
    color: var(--text);
    transition: all var(--t);
}

.header-search input::placeholder {
    color: var(--text-3);
}

.header-search input:focus {
    border-color: var(--blue);
    box-shadow: 0 0 0 3px var(--blue-glow);
}

.header-search button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--blue);
    border: none;
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--t);
}

.header-search button:hover {
    background: var(--blue-dark);
    transform: translateY(-50%) scale(1.05);
}

.header-search svg {
    width: 18px;
    height: 18px;
}

.header-phone {
    font-size: 16px;
    font-weight: 700;
    color: var(--text);
    white-space: nowrap;
}

.header-phone:hover {
    color: var(--blue);
}

.header-phone small {
    display: block;
    font-size: 11px;
    font-weight: 400;
    color: var(--text-3);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

.header-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    color: var(--text-2);
    font-size: 11px;
    font-weight: 500;
    position: relative;
    padding: 8px 14px;
    border-radius: 12px;
    transition: all var(--t);
}

.header-btn:hover {
    color: var(--blue);
    background: var(--blue-pale);
}

.header-btn svg {
    width: 22px;
    height: 22px;
}

.header-btn .badge {
    position: absolute;
    top: 2px;
    right: 6px;
    background: var(--blue);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pop .3s ease both;
}

/* Nav */
.site-nav {
    background: var(--white);
    border-top: 1px solid var(--border-light);
}

.site-nav ul {
    display: flex;
    gap: 0;
}

.site-nav a {
    display: block;
    padding: 11px 20px;
    color: var(--text-2);
    font-size: 14px;
    font-weight: 600;
    transition: all var(--t);
    position: relative;
}

.site-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--blue);
    transition: all var(--t);
    transform: translateX(-50%);
    border-radius: 2px;
}

.site-nav a:hover,
.site-nav a.active {
    color: var(--blue);
}

.site-nav a:hover::after,
.site-nav a.active::after {
    width: calc(100% - 40px);
}

/* === BREADCRUMBS === */
.breadcrumbs {
    padding: 16px 0;
    font-size: 13px;
    color: var(--text-3);
}

.breadcrumbs a {
    color: var(--text-2);
    font-weight: 500;
}

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

.breadcrumbs span {
    margin: 0 8px;
    opacity: .4;
}

/* === HERO === */
.hero {
    background: linear-gradient(135deg, var(--blue-bg) 0%, var(--white) 50%, var(--blue-pale) 100%);
    padding: 72px 0 80px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -15%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(56, 189, 248, .12) 0%, transparent 70%);
    animation: float 8s ease-in-out infinite;
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(14, 165, 233, .08) 0%, transparent 70%);
    animation: float 10s ease-in-out infinite 3s;
    pointer-events: none;
}

.hero__inner {
    max-width: 640px;
    position: relative;
    z-index: 1;
    animation: up .7s ease both;
}

.hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--white);
    border: 1px solid var(--border);
    padding: 6px 16px;
    border-radius: 99px;
    font-size: 13px;
    font-weight: 600;
    color: var(--blue);
    margin-bottom: 20px;
    box-shadow: var(--shadow);
}

.hero__title {
    font-size: 48px;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
    color: var(--text);
    letter-spacing: -.5px;
}

.hero__title em {
    font-style: normal;
    color: var(--blue);
}

.hero__text {
    font-size: 17px;
    color: var(--text-2);
    margin-bottom: 32px;
    line-height: 1.75;
}

.hero__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.hero__stats {
    display: flex;
    gap: 36px;
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--border);
}

.hero__stat-value {
    font-size: 28px;
    font-weight: 800;
    color: var(--blue);
}

.hero__stat-label {
    font-size: 13px;
    color: var(--text-3);
    margin-top: 2px;
}

/* === CARDS === */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 24px;
}

.product-card {
    background: var(--white);
    border-radius: var(--r);
    overflow: hidden;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow);
    transition: all .3s ease;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: var(--blue-pale);
}

.product-card__img {
    aspect-ratio: 1;
    overflow: hidden;
    background: linear-gradient(135deg, #fafcff, var(--blue-bg));
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.product-card__img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 20px;
    transition: transform .4s ease;
}

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

.product-card__badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--danger);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(239, 68, 68, .3);
}

.product-card__body {
    padding: 16px 18px 18px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-card__brand {
    font-size: 11px;
    color: var(--blue);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    font-weight: 700;
}

.product-card__name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    line-height: 1.45;
    margin-bottom: 8px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color var(--t);
}

.product-card__name:hover {
    color: var(--blue);
}

.product-card__sku {
    font-size: 12px;
    color: var(--text-3);
    margin-bottom: 10px;
}

.product-card__price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 14px;
}

.product-card__price-current {
    font-size: 22px;
    font-weight: 800;
    color: var(--text);
}

.product-card__price-old {
    font-size: 14px;
    color: var(--text-3);
    text-decoration: line-through;
}

.product-card__actions {
    margin-top: auto;
}

/* === BUTTONS === */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 24px;
    border: none;
    border-radius: var(--r-sm);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all var(--t);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--blue);
    color: #fff;
    box-shadow: 0 2px 12px var(--blue-glow);
}

.btn-primary:hover {
    background: var(--blue-dark);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--blue-glow);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-outline {
    background: transparent;
    color: var(--blue);
    border: 2px solid var(--blue);
}

.btn-outline:hover {
    background: var(--blue);
    color: #fff;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 8px;
}

.btn-full {
    width: 100%;
}

.btn-white {
    background: var(--white);
    color: var(--blue);
    border: 2px solid var(--border);
    box-shadow: var(--shadow);
}

.btn-white:hover {
    border-color: var(--blue);
    color: var(--blue-dark);
}

.btn svg {
    width: 18px;
    height: 18px;
}

.btn-cart.added {
    animation: glow .5s ease;
}

/* === SECTIONS === */
.section {
    padding: 56px 0;
}

.section__title {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    letter-spacing: -.3px;
}

.section__title span {
    position: relative;
}

.section__title span::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 40px;
    height: 3px;
    border-radius: 2px;
    background: var(--blue);
}

.section__title a {
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}

.section__title a:hover {
    gap: 8px;
}

/* === CATEGORIES === */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

.category-card {
    background: var(--white);
    border-radius: var(--r);
    padding: 28px 20px;
    text-align: center;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow);
    transition: all .3s ease;
    animation: up .5s ease both;
    position: relative;
    overflow: hidden;
}

.category-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(14, 165, 233, .03), transparent);
    opacity: 0;
    transition: opacity var(--t);
}

.category-card:hover::after {
    opacity: 1;
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--blue-pale);
}

.category-card__icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 14px;
    background: var(--blue-pale);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--blue);
    transition: all .3s ease;
}

.category-card:hover .category-card__icon {
    background: var(--blue);
    color: #fff;
    transform: scale(1.08) rotate(3deg);
}

.category-card__icon svg {
    width: 26px;
    height: 26px;
}

.category-card__name {
    font-weight: 700;
    font-size: 15px;
    color: var(--text);
    margin-bottom: 4px;
    position: relative;
    z-index: 1;
}

.category-card__count {
    font-size: 13px;
    color: var(--text-3);
    position: relative;
    z-index: 1;
}

/* USP Grid */
.usp-card {
    background: var(--white);
    border-radius: var(--r);
    padding: 22px;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow);
    display: flex;
    align-items: flex-start;
    gap: 16px;
    transition: all .3s ease;
    animation: up .5s ease both;
}

.usp-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    border-color: var(--blue-pale);
}

.usp-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: var(--blue-pale);
    color: var(--blue);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 22px;
    transition: all .3s ease;
}

.usp-card:hover .usp-icon {
    background: var(--blue);
    color: #fff;
}

.usp-title {
    font-weight: 700;
    font-size: 15px;
    margin-bottom: 2px;
}

.usp-desc {
    font-size: 13px;
    color: var(--text-2);
}

/* === CATALOG === */
.catalog-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 28px;
}

.catalog-sidebar {
    background: var(--white);
    border-radius: var(--r);
    padding: 24px;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow);
    align-self: start;
    position: sticky;
    top: 130px;
}

.filter-group {
    margin-bottom: 22px;
}

.filter-group__title {
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
    text-transform: uppercase;
    letter-spacing: .5px;
    color: var(--text);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.filter-group__title:hover {
    color: var(--blue);
}

.filter-group label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    padding: 5px 0;
    cursor: pointer;
    color: var(--text-2);
    transition: color var(--t);
}

.filter-group label:hover {
    color: var(--blue);
}

.filter-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--blue);
}

.catalog-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    gap: 12px;
    flex-wrap: wrap;
}

.catalog-toolbar__count {
    font-size: 14px;
    color: var(--text-2);
}

.catalog-toolbar select {
    padding: 9px 14px;
    border: 2px solid var(--border);
    border-radius: var(--r-sm);
    background: var(--white);
    font-size: 14px;
    cursor: pointer;
    outline: none;
    transition: border-color var(--t);
}

.catalog-toolbar select:focus {
    border-color: var(--blue);
}

/* === PRODUCT PAGE === */
.product-page {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    padding: 36px 0;
    animation: fadeIn .5s ease both;
}

.product-gallery__main {
    aspect-ratio: 1;
    background: var(--white);
    border-radius: var(--r);
    overflow: hidden;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
    border: 1px solid var(--border-light);
    transition: box-shadow var(--t);
}

.product-gallery__main:hover {
    box-shadow: var(--shadow-lg);
}

.product-gallery__main img {
    max-height: 100%;
    object-fit: contain;
    padding: 24px;
    transition: transform .4s ease;
}

.product-gallery__main:hover img {
    transform: scale(1.04);
}

.product-gallery__thumbs {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.product-gallery__thumb {
    width: 72px;
    height: 72px;
    border-radius: 12px;
    border: 2px solid var(--border);
    overflow: hidden;
    cursor: pointer;
    transition: all var(--t);
}

.product-gallery__thumb.active {
    border-color: var(--blue);
    box-shadow: 0 0 0 3px var(--blue-glow);
}

.product-gallery__thumb:hover {
    border-color: var(--blue-light);
}

.product-gallery__thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-info__brand {
    font-size: 12px;
    color: var(--blue);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
    font-weight: 700;
}

.product-info__brand a {
    color: var(--blue);
}

.product-info__name {
    font-size: 30px;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 10px;
    letter-spacing: -.3px;
}

.product-info__sku {
    font-size: 13px;
    color: var(--text-3);
    margin-bottom: 20px;
}

.product-info__price {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin-bottom: 24px;
    padding: 20px;
    border-radius: var(--r-sm);
    background: var(--blue-bg);
    border: 1px solid var(--blue-pale);
}

.product-info__price-current {
    font-size: 36px;
    font-weight: 800;
    color: var(--text);
}

.product-info__price-old {
    font-size: 18px;
    color: var(--text-3);
    text-decoration: line-through;
}

.product-info__price-badge {
    background: var(--danger);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 8px;
}

.product-info__stock {
    font-size: 14px;
    margin-bottom: 20px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 8px;
    font-weight: 600;
}

.product-info__stock.in-stock {
    color: var(--success);
    background: rgba(16, 185, 129, .08);
}

.product-info__stock.out-of-stock {
    color: var(--danger);
    background: rgba(239, 68, 68, .08);
}

.product-info__short {
    font-size: 15px;
    color: var(--text-2);
    line-height: 1.8;
    margin-bottom: 24px;
}

.product-info__cart {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 28px;
}

.quantity-input {
    display: flex;
    align-items: center;
    border: 2px solid var(--border);
    border-radius: var(--r-sm);
    overflow: hidden;
    transition: border-color var(--t);
}

.quantity-input:focus-within {
    border-color: var(--blue);
}

.quantity-input button {
    width: 42px;
    height: 42px;
    border: none;
    background: none;
    font-size: 18px;
    cursor: pointer;
    color: var(--text);
    transition: all var(--t);
}

.quantity-input button:hover {
    background: var(--blue-pale);
    color: var(--blue);
}

.quantity-input input {
    width: 54px;
    text-align: center;
    border: none;
    outline: none;
    border-left: 1px solid var(--border);
    border-right: 1px solid var(--border);
    height: 42px;
    font-weight: 700;
    font-size: 16px;
}

/* Product Tabs */
.product-tabs {
    margin-top: 48px;
    grid-column: 1/-1;
    animation: up .6s ease both .2s;
}

.product-tabs__nav {
    display: flex;
    border-bottom: 2px solid var(--border);
    margin-bottom: 0;
}

.product-tabs__btn {
    padding: 14px 28px;
    border: none;
    background: none;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-2);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all var(--t);
}

.product-tabs__btn.active,
.product-tabs__btn:hover {
    color: var(--blue);
    border-bottom-color: var(--blue);
}

.product-tabs__content {
    background: var(--white);
    border-radius: 0 0 var(--r) var(--r);
    padding: 28px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
    border-top: none;
}

.features-table {
    width: 100%;
    border-collapse: collapse;
}

.features-table tr {
    transition: background var(--t);
}

.features-table tr:nth-child(even) {
    background: var(--blue-bg);
}

.features-table tr:hover {
    background: var(--blue-pale);
}

.features-table td {
    padding: 12px 18px;
    font-size: 14px;
    border-bottom: 1px solid var(--border-light);
}

.features-table td:first-child {
    color: var(--text-2);
    width: 40%;
    font-weight: 500;
}

.features-table td:last-child {
    font-weight: 600;
}

/* === CART === */
.cart-table {
    width: 100%;
    border-collapse: collapse;
}

.cart-table th {
    text-align: left;
    padding: 14px 18px;
    font-size: 12px;
    color: var(--text-3);
    border-bottom: 2px solid var(--border);
    text-transform: uppercase;
    letter-spacing: .8px;
    font-weight: 700;
}

.cart-table td {
    padding: 18px;
    border-bottom: 1px solid var(--border-light);
    vertical-align: middle;
}

.cart-table tr {
    transition: background var(--t);
}

.cart-table tr:hover {
    background: var(--blue-bg);
}

.cart-item__img {
    width: 80px;
    height: 80px;
    border-radius: 12px;
    object-fit: contain;
    background: var(--blue-bg);
}

.cart-item__name {
    font-weight: 600;
    font-size: 14px;
}

.cart-item__name a {
    color: var(--text);
}

.cart-item__name a:hover {
    color: var(--blue);
}

.cart-item__sku {
    font-size: 12px;
    color: var(--text-3);
}

.cart-item__remove {
    background: none;
    border: none;
    color: var(--text-3);
    cursor: pointer;
    font-size: 18px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all var(--t);
}

.cart-item__remove:hover {
    background: rgba(239, 68, 68, .08);
    color: var(--danger);
}

.cart-summary {
    background: var(--white);
    border-radius: var(--r);
    padding: 28px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
}

.cart-summary__row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    font-size: 14px;
}

.cart-summary__row.total {
    font-size: 22px;
    font-weight: 800;
    border-top: 2px solid var(--border);
    padding-top: 18px;
    margin-top: 10px;
    color: var(--text);
}

/* === CHECKOUT === */
.checkout-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 32px;
}

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

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--text);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--r-sm);
    outline: none;
    transition: all var(--t);
    background: var(--white);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--blue);
    box-shadow: 0 0 0 3px var(--blue-glow);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* === FOOTER === */
.site-footer {
    background: var(--white);
    color: var(--text-2);
    padding: 56px 0 0;
    margin-top: 60px;
    border-top: 1px solid var(--border);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 36px;
}

.footer-col__title {
    color: var(--text);
    font-weight: 700;
    font-size: 15px;
    margin-bottom: 18px;
}

.footer-col a {
    display: block;
    color: var(--text-2);
    font-size: 14px;
    padding: 4px 0;
    transition: all var(--t);
}

.footer-col a:hover {
    color: var(--blue);
    padding-left: 4px;
}

.footer-col p {
    font-size: 14px;
    line-height: 1.8;
    color: var(--text-3);
}

.footer-bottom {
    border-top: 1px solid var(--border);
    padding: 20px 0;
    margin-top: 36px;
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-3);
}

/* === PAGINATION === */
.pagination {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 36px;
    padding: 20px 0;
}

/* Hide Laravel's default "Previous/Next" text links and "Showing X of Y" */
.pagination>nav>div:first-child {
    display: none;
}

.pagination>nav>div>span.relative {
    display: none;
}

.pagination p.text-sm {
    display: none;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 14px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all .25s cubic-bezier(.4, 0, .2, 1);
}

.pagination a {
    background: var(--white);
    color: var(--text);
    border: 1px solid var(--border-light);
    box-shadow: 0 1px 3px rgba(0, 0, 0, .06);
    cursor: pointer;
}

.pagination a:hover {
    background: linear-gradient(135deg, var(--blue) 0%, var(--blue-deep, #0369a1) 100%);
    color: #fff;
    border-color: transparent;
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 6px 20px var(--blue-glow, rgba(14, 165, 233, .3));
}

.pagination .active span,
.pagination span[aria-current="page"] {
    background: linear-gradient(135deg, var(--blue) 0%, var(--blue-deep, #0369a1) 100%);
    color: #fff;
    border: none;
    box-shadow: 0 4px 14px var(--blue-glow, rgba(14, 165, 233, .25));
    font-weight: 700;
}

.pagination .disabled span,
.pagination span[aria-disabled="true"] {
    color: var(--text-3, #cbd5e1);
    cursor: default;
    opacity: .5;
}

/* Style the SVG arrows in pagination */
.pagination svg {
    width: 18px;
    height: 18px;
}

/* Alerts */
.alert {
    padding: 16px 20px;
    border-radius: var(--r-sm);
    margin-bottom: 20px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 500;
    animation: slideDown .4s ease both;
    border: 1px solid transparent;
}

.alert-success {
    background: rgba(16, 185, 129, .08);
    color: #065f46;
    border-color: rgba(16, 185, 129, .2);
}

.alert-error {
    background: rgba(239, 68, 68, .08);
    color: #991b1b;
    border-color: rgba(239, 68, 68, .2);
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    animation: up .5s ease both;
}

.empty-state svg {
    width: 72px;
    height: 72px;
    color: var(--blue-light);
    margin: 0 auto 20px;
    opacity: .5;
}

.empty-state__title {
    font-size: 22px;
    font-weight: 800;
    margin-bottom: 8px;
}

.empty-state__text {
    color: var(--text-2);
    margin-bottom: 24px;
}

/* Prose */
.prose {
    line-height: 1.8;
}

.prose p {
    margin-bottom: 12px;
}

.prose ul,
.prose ol {
    padding-left: 24px;
    margin-bottom: 12px;
}

.prose ul {
    list-style: disc;
}

.prose ol {
    list-style: decimal;
}

.prose li {
    margin-bottom: 4px;
}

.prose h2,
.prose h3 {
    margin: 20px 0 10px;
    font-weight: 700;
}

/* === RESPONSIVE === */
/* ===== TABLET (1024px) ===== */
@media (max-width: 1024px) {
    .catalog-layout {
        grid-template-columns: 240px 1fr;
    }

    .product-page {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .checkout-layout {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
    }

    .hero__title {
        font-size: 36px;
    }
}

/* ===== MOBILE (768px) ===== */
@media (max-width: 768px) {

    /* --- Header mobile --- */
    .header-top {
        display: none;
    }

    .header-main {
        flex-wrap: wrap;
        gap: 10px;
        padding: 10px 0;
    }

    .header-logo {
        font-size: 16px;
    }

    .header-search {
        order: 10;
        max-width: none;
        flex: 1 1 100%;
    }

    .header-search input {
        font-size: 16px;
        /* Prevents iOS zoom on focus */
        height: 44px;
    }

    .header-phone {
        display: none;
    }

    .header-actions .header-btn span {
        display: none;
    }

    .header-actions .header-btn {
        padding: 8px;
    }

    .header-actions .header-btn svg {
        width: 24px;
        height: 24px;
    }

    .site-nav {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .site-nav ul {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        gap: 0;
    }

    .site-nav a {
        white-space: nowrap;
        padding: 10px 14px;
        font-size: 14px;
    }

    /* --- Layout --- */
    .container {
        padding-left: 12px;
        padding-right: 12px;
    }

    .section {
        padding: 28px 0;
    }

    .section__title {
        font-size: 20px;
    }

    .catalog-layout {
        grid-template-columns: 1fr;
    }

    .catalog-sidebar {
        position: static;
    }

    /* --- Products grid --- */
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .product-card {
        border-radius: 12px;
    }

    .product-card__body {
        padding: 10px 10px 12px;
    }

    .product-card__name {
        font-size: 13px;
        -webkit-line-clamp: 2;
    }

    .product-card__brand {
        font-size: 11px;
    }

    .product-card__sku {
        font-size: 11px;
    }

    .product-card__price-current {
        font-size: 16px;
    }

    .product-card__price-old {
        font-size: 12px;
    }

    .product-card__actions .btn {
        padding: 10px 8px;
        font-size: 13px;
        min-height: 42px;
    }

    /* --- Brand strip --- */
    .brand-strip {
        gap: 8px;
        padding: 8px 0;
    }

    .brand-strip__item {
        padding: 8px 14px;
        min-width: auto;
    }

    .brand-strip__item img {
        max-height: 22px;
    }

    /* --- Product page --- */
    .product-page {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .product-gallery__main img {
        max-height: 300px;
    }

    .product-gallery__thumbs {
        gap: 6px;
    }

    .product-gallery__thumb {
        width: 50px;
        height: 50px;
    }

    .product-info__name {
        font-size: 20px;
    }

    .product-info__price-current {
        font-size: 26px;
    }

    .product-info__actions .btn {
        min-height: 48px;
        font-size: 15px;
    }

    /* --- Form --- */
    .form-row {
        grid-template-columns: 1fr;
    }

    /* --- Footer --- */
    .footer-grid {
        grid-template-columns: 1fr;
    }

    /* --- Hero --- */
    .hero {
        padding: 32px 0 36px;
    }

    .hero__title {
        font-size: 26px;
    }

    .hero__text {
        font-size: 15px;
    }

    .hero__stats {
        gap: 16px;
        flex-wrap: wrap;
    }

    .hero__stat-value {
        font-size: 20px;
    }

    /* --- Catalog toolbar --- */
    .catalog-toolbar {
        flex-direction: column;
        gap: 8px;
        align-items: stretch;
    }

    .catalog-toolbar select {
        width: 100%;
        min-height: 42px;
    }

    /* --- Mobile bottom bar --- */
    .mobile-bottom-bar {
        display: flex !important;
    }

    body {
        padding-bottom: 64px;
    }
}

/* ===== SMALL PHONES (480px) ===== */
@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .product-card__body {
        padding: 8px 8px 10px;
    }

    .product-card__name {
        font-size: 12px;
    }

    .product-card__price-current {
        font-size: 15px;
    }

    .product-card__actions .btn {
        font-size: 12px;
        padding: 8px 6px;
    }

    .hero__title {
        font-size: 22px;
    }
}

/* ===== MOBILE BOTTOM BAR ===== */
.mobile-bottom-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: #fff;
    border-top: 1px solid #e2e8f0;
    box-shadow: 0 -2px 16px rgba(0, 0, 0, .08);
    padding: 6px 8px;
    justify-content: space-around;
    align-items: center;
    gap: 4px;
}

.mobile-bottom-bar a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    text-decoration: none;
    color: #64748b;
    font-size: 10px;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 8px;
    transition: color .2s;
    flex: 1;
}

.mobile-bottom-bar a.active,
.mobile-bottom-bar a:hover {
    color: #0ea5e9;
}

.mobile-bottom-bar svg {
    width: 22px;
    height: 22px;
}

/* === EPIC CINEMATIC PRELOADER === */
.epic-preloader {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background: #020617;
    /* Deep night sky */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    perspective: 1000px;
    transition: opacity 1.5s ease-in-out, visibility 1.5s ease-in-out;
    will-change: opacity;
}

.epic-preloader.fade-out {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Stars Canvas */
#starsCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    opacity: 0;
    animation: fadeInStars 3s ease-in-out forwards;
}

@keyframes fadeInStars {
    to {
        opacity: 1;
    }
}

/* Ocean Waves DOM kept but styled invisible to keep elements without lag */
.ocean {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 35%;
    z-index: 2;
    pointer-events: none;
}

.wave,
.wave2 {
    display: none;
}

/* Glowing Horizon Optimized */
.horizon-glow {
    position: absolute;
    top: 60%;
    left: 0;
    right: 0;
    height: 150px;
    background: radial-gradient(ellipse at center, rgba(14, 165, 233, 0.4) 0%, transparent 60%);
    z-index: 1;
    transform: scaleY(0.1);
    opacity: 0;
    animation: horizonFlare 4s ease-in-out forwards 1.5s;
    pointer-events: none;
    will-change: transform, opacity;
}

@keyframes horizonFlare {
    50% {
        transform: scaleY(1);
        opacity: 1;
    }

    100% {
        transform: scaleY(0.3);
        opacity: 0.6;
    }
}

/* Cinematic Typography Optimized */
.cinematic-text-wrap {
    position: relative;
    z-index: 10;
    text-align: center;
    transform: translateZ(500px) scale(2);
    opacity: 0;
    animation: textDescend 4s cubic-bezier(.2, .8, .2, 1) forwards 2s;
    will-change: transform, opacity;
}

@keyframes textDescend {
    0% {
        transform: translateZ(500px) scale(2);
        opacity: 0;
        letter-spacing: 15px;
    }

    100% {
        transform: translateZ(0) scale(1.2);
        opacity: 1;
        letter-spacing: -1px;
    }
}

.cinematic-title {
    font-size: 72px;
    font-weight: 800;
    color: #fff;
    margin-bottom: 5px;
    text-transform: lowercase;
    background: linear-gradient(to bottom, #fff 40%, rgba(255, 255, 255, 0.4));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.1;
}

.cinematic-title .highlight {
    color: #38bdf8;
    background: linear-gradient(135deg, #0ea5e9, #38bdf8);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.cinematic-subtitle {
    font-size: 16px;
    color: #94a3b8;
    font-weight: 400;
    letter-spacing: 12px;
    text-transform: uppercase;
    opacity: 0;
    transform: translateY(15px);
    animation: subReveal 3s ease forwards 4s;
}

@keyframes subReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Lens Flare Optimized */
.lens-flare {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 65%, rgba(56, 189, 248, 0.2) 0%, transparent 40%);
    z-index: 15;
    opacity: 0;
    pointer-events: none;
    animation: flarePulse 4s ease-in-out forwards 2.5s;
    will-change: transform, opacity;
}

@keyframes flarePulse {
    50% {
        opacity: 0.8;
        transform: scale(1.2);
    }

    100% {
        opacity: 0.2;
        transform: scale(1);
    }
}

body.loading {
    overflow: hidden;
}

/* Page reveal only for homepage after preloader */
body.loading.page-loaded main,
body.loading.page-loaded header,
body.loading.page-loaded footer {
    animation: pageReveal .5s ease both;
}

@keyframes pageReveal {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

/* === Brand tiles === */
.brands-row {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding: 4px 0 12px;
    scrollbar-width: thin;
}

.brand-tile {
    flex: 0 0 220px;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #fff;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 16px;
    padding: 24px 20px 20px;
    text-decoration: none;
    color: var(--text, #333);
    transition: all .25s ease;
    text-align: center;
}

.brand-tile:hover {
    border-color: var(--blue, #0ea5e9);
    box-shadow: 0 8px 28px rgba(14, 165, 233, .14);
    transform: translateY(-4px);
}

.brand-tile--active {
    border-color: var(--blue, #0ea5e9);
    box-shadow: 0 4px 16px rgba(14, 165, 233, .1);
    background: #f0f9ff;
}

.brand-tile__logo {
    width: 180px;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.brand-tile__logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.brand-tile__letter {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--blue, #0ea5e9), var(--blue-deep, #0369a1));
    color: #fff;
    font-size: 28px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-tile__name {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 3px;
}

.brand-tile__count {
    font-size: 13px;
    color: var(--text-muted, #94a3b8);
}

@media (max-width: 768px) {
    .brand-tile {
        flex: 0 0 170px;
        padding: 16px 12px 14px;
    }

    .brand-tile__logo {
        width: 140px;
        height: 70px;
    }
}

/* === Brand logo strip === */
.brand-strip {
    display: flex;
    align-items: center;
    gap: 0;
    border-bottom: 1px solid var(--border, #e5e7eb);
    padding: 10px 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.brand-strip::-webkit-scrollbar {
    display: none;
}

.brand-strip__item {
    flex: 1 1 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    text-decoration: none;
    opacity: .65;
    transition: all .2s ease;
    border-bottom: 3px solid transparent;
    margin-bottom: -1px;
    min-height: 52px;
}

.brand-strip__item:hover {
    opacity: 1;
}

.brand-strip__item--active {
    opacity: 1;
    border-bottom-color: var(--blue, #0ea5e9);
}

.brand-strip__item img {
    max-height: 32px;
    max-width: 120px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.brand-strip__text {
    font-size: 16px;
    font-weight: 800;
    color: var(--text, #333);
    white-space: nowrap;
}

@media (max-width: 768px) {
    .brand-strip__item {
        flex: 0 0 auto;
        padding: 8px 12px;
        min-height: 44px;
    }

    .brand-strip__item img {
        max-height: 24px;
        max-width: 90px;
    }
}