/* ============================================================
   MLM Binary Pro — Webinar module (public)
   ============================================================ */
.mlm-wb-reg, .mlm-wb-room, .mlm-wb-list {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #1f2937; -webkit-font-smoothing: antialiased;
}
.mlm-wb-btn {
    display: inline-block; width: 100%; text-align: center; padding: 14px 24px;
    border: none; border-radius: 10px; cursor: pointer;
    background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff !important;
    font-size: 15px; font-weight: 700; text-decoration: none !important;
    transition: transform .12s, box-shadow .12s; box-shadow: 0 6px 20px rgba(79,70,229,.3);
}
.mlm-wb-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 26px rgba(79,70,229,.42); color: #fff !important; }
.mlm-wb-btn:disabled { opacity: .6; cursor: not-allowed; transform: none; }
.mlm-wb-btn.sm { width: auto; padding: 9px 18px; font-size: 13px; }
.mlm-wb-badge { display: inline-block; background: #eef2ff; color: #4f46e5; border-radius: 999px; padding: 4px 12px; font-size: 12px; font-weight: 700; letter-spacing: .03em; margin-bottom: 12px; }
.mlm-wb-fineprint { font-size: 12px; color: #9ca3af; text-align: center; margin-top: 12px; }

/* ── Registration ──────────────────────────────────────────── */
.mlm-wb-reg { max-width: 560px; margin: 0 auto; }
.mlm-wb-reg-card { background: #fff; border: 1px solid #e5e7eb; border-radius: 18px; overflow: hidden; box-shadow: 0 8px 30px rgba(0,0,0,.08); }
.mlm-wb-cover { height: 200px; background-size: cover; background-position: center; }
.mlm-wb-reg-body { padding: 28px; }
.mlm-wb-title { font-size: 26px; font-weight: 800; margin: 0 0 12px; line-height: 1.25; }
.mlm-wb-desc { font-size: 14px; color: #4b5563; margin-bottom: 18px; }
.mlm-wb-schedule { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.mlm-wb-sched-item { display: flex; align-items: center; gap: 10px; background: #f8fafc; border-radius: 10px; padding: 10px 14px; flex: 1; min-width: 140px; }
.mlm-wb-sched-item .ico { font-size: 20px; }
.mlm-wb-sched-item strong { display: block; font-size: 13.5px; }
.mlm-wb-sched-item small { color: #9ca3af; font-size: 11.5px; }
.mlm-wb-form { display: flex; flex-direction: column; gap: 10px; }
.mlm-wb-field input { width: 100%; padding: 13px 16px; border: 1.5px solid #e5e7eb; border-radius: 10px; font-size: 15px; outline: none; transition: border .15s, box-shadow .15s; }
.mlm-wb-field input:focus { border-color: #4f46e5; box-shadow: 0 0 0 3px #eef2ff; }
.mlm-wb-msg { margin-top: 6px; }
.mlm-wb-ok  { background: #dcfce7; color: #15803d; border-radius: 8px; padding: 10px 14px; font-size: 13.5px; }
.mlm-wb-err { background: #fee2e2; color: #b91c1c; border-radius: 8px; padding: 10px 14px; font-size: 13.5px; }

/* ── Room ──────────────────────────────────────────────────── */
.mlm-wb-room { max-width: 1200px; width: 100%; margin: 0 auto; }
.mlm-wb-stage { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
.mlm-wb-video-col { position: relative; min-width: 0; width: 100%; }
@media (max-width: 900px) { .mlm-wb-stage { grid-template-columns: 1fr; } }
.mlm-wb-video { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: 14px; overflow: hidden; }
/* Fallback for browsers without aspect-ratio support */
@supports not (aspect-ratio: 16 / 9) { .mlm-wb-video { padding-bottom: 56.25%; height: 0; } }
.mlm-wb-video iframe, .mlm-wb-video video {
    position: absolute; inset: 0; width: 100%; height: 100%; border: 0; z-index: 1;
}
/* Transparent lock layer over the player — blocks pause/seek/click-through */
.mlm-wb-lock { position: absolute; inset: 0; z-index: 3; cursor: default; background: transparent; }
.mlm-wb-noembed { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; z-index: 1; }

/* Floating reaction buttons + emoji rise */
.mlm-wb-reactions { position: absolute; right: 12px; bottom: 70px; z-index: 5; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.mlm-wb-reactions button { pointer-events: auto; width: 42px; height: 42px; border-radius: 50%; border: none; background: rgba(255,255,255,.92); box-shadow: 0 2px 8px rgba(0,0,0,.2); font-size: 20px; cursor: pointer; transition: transform .1s; }
.mlm-wb-reactions button:hover { transform: scale(1.15); }
.mlm-wb-float-emoji { position: absolute; z-index: 6; font-size: 26px; pointer-events: none; animation: wb-rise 2.4s ease-out forwards; }
@keyframes wb-rise { 0% { opacity: 1; transform: translateY(0) scale(.6); } 30% { transform: translateY(-40px) scale(1.2); } 100% { opacity: 0; transform: translateY(-180px) scale(1); } }

/* Join toasts */
.mlm-wb-toasts { position: fixed; z-index: 90; pointer-events: none; right: 410px; bottom: 24px; display: flex; flex-direction: column-reverse; gap: 8px; }
@media (max-width: 900px) { .mlm-wb-toasts { right: 12px; bottom: 74px; } }
.mlm-wb-toast { background: rgba(17,24,39,.92); color: #fff; border-radius: 999px; padding: 8px 16px; font-size: 13px; font-weight: 600; box-shadow: 0 4px 14px rgba(0,0,0,.25); animation: wb-toast-in .3s ease-out; white-space: nowrap; }
.mlm-wb-toast .em { margin-right: 6px; }
@keyframes wb-toast-in { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }
.mlm-wb-bar { display: flex; align-items: center; gap: 14px; margin-top: 12px; flex-wrap: wrap; }
.mlm-wb-live { display: inline-flex; align-items: center; gap: 7px; background: #fee2e2; color: #dc2626; font-weight: 800; font-size: 12px; padding: 5px 12px; border-radius: 999px; }
.mlm-wb-live .dot { width: 8px; height: 8px; border-radius: 50%; background: #dc2626; animation: wb-pulse 1.4s infinite; }
@keyframes wb-pulse { 0%,100% { opacity: 1; } 50% { opacity: .3; } }
.mlm-wb-viewers { font-size: 13px; color: #6b7280; font-weight: 600; }
.mlm-wb-title-sm { font-size: 14px; font-weight: 700; margin-left: auto; }
.mlm-wb-cta { margin-top: 14px; text-align: center; animation: wb-slidein .4s; }
@keyframes wb-slidein { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.mlm-wb-cta .mlm-wb-btn { max-width: 420px; }

/* Chat */
.mlm-wb-chat-col { background: #fff; border: 1px solid #e5e7eb; border-radius: 14px; display: flex; flex-direction: column; height: 520px; overflow: hidden; }
.mlm-wb-chat-head { padding: 14px 16px; border-bottom: 1px solid #e5e7eb; font-weight: 700; font-size: 14px; background: #f8fafc; }
.mlm-wb-pinned { align-items: flex-start; gap: 8px; padding: 10px 12px; background: #fffbeb; border-bottom: 1px solid #fde68a; font-size: 12.5px; }
.mlm-wb-pinned .pin-ico { flex-shrink: 0; }
.mlm-wb-pinned .pin-body { flex: 1; line-height: 1.4; }
.mlm-wb-pinned .pin-x { background: none; border: none; cursor: pointer; color: #92400e; font-size: 16px; }
.mlm-wb-chat-list { flex: 1; overflow-y: auto; padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
.mlm-wb-cmsg { position: relative; }
.mlm-wb-cmsg.answer { background: #eff6ff; border-radius: 8px; padding: 6px 10px; }
.mlm-wb-cmsg .atag2 { color: #1d4ed8; font-weight: 700; font-size: 11px; }
.mlm-wb-pinbtn { position: absolute; right: 0; top: 0; background: none; border: none; cursor: pointer; opacity: 0; font-size: 12px; }
.mlm-wb-cmsg:hover .mlm-wb-pinbtn { opacity: .7; }
.mlm-wb-pinbtn:hover { opacity: 1 !important; }
.mlm-wb-cmsg { font-size: 13px; line-height: 1.4; }
.mlm-wb-cmsg .cauthor { font-weight: 700; color: #4f46e5; margin-right: 6px; }
.mlm-wb-cmsg .cbody { color: #374151; }
.mlm-wb-cmsg.admin .cauthor { color: #dc2626; }
.mlm-wb-cmsg.question { background: #fffbeb; border-radius: 8px; padding: 6px 10px; }
.mlm-wb-cmsg .qtag { color: #d97706; font-weight: 700; font-size: 11px; }
.mlm-wb-cmsg .atag { background: #dc2626; color: #fff; font-size: 9px; padding: 1px 5px; border-radius: 4px; margin-right: 4px; }
.mlm-wb-chat-form { display: flex; align-items: center; gap: 6px; padding: 10px; border-top: 1px solid #e5e7eb; }
.mlm-wb-chat-form input[type=text] { flex: 1; border: 1px solid #e5e7eb; border-radius: 8px; padding: 9px 12px; font-size: 13px; outline: none; }
.mlm-wb-chat-form input[type=text]:focus { border-color: #4f46e5; }
.mlm-wb-chat-form button { background: #4f46e5; color: #fff; border: none; border-radius: 8px; width: 38px; height: 38px; font-size: 16px; cursor: pointer; }
.mlm-wb-q { font-size: 11px; color: #6b7280; display: flex; align-items: center; gap: 3px; white-space: nowrap; }

/* Waiting / ended */
.mlm-wb-waiting { background: linear-gradient(135deg, #1e1b4b, #312e81); border-radius: 18px; padding: 60px 24px; text-align: center; color: #fff; }
.mlm-wb-waiting-inner { max-width: 600px; margin: 0 auto; }
.mlm-wb-waiting h2 { font-size: 28px; font-weight: 800; margin: 8px 0 12px; color: #fff; }
.mlm-wb-waiting p { color: #c7d2fe; font-size: 15px; }
.mlm-wb-waiting .mlm-wb-badge { background: rgba(255,255,255,.15); color: #fff; }
.mlm-wb-countdown-big { display: flex; gap: 14px; justify-content: center; margin: 28px 0; }
.mlm-wb-countdown-big .cd { background: rgba(255,255,255,.1); border-radius: 12px; padding: 16px 10px; min-width: 72px; }
.mlm-wb-countdown-big .cd span { display: block; font-size: 32px; font-weight: 800; line-height: 1; }
.mlm-wb-countdown-big .cd label { font-size: 11px; color: #a5b4fc; text-transform: uppercase; letter-spacing: .05em; }
.mlm-wb-gate { max-width: 560px; margin: 40px auto; background: #fff; border: 1px solid #e5e7eb; border-radius: 14px; padding: 40px; text-align: center; font-size: 16px; color: #6b7280; }

/* ── List ──────────────────────────────────────────────────── */
.mlm-wb-list { max-width: 1000px; margin: 0 auto; }
.mlm-wb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.mlm-wb-card { background: #fff; border: 1px solid #e5e7eb; border-radius: 14px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,.05); transition: transform .12s, box-shadow .12s; }
.mlm-wb-card:hover { transform: translateY(-3px); box-shadow: 0 8px 22px rgba(0,0,0,.1); }
.mlm-wb-card-cover { height: 150px; background-size: cover; background-position: center; }
.mlm-wb-card-body { padding: 18px; }
.mlm-wb-card-body h3 { font-size: 17px; font-weight: 700; margin: 0 0 8px; }
.mlm-wb-card-when { font-size: 13px; color: #6b7280; margin-bottom: 14px; }
.mlm-wb-empty { text-align: center; padding: 60px; color: #9ca3af; }

/* ── In-room shop (floating product panel) ─────────────────── */
.mlm-wb-shop { position: fixed; left: 16px; bottom: 16px; z-index: 80; width: 300px; max-width: calc(100vw - 32px); background: #fff; border-radius: 14px; box-shadow: 0 8px 30px rgba(0,0,0,.22); overflow: hidden; border: 1px solid #e5e7eb; }
.mlm-wb-shop-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; background: linear-gradient(135deg,#4f46e5,#7c3aed); color: #fff; font-weight: 700; font-size: 13px; }
.mlm-wb-shop-head > div { display: flex; align-items: center; gap: 8px; }
.mlm-wb-shop-timer { font-size: 12px; font-weight: 700; background: rgba(255,255,255,.2); padding: 2px 8px; border-radius: 6px; }
.mlm-wb-shop-min { background: rgba(255,255,255,.25); border: none; color: #fff; width: 22px; height: 22px; border-radius: 6px; cursor: pointer; font-size: 14px; line-height: 1; }
.mlm-wb-shop-body { padding: 12px; max-height: 360px; overflow-y: auto; }
.mlm-wb-prod { display: flex; gap: 10px; padding: 10px; border: 1px solid #eef2f7; border-radius: 10px; margin-bottom: 10px; }
.mlm-wb-prod:last-child { margin-bottom: 0; }
.mlm-wb-prod-img { width: 60px; height: 60px; border-radius: 8px; background-size: cover; background-position: center; flex-shrink: 0; }
.mlm-wb-prod-info { flex: 1; min-width: 0; }
.mlm-wb-prod-title { font-size: 13px; font-weight: 700; }
.mlm-wb-prod-price { font-size: 14px; color: #16a34a; font-weight: 800; margin: 2px 0 6px; }
.mlm-wb-prod-btn { background: #dc2626; color: #fff; border: none; border-radius: 8px; padding: 7px 14px; font-size: 12px; font-weight: 700; cursor: pointer; width: 100%; }
.mlm-wb-prod-btn:hover { background: #b91c1c; }
@media (max-width: 900px) { .mlm-wb-shop { width: 220px; left: 8px; bottom: 8px; } .mlm-wb-prod-img { width: 44px; height: 44px; } }

/* Checkout drawer */
.mlm-wb-drawer-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 95; }
.mlm-wb-drawer { position: fixed; top: 0; right: 0; bottom: 0; width: 440px; max-width: 100vw; background: #fff; z-index: 96; transform: translateX(100%); transition: transform .3s; display: flex; flex-direction: column; }
.mlm-wb-drawer.open { transform: translateX(0); }
.mlm-wb-drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid #e5e7eb; font-weight: 700; }
.mlm-wb-drawer-head button { background: none; border: none; font-size: 24px; cursor: pointer; color: #6b7280; }
.mlm-wb-drawer-body { flex: 1; overflow: auto; }
.mlm-wb-drawer-body iframe { width: 100%; height: 100%; border: 0; }

/* Poll */
.mlm-wb-poll { position: fixed; left: 50%; transform: translateX(-50%); bottom: 16px; z-index: 85; width: 340px; max-width: calc(100vw - 24px); background: #fff; border: 1px solid #e5e7eb; border-radius: 14px; box-shadow: 0 8px 30px rgba(0,0,0,.22); padding: 16px; }
@media (max-width: 900px) { .mlm-wb-poll { width: calc(100vw - 24px); bottom: 12px; } }
.mlm-wb-poll-q { font-weight: 700; font-size: 14px; margin-bottom: 10px; }
.mlm-wb-poll-opt { display: block; width: 100%; text-align: left; background: #f8fafc; border: 1px solid #e5e7eb; border-radius: 8px; padding: 9px 12px; margin-bottom: 6px; font-size: 13px; cursor: pointer; transition: background .1s; }
.mlm-wb-poll-opt:hover { background: #eef2ff; border-color: #4f46e5; }
.mlm-wb-poll-res { position: relative; background: #f1f5f9; border-radius: 8px; padding: 9px 12px; margin-bottom: 6px; font-size: 13px; overflow: hidden; }
.mlm-wb-poll-bar { position: absolute; inset: 0; background: #e0e7ff; z-index: 0; transition: width .5s; }
.mlm-wb-poll-res span, .mlm-wb-poll-res b { position: relative; z-index: 1; }
.mlm-wb-poll-res b { float: right; color: #4f46e5; }

/* Popup registration widget */
.mlm-wb-popup { position: fixed; inset: 0; background: rgba(17,24,39,.55); z-index: 100000; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mlm-wb-popup-inner { background: #fff; border-radius: 16px; padding: 28px; max-width: 420px; width: 100%; position: relative; box-shadow: 0 20px 60px rgba(0,0,0,.3); }
.mlm-wb-popup-close { position: absolute; top: 12px; right: 14px; background: none; border: none; font-size: 24px; cursor: pointer; color: #9ca3af; }
.mlm-wb-popup-title { font-size: 20px; font-weight: 800; margin: 0 0 6px; }
.mlm-wb-popup-when { font-size: 13px; color: #6b7280; margin-bottom: 16px; }

/* Certificate */
.mlm-wb-cert-wrap { max-width: 800px; margin: 0 auto; }
.mlm-wb-cert { background: #fff; padding: 16px; }
.mlm-wb-cert-border { border: 3px double #c9a227; border-radius: 8px; padding: 48px 40px; text-align: center; background: linear-gradient(#fffdf7,#fff); }
.mlm-wb-cert-top { font-size: 30px; font-weight: 800; letter-spacing: .15em; color: #1f2937; }
.mlm-wb-cert-sub { color: #6b7280; margin: 18px 0 6px; }
.mlm-wb-cert-name { font-size: 36px; font-weight: 800; color: #4f46e5; font-family: Georgia, serif; margin: 6px 0; }
.mlm-wb-cert-desc { color: #6b7280; margin: 12px 0 4px; }
.mlm-wb-cert-webinar { font-size: 20px; font-weight: 700; font-style: italic; }
.mlm-wb-cert-foot { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 48px; }
.mlm-wb-cert-foot .line { width: 160px; border-top: 1px solid #9ca3af; margin-bottom: 6px; }
.mlm-wb-cert-foot span { display: block; font-weight: 600; font-size: 14px; }
.mlm-wb-cert-foot small { color: #9ca3af; font-size: 11px; }
.mlm-wb-cert-foot .seal { font-size: 40px; color: #c9a227; }
