/* ============================================
   فونت یکدست و ریست کلی
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #0a0a1a 0%, #0f0f2e 25%, #1a0a2e 50%, #0d0d24 75%, #0a0a1a 100%);
    background-attachment: fixed;
    color: #e2e8f0;
    font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
}

/* ===== انیمیشن ذرات متحرک ===== */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background: 
        radial-gradient(circle at 20% 30%, rgba(102, 126, 234, 0.08), transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(139, 92, 246, 0.08), transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(56, 189, 248, 0.05), transparent 50%);
    pointer-events: none;
    z-index: 0;
    animation: auroraMove 20s infinite alternate ease-in-out;
}

@keyframes auroraMove {
    0% { opacity: 0.6; transform: translate(0, 0) scale(1); }
    50% { opacity: 1; transform: translate(40px, -30px) scale(1.1); }
    100% { opacity: 0.6; transform: translate(-20px, 20px) scale(0.95); }
}

/* ============================================
   کانتینر اصلی - شیشه‌ای
   ============================================ */
.container {
    max-width: 1400px;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 20px;
    background: rgba(15, 15, 35, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
    position: relative;
    z-index: 1;
}

.main-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ============================================
   هدر - شیشه‌ای
   ============================================ */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    flex-wrap: wrap;
    gap: 10px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.logo {
    font-size: 20px;
    font-weight: 700;
    color: #e2e8f0;
    font-family: 'Vazirmatn', sans-serif;
    text-shadow: 0 0 20px rgba(102, 126, 234, 0.3);
}

.live-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 0, 51, 0.15);
    padding: 6px 16px;
    border-radius: 50px;
    border: 1px solid rgba(255, 0, 51, 0.3);
    animation: pulse-border 2s infinite;
    font-family: 'Vazirmatn', sans-serif;
}

.live-dot {
    width: 10px;
    height: 10px;
    background: #ff0033;
    border-radius: 50%;
    animation: blink 1s infinite;
    box-shadow: 0 0 12px rgba(255, 0, 51, 0.6);
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.2; }
}

@keyframes pulse-border {
    0%, 100% { border-color: rgba(255, 0, 51, 0.3); box-shadow: 0 0 8px rgba(255, 0, 51, 0.1); }
    50% { border-color: rgba(255, 0, 51, 0.7); box-shadow: 0 0 20px rgba(255, 0, 51, 0.3); }
}

.live-time {
    color: #cbd5e0;
    font-size: 14px;
    font-variant-numeric: tabular-nums;
    font-family: 'Vazirmatn', sans-serif;
}

.viewer-count {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 14px;
    font-family: 'Vazirmatn', sans-serif;
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: #cbd5e0;
}

.viewer-count .count {
    color: #f87171;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    font-family: 'Vazirmatn', sans-serif;
}

/* ============================================
   ویدیو
   ============================================ */
.video-wrapper {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    background: #000;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    cursor: pointer;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

/* ============================================
   پایان وبینار
   ============================================ */
#endedContainer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(15, 15, 35, 0.95) 0%, rgba(30, 20, 50, 0.95) 100%);
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 5;
    padding: 20px;
    backdrop-filter: blur(10px);
}

#endedContainer #endedLogo {
    max-width: 60%;
    max-height: 50%;
    object-fit: contain;
    margin-bottom: 20px;
    display: block;
    filter: drop-shadow(0 0 20px rgba(102, 126, 234, 0.3));
}

#endedContainer #endedTextAlways {
    text-align: center;
    color: #e2e8f0;
    margin-top: 10px;
}

#endedContainer #endedTextAlways h2 {
    font-size: 28px;
    font-weight: 700;
    color: #f87171;
    margin-bottom: 8px;
}

#endedContainer #endedTextAlways p {
    font-size: 16px;
    color: #94a3b8;
}

/* ============================================
   دکمه پلی
   ============================================ */
