* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: system-ui, sans-serif;
}

body {
    background: #f5f5f5;
    font-family: "Onest", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

}

.app {
    max-width: 420px;
    height: 100vh;
    margin: 0 auto;
    background: #fff;
    display: flex;
    flex-direction: column;
}

/* HEADER */
.header {
    padding: 16px;
    border-bottom: 1px solid #eee;
}

.logo {
    display: flex;
    justify-content: center;
}

.logo img {
    height: 100px;
    object-fit: contain;
}


.search {
    margin-top: 12px;
}

.search input {
    width: 100%;
    padding: 10px 12px;
    border-radius: 12px;
    border: none;
    background: #f0f0f0;
}

/* MAIN */
#app-content {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
}

/* BOTTOM NAV */
.bottom-nav {
    display: flex;
    border-top: 1px solid #eee;
}

.bottom-nav button {
    flex: 1;
    padding: 12px 0;
    border: none;
    background: none;
    font-size: 14px;
    color: #999;
}

.bottom-nav button.active {
    color: #ff4d4f;
    font-weight: 600;
}

.banners {
    margin-bottom: 20px;
    overflow-x: auto;
}

.banners-track {
    display: flex;
    gap: 12px;
}

.banner {
    min-width: 260px;
    height: 120px;
    border-radius: 16px;
    padding: 14px;
    color: #fff;
    display: flex;
    align-items: flex-end;
}

.banner-text strong {
    font-size: 18px;
    display: block;
}

.banner-text span {
    font-size: 14px;
    opacity: 0.9;
}

