/* ===== Online Catalog (Brochure) ===== */
body.catalog-page {
    overflow: hidden;
    height: 100dvh;
}

.catalog-page {
    background: #12100e;
}

.catalog-page .main-content {
    padding: 0;
    height: 100dvh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.catalog-app {
    height: 100%;
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    color: #f5f0e8;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(196, 30, 58, .18) 0%, transparent 55%),
        radial-gradient(ellipse at 80% 100%, rgba(232, 163, 23, .12) 0%, transparent 50%),
        linear-gradient(165deg, #1a1510 0%, #0f0d0b 45%, #12100e 100%);
}

/* ===== Minimal catalog header ===== */
.catalog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    background: rgba(15, 13, 11, .85);
    backdrop-filter: blur(8px);
    flex-shrink: 0;
    z-index: 30;
}

.catalog-header-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    color: #fff;
}

.catalog-header-logo {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, #c41e3a, #9b1830);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

.catalog-header-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.catalog-header-logo i {
    font-size: .95rem;
    color: #fff;
}

.catalog-header-name {
    font-size: .92rem;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.catalog-header-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.catalog-nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 10px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, .08);
    background: rgba(255, 255, 255, .04);
    color: rgba(245, 240, 232, .85);
    font-size: .75rem;
    font-family: inherit;
    cursor: pointer;
    transition: background .2s, border-color .2s, color .2s;
    position: relative;
    white-space: nowrap;
}

.catalog-nav-btn:hover,
.catalog-nav-btn.is-active {
    background: rgba(196, 30, 58, .18);
    border-color: rgba(196, 30, 58, .35);
    color: #fff;
}

.catalog-nav-btn.is-active {
    background: rgba(196, 30, 58, .28);
}

.catalog-nav-btn i {
    font-size: .9rem;
}

.catalog-nav-cart .cart-badge {
    position: absolute;
    top: -5px;
    left: -5px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 999px;
    background: #e8a317;
    color: #1a1510;
    font-size: .62rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

.catalog-account-menu {
    position: relative;
}

.catalog-account-menu .account-menu-caret {
    font-size: .55rem !important;
    opacity: .6;
}

.catalog-account-dropdown {
    left: 0;
    right: auto;
    min-width: 190px;
    background: #1e1915;
    border-color: rgba(255, 255, 255, .1);
}

.catalog-account-dropdown a,
.catalog-account-dropdown button {
    color: rgba(245, 240, 232, .9);
}

.catalog-account-dropdown a:hover,
.catalog-account-dropdown button:hover {
    background: rgba(255, 255, 255, .06);
    color: #fff;
}

.catalog-hint {
    text-align: center;
    font-size: .72rem;
    color: rgba(245, 240, 232, .5);
    padding: 8px 14px 4px;
    flex-shrink: 0;
}

.catalog-stage {
    min-height: 0;
    display: flex;
    justify-content: center;
    align-items: stretch;
    padding: 4px 10px 8px;
    overflow: hidden;
}

.catalog-stage-inner {
    display: flex;
    align-items: stretch;
    gap: 8px;
    width: min(100%, 440px);
    max-width: 440px;
    height: 100%;
    margin: 0 auto;
    direction: ltr;
    min-height: 0;
}

.catalog-viewport {
    flex: 1;
    width: 100%;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    position: relative;
    touch-action: pan-y;
    direction: ltr;
    isolation: isolate;
}

.catalog-track {
    display: flex;
    flex-wrap: nowrap;
    height: 100%;
    direction: ltr;
    transition: transform .45s cubic-bezier(.4, 0, .2, 1);
    will-change: transform;
}

.catalog-sheet {
    flex: 0 0 auto;
    height: 100%;
    padding: 4px;
    box-sizing: border-box;
    direction: rtl;
    overflow: hidden;
}

.catalog-cover {
    position: relative;
}

.catalog-cover-inner,
.catalog-category {
    height: 100%;
    border-radius: 20px;
    background: linear-gradient(180deg, #2a221c 0%, #1e1915 100%);
    border: 1px solid rgba(255, 255, 255, .08);
    box-shadow:
        0 24px 64px rgba(0, 0, 0, .45),
        inset 0 1px 0 rgba(255, 255, 255, .06);
    overflow: hidden;
    position: relative;
}

.catalog-cover-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: clamp(16px, 4vw, 32px) clamp(14px, 4vw, 28px);
    gap: clamp(8px, 2vw, 14px);
    cursor: pointer;
}

.catalog-cover-glow {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 50% 30%, rgba(196, 30, 58, .25) 0%, transparent 60%),
        radial-gradient(circle at 70% 80%, rgba(232, 163, 23, .15) 0%, transparent 50%);
    pointer-events: none;
}

.catalog-cover-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .1);
    font-size: .82rem;
    color: rgba(245, 240, 232, .8);
    position: relative;
    z-index: 1;
}

.catalog-cover-title {
    font-size: clamp(1.35rem, 5vw, 2rem);
    font-weight: 800;
    color: #fff;
    line-height: 1.3;
    position: relative;
    z-index: 1;
}

.catalog-cover-tagline {
    font-size: 1rem;
    color: #e8a317;
    position: relative;
    z-index: 1;
}

.catalog-cover-divider {
    width: 64px;
    height: 3px;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, #c41e3a, transparent);
    position: relative;
    z-index: 1;
}

.catalog-cover-desc {
    font-size: .88rem;
    line-height: 1.9;
    color: rgba(245, 240, 232, .65);
    max-width: 280px;
    position: relative;
    z-index: 1;
}

.catalog-cover-stats {
    display: flex;
    gap: 24px;
    font-size: .85rem;
    color: rgba(245, 240, 232, .5);
    position: relative;
    z-index: 1;
}

