﻿/* =========================
   MIX PAGE (Make Your Own Mix)
   ========================= */

.mix-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 22px 16px 40px;
}

.mix-header {
    margin-bottom: 18px;
}

.mix-title {
    margin: 0;
    font-size: 30px;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.mix-subtitle {
    margin: 6px 0 0;
    color: #555;
    font-size: 14px;
}

/* =========================
   BUILDER SECTION
   ========================= */

.mix-builder {
    margin-top: 10px;
}

.mix-box {
    border: 1px solid #e7e7e7;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(0,0,0,.06);
    padding: 18px;
}

.mix-box__top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.mix-box__label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: #777;
    font-weight: 900;
}

.mix-box__meta {
    margin-top: 4px;
    font-size: 18px;
    font-weight: 900;
    color: #111;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.mix-box__dot {
    opacity: .35;
}

.mix-box__price {
    font-weight: 900;
}

.mix-box__badge {
    background: #111;
    color: #fff;
    border-radius: 999px;
    padding: 8px 12px;
    font-weight: 900;
    font-size: 12px;
    white-space: nowrap;
}

.mix-box__content {
    margin-top: 14px;
}

.mix-empty {
    border: 1px dashed #ddd;
    background: #fafafa;
    border-radius: 16px;
    padding: 14px;
    color: #666;
    font-weight: 700;
    line-height: 1.35;
}

.mix-empty--catalog {
    margin-top: 16px;
}

/* =========================
   SIZE BUTTONS
   ========================= */

.mix-size {
    margin-top: 14px;
    display: flex;
    gap: 10px;
}

.mix-size__btn {
    flex: 1 1 0;
    border: 1px solid #111;
    background: #fff;
    color: #111;
    border-radius: 14px;
    padding: 12px 10px;
    font-weight: 900;
    cursor: pointer;
    transition: transform .06s ease, background .15s ease, color .15s ease;
}

    .mix-size__btn:hover {
        transform: translateY(-1px);
    }

    .mix-size__btn.is-active {
        background: #111;
        color: #fff;
    }

/* Inline hint (professional replacement for alert) */
.mix-inline-hint {
    margin-top: 10px;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid #ffe1a6;
    background: #fff8e6;
    color: #7a4b00;
    font-weight: 800;
    font-size: 13px;
    display: none;
}

    .mix-inline-hint.is-visible {
        display: block;
    }

/* Attention animation on size buttons area */
.mix-size--attention {
    animation: mixPulse .9s ease;
}

@keyframes mixPulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(0,0,0,0);
    }

    40% {
        transform: scale(1.02);
        box-shadow: 0 12px 26px rgba(0,0,0,.10);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(0,0,0,0);
    }
}

/* =========================
   NOTE / MESSAGE
   ========================= */

.mix-note {
    margin-top: 16px;
    border-top: 1px dashed #e6e6e6;
    padding-top: 14px;
}

.mix-note__title {
    font-weight: 900;
    font-size: 14px;
    color: #111;
}

.mix-note__text {
    margin-top: 6px;
    color: #666;
    font-weight: 700;
    font-size: 12.5px;
    line-height: 1.35;
}

.mix-note__form {
    margin-top: 10px;
    display: flex;
    gap: 10px;
}

.mix-note__input {
    flex: 1 1 auto;
    border: 1px solid #ddd;
    border-radius: 14px;
    padding: 11px 12px;
    font-weight: 700;
    outline: none;
}

    .mix-note__input:focus {
        border-color: #111;
    }

/* =========================
   BUTTONS
   ========================= */

.mix-btn {
    border: 1px solid #111;
    background: #111;
    color: #fff;
    border-radius: 14px;
    padding: 11px 14px;
    font-weight: 900;
    cursor: pointer;
    transition: transform .06s ease, opacity .15s ease, background .15s ease, color .15s ease;
}

    .mix-btn:hover {
        transform: translateY(-1px);
    }

.mix-btn--primary {
    width: 100%;
    margin-top: 14px;
    padding: 14px 16px;
    border-radius: 16px;
    font-size: 14px;
}

.mix-btn--outline {
    background: #fff;
    color: #111;
}

.mix-btn--disabled,
.mix-btn:disabled {
    opacity: .55;
    cursor: not-allowed;
    transform: none;
}

.mix-cart-form {
    margin-top: 6px;
}

.mix-footnote {
    margin-top: 10px;
    color: #777;
    font-weight: 700;
    font-size: 12px;
}

/* =========================
   CATALOG (Categories + Products)
   ========================= */

.mix-catalog {
    margin-top: 26px;
}

.mix-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.mix-section-head--spaced {
    margin-top: 18px;
}

.mix-section-title {
    margin: 0;
    font-weight: 900;
    font-size: 20px;
    letter-spacing: -0.01em;
}

.mix-section-subtitle {
    margin: 0;
    color: #666;
    font-weight: 700;
    font-size: 13px;
}

/* =========================
   GRIDS
   ========================= */

.mix-categories,
.mix-products-grid {
    margin-top: 18px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 18px;
}

/* =========================
   CATEGORY CARD (overlay style)
   ========================= */

.mix-category-card {
    border: 1px solid #eee;
    background: #fff;
    border-radius: 22px;
    padding: 0;
    overflow: hidden;
    cursor: pointer;
    text-align: left;
    transition: transform .08s ease, box-shadow .2s ease, border-color .2s ease;
}

    .mix-category-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 18px 35px rgba(0,0,0,.08);
        border-color: #ddd;
    }

    .mix-category-card.is-active {
        border: 2px solid #111;
        box-shadow: 0 20px 40px rgba(0,0,0,.12);
    }