/* Цвета из логотипа GAMMA */
.banner-red {
    background: linear-gradient(135deg, #ff4d4f, #ff7a45);
}

.banner-green {
    background: linear-gradient(135deg, #00b894, #55efc4);
}

.banner-yellow {
    background: linear-gradient(135deg, #fbc531, #ffeaa7);
}

.recommended h3 {
    margin-bottom: 12px;
}

.products {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.product-card {
    background: #fff;
    border-radius: 16px;
    padding: 12px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.product-img {
    height: 120px;
    border-radius: 12px;
    background: #f0f0f0;
    margin-bottom: 8px;
}

.product-title {
    font-size: 14px;
    margin-bottom: 4px;
}

.product-price {
    font-weight: 600;
    color: #ff4d4f;
    margin-bottom: 8px;
}

.product-card button {
    width: 100%;
    padding: 8px;
    border-radius: 12px;
    border: none;
    background: #ff4d4f;
    color: #fff;
    font-weight: 600;
}

.banners {
    overflow-x: auto;
    scrollbar-width: none;
    /* Firefox */
}

.banners::-webkit-scrollbar {
    display: none;
    /* Chrome / Safari */
}

.banners {
    margin-bottom: 24px;
}

.recommended {
    margin-top: 8px;
}

.banner {
    border-radius: 20px;
}

.product-card {
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.product-card:active:not(:has(button:active)) {
    transform: scale(0.98);
}


.product-card button {
    background: linear-gradient(135deg, #ff4d4f, #ff7a45);
}

.product-card {
    position: relative;
}

.favorite {
    position: absolute;
    top: 8px;
    right: 18px;
    font-size: 28px;
    color: #ff4d4f;
    opacity: 0.8;
}

.product-card button {
    position: relative;
    z-index: 2;
}

.product-card:active {
    transform: none;
}

.product-card button:active {
    transform: scale(0.98);
}

.categories {
    padding: 16px;
}

.categories h3 {
    margin-bottom: 12px;
}

.category-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 12px;
    border-radius: 14px;
    background: #fff;
    margin-bottom: 10px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.category-item:active {
    background: #f2f2f2;
}

.cat-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.cat-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 18px;
}

.cat-icon.red {
    background: #ff4d4f;
}

.cat-icon.green {
    background: #13c2c2;
}

.cat-icon.yellow {
    background: #fadb14;
    color: #000;
}

.cat-icon.orange {
    background: #ff7a45;
}

.cat-title {
    font-size: 15px;
}

.cat-arrow {
    font-size: 20px;
    color: #999;
}

.category-item:active {
    background: #f7f7f7;
}

.category-item {
    cursor: pointer;
}

.cat-arrow {
    font-size: 18px;
    opacity: 0.6;
}

.category-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.back-btn {
    border: none;
    background: none;
    font-size: 18px;
    cursor: pointer;
}

.category-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.back-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: #f2f2f2;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.back-btn:active {
    transform: scale(0.95);
    background: #e6e6e6;
}

.back-icon {
    font-size: 18px;
}

.category-title {
    font-size: 20px;
    font-weight: 600;
}

.text-back {
    cursor: pointer;
}

.back-text {
    color: #ff4d4f;
    font-weight: 500;

}

.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #fff;
    padding-bottom: 10px;
}

.header.scrolled {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.page {
    animation: fadeSlide 0.25s ease;
}

@keyframes fadeSlide {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-page .add-to-cart.big {
    width: 100%;
    padding: 14px;
    margin-top: 20px;
    font-size: 16px;
    border-radius: 12px;
    background: #ff5a5f;
    color: #fff;
    border: none;
}

.product-price {
    font-size: 20px;
    font-weight: 600;
    margin: 10px 0;
}

.product-page {
    padding: 16px;
}

.product-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.product-image {
    height: 220px;
    background: #f3f3f3;
    border-radius: 16px;
}

.product-title {
    font-size: 18px;
    font-weight: 600;
}

.product-price {
    font-size: 20px;
    font-weight: 600;
}

.add-to-cart.big {
    margin-top: auto;
    width: 100%;
    padding: 14px;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 600;
    background: #ff4d4f;
    /* цвет логотипа */
    color: #fff;
    border: none;
}

.add-to-cart.big:active {
    transform: scale(0.97);
}

.products {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 12px;
}


.product-title {
    font-size: 16px;
    font-weight: 400;
    line-height: 1.2;
}

.product-price {
    color: #ff4d4f;
    font-weight: 700;
    font-size: 15px;
}

.add-to-cart {
    margin-top: auto;
    padding: 10px;
    border-radius: 12px;
    background: #ff4d4f;
    color: #fff;
    border: none;
    font-weight: 600;
}

.add-to-cart:active {
    transform: scale(0.96);
}

.category-header {
    position: sticky;
    top: 0;
    z-index: 10;

    display: flex;
    align-items: center;
    gap: 10px;

    padding: 12px;
    background: #fff;
    border-bottom: 1px solid #eee;
}

.skeleton {
    animation: pulse 1.2s infinite ease-in-out;
}

.skeleton-line {
    height: 18px;
    background: #eee;
    border-radius: 10px;
}

.skeleton-line.short {
    width: 60%;
}

@keyframes pulse {
    0% {
        opacity: 1
    }

    50% {
        opacity: .4
    }

    100% {
        opacity: 1
    }
}

.cart-page {
    padding: 20px;
    text-align: center;
}

.cart-header h3 {
    font-size: 20px;
    margin-bottom: 40px;
}

.cart-empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.cart-empty h4 {
    font-size: 18px;
    margin-bottom: 8px;
}

.cart-empty p {
    color: #888;
    font-size: 14px;
}

.cart-back-btn {
    margin-top: 40px;
    width: 100%;
    padding: 14px;
    border-radius: 50px;
    background: #ff4d4f;
    color: #fff;
    border: none;
    font-size: 16px;
}

.cart-back-btn {
    transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.cart-back-btn:active {
    transform: scale(0.97);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12) inset;
}

.product-card {
    cursor: pointer;
}

.product-card button {
    pointer-events: auto;
}

button {
    position: relative;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
}

button::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.35);
    opacity: 0;
    transition: opacity .25s;
}

button:active::after {
    opacity: 1;
}

.page {
    animation: pageIn .2s ease both;
}

@keyframes pageIn {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}