/**
 * css/modern-2026.css
 * -----------------------------------------------------------------------
 * DESIGN SYSTEM 2026 — token + component dùng CHUNG cho navbar, menu user,
 * button, card... trên mọi trang chức năng (Dashboard, Vòng Quay, Random
 * Acc, Profile, Đổi Thưởng). Kế thừa ĐÚNG bảng màu/font đã dùng ở
 * index.php để nhất quán xuyên suốt toàn site.
 *
 * Toàn bộ class dùng tiền tố "m26-" để KHÔNG xung đột với hệ thống class
 * cũ (.card, .btn, .navbar...) trong css/style.css — cho phép áp dụng
 * song song an toàn trong quá trình nâng cấp từng phần.
 *
 * Icon: 100% SVG outline tự vẽ (không emoji) — xem bộ icon ở cuối file.
 * -----------------------------------------------------------------------
 */

/* ============================================================
   RESET CƠ BẢN — để file này TỰ ĐỦ, không bắt buộc phải luôn đi kèm
   css/style.css mới hoạt động đúng. Thiếu box-sizing:border-box và
   reset margin/padding mặc định của trình duyệt là nguyên nhân THẬT đã
   gây ra layout "lệch"/"co cụm" trên mobile thực tế (vd <ul> giữ
   padding-left mặc định của trình duyệt, <body> giữ margin 8px...) khi
   1 trang lỡ không include css/style.css (nơi vốn có reset này) trước
   khi include file thiết kế mới.
   ============================================================ */
*, *::before, *::after {
    box-sizing: border-box;
}
html, body {
    margin: 0;
    padding: 0;
}
button { font: inherit; }

:root {
    --m26-ink: #080b14;
    --m26-surface: #0f1424;
    --m26-surface-2: #141a30;
    --m26-surface-3: #1a2138;
    --m26-border: rgba(148, 163, 184, 0.12);
    --m26-border-strong: rgba(148, 163, 184, 0.22);
    --m26-text: #e7eaf3;
    --m26-text-dim: #8b93ab;
    --m26-text-faint: #5b6280;
    --m26-gold: #fbbf24;
    --m26-gold-dim: rgba(251, 191, 36, 0.14);
    --m26-violet: #a78bfa;
    --m26-violet-dim: rgba(167, 139, 250, 0.14);
    --m26-rose: #fb7185;
    --m26-rose-dim: rgba(251, 113, 133, 0.14);
    --m26-mint: #34d399;
    --m26-mint-dim: rgba(52, 211, 153, 0.14);
    --m26-font-display: 'Space Grotesk', 'Inter', sans-serif;
    --m26-font-body: 'Inter', sans-serif;
    --m26-font-mono: 'JetBrains Mono', monospace;
}

body.m26-body {
    background: var(--m26-ink);
    color: var(--m26-text);
    font-family: var(--m26-font-body);
    /* Lớp bảo vệ cuối cùng chống TRÀN NGANG trên mobile — dù nguyên nhân
       gốc là gì (ảnh quá khổ, text dài không wrap, card giãn sai...), quy
       tắc này đảm bảo trang KHÔNG BAO GIỜ cuộn ngang được, luôn cắt vừa
       đúng viewport thay vì để lộ phần tràn ra ngoài màn hình. */
    overflow-x: hidden;
    width: 100%;
}

/* ============================================================
   KÍCH THƯỚC MẶC ĐỊNH AN TOÀN CHO ICON SVG (icon_functions.php)
   ============================================================
   SVG không có width/height cố định sẽ bị trình duyệt phóng to tràn cả
   layout (đã xảy ra thực tế: icon trong <h2>/<button>... hiện to gần kín
   màn hình vì không có giới hạn kích thước nào). Rule này áp dụng kích
   thước mặc định 1em (tự co giãn theo font-size của phần tử cha chứa
   nó — vd icon trong <h2> to hơn icon trong text thường 1 cách tự nhiên,
   đúng ý nghĩa "icon đi kèm chữ") cho MỌI svg chưa được set style riêng.
   Những chỗ ĐÃ truyền tham số $style (vd icon('coin', 'width:20px')) vẫn
   ưu tiên giá trị đó vì style inline luôn thắng specificity thấp hơn.
   ============================================================ */
svg {
    width: 1em;
    height: 1em;
    flex-shrink: 0;
    vertical-align: -0.125em;
}

