/* dashboard.css — لوحة المستخدم: شريط الترحيب وبطاقات الحالة/الإضافة، المؤقت، الآن يعرض، القوائم، الروابط، السجل، التذييل */

  /* ─── شريط الترحيب وحالة البث (لوحة المستخدم) ─── */
  .welcome-strip {
    display:flex; align-items:center; justify-content:space-between; gap:10px;
    margin-bottom:14px; flex-wrap:wrap;
  }
  .welcome-strip h2 { margin:0; font-size:18px; font-weight:900; }
  .status-card { padding-top:18px; padding-bottom:18px; }
  .hero-card {
    border:1px solid var(--border-strong, var(--border));
    box-shadow:0 24px 60px rgba(250,10,27,.10), 0 20px 60px rgba(0,0,0,.35);
  }
  .hero-title { margin:0 0 14px; font-size:15.5px; font-weight:800; color:var(--text); }

  /* ─── بانر الإشعار ─── */
  .notice-banner {
    background:linear-gradient(135deg,rgba(239,68,68,.16),rgba(249,115,22,.12));
    border:1px solid rgba(248,113,113,.4); border-radius:16px; padding:13px 16px;
    margin-bottom:16px; font-size:13.5px; line-height:1.7; animation:rise .4s both;
    width:100%; max-width:100%; box-sizing:border-box; height:auto; max-height:none;
    overflow:visible; white-space:pre-wrap; overflow-wrap:anywhere; word-break:break-word; unicode-bidi:plaintext;
  }

  /* ─── شارة الحالة ─── */
  .status-pill {
    display:inline-flex; align-items:center; gap:8px; padding:7px 15px; border-radius:999px;
    font-size:13px; font-weight:700; margin-bottom:14px; border:1px solid var(--border);
    background:rgba(0,0,0,.25);
  }
  .status-pill .dot { width:9px; height:9px; border-radius:50%; }
  .status-pill.pending .dot { background:var(--warn); box-shadow:0 0 10px var(--warn); animation:blink 1s infinite; }
  .status-pill.ready .dot { background:var(--ok); box-shadow:0 0 10px var(--ok); }
  .status-pill.error .dot { background:var(--err); box-shadow:0 0 10px var(--err); }
  @keyframes blink { 50% { opacity:.35; } }

  .status-box {
    border-radius:16px; padding:15px 17px; margin-bottom:14px; font-size:14px; line-height:1.8;
    background:rgba(0,0,0,.28); border:1px solid var(--border);
  }
  .status-box.pending { border-color:rgba(251,191,36,.5); }
  .status-box.ready { border-color:rgba(52,211,153,.5); }
  .status-box.error { border-color:rgba(248,113,113,.5); }

  /* ─── مؤقت التقدم ─── */
  .timer { background:rgba(0,0,0,.28); border:1px solid var(--border); border-radius:16px; padding:15px 17px; margin-bottom:14px; }
  .timer-bar { height:9px; background:rgba(255,255,255,.07); border-radius:20px; overflow:hidden; margin-bottom:9px; position:relative; }
  .timer-fill {
    height:100%; width:0%; border-radius:20px; background:var(--grad);
    transition:width 1s linear; position:relative; overflow:hidden;
  }
  .timer-fill::after {
    content:""; position:absolute; inset:0;
    background:linear-gradient(90deg,transparent,rgba(255,255,255,.45),transparent);
    animation:shimmer 1.4s infinite;
  }
  @keyframes shimmer { from { transform:translateX(100%);} to { transform:translateX(-100%);} }
  .timer-text { font-size:13px; color:var(--muted); text-align:center; }

  /* ─── الآن يعرض ─── */
  .now-box {
    background:linear-gradient(135deg,rgba(52,211,153,.12),rgba(250,10,27,.08));
    border:1px solid rgba(52,211,153,.35); border-radius:18px; padding:17px; margin-bottom:14px;
    position:relative; overflow:hidden;
  }
  .now-box h3 { margin:0 0 8px; font-size:13px; color:var(--ok); font-weight:800; display:flex; align-items:center; gap:8px; }
  .eq { display:inline-flex; gap:3px; align-items:flex-end; height:14px; }
  .eq i { width:3.5px; background:var(--ok); border-radius:2px; animation:eq 1s infinite ease-in-out; }
  .eq i:nth-child(1){ height:60%; animation-delay:0s; }
  .eq i:nth-child(2){ height:100%; animation-delay:.2s; }
  .eq i:nth-child(3){ height:45%; animation-delay:.4s; }
  .eq i:nth-child(4){ height:80%; animation-delay:.6s; }
  @keyframes eq { 50% { transform:scaleY(.4);} }
  #nowTitle { font-size:16px; font-weight:800; line-height:1.6; margin-bottom:5px; }
  .now-sub { font-size:12.5px; color:var(--muted); }

  /* ─── قوائم (التشغيل + السجل) ─── */
  .list-box { background:rgba(0,0,0,.28); border:1px solid var(--border); border-radius:18px; padding:17px; margin-bottom:14px; }
  .list-box > h3 { margin:0 0 12px; font-size:14.5px; font-weight:800; display:flex; justify-content:space-between; align-items:center; }
  .list-box > h3 .muted { font-weight:400; font-size:12px; }

  .q-item {
    display:flex; align-items:center; gap:10px; padding:11px 12px; border-radius:13px;
    margin-bottom:7px; background:rgba(255,255,255,.04); border:1px solid transparent;
    font-size:13.5px; transition:.2s;
  }
  .q-item:hover { background:rgba(255,255,255,.07); }
  .q-item.current {
    background:linear-gradient(135deg,rgba(52,211,153,.14),rgba(52,211,153,.05));
    border-color:rgba(52,211,153,.45);
  }
  .q-num {
    min-width:26px; height:26px; border-radius:9px; background:rgba(0,0,0,.35); color:var(--muted);
    display:flex; align-items:center; justify-content:center; font-size:12px; font-weight:800; flex-shrink:0;
  }
  .q-item.current .q-num { background:var(--ok); color:#052e16; }
  .q-item .t { flex:1; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
  .q-item .live-tag {
    font-size:10px; font-weight:800; color:var(--ok); background:rgba(52,211,153,.15);
    padding:3px 8px; border-radius:999px; flex-shrink:0;
  }
  .q-item button {
    padding:6px 11px; font-size:12px; border:none; border-radius:9px; cursor:pointer; flex-shrink:0;
    font-family:inherit; font-weight:700; transition:.15s;
  }
  .q-play { background:rgba(250,10,27,.18); color:var(--accent); }
  .q-play:hover { background:var(--accent); color:#fff; }
  .q-del { background:rgba(248,113,113,.13); color:var(--err); }
  .q-del:hover { background:var(--err); color:#fff; }

  .controls-row { display:flex; gap:8px; margin-top:11px; }
  .controls-row button {
    flex:1; padding:11px; border:none; border-radius:12px; cursor:pointer;
    font-family:inherit; font-weight:800; font-size:13.5px; transition:.2s;
    display:flex; align-items:center; justify-content:center; gap:6px;
  }
  .btn-next { background:linear-gradient(135deg,#fbbf24,#f59e0b); color:#422006; box-shadow:0 6px 18px rgba(251,191,36,.25); }
  .btn-next:hover { transform:translateY(-2px); }
  .btn-soft { background:rgba(255,255,255,.07); color:var(--muted); border:1px solid var(--border); }
  .btn-soft:hover { color:var(--text); border-color:var(--border-strong); }

  /* ─── تنبيه الحقل ─── */
  .warn-box {
    background:linear-gradient(135deg,rgba(251,191,36,.13),rgba(251,191,36,.05));
    border:1px solid rgba(251,191,36,.4); color:#fde68a; border-radius:14px;
    padding:12px 15px; margin-bottom:14px; font-size:13px; line-height:1.8;
  }

  /* ─── نموذج الإضافة ─── */
  .add-row { display:flex; gap:9px; }
  .add-row select { flex:1; }
  .add-row .btn { flex:1.6; padding:13px; }

  /* ─── صناديق الروابط ─── */
  .links-box { background:rgba(0,0,0,.28); border:1px solid var(--border); border-radius:18px; padding:17px; margin-bottom:14px; }
  .links-box h3 { margin:0 0 12px; font-size:14.5px; font-weight:800; display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
  .links-box.cartv {
    background:linear-gradient(135deg,rgba(239,68,68,.13),rgba(249,115,22,.07));
    border:1.5px solid rgba(248,113,113,.5);
    box-shadow:0 8px 30px rgba(239,68,68,.12);
  }
  .links-box.cartv h3 { color:#fca5a5; }
  .url-badge {
    font-size:10.5px; font-weight:800; letter-spacing:.3px; padding:3px 9px; border-radius:999px;
    text-transform:uppercase;
  }
  .url-badge.permanent { background:rgba(248,113,113,.22); color:#fca5a5; border:1px solid rgba(248,113,113,.4); }
  .url-badge.temporary { background:rgba(255,255,255,.08); color:var(--muted); border:1px solid var(--border); }
  .link-row { display:flex; gap:8px; margin-bottom:9px; align-items:center; }
  .link-row.permanent input {
    border-color:rgba(248,113,113,.4); background:rgba(0,0,0,.35);
    font-weight:700; letter-spacing:.2px;
  }
  .link-row input { margin:0; direction:ltr; text-align:left; font-size:12px; padding:12px; }
  .link-row button {
    padding:11px 16px; border:none; border-radius:11px; cursor:pointer; white-space:nowrap;
    font-family:inherit; font-weight:800; font-size:13px; transition:.15s; flex-shrink:0;
  }
  .copy-btn { background:rgba(255,255,255,.08); color:var(--text); border:1px solid var(--border); }
  .copy-btn:hover { background:rgba(255,255,255,.15); }
  .copy-btn.red { background:var(--grad-red); color:#fff; box-shadow:0 6px 18px rgba(239,68,68,.35); border:none; }
  .copy-btn.red:hover { transform:translateY(-2px); box-shadow:0 10px 24px rgba(239,68,68,.5); }
  .hint { font-size:12px; color:var(--muted); line-height:1.7; }
  .cartv-steps { display:flex; flex-direction:column; gap:6px; margin:2px 0 12px; }
  .cartv-steps .step { display:flex; align-items:center; gap:8px; font-size:12px; color:var(--muted); }
  .cartv-steps .step b { color:var(--text); font-weight:700; }
  .cartv-steps .step .num {
    flex-shrink:0; width:18px; height:18px; border-radius:50%; background:rgba(248,113,113,.2);
    color:#fca5a5; font-size:10.5px; font-weight:800; display:flex; align-items:center; justify-content:center;
  }

  /* ─── سجل المشاهدة ─── */
  .hist-item { padding:10px 12px; border-radius:12px; margin-bottom:7px; background:rgba(255,255,255,.04); font-size:12.5px; position:relative; }
  .hist-item .row1 { display:flex; align-items:center; gap:8px; }
  .hist-item .t { flex:1; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-weight:500; display:flex; align-items:center; gap:6px; }
  .hist-date { font-size:11px; color:var(--muted); flex-shrink:0; }
  .hist-menu-btn {
    flex-shrink:0; width:28px; height:28px; border-radius:8px; border:none; background:transparent;
    color:var(--muted); cursor:pointer; display:flex; align-items:center; justify-content:center; font-size:14px;
  }
  .hist-menu-btn:hover { background:rgba(255,255,255,.1); color:var(--text); }
  .hist-menu {
    position:absolute; inset-inline-end:44px; top:6px; z-index:5; min-width:200px; /* بجانب زر ⋮ لا فوقه: يبقى عمود الأزرار مكشوفاً فيُفتح خيار عنصر آخر بلمسة واحدة */
    background:var(--card-solid, #121a2e); border:1px solid var(--border-strong, var(--border));
    border-radius:12px; box-shadow:0 14px 34px rgba(0,0,0,.4); padding:6px; display:none;
  }
  .hist-menu.open { display:block; }
  .hist-menu button {
    width:100%; text-align:start; padding:9px 11px; font-size:12.5px; border:none; background:transparent;
    color:var(--text); border-radius:8px; cursor:pointer; font-family:inherit; font-weight:600;
    display:flex; align-items:center; gap:8px;
  }
  .hist-menu button:hover { background:rgba(255,255,255,.08); }
  .hist-menu button.direct { color:var(--ok); }
  .hist-date { font-size:11px; color:var(--muted); margin-right:auto; }

  /* ─── التذييل ─── */
  .footer { text-align:center; margin-top:28px; color:var(--muted); font-size:13px; font-weight:500; }
  .footer .heart { color:var(--err); display:inline-block; animation:beat 1.3s infinite; }
  .footer a:hover { color:var(--accent) !important; border-bottom-color:var(--accent) !important; }
  @keyframes beat { 0%,100%{transform:scale(1)} 25%{transform:scale(1.3)} 40%{transform:scale(1)} }