.mix-category-card__media {
    position: relative;
    height: 190px;
    background: #f3f3f3;
}

    .mix-category-card__media img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        transition: transform .35s ease;
    }

.mix-category-card:hover .mix-category-card__media img {
    transform: scale(1.06);
}

.mix-category-card__overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 14px;
    background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,.70) 100%);
    color: #fff;
}

.mix-category-card__name {
    margin: 0;
    font-weight: 900;
    font-size: 16px;
    line-height: 1.2;
}

.mix-category-card__hint {
    margin-top: 6px;
    font-size: 12px;
    font-weight: 800;
    opacity: .9;
}

/* =========================
   PRODUCT CARD (media + badge + body)
   ========================= */

.mix-product-card {
    border: 1px solid #eee;
    background: #fff;
    border-radius: 22px;
    padding: 0;
    overflow: hidden;
    transition: transform .08s ease, box-shadow .2s ease, border-color .2s ease;
    content-visibility: auto;
    contain-intrinsic-size: 240px 280px;
}

    .mix-product-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 18px 35px rgba(0,0,0,.08);
        border-color: #ddd;
    }

.mix-product-card__media {
    position: relative;
    height: 190px;
    background: #f3f3f3;
}

    .mix-product-card__media img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        transition: transform .35s ease;
    }

.mix-product-card:hover .mix-product-card__media img {
    transform: scale(1.06);
}

.mix-product-card__badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(0,0,0,.72);
    color: #fff;
    font-weight: 900;
    font-size: 12px;
}

.mix-product-card__body {
    padding: 14px;
}

.mix-product-card__name {
    margin: 0 0 10px 0;
    font-weight: 900;
    font-size: 14px;
    color: #111;
    line-height: 1.25;
}

.mix-product-card__form {
    margin-top: 10px;
}

/* =========================
   TOAST
   ========================= */

.mix-toast {
    position: fixed;
    left: 50%;
    bottom: 20px;
    transform: translateX(-50%);
    background: #111;
    color: #fff;
    padding: 10px 14px;
    border-radius: 999px;
    font-weight: 900;
    font-size: 13px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease, transform .2s ease;
    z-index: 9999;
}

    .mix-toast.is-visible {
        opacity: 1;
        transform: translateX(-50%) translateY(-4px);
    }

/* =========================
   BOX VISUAL + COLORED TILES
   ========================= */

.mix-box-visual {
    border: 1px solid #eee;
    border-radius: 18px;
    background: linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
    padding: 14px;
}

.mix-box-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
}

.mix-tile {
    border-radius: 16px;
    padding: 12px;
    border: 1px solid rgba(0,0,0,.06);
    box-shadow: 0 10px 22px rgba(0,0,0,.05);
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-height: 110px;
}

.mix-tile__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.mix-tile__avatar {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    overflow: hidden;
    background: rgba(255,255,255,.55);
    border: 1px solid rgba(0,0,0,.08);
    flex: 0 0 auto;
}

    .mix-tile__avatar img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

.mix-tile__remove {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    border: 1px solid rgba(0,0,0,.10);
    background: rgba(255,255,255,.60);
    font-weight: 900;
    cursor: pointer;
}

    .mix-tile__remove:hover {
        background: rgba(255,255,255,.85);
    }

.mix-tile__name {
    font-weight: 900;
    color: #111;
    font-size: 13px;
    line-height: 1.2;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Color palette */
.mix-c1 {
    background: #fff1f2;
}

.mix-c2 {
    background: #ecfeff;
}

.mix-c3 {
    background: #fefce8;
}

.mix-c4 {
    background: #f0fdf4;
}

.mix-c5 {
    background: #eff6ff;
}

.mix-c6 {
    background: #faf5ff;
}

.mix-c7 {
    background: #fff7ed;
}

.mix-c8 {
    background: #f8fafc;
}

/* =========================
   RESPONSIVE
   ========================= */

@media (max-width: 1100px) {
    .mix-categories,
    .mix-products-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .mix-title {
        font-size: 26px;
    }

    .mix-note__form {
        flex-direction: column;
    }

    .mix-note__input {
        width: 100%;
    }

    .mix-categories,
    .mix-products-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 520px) {
    .mix-page {
        padding: 18px 12px 34px;
    }

    .mix-categories,
    .mix-products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .mix-box {
        padding: 14px;
        border-radius: 18px;
    }

    .mix-size__btn {
        padding: 11px 8px;
        border-radius: 12px;
    }

    .mix-box-tiles {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
/* =========================
   PERFORMANCE: lock categories (show only active)
   ========================= */
.mix-categories.is-locked .mix-category-card {
    display: none;
}

    .mix-categories.is-locked .mix-category-card.is-active {
        display: block;
    }

/* Change category button */
.mix-change-category {
    white-space: nowrap;
    align-self: flex-end;
}

/* small warning note */
.mix-warning {
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid #ffe1a6;
    background: #fff8e6;
    color: #7a4b00;
    font-weight: 800;
    font-size: 13px;
}

/* paging row under products */
.mix-paging {
    margin-top: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.mix-paging__meta {
    color: #666;
    font-weight: 800;
    font-size: 13px;
}
.mix-extraOption {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 8px;
    align-items: center;
    border: 1px solid rgba(0,0,0,.08);
    background: rgba(255,255,255,.65);
    border-radius: 12px;
    padding: 8px 10px;
    font-size: 12px;
    font-weight: 800;
}

.mix-extraOption__checkbox {
    width: 16px;
    height: 16px;
    accent-color: #111;
}

.mix-extraOption__text {
    color: #111;
    line-height: 1.2;
}

.mix-extraOption__price {
    white-space: nowrap;
    font-weight: 900;
    color: #111;
}