.m26-body .m26-ambient {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background:
        radial-gradient(700px 500px at 12% -5%, rgba(167, 139, 250, 0.12), transparent 60%),
        radial-gradient(800px 600px at 110% 15%, rgba(251, 191, 36, 0.08), transparent 60%);
}

.m26-navbar {
    position: sticky;
    top: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 14px clamp(16px, 4vw, 40px);
    background: rgba(8, 11, 20, 0.82);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--m26-border);
}

.m26-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    font-family: var(--m26-font-display);
    font-weight: 700;
    font-size: 16px;
    color: var(--m26-text);
    white-space: nowrap;
}
.m26-brand img { width: 30px; height: 30px; border-radius: 8px; }

.m26-nav-links {
    display: flex;
    align-items: center;
    gap: 6px;
    list-style: none;
    margin: 0;
    padding: 0;
    flex: 1;
    justify-content: center;
    flex-wrap: wrap;
}

.m26-nav-links a {
    display: flex;
    align-items: center;
    gap: 7px;
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--m26-text-dim);
    padding: 8px 14px;
    border-radius: 10px;
    transition: color 0.15s, background 0.15s;
    white-space: nowrap;
}
.m26-nav-links a svg { width: 16px; height: 16px; flex-shrink: 0; }
.m26-nav-links a:hover { color: var(--m26-text); background: rgba(255, 255, 255, 0.05); }
.m26-nav-links a.is-active { color: var(--m26-gold); background: var(--m26-gold-dim); }

.m26-player {
    position: relative;
    flex-shrink: 0;
}

.m26-player-trigger {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--m26-surface);
    border: 1px solid var(--m26-border-strong);
    border-radius: 100px;
    padding: 6px 14px 6px 6px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
    font: inherit;
    color: inherit;
    flex-wrap: nowrap;
    max-width: 100%;
}
.m26-player-trigger:hover { border-color: rgba(251, 191, 36, 0.4); background: var(--m26-surface-2); }

.m26-player-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--m26-violet), var(--m26-rose));
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--m26-font-display);
    font-weight: 700;
    font-size: 13px;
    color: #0d0716;
    flex-shrink: 0;
}

/* Khung avatar theo Cấp Độ — bọc quanh avatar gốc, KHÔNG thay thế nó,
   khung PHÓNG TO hơn avatar để tạo hiệu ứng viền bao quanh đẹp mắt. */
.m26-avatar-frame-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.m26-avatar-frame-img {
    position: absolute;
    top: 50%; left: 50%;
    width: 150%; height: 150%;
    transform: translate(-50%, -50%);
    object-fit: contain;
    pointer-events: none;
    z-index: 1;
}

.m26-player-info { display: flex; flex-direction: column; line-height: 1.2; text-align: left; }
.m26-player-name { font-size: 12.5px; font-weight: 700; color: var(--m26-text); max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m26-player-points { display: flex; align-items: center; gap: 4px; font-family: var(--m26-font-mono); font-size: 11px; color: var(--m26-gold); }
.m26-player-points svg { width: 11px; height: 11px; }

.m26-player-chevron { width: 14px; height: 14px; color: var(--m26-text-faint); transition: transform 0.2s; flex-shrink: 0; }
.m26-player.is-open .m26-player-chevron { transform: rotate(180deg); }

.m26-player-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 220px;
    background: var(--m26-surface-2);
    border: 1px solid var(--m26-border-strong);
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
    z-index: 300;
}
.m26-player.is-open .m26-player-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.m26-player-dropdown a, .m26-player-dropdown button {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    text-align: left;
    padding: 10px 12px;
    border-radius: 10px;
    text-decoration: none;
    color: var(--m26-text-dim);
    font-size: 13.5px;
    font-weight: 500;
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s, color 0.15s;
}
.m26-player-dropdown a svg, .m26-player-dropdown button svg { width: 16px; height: 16px; flex-shrink: 0; }
.m26-player-dropdown a:hover, .m26-player-dropdown button:hover { background: rgba(255, 255, 255, 0.06); color: var(--m26-text); }
.m26-player-dropdown .m26-dropdown-divider { height: 1px; background: var(--m26-border); margin: 6px 4px; }
.m26-player-dropdown button.m26-danger { color: var(--m26-rose); }
.m26-player-dropdown button.m26-danger:hover { background: var(--m26-rose-dim); }

