/* Модуль холодильника — фиксирован по центру снизу */
.fridge-module {
    position: fixed;
    left: 50%;
    bottom: 20px;
    transform: translateX(-50%);
    z-index: 9999;
}

/* Базовая кнопка (ОТКРЫТЬ ХОЛОДИЛЬНИК) */
.fridge-module .fridge-float-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 10px 22px;
    border-radius: 50px;
    border: none;
    cursor: pointer;

    font-family: "Akrobat Regular", Arial, Helvetica, sans-serif !important;
    font-size: 18px !important;
    font-weight: 100;
    color: #ffffff !important;

    background: rgba(7, 183, 33, 0.61);

    text-transform: none;
    letter-spacing: 0.4px;

    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition:
        background 0.18s ease-out,
        color 0.18s ease-out,
        transform 0.18s ease-out,
        box-shadow 0.18s ease-out,
        opacity 0.18s ease-out;
}

/* Ховер базового состояния: зелёный плотнее, текст чёрный */
.fridge-module .fridge-float-btn:hover {
    background: rgba(7, 183, 33, 0.9);
    color: #000000 !important;

    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
}

/* Актив (при нажатии) */
.fridge-module .fridge-float-btn:active {
    transform: translateY(0);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
}

/* Состояния модуля под сценарии */
.fridge-module--idle .fridge-float-btn {
    opacity: 1;
}

.fridge-module--busy .fridge-float-btn {
    opacity: 0.7;
    pointer-events: none;
}

/* Режим СКАНИРОВАТЬ ТОВАР — стили как у .button.alt.st-bonus-open-popup */
.fridge-module.fridge-module--scanning .fridge-float-btn {
    display: block;
    width: 100%;
    text-align: center;
    background: #4cadc9b8 !important;
    color: #ffffff !important;
    border: none;
    padding: 12px 16px;
    border-radius: 6px;
    font-size: 18px;
    font-weight: 400;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s ease, box-shadow 0.1s ease;
}

/* Ховер в режиме сканирования */
.fridge-module.fridge-module--scanning .fridge-float-btn:hover {
    background: #3a92af !important;
    color: #000000 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
    transform: translateY(-1px);
}

/* Оверлей сканера (под будущую камеру) */
.fridge-scanner-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    z-index: 10000;

    display: flex;
    align-items: center;
    justify-content: center;
}

.fridge-scanner-inner {
    background: #111;
    border-radius: 12px;
    padding: 20px;
    width: 90%;
    max-width: 420px;
    color: #fff;
    text-align: center;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
}

.fridge-scanner-title {
    font-size: 20px;
    margin-bottom: 10px;
}

.fridge-scanner-text {
    font-size: 14px;
    margin-bottom: 20px;
    opacity: 0.9;
}

.fridge-scanner-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 18px;
    border-radius: 999px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    background: #ffffff;
    color: #000000;
}

/* Адаптив — на очень маленьких экранах немного ужимаем */
@media (max-width: 480px) {
    .fridge-module .fridge-float-btn {
        padding: 8px 16px;
        font-size: 14px !important;
    }

    .fridge-module {
        left: 50%;
        bottom: 10px;
        transform: translateX(-50%);
    }
}

.fridge-scanner-inner {
    background: #111;
    border-radius: 12px;
    padding: 20px;
    width: 90%;
    max-width: 420px;
    color: #fff;
    text-align: center;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
    position: relative;
}

.fridge-scanner-video {
    width: 100%;
    max-width: 360px;
    height: 120px;
    background: #000;
    border-radius: 12px;
    margin: 0 auto 12px auto;
    object-fit: cover;
    display: block;
}

/* Лазерная линия по центру */
.fridge-scanner-inner::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 80%;
    height: 2px;
    background: rgba(255, 0, 0, 0.7);
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.fridge-scanner-result {
    font-size: 14px;
    margin-bottom: 16px;
    min-height: 18px;
    color: #8bc34a;
}
/* Выравнивание текста по центру */
.fridge-status-message {
    text-align: center;
}