#playBtn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60%;
    max-width: 300px;
    max-height: 300px;
    aspect-ratio: 1 / 1;
    background: rgba(102, 126, 234, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: #fff;
    font-size: clamp(50px, 12vw, 100px);
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
    box-shadow: 0 0 60px rgba(102, 126, 234, 0.2);
    transition: all 0.3s ease;
    opacity: 0;
    pointer-events: none;
}

.video-wrapper.paused #playBtn {
    opacity: 1;
    pointer-events: auto;
}

.video-wrapper.playing #playBtn {
    opacity: 0;
    pointer-events: none;
}

#playBtn:hover {
    background: rgba(102, 126, 234, 0.35);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%) scale(1.05);
    box-shadow: 0 0 80px rgba(102, 126, 234, 0.4);
}

#playBtn::before {
    content: '';
    position: absolute;
    inset: -12px;
    border-radius: 50%;
    border: 2px solid rgba(102, 126, 234, 0.2);
    animation: ripple-play 2.5s infinite;
}

@keyframes ripple-play {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.4); opacity: 0; }
}

/* ============================================
   پاپ‌آپ خوش‌آمدگویی
   ============================================ */
.welcome-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(20px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.welcome-content {
    background: rgba(20, 20, 45, 0.8);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 40px 50px;
    max-width: 450px;
    width: 90%;
    text-align: center;
    box-shadow: 
        0 40px 80px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.welcome-icon {
    font-size: 64px;
    margin-bottom: 16px;
}

.welcome-content h2 {
    font-size: 26px;
    font-weight: 700;
    color: #f1f5f9;
    margin-bottom: 8px;
}

.welcome-content p {
    font-size: 14px;
    color: #94a3b8;
    margin-bottom: 24px;
}

.welcome-content input {
    width: 100%;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #e2e8f0;
    font-size: 16px;
    font-family: 'Vazirmatn', sans-serif;
    outline: none;
    transition: all 0.3s ease;
    margin-bottom: 20px;
    text-align: center;
}

.welcome-content input:focus {
    border-color: rgba(102, 126, 234, 0.6);
    box-shadow: 0 0 20px rgba(102, 126, 234, 0.15);
}

.welcome-content input::placeholder {
    color: #64748b;
}

.welcome-buttons {
    display: flex;
    gap: 12px;
}

.welcome-buttons button {
    flex: 1;
    padding: 14px 20px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Vazirmatn', sans-serif;
}

.btn-guest {
    background: rgba(255, 255, 255, 0.08);
    color: #cbd5e0;
}

.btn-guest:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: scale(1.02);
}

.btn-enter {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-enter:hover {
    background: linear-gradient(135deg, #5a67d8, #6b46a1);
    transform: scale(1.02);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
}

/* ============================================
   اطلاعات وبینار
   ============================================ */
.info-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    flex-wrap: wrap;
    gap: 10px;
    font-family: 'Vazirmatn', sans-serif;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.info-bar h3 {
    font-weight: 600;
    font-size: 18px;
    color: #f1f5f9;
    font-family: 'Vazirmatn', sans-serif;
}

.info-bar .sub {
    color: #94a3b8;
    font-size: 13px;
    font-family: 'Vazirmatn', sans-serif;
}

.stats {
    display: flex;
    gap: 20px;
}

.stats .item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #cbd5e0;
    font-size: 14px;
    font-family: 'Vazirmatn', sans-serif;
}

.message-box {
    background: rgba(255, 0, 51, 0.1);
    border: 2px solid rgba(255, 0, 51, 0.3);
    border-radius: 16px;
    padding: 40px 20px;
    text-align: center;
    font-size: 28px;
    color: #f87171;
    display: none;
    font-family: 'Vazirmatn', sans-serif;
    backdrop-filter: blur(12px);
}

.message-box span {
    display: block;
    font-size: 18px;
    color: #f87171;
    margin-top: 10px;
    font-family: 'Vazirmatn', sans-serif;
}

.ended-message {
    text-align: center;
    padding: 40px 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    display: none;
    font-family: 'Vazirmatn', sans-serif;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.ended-message h2 {
    font-size: 28px;
    font-weight: 300;
    color: #64748b;
    font-family: 'Vazirmatn', sans-serif;
}

/* ============================================
   چت - شیشه‌ای
   ============================================ */
.chat-section {
    background: rgba(15, 15, 35, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 500px;
    font-family: 'Vazirmatn', sans-serif;
    position: relative;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.chat-header {
    padding: 14px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: 'Vazirmatn', sans-serif;
}

.chat-header h4 {
    font-size: 16px;
    font-weight: 600;
    color: #e2e8f0;
    font-family: 'Vazirmatn', sans-serif;
}

.chat-header .online {
    font-size: 12px;
    color: #4ade80;
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: 'Vazirmatn', sans-serif;
}

.chat-header .online::before {
    content: '';
    width: 8px;
    height: 8px;
    background: #4ade80;
    border-radius: 50%;
    display: inline-block;
    animation: blink 1.5s infinite;
    box-shadow: 0 0 8px rgba(74, 222, 128, 0.4);
}

.chat-messages {
    flex: 1;
    padding: 16px 20px;
    overflow-y: auto;
    max-height: 500px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-family: 'Vazirmatn', sans-serif;
}

.chat-messages::-webkit-scrollbar {
    width: 4px;
}

.chat-messages::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
}

.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.chat-message {
    display: flex;
    flex-direction: column;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    animation: fadeInUp 0.4s ease;
    border-right: 3px solid rgba(255, 255, 255, 0.08);
    font-family: 'Vazirmatn', sans-serif;
}

.chat-message.system {
    border-right-color: rgba(251, 191, 36, 0.6);
    background: rgba(251, 191, 36, 0.08);
}

.chat-message .user {
    font-size: 12px;
    font-weight: 600;
    color: #fbbf24;
    margin-bottom: 2px;
    font-family: 'Vazirmatn', sans-serif;
}

.chat-message .text {
    font-size: 14px;
    line-height: 1.5;
    color: #e2e8f0;
    word-break: break-word;
    font-family: 'Vazirmatn', sans-serif;
}

.chat-message .time {
    font-size: 10px;
    color: #64748b;
    margin-top: 4px;
    align-self: flex-end;
    font-family: 'Vazirmatn', sans-serif;
}

.chat-message.deleted {
    opacity: 0.4;
    border-right-color: rgba(248, 113, 113, 0.6);
    background: rgba(248, 113, 113, 0.05);
}

.chat-message.deleted .text {
    font-style: italic;
    color: #64748b;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   پیام پین شده
   ============================================ */
.pinned-message {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    background: rgba(251, 191, 36, 0.08);
    border-right: 4px solid rgba(251, 191, 36, 0.6);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 13px;
    color: #e2e8f0;
    font-family: 'Vazirmatn', sans-serif;
}

.pin-icon {
    font-size: 18px;
    color: #fbbf24;
    flex-shrink: 0;
}

.pin-text {
    flex: 1;
    word-break: break-word;
}

/* ============================================
   تشخیص ادمین در چت
   ============================================ */
.chat-message.admin-message {
    border-right-color: rgba(248, 113, 113, 0.6);
    background: rgba(248, 113, 113, 0.08);
}

.chat-message.admin-message .user {
    color: #f87171;
    font-weight: 700;
}

/* ============================================
   پیام حذف شده
   ============================================ */
.chat-message.deleted {
    display: none !important;
}

/* ============================================
   ورودی چت
   ============================================ */
.chat-input {
    padding: 14px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    gap: 10px;
    align-items: center;
    font-family: 'Vazirmatn', sans-serif;
    position: relative;
}

.input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    transition: all 0.3s ease;
    min-width: 0;
}

.input-wrapper:focus-within {
    border-color: rgba(102, 126, 234, 0.6);
    box-shadow: 0 0 15px rgba(102, 126, 234, 0.15);
}

.emoji-btn {
    background: transparent;
    border: none;
    color: #64748b;
    font-size: 22px;
    padding: 8px 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: 12px 0 0 12px;
    flex-shrink: 0;
}

.emoji-btn:hover {
    color: #e2e8f0;
    background: rgba(255, 255, 255, 0.05);
}

.input-wrapper input {
    flex: 1;
    background: transparent;
    border: none;
    padding: 10px 12px 10px 0;
    color: #e2e8f0;
    font-size: 14px;
    outline: none;
    font-family: 'Vazirmatn', sans-serif;
    min-width: 0;
    width: 100%;
}

.input-wrapper input::placeholder {
    color: #64748b;
}

.chat-input button {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    font-family: 'Vazirmatn', sans-serif;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    flex-shrink: 0;
}

.chat-input button:hover {
    background: linear-gradient(135deg, #5a67d8, #6b46a1);
    transform: scale(1.02);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
}

.chat-input button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    transform: none;
}

/* ============================================
   باکس شکلک‌ها
   ============================================ */
.emoji-box {
    position: absolute;
    bottom: 75px;
    right: 20px;
    background: rgba(20, 20, 45, 0.9);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 12px 16px;
    display: none;
    flex-wrap: wrap;
    gap: 6px;
    max-width: 320px;
    z-index: 20;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.emoji-item {
    font-size: 24px;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 8px;
    transition: all 0.2s ease;
    user-select: none;
}

.emoji-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.2);
}

/* ============================================
   جدول پخش - شیشه‌ای تاریک
   ============================================ */
.schedule-wrapper {
    margin-top: 20px;
    position: relative;
    z-index: 1;
}

.schedule-container {
    background: rgba(15, 15, 35, 0.5);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-radius: 24px;
    padding: 24px 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.03);
    position: relative;
    overflow: hidden;
}

.schedule-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 40%, rgba(102, 126, 234, 0.06), transparent 60%);
    animation: auroraMove 15s infinite alternate ease-in-out;
    pointer-events: none;
}