.m26-auth-buttons { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.m26-btn-ghost-sm, .m26-btn-gold-sm {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
}
.m26-btn-ghost-sm { background: var(--m26-surface); border: 1px solid var(--m26-border-strong); color: var(--m26-text); }
.m26-btn-ghost-sm:hover { background: var(--m26-surface-2); }
.m26-btn-gold-sm { background: linear-gradient(135deg, var(--m26-gold), #f59e0b); color: #1a1300; }
.m26-btn-gold-sm:hover { transform: translateY(-1px); }

.m26-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    background: none;
    border: none;
    cursor: pointer;
    flex-shrink: 0;
}
.m26-hamburger span { display: block; width: 22px; height: 2px; background: var(--m26-text); border-radius: 2px; transition: transform 0.2s, opacity 0.2s; }
.m26-hamburger.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.m26-hamburger.is-active span:nth-child(2) { opacity: 0; }
.m26-hamburger.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 900px) {
    /* SỬA TRIỆT ĐỂ hiệu ứng "ngang rồi mới gãy xuống dọc" khi bấm mở menu
       — nguyên nhân là animate bằng max-height buộc trình duyệt phải
       TÍNH LẠI LAYOUT liên tục trong suốt quá trình transition, khiến
       mắt thường thoáng thấy 1 khung hình trung gian nơi các mục còn
       xếp ngang/chưa kịp xuống dòng đúng. Đổi sang animate opacity +
       transform (translateY) — 2 thuộc tính này được trình duyệt xử lý
       ở tầng compositor riêng, KHÔNG đụng vào layout, nên menu luôn ở
       ĐÚNG dạng cột dọc NGAY TỪ ĐẦU, chỉ mờ dần + trượt nhẹ khi xuất
       hiện, không còn hiện tượng "gãy hình" nào cả. */
    .m26-nav-links {
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        background: var(--m26-surface);
        gap: 3px;
        padding: 10px;
        border-bottom: 1px solid var(--m26-border);
        max-height: 70vh;
        overflow-y: auto;
        justify-content: flex-start;
        box-shadow: 0 16px 32px rgba(0, 0, 0, 0.35);
        opacity: 0;
        transform: translateY(-8px);
        visibility: hidden;
        pointer-events: none;
        transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0.18s;
    }
    .m26-nav-links.is-open {
        opacity: 1;
        transform: translateY(0);
        visibility: visible;
        pointer-events: auto;
        transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0s;
    }
    /* Icon quay về ĐÚNG kích thước/style gốc như desktop (16px, không
       khung nền riêng) — bản trước thêm khung nền làm icon to hơn nhìn
       không ổn, giữ lại padding/viền phân tách giữa các mục cho gọn
       gàng nhưng bỏ hẳn phần "khung nền cho icon". */
    .m26-nav-links a {
        padding: 11px 12px;
        gap: 10px;
    }
    .m26-nav-links a:not(:last-child) { border-bottom: 1px solid var(--m26-border); }
    .m26-nav-links a.is-active {
        background: var(--m26-gold-dim);
    }
    .m26-hamburger { display: flex; }
    .m26-player-name { max-width: 70px; }
}

/* ============================================================
   MÀN HÌNH RẤT HẸP (điện thoại thật, <480px) — 900px vẫn còn quá rộng để
   chứa đủ brand + hamburger + player-trigger (avatar + tên + điểm + mũi
   tên) trên 1 hàng ngang mà KHÔNG bị wrap xuống dòng hoặc bóp méo (đã
   xảy ra thực tế: player card bị vỡ layout trên mobile thật). Từ đây, bỏ
   hẳn tên/điểm/mũi tên khỏi nút chính, CHỈ giữ avatar tròn nhỏ gọn — toàn
   bộ thông tin (tên đầy đủ, điểm) vẫn xem được khi bấm mở dropdown.
   ============================================================ */
@media (max-width: 480px) {
    .m26-player-info,
    .m26-player-chevron {
        display: none;
    }
    .m26-player-trigger {
        padding: 4px;
        gap: 0;
    }
    .m26-player-dropdown {
        min-width: 200px;
        right: -6px;
    }
    /* Hiện lại tên + điểm NGAY TRONG dropdown (phía trên các mục menu) vì
       nút chính giờ chỉ còn avatar, không còn chỗ nào khác hiện info này
       cho user xem nhanh trước khi bấm vào "Tài khoản". */
    .m26-player-dropdown::before {
        content: attr(data-player-summary);
        display: block;
        padding: 10px 12px;
        margin-bottom: 6px;
        border-bottom: 1px solid var(--m26-border);
        font-size: 12.5px;
        font-weight: 700;
        color: var(--m26-text);
        white-space: normal;
        word-break: break-word;
    }
}

.m26-card {
    background: var(--m26-surface);
    border: 1px solid var(--m26-border);
    border-radius: 16px;
    padding: 22px;
}

.m26-card-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--m26-font-display);
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 16px;
    color: var(--m26-text);
}
.m26-card-title svg { width: 19px; height: 19px; color: var(--m26-gold); flex-shrink: 0; }

