/* «Снимок инвентаря» (frontend/inv-snapshot.js, 16.10): кнопка в шапке инвентаря и окно с готовой картинкой.
   Кнопка — того же вида, что «Загрузить все фото» (css/render-loader.css .ph-all). Без blur и backdrop-filter. */
.snap-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 36px;
    padding: 0 12px 0 10px;
    border-radius: 11px;
    background: rgba(0, 229, 153, 0.07);
    border: 1px solid rgba(0, 229, 153, 0.3);
    color: #E6F6EF;
    font: inherit;
    font-size: 0.84rem;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
    -webkit-tap-highlight-color: transparent;
}
.snap-btn[hidden] { display: none; }
.snap-btn svg { width: 17px; height: 17px; color: #00E599; flex: none; }
.snap-btn:hover { background: rgba(0, 229, 153, 0.13); border-color: rgba(0, 229, 153, 0.55); }
.snap-btn:active { transform: scale(0.97); }
.snap-btn:focus-visible { outline: 2px solid #00E599; outline-offset: 2px; }

html.snap-open { overflow: hidden; }
.snap-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(4, 6, 8, 0.78);
    opacity: 0;
    transition: opacity 0.2s ease;
}
.snap-modal[hidden] { display: none; }
.snap-modal.is-on { opacity: 1; }
.snap-modal__panel {
    width: min(980px, 100%);
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px 18px 18px;
    border-radius: 18px;
    background: #12151A;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
    transform: translateY(6px);
    transition: transform 0.25s cubic-bezier(.2, .8, .2, 1);
}
.snap-modal.is-on .snap-modal__panel { transform: none; }
.snap-modal__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.snap-modal__head h3 { margin: 0; font-size: 1.05rem; font-weight: 800; }
.snap-modal__close {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 0;
    background: rgba(255, 255, 255, 0.06);
    color: #C9CDC9;
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
}
.snap-modal__close:hover { background: rgba(255, 255, 255, 0.12); }
.snap-modal__view {
    min-height: 220px;
    border-radius: 12px;
    background: #0B0D10;
    display: grid;
    place-items: center;
}
/* картинка целиком, без прокрутки: по высоте окна, ширина — сколько выйдет */
.snap-modal__view img { display: block; width: auto; height: auto; max-width: 100%; max-height: calc(100vh - 230px); border-radius: 12px; }
.snap-modal__wait { display: flex; flex-direction: column; align-items: center; gap: 12px; color: #9AA3A0; font-size: 0.9rem; padding: 40px 0; }
.snap-modal__wait i {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: conic-gradient(from 0deg, rgba(0, 229, 153, 0) 0deg, #00E599 290deg, rgba(0, 229, 153, 0) 360deg);
    -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 3px));
    mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 3px));
    animation: snap-spin 0.8s linear infinite;
}
@keyframes snap-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .snap-modal__wait i { animation-duration: 2.4s; } }
.snap-modal__err { padding: 40px 20px; color: #F0A3A3; font-size: 0.9rem; text-align: center; }
.snap-modal__note { margin: 0; font-size: 0.8rem; line-height: 1.45; color: #8E948F; }
.snap-modal__note:empty { display: none; }
.snap-modal__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.snap-modal__actions[hidden] { display: none; }
.snap-act {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 0 16px;
    border-radius: 11px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.04);
    color: #E8EBF0;
    font: inherit;
    font-size: 0.86rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}
.snap-act[hidden] { display: none; }
.snap-act svg { width: 17px; height: 17px; flex: none; }
.snap-act:hover { background: rgba(255, 255, 255, 0.08); }
.snap-act--main { background: #00E599; border-color: #00E599; color: #04140D; }
.snap-act--main:hover { background: #2DF0B0; }
@media (max-width: 600px) {
    .snap-modal { padding: 10px; }
    .snap-modal__panel { padding: 12px; }
    .snap-btn span { display: none; }
    .snap-btn { padding: 0 10px; }
}