.schedule-title {
    font-size: 22px;
    font-weight: 700;
    color: #f1f5f9;
    text-align: center;
    margin-bottom: 20px;
    font-family: 'Vazirmatn', sans-serif;
    position: relative;
    z-index: 1;
}

.schedule-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    position: relative;
    z-index: 1;
}

@media (min-width: 768px) {
    .schedule-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .schedule-container {
        padding: 30px 28px;
    }
}

/* ===== کارت هر وبینار ===== */
.schedule-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    padding: 18px 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.schedule-card:hover {
    transform: translateY(-6px) scale(1.01);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
    border-color: rgba(102, 126, 234, 0.3);
    background: rgba(255, 255, 255, 0.05);
}

.schedule-card-live {
    border-color: rgba(220, 38, 38, 0.4);
    background: rgba(220, 38, 38, 0.08);
    box-shadow: 0 4px 24px rgba(220, 38, 38, 0.2);
    animation: pulse-card 2s infinite;
}

@keyframes pulse-card {
    0%, 100% { box-shadow: 0 4px 24px rgba(220, 38, 38, 0.2); }
    50% { box-shadow: 0 4px 40px rgba(220, 38, 38, 0.4); }
}

.schedule-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.schedule-card-badge {
    font-size: 12px;
    color: #818cf8;
    font-weight: 500;
    font-family: 'Vazirmatn', sans-serif;
}