.catalog-cover-stats strong {
    display: block;
    font-size: 1.4rem;
    color: #fff;
    font-weight: 800;
}

.catalog-cover-open {
    margin-top: 4px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 22px;
    border-radius: 999px;
    background: linear-gradient(135deg, #c41e3a, #9b1830);
    color: #fff;
    font-size: .88rem;
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(196, 30, 58, .4);
    transition: transform .2s, box-shadow .2s;
    position: relative;
    z-index: 1;
}

.catalog-cover-open:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(196, 30, 58, .5);
}

.catalog-cover-swipe {
    font-size: .78rem;
    color: rgba(245, 240, 232, .4);
    display: flex;
    align-items: center;
    gap: 6px;
    position: relative;
    z-index: 1;
}

.catalog-category {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
}

.catalog-sheet-header {
    padding: 22px 22px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    flex-shrink: 0;
}

.catalog-sheet-index {
    display: block;
    font-size: .72rem;
    color: rgba(245, 240, 232, .4);
    margin-bottom: 6px;
}

.catalog-sheet-title {
    font-size: 1.45rem;
    font-weight: 800;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 10px;
}

.catalog-sheet-title i {
    color: #e8a317;
    font-size: 1.1rem;
}

.catalog-sheet-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 8px 14px 18px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.15) transparent;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    touch-action: pan-y;
}

.catalog-sheet-body::-webkit-scrollbar {
    width: 4px;
}

.catalog-sheet-body::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .18);
    border-radius: 4px;
}

.catalog-item {
    width: 100%;
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    align-items: center;
    gap: 10px;
    padding: 14px 8px;
    border: none;
    background: transparent;
    color: inherit;
    text-align: right;
    border-bottom: 1px dashed rgba(255, 255, 255, .08);
    cursor: pointer;
    transition: background .2s;
    font-family: inherit;
}

.catalog-item:last-child {
    border-bottom: none;
}

.catalog-item:hover:not(:disabled) {
    background: rgba(255, 255, 255, .04);
}

.catalog-item:active:not(:disabled) {
    background: rgba(196, 30, 58, .12);
}

.catalog-item.is-out {
    opacity: .45;
    cursor: not-allowed;
}

.catalog-item-price {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    min-width: 72px;
    font-size: .82rem;
    color: #e8a317;
    font-weight: 700;
    white-space: nowrap;
}

.catalog-item-old {
    font-size: .7rem;
    color: rgba(245, 240, 232, .35);
    text-decoration: line-through;
    font-weight: 400;
}

.catalog-item-current {
    font-size: .88rem;
}

.catalog-item-line {
    flex: 1;
    height: 1px;
    border-bottom: 1px dotted rgba(245, 240, 232, .2);
    min-width: 12px;
}

.catalog-item-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.catalog-item-name {
    font-size: .92rem;
    font-weight: 700;
    color: #fff;
}

.catalog-item-desc {
    font-size: .75rem;
    color: rgba(245, 240, 232, .45);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.catalog-item-thumb {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--item-color, #c41e3a);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(255, 255, 255, .1);
}

.catalog-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.catalog-item-thumb i {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, .9);
}

.catalog-item.is-adding {
    pointer-events: none;
    opacity: .7;
}

.catalog-item.is-added .catalog-item-thumb {
    box-shadow: 0 0 0 2px #e8a317;
}

.catalog-empty {
    text-align: center;
    padding: 40px 20px;
    color: rgba(245, 240, 232, .4);
    font-size: .9rem;
}

.catalog-nav {
    width: 36px;
    height: 36px;
    align-self: center;
    flex-shrink: 0;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .06);
    color: rgba(245, 240, 232, .7);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background .2s, color .2s;
}

.catalog-nav:hover:not(:disabled) {
    background: rgba(255, 255, 255, .12);
    color: #fff;
}

.catalog-nav:disabled {
    opacity: .25;
    cursor: default;
}

.catalog-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 8px 20px 14px;
    flex-shrink: 0;
}

.catalog-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, .2);
    padding: 0;
    cursor: pointer;
    transition: background .2s, transform .2s;
}

.catalog-dot.active {
    background: #e8a317;
    transform: scale(1.2);
}

.catalog-toast {
    position: fixed;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%) translateY(80px);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 22px;
    border-radius: 999px;
    background: #1e1915;
    border: 1px solid rgba(232, 163, 23, .35);
    color: #f5f0e8;
    font-size: .88rem;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .4);
    z-index: 100;
    transition: transform .35s cubic-bezier(.4, 0, .2, 1), opacity .35s;
    opacity: 0;
    pointer-events: none;
    max-width: calc(100% - 32px);
}

.catalog-toast.is-visible {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.catalog-toast i {
    color: #e8a317;
    font-size: 1.1rem;
    flex-shrink: 0;
}

@media (max-width: 640px) {
    .catalog-header-name {
        max-width: 90px;
        font-size: .82rem;
    }

    .catalog-header-nav > .catalog-nav-btn > span {
        display: none;
    }

    .catalog-account-menu .catalog-nav-btn > span {
        display: none;
    }

    .catalog-nav-btn {
        padding: 8px 9px;
    }
}

@media (max-width: 520px) {
    .catalog-nav {
        width: 34px;
        height: 34px;
        font-size: .85rem;
    }

    .catalog-hint {
        font-size: .7rem;
        padding-top: 8px;
    }

    .catalog-item {
        grid-template-columns: auto 1fr auto;
        gap: 8px;
    }

    .catalog-item-line {
        display: none;
    }
}

@media (min-width: 768px) {
    .catalog-stage-inner {
        max-width: 460px;
        width: min(100%, 460px);
    }
}