.m26-btn-primary, .m26-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 22px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 14.5px;
    text-decoration: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}
.m26-btn-primary svg, .m26-btn-secondary svg { width: 17px; height: 17px; }
.m26-btn-primary {
    background: linear-gradient(135deg, var(--m26-gold), #f59e0b);
    color: #1a1300;
}
.m26-btn-primary:hover { transform: translateY(-1px); box-shadow: 0 10px 26px rgba(251, 191, 36, 0.28); }
.m26-btn-secondary { background: var(--m26-surface-2); border: 1px solid var(--m26-border-strong); color: var(--m26-text); }
.m26-btn-secondary:hover { background: var(--m26-surface-3); }
.m26-btn-primary:disabled, .m26-btn-secondary:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.m26-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 11px;
    border-radius: 100px;
    font-size: 11.5px;
    font-weight: 700;
    font-family: var(--m26-font-mono);
}
.m26-badge svg { width: 12px; height: 12px; }
.m26-badge-gold { background: var(--m26-gold-dim); color: var(--m26-gold); }
.m26-badge-violet { background: var(--m26-violet-dim); color: var(--m26-violet); }
.m26-badge-rose { background: var(--m26-rose-dim); color: var(--m26-rose); }
.m26-badge-mint { background: var(--m26-mint-dim); color: var(--m26-mint); }
.m26-badge-muted { background: rgba(148, 163, 184, 0.1); color: var(--m26-text-faint); }

.m26-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding: 28px clamp(16px, 4vw, 40px) 36px;
    border-top: 1px solid var(--m26-border);
    color: var(--m26-text-faint);
    font-size: 13px;
    position: relative;
    z-index: 1;
}
.m26-footer a { color: var(--m26-text-dim); text-decoration: none; }
.m26-footer a:hover { color: var(--m26-violet); }
.m26-footer-links { display: flex; align-items: center; gap: 8px; }
.m26-footer-dot { color: var(--m26-text-faint); }

/* ============================================================
   BONG BÓNG CHAT LIÊN HỆ — nổi cố định góc dưới-phải màn hình, hiện ở
   MỌI trang (footer.php dùng chung). Bấm mở/đóng danh sách kênh liên hệ
   Admin đã cấu hình (Discord/Telegram/Facebook/Zalo).
   ============================================================ */
.m26-chat-bubble-wrap {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 60;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
    /* QUAN TRỌNG: container này có display:flex nên kích thước THẬT của
       nó co giãn theo NỘI DUNG CON LỚN NHẤT (bao gồm cả .m26-chat-menu
       đang ẩn — visibility:hidden KHÔNG làm nó hết chiếm chỗ trong
       layout), khiến vùng XUNG QUANH nút tròn (nơi mắt thường không
       thấy gì) vẫn CHẶN CLICK các phần tử bên dưới (vd nút "Chi tiết"
       trong lịch sử nhận acc nếu nằm gần góc màn hình — lỗi đã được báo
       cáo). Tắt pointer-events ở ĐÂY (container cha), chỉ bật lại CHO
       ĐÚNG 2 phần tử con thực sự cần click được (nút tròn + menu khi mở).
    */
    pointer-events: none;
}
.m26-chat-bubble-wrap > * { pointer-events: auto; }

.m26-chat-bubble {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--m26-violet), var(--m26-rose));
    border: none;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(167, 139, 250, 0.4);
    transition: transform 0.15s ease;
}
.m26-chat-bubble:hover { transform: scale(1.06); }
.m26-chat-bubble:active { transform: scale(0.96); }

.m26-chat-menu {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: var(--m26-surface);
    border: 1px solid var(--m26-border);
    border-radius: 16px;
    padding: 10px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
    opacity: 0;
    transform: translateY(8px) scale(0.96);
    visibility: hidden;
    pointer-events: none;
    transform-origin: bottom right;
    transition: opacity 0.15s ease, transform 0.15s ease, visibility 0s linear 0.15s;
}
.m26-chat-menu.is-open {
    opacity: 1;
    transform: translateY(0) scale(1);
    visibility: visible;
    pointer-events: auto;
    transition: opacity 0.15s ease, transform 0.15s ease, visibility 0s linear 0s;
}