.schedule-card-title {
    font-size: 18px;
    font-weight: 700;
    color: #f1f5f9;
    margin: 0;
    font-family: 'Vazirmatn', sans-serif;
}

@media (max-width: 480px) {
    .schedule-card-title {
        font-size: 15px;
    }
}

.schedule-card-live-badge {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: #fff;
    font-size: 11px;
    padding: 3px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-family: 'Vazirmatn', sans-serif;
    white-space: nowrap;
    animation: pulse-live 1.5s infinite;
    box-shadow: 0 0 15px rgba(220, 38, 38, 0.4);
}

@keyframes pulse-live {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(0.95); }
}

.schedule-card-date {
    font-size: 14px;
    color: #94a3b8;
    font-family: 'Vazirmatn', sans-serif;
    margin-bottom: 12px;
}

.schedule-card-live-status {
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.15), rgba(220, 38, 38, 0.05));
    border-radius: 10px;
    padding: 10px;
    text-align: center;
    color: #f87171;
    font-weight: 600;
    font-size: 14px;
    font-family: 'Vazirmatn', sans-serif;
    border: 1px solid rgba(220, 38, 38, 0.2);
    animation: pulse-live-status 2s infinite;
}

@keyframes pulse-live-status {
    0%, 100% { background: linear-gradient(135deg, rgba(220, 38, 38, 0.15), rgba(220, 38, 38, 0.05)); }
    50% { background: linear-gradient(135deg, rgba(220, 38, 38, 0.25), rgba(220, 38, 38, 0.1)); }
}