.m26-chat-menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 10px;
    text-decoration: none;
    color: var(--m26-text);
    font-size: 13.5px;
    font-weight: 600;
    white-space: nowrap;
    transition: background 0.12s ease;
}
.m26-chat-menu-item:hover { background: var(--m26-surface-2); }
.m26-chat-menu-icon {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--chat-color, var(--m26-violet));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.m26-chat-menu-icon svg { width: 16px; height: 16px; }

@media (max-width: 640px) {
    .m26-chat-bubble-wrap { right: 14px; bottom: 14px; }
    .m26-chat-bubble { width: 48px; height: 48px; }
}
.m26-footer a:hover { color: var(--m26-text); }

/* ============================================================
   TOAST NOTIFICATION — thay thế alert() xấu xí của trình duyệt bằng
   thông báo trượt vào từ góc trên-phải, tự biến mất sau vài giây, có 4
   biến thể màu theo ngữ nghĩa (thành công/lỗi/cảnh báo/thông tin). Dùng
   chung cho toàn site qua hàm JS m26Toast() trong js/modern-2026.js.
   ============================================================ */
.m26-toast-container {
    position: fixed;
    top: 80px;
    right: 16px;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: min(380px, calc(100vw - 32px));
    pointer-events: none;
}

.m26-toast {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: var(--m26-surface-2);
    border: 1px solid var(--m26-border-strong);
    border-radius: 14px;
    padding: 14px 16px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
    pointer-events: auto;
    transform: translateX(120%);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s;
}
.m26-toast.is-visible { transform: translateX(0); opacity: 1; }

.m26-toast-icon {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 1px;
}
.m26-toast-icon svg { width: 13px; height: 13px; }
.m26-toast-success .m26-toast-icon { background: var(--m26-mint-dim); color: var(--m26-mint); }
.m26-toast-error .m26-toast-icon { background: var(--m26-rose-dim); color: var(--m26-rose); }
.m26-toast-warning .m26-toast-icon { background: var(--m26-gold-dim); color: var(--m26-gold); }
.m26-toast-info .m26-toast-icon { background: var(--m26-violet-dim); color: var(--m26-violet); }

.m26-toast-message {
    flex: 1;
    font-size: 13.5px;
    line-height: 1.5;
    color: var(--m26-text);
    word-break: break-word;
}

.m26-toast-close {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--m26-text-faint);
    cursor: pointer;
    padding: 0;
}
.m26-toast-close svg { width: 14px; height: 14px; }
.m26-toast-close:hover { color: var(--m26-text); }

@media (max-width: 480px) {
    .m26-toast-container { left: 16px; right: 16px; max-width: none; top: 72px; }
    .m26-toast { transform: translateY(-120%); }
    .m26-toast.is-visible { transform: translateY(0); }
}

/* ============================================================
   CONFIRM MODAL — thay thế confirm() của trình duyệt, dùng cho các hành
   động cần xác nhận trước khi thực hiện (đăng xuất, xoá...). Dùng qua
   hàm JS m26Confirm() (trả về Promise<boolean>).
   ============================================================ */
.m26-confirm-overlay {
    position: fixed;
    inset: 0;
    z-index: 3100;
    background: rgba(5, 7, 12, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s;
}
.m26-confirm-overlay.is-visible { opacity: 1; visibility: visible; }

.m26-confirm-box {
    background: var(--m26-surface-2);
    border: 1px solid var(--m26-border-strong);
    border-radius: 18px;
    padding: 26px;
    max-width: 380px;
    width: 100%;
    transform: scale(0.94);
    transition: transform 0.2s;
}
.m26-confirm-overlay.is-visible .m26-confirm-box { transform: scale(1); }

.m26-confirm-title {
    font-family: var(--m26-font-display);
    font-size: 17px;
    font-weight: 700;
    color: var(--m26-text);
    margin: 0 0 10px;
}
.m26-confirm-message {
    font-size: 14px;
    color: var(--m26-text-dim);
    line-height: 1.6;
    margin: 0 0 22px;
}
.m26-confirm-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}
.m26-confirm-actions button {
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    font-family: inherit;
}
.m26-confirm-cancel { background: var(--m26-surface-3); color: var(--m26-text); }
.m26-confirm-cancel:hover { background: var(--m26-surface); }
.m26-confirm-ok { background: linear-gradient(135deg, var(--m26-rose), #e11d48); color: #fff; }
.m26-confirm-ok:hover { transform: translateY(-1px); }