/* ===== تایمر ===== */
.schedule-timer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 10px;
}

.schedule-timer-box {
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 12px;
    padding: 10px 6px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.schedule-timer-box:hover {
    transform: translateY(-3px) scale(1.05);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    border-color: rgba(102, 126, 234, 0.3);
}

.schedule-timer-box-seconds {
    background: linear-gradient(145deg, rgba(102, 126, 234, 0.2), rgba(102, 126, 234, 0.08));
    border-color: rgba(102, 126, 234, 0.3);
}

.schedule-timer-number {
    font-size: 24px;
    font-weight: 700;
    color: #f1f5f9;
    font-family: 'Vazirmatn', sans-serif;
    line-height: 1.2;
    transition: all 0.3s ease;
}

.schedule-timer-box:hover .schedule-timer-number {
    color: #818cf8;
}

@media (min-width: 768px) {
    .schedule-timer-number {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .schedule-timer-number {
        font-size: 18px;
    }
}

.schedule-timer-label {
    font-size: 10px;
    color: #64748b;
    font-family: 'Vazirmatn', sans-serif;
    margin-top: 2px;
}

.schedule-timer-hint {
    text-align: center;
    font-size: 11px;
    color: #475569;
    margin-top: 8px;
    font-family: 'Vazirmatn', sans-serif;
}

/* ===== حالت خالی ===== */
.schedule-empty {
    text-align: center;
    padding: 40px 20px;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.schedule-empty-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

.schedule-empty-text {
    font-size: 18px;
    color: #94a3b8;
    font-weight: 600;
    font-family: 'Vazirmatn', sans-serif;
}

.schedule-empty-sub {
    font-size: 14px;
    color: #64748b;
    font-family: 'Vazirmatn', sans-serif;
    margin-top: 4px;
}

/* ===== مخفی کردن کامل باکس ویدیو ===== */
.video-wrapper.hidden {
    display: none !important;
    height: 0 !important;
    padding: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
}

/* ============================================
   ریسپانسیو
   ============================================ */
@media (max-width: 1024px) {
    .container {
        grid-template-columns: 1fr;
        padding: 16px;
        gap: 16px;
    }
    .chat-section {
        min-height: 350px;
    }
    .chat-messages {
        max-height: 300px;
    }
}

@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    .container {
        padding: 10px;
        gap: 12px;
        border-radius: 16px;
    }
    .header {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        padding: 10px 14px;
    }
    .logo {
        text-align: center;
        font-size: 17px;
    }
    .live-badge {
        justify-content: center;
        padding: 5px 12px;
    }
    .viewer-count {
        justify-content: center;
        padding: 5px 12px;
        font-size: 13px;
    }
    #playBtn {
        font-size: clamp(35px, 10vw, 70px);
        max-width: 200px;
        max-height: 200px;
    }
    .info-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        padding: 10px 14px;
    }
    .info-bar h3 {
        font-size: 16px;
    }
    .stats {
        justify-content: space-around;
        gap: 10px;
        flex-wrap: wrap;
    }
    .stats .item {
        font-size: 13px;
    }
    .chat-section {
        min-height: 300px;
    }
    .chat-messages {
        max-height: 250px;
        padding: 12px 14px;
    }
    .chat-input {
        padding: 10px 14px;
        flex-direction: row;
        gap: 8px;
        flex-wrap: nowrap;
    }
    .input-wrapper {
        width: auto;
        flex: 1;
        min-width: 0;
    }
    .chat-input button {
        width: auto;
        padding: 10px 16px;
        font-size: 13px;
        flex-shrink: 0;
    }
    .input-wrapper input {
        font-size: 13px;
        padding: 8px 10px 8px 0;
    }
    .emoji-btn {
        font-size: 18px;
        padding: 6px 10px;
    }
    .message-box {
        font-size: 20px;
        padding: 30px 16px;
    }
    .message-box span {
        font-size: 15px;
    }
    #endedContainer #endedLogo {
        max-width: 80%;
        max-height: 40%;
    }
    #endedContainer #endedTextAlways h2 {
        font-size: 22px;
    }
    #endedContainer #endedTextAlways p {
        font-size: 14px;
    }
    .welcome-content {
        padding: 30px 24px;
    }
    .welcome-buttons {
        flex-direction: column;
    }
    .emoji-box {
        max-width: 280px;
        right: 10px;
        bottom: 90px;
    }
    .emoji-item {
        font-size: 20px;
        padding: 4px 6px;
    }
}

@media (max-width: 400px) {
    .container {
        padding: 6px;
    }
    .chat-messages {
        max-height: 200px;
        padding: 10px 12px;
    }
    .chat-message {
        padding: 6px 12px;
    }
    .chat-message .text {
        font-size: 13px;
    }
    #playBtn {
        font-size: clamp(25px, 8vw, 50px);
        max-width: 150px;
        max-height: 150px;
    }
    #endedContainer #endedLogo {
        max-width: 90%;
        max-height: 35%;
    }
    #endedContainer #endedTextAlways h2 {
        font-size: 18px;
    }
    #endedContainer #endedTextAlways p {
        font-size: 12px;
    }
    .emoji-box {
        max-width: 240px;
    }
    .emoji-item {
        font-size: 18px;
        padding: 3px 5px;
    }
    .chat-input {
        padding: 8px 10px;
        gap: 6px;
    }
    .chat-input button {
        padding: 8px 12px;
        font-size: 12px;
        border-radius: 8px;
    }
    .input-wrapper input {
        font-size: 12px;
        padding: 6px 8px 6px 0;
    }
    .emoji-btn {
        font-size: 16px;
        padding: 4px 8px;
    }
}

/* ============================================
   مخفی کردن کامل باکس ویدیو و اینفو بار
   ============================================ */
.video-wrapper.hidden {
    display: none !important;
}

.info-bar.hidden {
    display: none !important;
}



/* ============================================
   رفع مشکل وسط‌چین شدن ویجت شمارش معکوس
   ============================================ */
#countdownWidget {
    display: flex;
    justify-content: center;
    width: 100%;
}

#countdownWidget .countdown-widget-container {
    max-width: 760px;
    width: 100%;
    margin: 0 auto;
}

/* اطمینان از اینکه در دسکتاپ وسط باشد */
@media (min-width: 1025px) {
    #countdownWidget {
        justify-content: center;
    }
    
    #countdownWidget .countdown-widget-container {
        margin-left: auto !important;
        margin-right: auto !important;
    }
}


/* ============================================
   ویجت شمارش معکوس - مخفی در حالت پخش
   ============================================ */
#countdownWidget {
    display: block;
    width: 100%;
}

#countdownWidget.hidden {
    display: none !important;
}