/* ============ Maqta — style ============ */
:root {
  --bg: #0b0b0d;
  --bg-2: #141418;
  --bg-3: #1d1d22;
  --bg-4: #27272e;
  --line: #2a2a31;
  --txt: #f2f2f4;
  --txt-2: #a9a9b3;
  --txt-3: #73737d;
  --accent: #ff3d5a;
  --accent-2: #ff6b3d;
  --cyan: #2ee6e0;
  --grad: linear-gradient(135deg, var(--accent), var(--accent-2));
  --r: 12px;
  --top: 60px;
  --side: 232px;
  --side-mini: 76px;
  --bottom: 60px;
  --font: 'IBM Plex Sans Arabic', system-ui, -apple-system, 'Segoe UI', Tahoma, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--txt);
  font: 15px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
input, textarea, select { font: inherit; color: inherit; }
img, video { display: block; max-width: 100%; }
hr { border: 0; border-top: 1px solid var(--line); margin: 10px 0; }
.ic { flex: none; }
.muted { color: var(--txt-2); }
.small { font-size: 13px; }
.center { text-align: center; }
[hidden] { display: none !important; }

/* ============ Buttons ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 40px; padding: 0 18px; border-radius: 999px; font-weight: 600; font-size: 14px;
  transition: background .15s, transform .1s, opacity .15s; white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-primary { background: var(--grad); color: #fff; }
.btn-primary:hover:not(:disabled) { filter: brightness(1.08); }
.btn-white { background: #fff; color: #000; }
.btn-white:hover { background: #ddd; }
.btn-ghost { background: var(--bg-3); }
.btn-ghost:hover { background: var(--bg-4); }
.btn-outline { border: 1px solid var(--line); color: var(--cyan); }
.btn-outline:hover { background: rgba(46, 230, 224, .08); }
.btn-sm { height: 34px; padding: 0 14px; font-size: 13px; }
.btn-block { width: 100%; height: 46px; font-size: 15px; }
.icon-btn {
  width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; position: relative;
  transition: background .15s;
}
.icon-btn:hover { background: var(--bg-3); }
.pill {
  display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 16px;
  border-radius: 999px; background: var(--bg-3); font-weight: 600; font-size: 14px; transition: background .15s;
}
.pill:hover { background: var(--bg-4); }
.pill.on { color: var(--accent); }
.pill.on .ic path { fill: currentColor; }
.pill-danger:hover { background: #3a1820; color: #ff8a9b; }
.pop { animation: pop .35s; }
@keyframes pop { 40% { transform: scale(1.18); } }

/* ============ Avatar ============ */
.av { border-radius: 50%; object-fit: cover; flex: none; background: var(--bg-3); }
.av-letter { display: inline-grid; place-items: center; color: #fff; font-weight: 700; line-height: 1; }

/* ============ Topbar ============ */
.topbar {
  position: fixed; inset: 0 0 auto 0; height: var(--top); z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 0 16px; background: rgba(11, 11, 13, .92); backdrop-filter: blur(14px);
}
.tb-start, .tb-end { display: flex; align-items: center; gap: 8px; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 20px; letter-spacing: -.3px; }
.logo-mark {
  width: 34px; height: 26px; border-radius: 8px; background: var(--grad); color: #fff;
  display: grid; place-items: center; box-shadow: -3px 0 0 var(--cyan);
}
.search {
  flex: 1; max-width: 600px; display: flex; height: 42px;
  border: 1px solid var(--line); border-radius: 999px; overflow: hidden; background: var(--bg-2);
}
.search:focus-within { border-color: #4a4a55; }
.search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; padding: 0 18px; }
.search button { width: 60px; background: var(--bg-3); display: grid; place-items: center; color: var(--txt-2); }
.search button:hover { color: var(--txt); }
.bell .badge {
  position: absolute; top: 4px; inset-inline-end: 2px; min-width: 18px; height: 18px; padding: 0 5px;
  background: var(--accent); color: #fff; border-radius: 999px; font-size: 11px; font-weight: 700;
  display: grid; place-items: center; line-height: 1;
}
.av-btn { border-radius: 50%; padding: 2px; }
.av-btn:hover { box-shadow: 0 0 0 2px var(--bg-4); }
.menu-wrap { position: relative; }
.menu {
  position: absolute; top: calc(100% + 8px); inset-inline-end: 0; width: 260px; z-index: 60;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 14px; padding: 8px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .5);
}
.menu-head { display: flex; gap: 10px; align-items: center; padding: 8px 8px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.menu-head span { display: block; color: var(--txt-2); font-size: 13px; }
.menu a, .menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px; border-radius: 10px; text-align: start;
}
.menu a:hover, .menu button:hover { background: var(--bg-3); }

/* ============ Sidebar ============ */
.sidebar {
  position: fixed; top: var(--top); bottom: 0; inset-inline-start: 0; width: var(--side);
  padding: 10px; overflow-y: auto; z-index: 40;
}
.sidebar a {
  display: flex; align-items: center; gap: 18px; padding: 10px 14px; border-radius: 10px; font-size: 15px;
}
.sidebar a:hover { background: var(--bg-3); }
.sidebar a.on { background: var(--bg-3); font-weight: 600; }
.sidebar a.on .ic { color: var(--accent); }
.side-cta { padding: 10px 14px; }
.side-cta p { color: var(--txt-2); font-size: 13px; margin: 0 0 10px; }
.side-mini .sidebar { width: var(--side-mini); }
.side-mini .sidebar a { flex-direction: column; gap: 4px; font-size: 10px; padding: 14px 4px; }
.side-mini .sidebar hr, .side-mini .side-cta { display: none; }

/* ============ Main ============ */
.main { padding: calc(var(--top) + 12px) 24px 40px; margin-inline-start: var(--side); min-height: 100vh; }
.side-mini .main { margin-inline-start: var(--side-mini); }
.bottomnav { display: none; }
.only-mobile { display: none !important; }

.page-h { display: flex; align-items: center; gap: 10px; font-size: 22px; margin: 6px 0 20px; }
.small-h { font-size: 17px; font-weight: 600; color: var(--txt-2); }

.flash { padding: 12px 16px; border-radius: 10px; margin-bottom: 16px; font-size: 14px; }
.flash-ok { background: #10301f; color: #8ff0b8; }
.flash-err { background: #3a1520; color: #ffb3bf; }

/* chips */
.chips { display: flex; gap: 10px; overflow-x: auto; padding: 4px 0 16px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips.wrap { flex-wrap: wrap; overflow: visible; }
.chip {
  flex: none; padding: 6px 14px; border-radius: 9px; background: var(--bg-3); font-size: 14px; font-weight: 500;
  transition: background .15s;
}
.chip:hover { background: var(--bg-4); }
.chip.on { background: var(--txt); color: var(--bg); }

/* ============ Video grid (YouTube) ============ */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 36px 18px; }
.vthumb {
  position: relative; display: block; aspect-ratio: 16/9; border-radius: var(--r); overflow: hidden; background: var(--bg-3);
}
.vthumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.vcard:hover .vthumb img, .vrow:hover .vthumb img { transform: scale(1.03); }
.vthumb.is-short img { object-fit: contain; background: #000; }
.thumb-ph {
  width: 100%; height: 100%; display: grid; place-items: center; color: rgba(255, 255, 255, .8);
  background: radial-gradient(circle at 30% 20%, var(--c), #111 75%);
}
.dur {
  position: absolute; bottom: 8px; inset-inline-start: 8px; padding: 1px 6px; border-radius: 5px;
  background: rgba(0, 0, 0, .8); font-size: 12px; font-weight: 600; direction: ltr;
}
.vmeta { display: flex; gap: 12px; margin-top: 12px; }
.vmeta-txt { display: flex; flex-direction: column; min-width: 0; }
.vtitle {
  font-weight: 600; font-size: 15px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden; margin-bottom: 3px;
}
.vchan, .vstats { color: var(--txt-2); font-size: 13px; }
.vchan:hover { color: var(--txt); }

/* ============ Shorts shelf ============ */
.shelf { margin: 0 0 36px; }
.shelf-h { display: flex; align-items: center; gap: 8px; font-size: 19px; margin: 0 0 14px; }
.shorts-logo { color: var(--accent); display: inline-flex; }
.shelf-row { display: grid; grid-auto-flow: column; grid-auto-columns: 200px; gap: 12px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.scard {
  position: relative; display: block; aspect-ratio: 9/16; border-radius: var(--r); overflow: hidden; background: var(--bg-3);
}
.scard img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.scard:hover img { transform: scale(1.04); }
.scard .thumb-ph { position: absolute; inset: 0; }
.scard-info {
  position: absolute; inset: auto 0 0 0; padding: 40px 10px 10px;
  background: linear-gradient(transparent, rgba(0, 0, 0, .85)); display: flex; flex-direction: column; gap: 3px;
}
.scard-title { font-weight: 600; font-size: 14px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.scard-views { display: flex; align-items: center; gap: 4px; font-size: 12px; color: #ddd; }
.grid-shorts { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }

.pager { display: flex; justify-content: center; gap: 10px; margin-top: 36px; }
.empty { text-align: center; padding: 70px 20px; color: var(--txt-2); display: flex; flex-direction: column; align-items: center; gap: 8px; }
.empty h2 { color: var(--txt); margin: 8px 0 0; font-size: 20px; }
.empty p { margin: 0 0 10px; }

/* ============ Watch ============ */
.watch { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 24px; max-width: 1700px; margin: 0 auto; }
.player-wrap { position: relative; background: #000; border-radius: var(--r); overflow: hidden; aspect-ratio: 16/9; }
.player { width: 100%; height: 100%; background: #000; }
.protected { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.watch-title { font-size: 20px; line-height: 1.4; margin: 14px 0 10px; }
.watch-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.chan { display: flex; align-items: center; gap: 12px; }
.chan-txt { display: flex; flex-direction: column; line-height: 1.3; }
.chan-name { font-weight: 600; }
.chan .btn { margin-inline-start: 10px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.desc { background: var(--bg-3); border-radius: var(--r); padding: 12px 14px; margin: 14px 0 24px; font-size: 14px; }
.desc-stats { font-weight: 600; margin-bottom: 4px; }
.desc-body { max-height: 66px; overflow: hidden; white-space: normal; word-wrap: break-word; }
.desc.open .desc-body { max-height: none; }
.desc-more { font-weight: 600; margin-top: 6px; color: var(--txt); }
.desc a, .ch-bio a, .c-text a, .sdesc a { color: #6fb6ff; }
.desc a.tag, .c-text a.tag, .sdesc a.tag, .ch-bio a.tag { color: var(--cyan); font-weight: 500; }
.watch-side { display: flex; flex-direction: column; gap: 10px; }
.side-shorts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-bottom: 8px; }
.vrow { display: flex; gap: 10px; }
.vrow .vthumb { width: 168px; flex: none; border-radius: 9px; }
.vrow .vtitle { font-size: 14px; }

/* ============ Comments ============ */
.comments-h { font-size: 18px; margin: 0 0 18px; }
.c-form { display: flex; gap: 12px; margin-bottom: 26px; }
.c-form-reply { margin: 10px 0 6px; }
.c-form-main { flex: 1; }
.c-form textarea {
  width: 100%; resize: none; border: 0; border-bottom: 1px solid var(--line); background: none; outline: 0; padding: 6px 0; line-height: 1.5;
}
.c-form textarea:focus { border-bottom-color: var(--txt); }
.c-form-btns { display: flex; justify-content: flex-end; gap: 8px; margin-top: 8px; }
.c-login { display: block; text-align: center; padding: 14px; border-radius: var(--r); background: var(--bg-3); margin-bottom: 20px; color: var(--cyan); font-weight: 600; }
.c-item { display: flex; gap: 12px; margin-bottom: 18px; }
.c-item.is-reply { margin: 12px 0 0; }
.c-body { flex: 1; min-width: 0; }
.c-top { display: flex; align-items: baseline; gap: 8px; }
.c-name { font-weight: 600; font-size: 13px; }
.c-name.creator { background: var(--bg-4); padding: 0 8px; border-radius: 999px; }
.c-text { font-size: 14px; word-wrap: break-word; }
.c-acts { display: flex; gap: 14px; margin-top: 2px; }
.c-acts button { font-size: 12px; font-weight: 600; color: var(--txt-2); padding: 4px 0; }
.c-acts button:hover { color: var(--txt); }
.c-toggle { color: #6fb6ff; font-weight: 600; font-size: 13px; padding: 6px 0; }
.c-loading { display: grid; place-items: center; padding: 30px; }
.c-empty { text-align: center; padding: 20px; }

.spinner {
  width: 30px; height: 30px; border-radius: 50%; display: inline-block;
  border: 3px solid var(--bg-4); border-top-color: var(--accent); animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============ Shorts feed (TikTok) ============ */
.page-shorts .main { padding: var(--top) 0 0; height: 100dvh; overflow: hidden; }
.shorts-tabs {
  position: fixed; top: calc(var(--top) + 30px); left: calc((100% - var(--side)) / 2); transform: translateX(calc(-50% + 32px)); z-index: 20;
  display: flex; gap: 22px; font-weight: 700; font-size: 16px; text-shadow: 0 1px 6px rgba(0, 0, 0, .6);
}
.side-mini .shorts-tabs { left: calc((100% - var(--side-mini)) / 2); }
.shorts-tabs a { color: rgba(255, 255, 255, .6); padding-bottom: 4px; }
.shorts-tabs a.on { color: #fff; border-bottom: 2px solid #fff; }
.sfeed {
  height: calc(100dvh - var(--top)); overflow-y: scroll; scroll-snap-type: y mandatory;
  overscroll-behavior: contain; scrollbar-width: none;
}
.sfeed::-webkit-scrollbar { display: none; }
.sfeed-loading, .sempty { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: var(--txt-2); text-align: center; padding: 20px; }
.sempty h2 { color: var(--txt); font-size: 18px; margin: 0; }
.sitem {
  height: 100%; scroll-snap-align: start; scroll-snap-stop: always;
  display: flex; align-items: flex-end; justify-content: center; gap: 14px; padding: 16px 0;
}
.sframe {
  position: relative; height: 100%; aspect-ratio: 9/16; max-width: 100%; border-radius: 16px; overflow: hidden; background: #000;
}
.svideo { width: 100%; height: 100%; object-fit: contain; background: #000; }
.stap { position: absolute; inset: 0 0 90px 0; cursor: pointer; z-index: 2; }
.splay {
  position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; z-index: 3; color: rgba(255, 255, 255, .85);
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, .5));
}
.sbar { position: absolute; inset: auto 0 0 0; height: 3px; background: rgba(255, 255, 255, .2); z-index: 4; }
.sbar-fill { height: 100%; width: 0; background: #fff; transition: width .25s linear; }
html[dir="rtl"] .sbar-fill { margin-inline-start: 0; }
.sinfo {
  position: absolute; inset: auto 0 0 0; z-index: 3; padding: 70px 14px 16px;
  background: linear-gradient(transparent, rgba(0, 0, 0, .75)); display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
}
.suser { display: flex; align-items: center; gap: 8px; font-size: 15px; }
.sf-follow {
  border: 1px solid rgba(255, 255, 255, .8); border-radius: 8px; padding: 2px 12px; font-size: 13px; font-weight: 600;
}
.sf-follow.on { border-color: transparent; background: rgba(255, 255, 255, .2); }
.sdesc { width: 100%; font-size: 14px; line-height: 1.5; max-height: 4.5em; overflow: hidden; text-shadow: 0 1px 3px rgba(0, 0, 0, .6); }
.sactions { display: flex; flex-direction: column; align-items: center; gap: 16px; padding-bottom: 8px; }
.sact-av { margin-bottom: 4px; }
.sact-av .av { border: 2px solid #fff; }
.sact {
  display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; font-weight: 600;
}
.sact .ic {
  width: 50px; height: 50px; padding: 12px; border-radius: 50%; background: var(--bg-3); transition: transform .15s, background .15s;
}
.sact:hover .ic { background: var(--bg-4); }
.sact:active .ic { transform: scale(.9); }
.sact.js-like.on .ic { color: var(--accent); }
.sact.js-like.on .ic path { fill: currentColor; }
.snd-toggle {
  position: fixed; top: calc(var(--top) + 12px); inset-inline-end: 20px; z-index: 25;
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: rgba(0, 0, 0, .45); color: #fff;
}
.snd-toggle.on { background: rgba(255, 255, 255, .15); }
.burst {
  position: absolute; z-index: 5; color: var(--accent); pointer-events: none; transform: translate(-50%, -50%);
  animation: burst .8s ease-out forwards;
}
.burst .ic { width: 96px; height: 96px; filter: drop-shadow(0 6px 18px rgba(255, 61, 90, .5)); }
.burst .ic path { fill: currentColor; }
@keyframes burst {
  0% { transform: translate(-50%, -50%) scale(.3) rotate(-12deg); opacity: 0; }
  25% { transform: translate(-50%, -50%) scale(1.15) rotate(-12deg); opacity: 1; }
  100% { transform: translate(-50%, -120%) scale(1) rotate(-12deg); opacity: 0; }
}

/* sheet */
.sheet { position: fixed; inset: 0; z-index: 80; }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .5); opacity: 0; transition: opacity .25s; }
.sheet-panel {
  position: absolute; inset: auto 0 0 0; margin: 0 auto; max-width: 560px; height: 72dvh;
  background: var(--bg-2); border-radius: 18px 18px 0 0; display: flex; flex-direction: column;
  transform: translateY(100%); transition: transform .25s ease;
}
.sheet.open .sheet-backdrop { opacity: 1; }
.sheet.open .sheet-panel { transform: none; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; border-bottom: 1px solid var(--line); }
.comments.in-sheet { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; }
.comments.in-sheet .c-form, .comments.in-sheet .c-login { order: 2; position: sticky; bottom: -16px; background: var(--bg-2); padding: 12px 0; margin: auto 0 -16px; }
.comments.in-sheet .c-list { order: 1; }

/* ============ Upload ============ */
.upload { max-width: 1100px; margin: 0 auto; }
.upload-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 24px; }
.drop {
  border: 2px dashed var(--line); border-radius: 16px; min-height: 380px; display: grid; place-items: center;
  cursor: pointer; background: var(--bg-2); transition: border-color .15s, background .15s; overflow: hidden;
}
.drop:hover, .drop.over { border-color: var(--accent); background: #1a1216; }
.drop.has-file { cursor: default; border-style: solid; background: #000; }
.drop-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; padding: 20px; color: var(--txt-2); }
.drop-empty strong { color: var(--txt); }
.drop-preview { width: 100%; max-height: 70vh; }
.drop.is-vertical .drop-preview { width: auto; height: 70vh; }
.upload-fields { display: flex; flex-direction: column; gap: 16px; }
.type-switch { display: flex; gap: 10px; }
.radio {
  flex: 1; display: flex; align-items: center; gap: 8px; padding: 12px; border-radius: 12px; border: 1px solid var(--line); cursor: pointer;
}
.radio:has(input:checked) { border-color: var(--accent); background: #1d1216; }
.radio input { accent-color: var(--accent); }
.thumb-pick { display: flex; gap: 14px; align-items: center; }
.thumb-prev { width: 150px; aspect-ratio: 16/9; flex: none; border-radius: 10px; background: var(--bg-3); display: grid; place-items: center; overflow: hidden; }
.thumb-prev img { width: 100%; height: 100%; object-fit: cover; }
.thumb-pick p { margin: 6px 0 0; }
.progress { position: relative; height: 34px; border-radius: 10px; background: var(--bg-3); overflow: hidden; }
.progress-bar { position: absolute; inset: 0 0 0 auto; width: 0; background: var(--grad); transition: width .2s; }
html[dir="rtl"] .progress-bar { inset: 0 0 0 auto; }
.progress span { position: relative; display: grid; place-items: center; height: 100%; font-weight: 700; font-size: 13px; }

/* ============ Forms ============ */
.form { display: flex; flex-direction: column; gap: 14px; }
.form label, .upload-fields > label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 500; }
.form input:not([type=checkbox]):not([type=file]), .form textarea, .upload-fields input:not([type=radio]):not([type=file]), .upload-fields textarea {
  width: 100%; padding: 11px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg-2); outline: 0; transition: border-color .15s;
}
.form input:focus, .form textarea:focus, .upload-fields input:focus, .upload-fields textarea:focus { border-color: var(--accent); }
textarea { resize: vertical; }
.form input:disabled { opacity: .6; }
.auth-card { max-width: 420px; margin: 30px auto; background: var(--bg-2); border: 1px solid var(--line); border-radius: 18px; padding: 30px; }
.auth-card.wide { max-width: 560px; }
.auth-card h1 { margin: 0 0 4px; font-size: 24px; }
.auth-card > .muted { margin: 0 0 20px; }
.auth-card a:not(.btn) { color: var(--cyan); }
.av-edit { display: flex; align-items: center; gap: 16px; }
.av-edit > div { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.check { flex-direction: row !important; align-items: center; font-size: 13px !important; }
details.pw { border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; }
details.pw summary { cursor: pointer; font-weight: 600; }
details.pw[open] { display: flex; flex-direction: column; gap: 12px; }

/* ============ Channel ============ */
.ch-cover {
  height: 170px; border-radius: 16px;
  background: radial-gradient(circle at 80% 0%, var(--c), transparent 60%), radial-gradient(circle at 0% 100%, #2a0d16, transparent 60%), var(--bg-3);
}
.ch-info { display: flex; gap: 22px; align-items: flex-start; padding: 0 20px; margin-top: -40px; }
.ch-info > .av { border: 4px solid var(--bg); }
.ch-txt { padding-top: 46px; }
.ch-txt h1 { margin: 0; font-size: 26px; }
.ch-txt > p { margin: 2px 0 0; }
.ch-bio { color: var(--txt-2); max-width: 640px; }
.ch-nums { display: flex; gap: 18px; margin: 10px 0 14px; font-size: 14px; color: var(--txt-2); }
.ch-nums strong { color: var(--txt); }
.ch-actions { display: flex; gap: 10px; }
.tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); margin: 26px 0 22px; }
.tabs a { padding: 10px 18px; font-weight: 600; color: var(--txt-2); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs a.on { color: var(--txt); border-bottom-color: var(--txt); }
.own-wrap { position: relative; }
.own-del {
  position: absolute; top: 8px; inset-inline-end: 8px; z-index: 2; width: 34px; height: 34px; border-radius: 50%;
  background: rgba(0, 0, 0, .7); display: grid; place-items: center; opacity: 0; transition: opacity .15s;
}
.own-wrap:hover .own-del { opacity: 1; }
.own-del:hover { background: var(--accent); }

/* ============ Search ============ */
.tag-head { display: flex; align-items: center; gap: 16px; margin: 6px 0 26px; }
.tag-icon { width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-3); color: var(--cyan); }
.tag-head h1 { margin: 0; font-size: 26px; }
.tag-head p { margin: 0; }
.chan-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; margin-bottom: 30px; }
.chan-card { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 18px 10px; border-radius: 14px; background: var(--bg-2); text-align: center; }
.chan-card:hover { background: var(--bg-3); }
.rows { display: flex; flex-direction: column; gap: 16px; max-width: 1000px; }
.rows .vrow .vthumb { width: 340px; }
.rows .vtitle { font-size: 17px; }
.trending { margin-top: 30px; }

/* ============ Notifications ============ */
.notifs { list-style: none; margin: 0; padding: 0; max-width: 760px; }
.notifs li { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 12px; }
.notifs li:hover { background: var(--bg-2); }
.notifs li.unread { background: #1a1418; }
.n-txt { flex: 1; font-size: 14px; }
.n-txt .muted { display: block; }
.n-thumb img { width: 96px; aspect-ratio: 16/9; object-fit: cover; border-radius: 8px; }

/* ============ Toast ============ */
.toast {
  position: fixed; bottom: 30px; left: 50%; transform: translate(-50%, 20px); z-index: 100;
  background: #fff; color: #000; padding: 10px 20px; border-radius: 999px; font-weight: 600; font-size: 14px;
  opacity: 0; transition: opacity .25s, transform .25s; pointer-events: none;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ============ Responsive ============ */
@media (max-width: 1200px) {
  .watch { grid-template-columns: 1fr; }
  .watch-side .side-shorts { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 860px) {
  :root { --top: 54px; }
  .only-desktop { display: none !important; }
  .only-mobile { display: grid !important; }
  .search.only-mobile { display: flex !important; }
  .topbar { padding: 0 8px; }
  .topbar > .search { display: none; }
  .sidebar { display: none; }
  .main, .side-mini .main { margin-inline-start: 0; padding: calc(var(--top) + 8px) 12px calc(var(--bottom) + 24px); }
  .search-page { margin-bottom: 16px; max-width: none; }
  .grid { grid-template-columns: 1fr; gap: 26px; }
  .grid .vthumb { margin: 0 -12px; border-radius: 0; }
  .shelf-row { grid-auto-columns: 42vw; }
  .grid-shorts { grid-template-columns: repeat(3, 1fr); gap: 3px; }
  .grid-shorts .scard { border-radius: 4px; }
  .own-del { opacity: 1; }

  .bottomnav {
    display: flex; position: fixed; inset: auto 0 0 0; height: calc(var(--bottom) + env(safe-area-inset-bottom)); z-index: 60;
    padding-bottom: env(safe-area-inset-bottom); background: rgba(11, 11, 13, .96); border-top: 1px solid var(--line);
    justify-content: space-around; align-items: center;
  }
  .bottomnav a { display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 10px; color: var(--txt-2); flex: 1; }
  .bottomnav a.on { color: var(--txt); }
  .bottomnav .bn-upload {
    flex: none; width: 48px; height: 32px; border-radius: 10px; background: #fff; color: #000; display: grid; place-items: center;
    box-shadow: -4px 0 0 var(--accent), 4px 0 0 var(--cyan);
  }

  .watch-title { font-size: 17px; }
  .player-wrap { margin: -8px -12px 0; border-radius: 0; }
  .page-watch .main { padding-top: var(--top); }
  .rows .vrow .vthumb { width: 46%; }
  .rows .vtitle { font-size: 14px; }
  .vrow .vthumb { width: 46%; }
  .upload-grid { grid-template-columns: 1fr; }
  .drop { min-height: 240px; }
  .ch-info { flex-direction: column; align-items: center; text-align: center; margin-top: -56px; }
  .ch-txt { padding-top: 0; }
  .ch-nums, .ch-actions { justify-content: center; }
  .ch-cover { height: 120px; margin: 0 -12px; border-radius: 0; }
  .auth-card { padding: 22px; margin: 10px auto; border: 0; background: none; }

  /* Shorts: ملء الشاشة */
  .page-shorts .topbar { background: transparent; backdrop-filter: none; }
  .page-shorts .topbar .logo-txt, .page-shorts .topbar .bell, .page-shorts .topbar .menu-wrap, .page-shorts .topbar .btn { display: none; }
  .page-shorts .main { padding: 0; }
  .page-shorts .bottomnav { background: #000; border-top-color: #111; }
  .sfeed { height: calc(100dvh - var(--bottom) - env(safe-area-inset-bottom)); }
  .sitem { padding: 0; position: relative; }
  .sframe { width: 100%; height: 100%; aspect-ratio: auto; border-radius: 0; }
  .svideo { object-fit: cover; }
  .sactions { position: absolute; inset-inline-end: 8px; bottom: 90px; z-index: 6; gap: 14px; }
  .sact .ic { background: none; width: 40px; height: 40px; padding: 4px; filter: drop-shadow(0 1px 4px rgba(0, 0, 0, .6)); }
  .sact span { text-shadow: 0 1px 3px rgba(0, 0, 0, .7); }
  .sinfo { padding-inline-end: 72px; }
  .shorts-tabs, .side-mini .shorts-tabs { top: 14px; left: 50%; transform: translateX(-50%); }
  .snd-toggle { top: 58px; inset-inline-end: 10px; }
  .sheet-panel { border-radius: 16px 16px 0 0; }
}

/* ============ Announcement / warn ============ */
.announce {
  background: linear-gradient(90deg, rgba(255, 61, 90, .14), rgba(46, 230, 224, .1)); border: 1px solid rgba(255, 61, 90, .25);
  padding: 10px 16px; border-radius: 12px; margin-bottom: 18px; font-size: 14px;
}
.announce a { color: var(--cyan); }
.flash-warn { background: #2e2410; color: #ffd98a; }
.flash-warn a { text-decoration: underline; }
.menu-admin { color: var(--cyan); }

/* ============ Admin ============ */
.page-admin .main { padding-top: calc(var(--top) + 8px); }
.adm { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 24px; max-width: 1500px; margin: 0 auto; }
.adm-nav { position: sticky; top: calc(var(--top) + 12px); align-self: start; display: flex; flex-direction: column; gap: 2px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; padding: 10px; }
.adm-brand { display: flex; align-items: center; gap: 8px; font-weight: 700; padding: 8px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; color: var(--cyan); }
.adm-ver { margin-inline-start: auto; font-size: 11px; color: var(--txt-3); font-weight: 500; }
.adm-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; font-size: 14px; color: var(--txt-2); }
.adm-nav a:hover { background: var(--bg-3); color: var(--txt); }
.adm-nav a.on { background: var(--bg-3); color: var(--txt); font-weight: 600; }
.adm-nav a.on .ic { color: var(--accent); }
.adm-back { margin-top: 6px; border-top: 1px solid var(--line); border-radius: 0 0 10px 10px !important; }
.adm-body { min-width: 0; }
.adm-h { font-size: 22px; margin: 4px 0 18px; }

.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-bottom: 18px; }
.kpi { background: var(--bg-2); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; transition: border-color .15s; }
a.kpi:hover { border-color: #3a3a44; }
.kpi-ic { color: var(--accent); margin-bottom: 4px; }
.kpi-n { font-size: 24px; font-weight: 700; line-height: 1.2; }
.kpi-l { color: var(--txt-2); font-size: 13px; }
.kpis-sm .kpi { padding: 10px 14px; }
.kpis-sm .kpi-n { font-size: 19px; }

.panel { background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; margin-bottom: 18px; min-width: 0; }
.panel-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.panel-h h2 { font-size: 16px; margin: 0; display: flex; align-items: center; gap: 8px; }
.adm-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.adm-grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.adm-grid2 > .panel, .adm-grid3 > .panel { margin-bottom: 0; }
.adm-grid2, .adm-grid3 { margin-bottom: 18px; }

.legend { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--txt-2); }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.lg-u, .bar-u { background: var(--cyan); }
.lg-v, .bar-v { background: var(--accent); }
.bars { display: flex; align-items: flex-end; gap: 6px; height: 170px; padding-top: 6px; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; }
.bar-pair { flex: 1; width: 100%; display: flex; align-items: flex-end; justify-content: center; gap: 2px; }
.bar { width: 42%; max-width: 12px; min-height: 2px; border-radius: 3px 3px 0 0; }
.bar-d { font-size: 10px; color: var(--txt-3); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 0; font-size: 14px; }
.kv dt { color: var(--txt-2); }
.kv dd { margin: 0; font-weight: 600; text-align: end; }

.mini-row { display: flex; align-items: center; gap: 10px; padding: 7px 6px; border-radius: 10px; }
.mini-row:hover { background: var(--bg-3); }
.mini-txt { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.mini-txt strong { font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-thumb { width: 64px; aspect-ratio: 16/9; flex: none; border-radius: 6px; overflow: hidden; background: var(--bg-3); display: block; position: relative; }
.mini-thumb img { width: 100%; height: 100%; object-fit: cover; }
.mini-thumb .thumb-ph .ic { width: 16px; height: 16px; }
.mini-thumb.big { width: 100%; }
.mini-thumb.big.tall { aspect-ratio: 16/9; }
.mini-thumb.big.tall img { object-fit: contain; background: #000; }

.badge-s { display: inline-block; font-size: 11px; font-weight: 600; padding: 1px 8px; border-radius: 999px; margin-inline-start: 4px; vertical-align: middle; }
.b-admin { background: rgba(46, 230, 224, .15); color: var(--cyan); }
.b-ban { background: rgba(255, 61, 90, .15); color: #ff8a9b; }

.toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.toolbar input[type=search], .toolbar select, .ban-form input, .title-edit input {
  height: 36px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg-2); outline: 0;
}
.toolbar input[type=search] { flex: 1; min-width: 200px; }
.toolbar input:focus, .ban-form input:focus, .title-edit input:focus { border-color: var(--accent); }

.table-wrap { overflow-x: auto; background: var(--bg-2); border: 1px solid var(--line); border-radius: 14px; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: start; font-weight: 600; color: var(--txt-2); font-size: 12px; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tbody tr:hover { background: rgba(255, 255, 255, .02); }
.tbl .row-ban { background: rgba(255, 61, 90, .05); }
.tbl input[type=checkbox], .vcheck input, .crow input, .check input { accent-color: var(--accent); width: 16px; height: 16px; }
.cell-user { display: flex; align-items: center; gap: 10px; min-width: 190px; }
.cell-video { display: flex; align-items: center; gap: 10px; min-width: 300px; }
.title-edit { display: flex; gap: 4px; flex: 1; }
.title-edit input { flex: 1; min-width: 0; height: 32px; background: transparent; border-color: transparent; }
.title-edit input:hover, .title-edit input:focus { background: var(--bg); border-color: var(--line); }
.ltr { direction: ltr; unicode-bidi: isolate; }
.acts { white-space: nowrap; display: flex; gap: 6px; align-items: center; }
td.acts { display: table-cell; }
td.acts > * { margin-inline-end: 4px; }
form.inline { display: inline-block; margin: 0; }
.abtn {
  display: inline-flex; align-items: center; gap: 5px; height: 30px; padding: 0 11px; border-radius: 8px;
  background: var(--bg-3); font-size: 13px; font-weight: 500; white-space: nowrap; transition: background .15s;
}
.abtn:hover { background: var(--bg-4); }
.abtn.warn { color: #ffc46b; }
.abtn.danger { color: #ff8a9b; }
.abtn.danger:hover { background: #3a1820; }
.abtn.ok { color: #8ff0b8; }
.abtn.tag-btn { height: 24px; font-size: 12px; }

.bulk-bar { display: flex; align-items: center; gap: 10px; margin: 12px 0; }
.bulk-bar.top { margin-top: 0; }
.vgrid-adm { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
.vcheck { position: relative; display: flex; flex-direction: column; gap: 4px; cursor: pointer; padding: 6px; border-radius: 10px; border: 1px solid transparent; }
.vcheck:has(input:checked) { border-color: var(--accent); background: #1d1216; }
.vcheck input { position: absolute; top: 12px; inset-inline-start: 12px; z-index: 2; }
.vcheck-t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.clist { display: flex; flex-direction: column; background: var(--bg-2); border: 1px solid var(--line); border-radius: 14px; }
.crow { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-bottom: 1px solid var(--line); cursor: pointer; }
.crow:last-child { border: 0; }
.crow:has(input:checked) { background: #1d1216; }
.crow input { margin-top: 8px; }
.crow-body { display: flex; flex-direction: column; min-width: 0; }
.crow-body a { color: var(--cyan); }
.crow-text { font-size: 14px; word-wrap: break-word; }

.u-head { display: flex; align-items: center; gap: 16px; margin: 12px 0 18px; flex-wrap: wrap; }
.u-head > div { flex: 1; min-width: 200px; }
.u-head.is-ban > .av { filter: grayscale(1); opacity: .6; }
.ban-reason { background: #3a1520; color: #ffb3bf; padding: 6px 12px; border-radius: 8px; font-size: 13px; margin: 8px 0 0; display: inline-block; }
.danger-zone { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; border-top: 1px solid var(--line); padding-top: 16px; }
.ban-form { display: flex; gap: 6px; width: 100%; }
.ban-form input { flex: 1; min-width: 0; }
.panel .form textarea, .panel .form input:not([type=checkbox]) { background: var(--bg); }
.panel .form .btn { align-self: flex-start; }

.settings-form { max-width: 820px; }
.settings-form .panel { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 500; }
.field input, .field textarea, .field select { padding: 10px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); outline: 0; font-weight: 400; }
.field select { color: var(--txt); cursor: pointer; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); }
.fields2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.switch { display: flex; align-items: center; gap: 14px; cursor: pointer; padding: 6px 0; }
.switch > span:last-child { display: flex; flex-direction: column; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.sw { width: 44px; height: 24px; border-radius: 999px; background: var(--bg-4); position: relative; flex: none; transition: background .2s; }
.sw::after { content: ""; position: absolute; top: 3px; inset-inline-start: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .2s; }
.switch input:checked + .sw { background: #2bb673; }
.switch.danger input:checked + .sw { background: var(--accent); }
html[dir="rtl"] .switch input:checked + .sw::after { transform: translateX(-20px); }
html[dir="ltr"] .switch input:checked + .sw::after { transform: translateX(20px); }
.switch input:focus-visible + .sw { box-shadow: 0 0 0 2px var(--cyan); }
.save-btn { min-width: 200px; }

.ver-pill { font-size: 12px; background: var(--bg-3); padding: 3px 10px; border-radius: 999px; color: var(--cyan); font-weight: 600; }
.steps-list { margin: 0 0 16px; padding-inline-start: 20px; color: var(--txt-2); font-size: 14px; }
.steps-list b { color: var(--txt); }
.file-drop { display: flex !important; flex-direction: column; align-items: center; gap: 6px; padding: 22px; border: 2px dashed var(--line); border-radius: 14px; cursor: pointer; color: var(--txt-2); text-align: center; flex-direction: column !important; }
.file-drop:hover, .file-drop.has { border-color: var(--accent); color: var(--txt); }
.file-drop input { display: none; }
.backups { list-style: none; margin: 0; padding: 0; }
.backups li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.backups li:last-child { border: 0; }
.restore-form { margin-top: 14px; padding: 14px; border-radius: 12px; background: #2e2410; display: flex; flex-direction: column; gap: 10px; }
.restore-form label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.restore-form input { padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); outline: 0; }
.restore-form .btn { align-self: flex-start; }

@media (max-width: 1100px) {
  .adm-grid3 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .adm { grid-template-columns: 1fr; gap: 14px; }
  .adm-nav { position: static; flex-direction: row; overflow-x: auto; padding: 6px; scrollbar-width: none; }
  .adm-nav::-webkit-scrollbar { display: none; }
  .adm-brand, .adm-back { display: none !important; }
  .admin-app .adm-nav { position: sticky; top: 58px; z-index: 40; }
  .adm-nav a { flex: none; padding: 8px 12px; }
  .adm-grid2, .fields2 { grid-template-columns: 1fr; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .bars { height: 130px; gap: 3px; }
}
.page-admin .sidebar { display: none; }
.page-admin .main, .side-mini.page-admin .main { margin-inline-start: 0; }
.page-admin #sideToggle { visibility: hidden; }

/* ============ Admin app (standalone) ============ */
.admin-app { min-height: 100vh; }
.adm-top {
  position: sticky; top: 0; z-index: 50; height: 58px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 0 20px; background: rgba(11, 11, 13, .94); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line);
}
.adm-logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 17px; }
.aa-ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #1f8f8b, var(--cyan)); box-shadow: 0 6px 20px rgba(46, 230, 224, .2); }
.aa-ic.sm { width: 32px; height: 32px; border-radius: 9px; }
.adm-top-end { display: flex; align-items: center; gap: 8px; }
.adm-pill { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 999px; background: var(--bg-3); font-size: 13px; font-weight: 500; }
.adm-pill:hover { background: var(--bg-4); }
.adm-pill.warn { background: #2e2410; color: #ffd98a; }
.adm-who { display: inline-flex; align-items: center; gap: 6px; color: var(--txt-2); font-size: 13px; padding: 0 6px; }
.admin-app .adm { padding: 20px; }
.admin-app .adm-nav { top: 78px; }

/* admin login */
.admin-auth { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px;
  background: radial-gradient(circle at 20% 0%, rgba(46, 230, 224, .08), transparent 50%), radial-gradient(circle at 100% 100%, rgba(255, 61, 90, .07), transparent 50%), var(--bg); }
.aa-wrap { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: 18px; }
.aa-brand { display: flex; align-items: center; gap: 12px; }
.aa-brand strong { display: block; font-size: 18px; }
.aa-brand span { color: var(--txt-2); font-size: 13px; }
.aa-card { background: var(--bg-2); border: 1px solid var(--line); border-radius: 18px; padding: 26px; }
.aa-card h1 { margin: 0 0 2px; font-size: 22px; }
.aa-card > .muted { margin: 0 0 18px; }
.aa-back { text-align: center; }

@media (max-width: 860px) {
  .adm-top { padding: 0 12px; }
  .hide-sm { display: none; }
  .admin-app .adm { padding: 12px; }
}
.side-admin { color: var(--cyan); }
.changelog { display: flex; flex-direction: column; gap: 4px; }
.cl-item { border-inline-start: 2px solid var(--line); padding: 4px 16px 10px; position: relative; }
.cl-item::before { content: ""; position: absolute; inset-inline-start: -6px; top: 10px; width: 10px; height: 10px; border-radius: 50%; background: var(--bg-4); }
.cl-item.current { border-color: var(--cyan); }
.cl-item.current::before { background: var(--cyan); }
.cl-head { display: flex; align-items: center; gap: 8px; }
.cl-ver { font-weight: 700; }
.cl-item ul { margin: 6px 0 0; padding-inline-start: 18px; color: var(--txt-2); font-size: 14px; }
.progress span { padding: 0 10px; font-size: 12px; white-space: nowrap; overflow: hidden; }

.heavy { color: #ffc46b; font-weight: 600; }
.upload-warn { background: #2e2410; color: #ffd98a; padding: 10px 14px; border-radius: 10px; font-size: 13px; }

/* verified badge */
.vbadge { display: inline-flex; vertical-align: -2px; margin-inline-start: 4px; color: var(--cyan); }
.vbadge svg { display: block; }
.ch-txt h1 .vbadge { vertical-align: -1px; margin-inline-start: 8px; }

/* modal (report) */
.modal { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 16px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .6); opacity: 0; transition: opacity .2s; }
.modal-card { position: relative; width: 100%; max-width: 420px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 18px; padding: 20px;
  display: flex; flex-direction: column; gap: 10px; transform: translateY(10px) scale(.98); opacity: 0; transition: transform .2s, opacity .2s; max-height: 90vh; overflow: auto; }
.modal.open .modal-backdrop { opacity: 1; }
.modal.open .modal-card { transform: none; opacity: 1; }
.modal-card h3 { margin: 0; }
.modal-card p { margin: 0; }
.reasons { display: flex; flex-direction: column; gap: 2px; }
.reason { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; cursor: pointer; font-size: 14px; }
.reason:hover { background: var(--bg-3); }
.reason:has(input:checked) { background: var(--bg-3); color: var(--txt); }
.reason input { accent-color: var(--accent); }
.modal-card textarea { width: 100%; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); outline: 0; resize: vertical; }
.modal-btns { display: flex; justify-content: flex-end; gap: 8px; }
@media (max-width: 860px) { .hide-xs { display: none; } }

/* ============ v1.4: identity, reports, pages ============ */
.logo-img { height: 30px; width: auto; max-width: 160px; object-fit: contain; display: block; }
.aa-logo { height: 44px; max-width: 160px; object-fit: contain; }
.side-foot { margin-top: 18px; padding: 12px 14px 20px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 4px 12px; }
.side-foot a { padding: 0 !important; font-size: 12px !important; color: var(--txt-3); display: inline !important; background: none !important; }
.side-foot a:hover { color: var(--txt); }
.side-foot p { width: 100%; margin: 6px 0 0; font-size: 12px; color: var(--txt-3); }
.side-mini .side-foot { display: none; }
.page-wrap { max-width: 820px; margin: 0 auto; background: var(--bg-2); border: 1px solid var(--line); border-radius: 18px; padding: 28px 32px; }
.page-body { line-height: 1.9; font-size: 16px; }
.page-body h1 { margin-top: 0; font-size: 28px; }
.page-body h2 { font-size: 20px; margin: 26px 0 8px; }
.page-body a { color: var(--cyan); text-decoration: underline; }
.page-body img { max-width: 100%; border-radius: 12px; height: auto; }
.page-updated { margin-top: 30px; }
.nav-count { margin-inline-start: auto; background: var(--accent); color: #fff; font-size: 11px; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; display: grid; place-items: center; }
.rep-list { display: flex; flex-direction: column; gap: 12px; }
.rep { display: flex; flex-direction: column; gap: 10px; margin: 0; }
.rep-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rep-reasons { display: flex; flex-wrap: wrap; gap: 6px; }
.rep-reasons .chip { font-size: 12px; padding: 3px 10px; }
.rep-target { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 12px; background: var(--bg); }
.rep-target .mini-thumb.big { width: 150px; }
.rep-quote { display: block; margin-top: 4px; padding: 6px 10px; border-inline-start: 3px solid var(--accent); background: var(--bg-3); border-radius: 6px; font-size: 14px; }
.rep-details { font-size: 13px; color: var(--txt-2); }
.rep-details summary { cursor: pointer; }
.rep-details p { margin: 6px 0; padding: 6px 10px; background: var(--bg); border-radius: 8px; }
.rep-acts { display: flex; flex-wrap: wrap; gap: 8px; }
.verify-row { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.brand-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.brand-box { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; padding: 12px; border: 1px dashed var(--line); border-radius: 12px; }
.brand-prev { width: 100%; height: 80px; border-radius: 10px; background: var(--bg); display: grid; place-items: center; overflow: hidden; }
.brand-prev img { max-height: 64px; max-width: 90%; object-fit: contain; }
.fav-prev img { width: 48px; height: 48px; }
.presets { display: flex; flex-wrap: wrap; gap: 8px; }
.preset { display: flex; align-items: center; gap: 3px; padding: 6px 10px; border-radius: 10px; background: var(--bg); border: 1px solid var(--line); }
.preset.on, .preset:hover { border-color: var(--txt-2); }
.preset span { width: 16px; height: 16px; border-radius: 50%; display: inline-block; }
.preset em { font-style: normal; font-size: 12px; margin-inline-start: 6px; }
.color-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.color-field { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; background: var(--bg); cursor: pointer; font-size: 13px; }
.color-field input { width: 42px; height: 42px; border: 0; padding: 0; background: none; border-radius: 10px; cursor: pointer; }
.color-field code { color: var(--txt-3); font-size: 11px; }
.live-prev { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px; border-radius: 12px; background: var(--bg); }
.tag-prev { color: var(--cyan); }
.fonts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.font-opt { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 12px; border: 1px solid var(--line); cursor: pointer; }
.font-opt:has(input:checked) { border-color: var(--accent); background: var(--bg); }
.font-opt input { accent-color: var(--accent); }
.font-opt span { display: flex; flex-direction: column; }
.font-opt strong { font-size: 18px; }
.font-opt em { font-style: normal; font-size: 11px; color: var(--txt-3); font-family: var(--font); }
textarea.code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; }
.texts-panel { gap: 0 !important; }
.texts-filter { height: 38px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); outline: 0; margin-bottom: 8px; }
.txt-row { display: grid; grid-template-columns: 220px 1fr 34px; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.txt-row input { height: 38px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); outline: 0; min-width: 0; }
.txt-row input:focus { border-color: var(--accent); }
.txt-row.changed .txt-label::after { content: " •"; color: var(--accent); }
.txt-label { color: var(--txt-2); }
.editor-bar { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0; }
.page-preview { background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 16px; min-height: 300px; font-weight: 400; }
@media (max-width: 860px) {
  .brand-row, .color-grid { grid-template-columns: 1fr 1fr; }
  .fonts { grid-template-columns: 1fr; }
  .txt-row { grid-template-columns: 1fr 34px; }
  .txt-row .txt-label { grid-column: 1 / -1; font-size: 12px; }
  .page-wrap { padding: 20px 16px; border: 0; }
}

/* ============ MPlayer — مشغّل الموقع ============ */
.mp { position: relative; width: 100%; height: 100%; background: #000; overflow: hidden; outline: 0; user-select: none; -webkit-user-select: none; color: #fff; font-family: var(--font); }
.mp video { width: 100%; height: 100%; display: block; object-fit: contain; }
.mp-tap { position: absolute; inset: 0 0 56px 0; z-index: 2; cursor: pointer; }
.mp-wm { position: absolute; top: 14px; inset-inline-end: 16px; z-index: 3; opacity: .45; pointer-events: none; font-weight: 700; font-size: 15px; text-shadow: 0 1px 4px rgba(0, 0, 0, .7); }
.mp-wm img { height: 26px; width: auto; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .6)); }
.mp-big { position: absolute; z-index: 4; inset: 0; margin: auto; width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; color: #fff;
  background: color-mix(in srgb, var(--accent) 88%, transparent); box-shadow: 0 10px 40px rgba(0, 0, 0, .5); transition: transform .15s, opacity .2s; }
.mp-big:hover { transform: scale(1.06); }
.mp-big svg { margin-inline-start: 4px; }
.mp.mp-started:not(.mp-paused) .mp-big, .mp.mp-started.mp-paused:not(.mp-ended) .mp-big { opacity: 0; pointer-events: none; }
.mp-spin { position: absolute; z-index: 4; inset: 0; margin: auto; width: 54px; height: 54px; border-radius: 50%; border: 4px solid rgba(255, 255, 255, .2); border-top-color: var(--accent); animation: spin .8s linear infinite; pointer-events: none; }
.mp-toast { position: absolute; z-index: 5; top: 18%; left: 50%; transform: translateX(-50%); background: rgba(0, 0, 0, .7); padding: 8px 16px; border-radius: 999px; font-weight: 700; font-size: 15px; pointer-events: none; direction: ltr; }
.mp-ripple { position: absolute; z-index: 3; top: 0; bottom: 0; width: 38%; display: grid; place-items: center; font-weight: 700; font-size: 18px; opacity: 0; pointer-events: none;
  background: radial-gradient(circle at center, rgba(255, 255, 255, .18), transparent 70%); direction: ltr; }
.mp-ripple-a { left: 0; border-radius: 0 50% 50% 0; }
.mp-ripple-b { right: 0; border-radius: 50% 0 0 50%; }
.mp-ripple.on { animation: mpRipple .6s ease-out; }
@keyframes mpRipple { 0% { opacity: 0; } 25% { opacity: 1; } 100% { opacity: 0; } }
.mp-resume { position: absolute; z-index: 6; bottom: 70px; inset-inline-start: 14px; display: flex; align-items: center; gap: 8px; background: rgba(0, 0, 0, .78); padding: 8px 10px 8px 14px; border-radius: 12px; font-size: 14px; }
.mp-resume button { padding: 6px 12px; border-radius: 8px; font-weight: 600; font-size: 13px; }
.mp-resume-yes { background: var(--accent); }
.mp-resume-no { background: rgba(255, 255, 255, .14); }
.mp-ui { position: absolute; z-index: 5; inset: auto 0 0 0; padding: 30px 12px 6px; background: linear-gradient(transparent, rgba(0, 0, 0, .85)); opacity: 0; transition: opacity .25s; }
.mp.mp-show .mp-ui, .mp.mp-paused .mp-ui, .mp:not(.mp-started) .mp-ui { opacity: 1; }
.mp:not(.mp-show):not(.mp-paused) { cursor: none; }
.mp-bar { position: relative; height: 18px; display: flex; align-items: center; cursor: pointer; touch-action: none; }
.mp-bar::before { content: ""; position: absolute; inset-inline: 0; height: 4px; background: rgba(255, 255, 255, .25); border-radius: 4px; transition: height .12s; }
.mp-buf, .mp-hov, .mp-fill { position: absolute; inset-inline-start: 0; height: 4px; border-radius: 4px; transition: height .12s; pointer-events: none; }
.mp-buf { background: rgba(255, 255, 255, .45); }
.mp-hov { background: rgba(255, 255, 255, .25); }
.mp-fill { background: var(--accent); }
.mp-bar:hover::before, .mp-bar:hover .mp-buf, .mp-bar:hover .mp-hov, .mp-bar:hover .mp-fill, .mp-drag .mp-bar::before, .mp-drag .mp-fill, .mp-drag .mp-buf { height: 6px; }
.mp-knob { position: absolute; inset-inline-end: -7px; top: 50%; width: 14px; height: 14px; margin-top: -7px; border-radius: 50%; background: var(--accent); transform: scale(0); transition: transform .12s; }
.mp-bar:hover .mp-knob, .mp-drag .mp-knob { transform: scale(1); }
.mp-tip { position: absolute; bottom: 22px; transform: translateX(-50%); background: rgba(0, 0, 0, .85); padding: 3px 8px; border-radius: 6px; font-size: 12px; font-weight: 600; direction: ltr; pointer-events: none; white-space: nowrap; }
.mp-row { display: flex; align-items: center; gap: 2px; height: 44px; }
.mp-b { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; color: #fff; opacity: .92; transition: background .15s; flex: none; }
.mp-b:hover { background: rgba(255, 255, 255, .12); opacity: 1; }
.mp-vol { display: flex; align-items: center; }
.mp-volr { width: 0; opacity: 0; transition: width .2s, opacity .2s; -webkit-appearance: none; appearance: none; height: 4px; border-radius: 4px; cursor: pointer;
  background: linear-gradient(to left, #fff var(--p, 100%), rgba(255, 255, 255, .3) var(--p, 100%)); }
html[dir="ltr"] .mp-volr { background: linear-gradient(to right, #fff var(--p, 100%), rgba(255, 255, 255, .3) var(--p, 100%)); }
.mp-vol:hover .mp-volr, .mp-volr:focus { width: 72px; opacity: 1; margin-inline: 4px 8px; }
.mp-volr::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; border-radius: 50%; background: #fff; }
.mp-volr::-moz-range-thumb { width: 12px; height: 12px; border: 0; border-radius: 50%; background: #fff; }
.mp-time { font-size: 13px; font-weight: 500; padding: 0 8px; direction: ltr; unicode-bidi: isolate; white-space: nowrap; opacity: .95; }
.mp-sp { flex: 1; }
.mp-set-wrap { position: relative; }
.mp-menu { position: absolute; bottom: 48px; inset-inline-end: 0; min-width: 150px; background: rgba(20, 20, 24, .96); border-radius: 12px; padding: 6px; box-shadow: 0 10px 40px rgba(0, 0, 0, .6); }
.mp-menu-h { font-size: 12px; color: #aaa; padding: 6px 10px; }
.mp-menu button { display: block; width: 100%; text-align: start; padding: 8px 10px; border-radius: 8px; font-size: 14px; direction: ltr; }
.mp-menu button:hover { background: rgba(255, 255, 255, .1); }
.mp-menu button.on { color: var(--accent); font-weight: 700; }
.mp-menu button.on::after { content: " ✓"; }
.mp.mp-fs { border-radius: 0; }
.mp.mp-fs video { object-fit: contain; }
.player-wrap .mp { border-radius: inherit; }
/* وضع السينما */
.theater .watch { grid-template-columns: 1fr; max-width: 1500px; }
.theater .player-wrap { max-height: calc(100vh - var(--top) - 40px); aspect-ratio: 16/9; margin-inline: auto; width: min(100%, calc((100vh - var(--top) - 40px) * 16 / 9)); }
.theater .watch-side { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.theater .side-shorts { grid-column: 1 / -1; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
@media (max-width: 860px) {
  .mp-desk, .mp-volr { display: none !important; }
  .mp-wm { top: 10px; font-size: 12px; }
  .mp-wm img { height: 18px; }
  .mp-big { width: 62px; height: 62px; }
  .mp-row { height: 40px; }
}
.speed-out { margin-top: 14px; display: flex; flex-direction: column; gap: 6px; }
.sp-row { display: flex; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: 10px; background: var(--bg); font-size: 14px; flex-wrap: wrap; }
.sp-row.bad b { color: #ff8a9b; }
.sp-row.good b { color: #8ff0b8; }
.sp-verdict { margin: 8px 0 0; padding: 12px; border-radius: 10px; background: color-mix(in srgb, var(--accent) 14%, transparent); }

/* ================= الترويج داخل المشغّل (1.5.0) ================= */
.mp-adon .mp-ui, .mp-adon .mp-big, .mp-adon .mp-tap, .mp-adon .mp-resume, .mp-adon .mp-pcard, .mp-adon .mp-etop { display: none !important; }
.mp-ad { position: absolute; inset: 0; z-index: 20; background: #000; display: flex; align-items: center; justify-content: center; }
.mp-ad-media { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.mp-ad-media video, .mp-ad-media img { width: 100%; height: 100%; object-fit: contain; }
.mp-ad-top { position: absolute; top: 12px; inset-inline-start: 12px; display: flex; gap: 8px; align-items: center; font-size: 13px; pointer-events: none; }
.mp-ad-badge { background: #f5c518; color: #111; font-weight: 700; padding: 2px 8px; border-radius: 6px; font-size: 12px; }
.mp-ad-time { background: rgba(0, 0, 0, .6); padding: 2px 8px; border-radius: 6px; }
.mp-ad-info { position: absolute; bottom: 18px; inset-inline-start: 12px; display: flex; align-items: center; gap: 10px; background: rgba(0, 0, 0, .72); padding: 8px 10px; border-radius: 12px; max-width: calc(100% - 190px); }
.mp-ad-info img { width: 44px; height: 44px; object-fit: cover; border-radius: 8px; flex: none; }
.mp-ad-title { font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.mp-ad-cta { flex: none; background: var(--accent); color: #fff; font-weight: 700; font-size: 13px; padding: 7px 14px; border-radius: 999px; white-space: nowrap; }
.mp-ad-cta:hover { filter: brightness(1.1); }
.mp-ad-skip { position: absolute; bottom: 18px; inset-inline-end: 0; display: flex; align-items: center; gap: 6px; background: rgba(0, 0, 0, .78); color: #fff;
  border: 1px solid rgba(255, 255, 255, .35); border-inline-end: 0; padding: 10px 16px; font-size: 14px; font-weight: 600; border-radius: 0; cursor: pointer; }
[dir=rtl] .mp-ad-skip svg { transform: scaleX(-1); }
.mp-ad-skip:disabled { cursor: default; color: #ccc; font-weight: 400; font-size: 13px; }
.mp-ad-skip:not(:disabled):hover { background: rgba(30, 30, 30, .95); }
.mp-ad-mute { position: absolute; top: 8px; inset-inline-end: 10px; width: 38px; height: 38px; border-radius: 50%; background: rgba(0, 0, 0, .55); color: #fff; display: grid; place-items: center; border: 0; cursor: pointer; }
.mp-ad-prog { position: absolute; bottom: 0; inset-inline: 0; height: 4px; background: rgba(255, 255, 255, .2); }
.mp-ad-prog i { display: block; height: 100%; width: 0; background: #f5c518; transition: width .25s linear; }
.mp-pcard { position: absolute; z-index: 7; bottom: 72px; inset-inline-start: 14px; max-width: min(380px, calc(100% - 28px)); display: flex; align-items: center; gap: 10px;
  background: rgba(15, 15, 18, .9); border: 1px solid rgba(255, 255, 255, .12); border-radius: 14px; padding: 8px; padding-inline-end: 34px;
  transform: translateY(14px); opacity: 0; transition: transform .3s, opacity .3s; backdrop-filter: blur(6px); }
.mp-pcard.on { transform: none; opacity: 1; }
.mp-pc-img img { width: 64px; height: 40px; border-radius: 8px; object-fit: cover; display: block; }
.mp-pc-txt { display: flex; flex-direction: column; min-width: 0; font-size: 13px; }
.mp-pc-txt strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mp-pc-badge { color: #f5c518; font-size: 11px; font-weight: 700; }
.mp-pc-cta { flex: none; background: #fff; color: #111; font-size: 12px; font-weight: 700; padding: 6px 12px; border-radius: 999px; white-space: nowrap; }
.mp-pc-x { position: absolute; top: 4px; inset-inline-end: 6px; width: 24px; height: 24px; border: 0; background: none; color: #aaa; font-size: 18px; cursor: pointer; line-height: 1; }
.mp-pc-x:hover { color: #fff; }
@media (max-width: 600px) {
  .mp-ad-info { bottom: 56px; max-width: calc(100% - 24px); }
  .mp-ad-skip { bottom: 10px; padding: 8px 12px; }
  .mp-pcard { bottom: 58px; }
  .mp-pc-img img { width: 48px; height: 32px; }
}

/* ================= صفحة التضمين ================= */
html:has(.embed-body), .embed-body { height: 100%; margin: 0; overflow: hidden; background: #000; }
.embed-body .mp { position: fixed; inset: 0; width: 100%; height: 100%; border-radius: 0; aspect-ratio: auto; max-height: none; }
.embed-body .mp video { width: 100%; height: 100%; object-fit: contain; background: #000; }
.mp-wm-link { pointer-events: auto; opacity: .6; transition: opacity .15s; }
.mp-wm-link:hover { opacity: 1; }
.mp-etop { position: absolute; z-index: 5; top: 0; inset-inline: 0; display: flex; align-items: center; gap: 10px; padding: 12px 14px 28px; padding-inline-end: 110px;
  background: linear-gradient(rgba(0, 0, 0, .75), transparent); color: #fff; opacity: 0; transition: opacity .2s; }
.mp.mp-show .mp-etop, .mp.mp-paused .mp-etop { opacity: 1; }
.mp-etop > svg { flex: none; opacity: .7; }
.mp-eav { width: 34px; height: 34px; border-radius: 50%; flex: none; object-fit: cover; display: grid; place-items: center; font-weight: 700; }
.mp-etxt { display: flex; flex-direction: column; min-width: 0; line-height: 1.35; }
.mp-etxt strong { font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mp-etxt span { font-size: 12px; color: #ccc; }
.mp-eend { position: absolute; z-index: 4; inset: 0; display: none; align-items: center; justify-content: center; background: rgba(0, 0, 0, .55); pointer-events: none; }
.mp.mp-ended .mp-eend { display: flex; }
.mp-eend-btn { pointer-events: auto; display: flex; align-items: center; gap: 8px; background: #fff; color: #111; font-weight: 700; padding: 10px 18px; border-radius: 999px; margin-top: 110px; }
.embed-msg { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: #ddd; text-align: center; padding: 16px; }
.embed-msg .logo-img { height: 30px; }

/* ================= نافذة المشاركة ================= */
.share-card { max-width: 560px; display: flex; flex-direction: column; gap: 14px; max-height: calc(100vh - 32px); overflow: auto; }
.share-h { display: flex; justify-content: space-between; align-items: center; }
.share-x { background: none; border: 0; color: var(--txt-2); font-size: 26px; line-height: 1; cursor: pointer; }
.share-tabs { display: flex; gap: 6px; background: var(--bg); padding: 4px; border-radius: 12px; }
.share-tabs button { flex: 1; border: 0; background: none; color: var(--txt-2); padding: 8px; border-radius: 9px; font-weight: 600; cursor: pointer; }
.share-tabs button.on { background: var(--bg-3); color: var(--txt); }
.share-pane { display: flex; flex-direction: column; gap: 12px; }
.share-socials { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 4px; }
.share-soc { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; color: var(--txt-2); background: none; border: 0; cursor: pointer; flex: none; min-width: 56px; }
.share-soc span { width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 18px; }
.copy-row { display: flex; gap: 8px; }
.copy-row input { flex: 1; min-width: 0; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--txt); font-size: 13px; }
.embed-prev { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: 12px; overflow: hidden; }
.embed-prev.tall { aspect-ratio: 9 / 16; max-width: 220px; margin: 0 auto; }
.embed-prev iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.embed-opts { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: end; }
.embed-opts .field { min-width: 180px; }
.em-code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px !important; direction: ltr; text-align: left; }

/* ================= لوحة الترويج ================= */
.b-on { background: rgba(46, 204, 113, .15); color: #6fe3a1; }
.b-off { background: rgba(255, 255, 255, .08); color: var(--txt-2); }
.b-wait { background: rgba(245, 197, 24, .15); color: #f5c518; }
.promo-cell { display: flex; gap: 10px; align-items: center; }
.promo-cell img, .pc-ic { width: 56px; height: 36px; border-radius: 8px; object-fit: cover; flex: none; background: var(--bg-3); display: grid; place-items: center; color: var(--txt-2); font-weight: 700; }
.promo-cell div { display: flex; flex-direction: column; }
.promo-prev { display: block; max-width: 260px; max-height: 150px; border-radius: 10px; margin: 6px 0; }
.choice-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.choice { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; font-size: 14px; }
.choice > span { display: flex; flex-direction: column; gap: 2px; }
.choice:has(input:checked) { border-color: var(--accent); background: #1d1216; }
.choice input { accent-color: var(--accent); margin-top: 3px; }
.fields3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.fields3 [hidden], .type-switch [hidden] { display: none !important; }
@media (max-width: 700px) { .choice-cards, .fields3 { grid-template-columns: 1fr; } .type-switch { flex-wrap: wrap; } }

/* ================= التشغيل التلقائي للتالي (1.6.0) ================= */
.mp-sw { position: relative; display: inline-block; width: 34px; height: 14px; border-radius: 999px; background: rgba(255, 255, 255, .35); transition: background .2s; vertical-align: middle; }
.mp-sw i { position: absolute; top: 50%; inset-inline-start: -2px; width: 20px; height: 20px; margin-top: -10px; border-radius: 50%; background: #ddd; color: #333;
  display: grid; place-items: center; transition: inset-inline-start .2s, background .2s; box-shadow: 0 1px 3px rgba(0, 0, 0, .4); }
.mp-sw i svg { display: block; }
.on > .mp-sw { background: color-mix(in srgb, var(--accent) 60%, transparent); }
.on > .mp-sw i { inset-inline-start: 16px; background: #fff; color: var(--accent); }
[dir=rtl] .mp-sw i svg { transform: scaleX(-1); }
.mp-auto { width: auto !important; padding: 0 6px; }
.mp-next { position: absolute; inset: 0; z-index: 8; background: rgba(0, 0, 0, .78); display: grid; place-items: center; padding: 16px; }
.mp-next-in { display: flex; flex-direction: column; gap: 12px; width: min(420px, 100%); }
.mp-next-l { color: #ccc; font-size: 14px; }
.mp-next-l b { color: #fff; font-size: 16px; }
.mp-next-card { display: flex; gap: 12px; align-items: center; color: #fff; }
.mp-next-card img { width: 160px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 10px; flex: none; }
.mp-next-card span { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.mp-next-card strong { font-size: 16px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mp-next-card small { color: #aaa; font-size: 13px; }
.mp-next-btns { display: flex; gap: 10px; }
.mp-next-btns > * { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 10px; border-radius: 999px; font-weight: 700; font-size: 14px; cursor: pointer; border: 0; }
.mp-next-no { background: rgba(255, 255, 255, .15); color: #fff; }
.mp-next-go { background: #fff; color: #111; }
@media (max-width: 600px) { .mp-next-card img { width: 110px; } .mp-next-card strong { font-size: 14px; } .mp-next-in { gap: 8px; } }
.auto-toggle { position: fixed; top: calc(var(--top) + 64px); inset-inline-end: 14px; z-index: 25; display: flex; align-items: center; gap: 6px;
  padding: 7px 10px; border-radius: 999px; background: rgba(0, 0, 0, .45); color: #fff; font-size: 12px; font-weight: 600; }
@media (max-width: 760px) { .auto-toggle { top: 108px; inset-inline-end: 6px; } }
.mp.mp-ended .mp-spin, .mp:has(.mp-next) .mp-spin, .mp:has(.mp-next) .mp-big { display: none !important; }

/* ================= خدمة البث: الجودة (1.7.0) ================= */
.mp-menu { max-height: min(70vh, 360px); overflow-y: auto; }
.mp-menu .mp-q small { color: #aaa; font-size: 12px; margin-inline-start: 4px; }
.mp-menu .mp-q b { font-size: 9px; background: var(--accent); color: #fff; padding: 0 4px; border-radius: 3px; margin-inline-start: 4px; vertical-align: 2px; }
.mp-menu-sep { height: 1px; background: rgba(255, 255, 255, .12); margin: 4px 0; }
.cdn-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--txt-2); margin-top: 8px; }
.cdn-bar { width: 120px; height: 6px; border-radius: 3px; background: var(--bg-3); overflow: hidden; }
.cdn-bar i { display: block; height: 100%; background: var(--accent); width: 0; transition: width .4s; }
.cdn-log { font-family: ui-monospace, Menlo, monospace; font-size: 12px; background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 10px; max-height: 220px; overflow: auto; direction: ltr; text-align: left; white-space: pre-wrap; }
.cdn-steps { margin: 0; padding-inline-start: 20px; line-height: 2; font-size: 14px; }
.cdn-steps code, .cron-line { direction: ltr; unicode-bidi: embed; }
.cron-line { display: block; background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 10px; font-size: 12px; word-break: break-all; text-align: left; }

/* ================= تناسق كل الأجهزة (1.7.3) ================= */
/* أزرار أكبر للمس */
.sf-follow { padding: 5px 14px; min-height: 30px; }
.shorts-tabs a { padding: 6px 6px 6px; }
.chip { min-height: 32px; display: inline-flex; align-items: center; }

/* تابلت (601–860): عمودين بدل عمود واحد عريض */
@media (min-width: 601px) and (max-width: 860px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 14px; }
  .grid .vthumb { margin: 0; border-radius: var(--r); }
  .shelf-row { grid-auto-columns: 26vw; }
  .grid-shorts { grid-template-columns: repeat(4, 1fr); gap: 6px; }
  .rows .vrow .vthumb, .vrow .vthumb { width: 38%; }
  .watch-side .side-shorts { grid-template-columns: repeat(4, 1fr); }
  .watch-side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .watch-side .side-shorts { grid-column: 1 / -1; }
  .auth-card { border: 1px solid var(--line); background: var(--bg-2); margin: 30px auto; padding: 30px; }
}
/* تابلت أفقي ولابتوب صغير (861–1200): الاقتراحات بعمودين تحت الفيديو */
@media (min-width: 861px) and (max-width: 1200px) {
  .watch-side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .watch-side .side-shorts { grid-column: 1 / -1; }
}
/* موبايل صغير جداً (≤360) */
@media (max-width: 360px) {
  .main, .side-mini .main { padding-left: 8px; padding-right: 8px; }
  .grid .vthumb { margin: 0 -8px; }
  .watch-title { font-size: 16px; }
  .actions { gap: 6px; }
  .pill { padding: 0 10px; }
  .bottomnav a { font-size: 9px; }
}
/* شاشات كبيرة: كروت أكبر ومحتوى بالنص */
@media (min-width: 1600px) {
  .grid { grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); }
  .shelf-row { grid-auto-columns: 220px; }
}
@media (min-width: 2200px) {
  .main > * { max-width: 2000px; margin-inline: auto; }
}
/* Shorts على الكمبيوتر: أزرار الصوت والتلقائي جنب الفيديو مش بطرف الشاشة */
@media (min-width: 861px) {
  .page-shorts { --sw: calc((100dvh - var(--top) - 32px) * 9 / 16); --mid: calc((100vw - var(--side)) / 2); }
  .page-shorts.side-mini { --mid: calc((100vw - var(--side-mini)) / 2); }
  .page-shorts .snd-toggle, .page-shorts .auto-toggle { inset-inline-end: auto; left: calc(var(--mid) - var(--sw) / 2 + 44px); }
  .page-shorts .snd-toggle { top: calc(var(--top) + 28px); }
  .page-shorts .auto-toggle { top: calc(var(--top) + 80px); }
}

/* داخل تطبيق أندرويد: التطبيق نفسه بيترك مكان أزرار النظام — منشيل الهامش المكرر */
html.in-app .bottomnav { height: var(--bottom) !important; padding-bottom: 0 !important; }
html.in-app .sfeed { height: calc(100dvh - var(--bottom)) !important; }
@media (min-width: 861px) { html.in-app .sfeed { height: calc(100dvh - var(--top)) !important; } }

/* ================= المكتبة: السجل، شاهد لاحقاً، القوائم (1.9.0) ================= */
.vprog { position: absolute; inset: auto 0 0 0; height: 4px; background: rgba(255, 255, 255, .3); z-index: 2; }
.vprog i { display: block; height: 100%; background: #ff2b4a; }
.pill.js-save.on { color: var(--accent); }
.pill.js-save.on .ic path { fill: currentColor; }
.save-card { max-width: 400px; display: flex; flex-direction: column; gap: 12px; }
.save-list { display: flex; flex-direction: column; max-height: 50vh; overflow: auto; }
.save-row { display: flex; align-items: center; gap: 12px; padding: 10px 4px; border-radius: 8px; cursor: pointer; font-size: 15px; }
.save-row:hover { background: var(--bg-3); }
.save-row input { width: 18px; height: 18px; accent-color: var(--accent); flex: none; }
.save-row span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.save-row small { color: var(--txt-2); font-size: 12px; }
.save-new { display: flex; gap: 6px; border-top: 1px solid var(--line); padding-top: 12px; }
.save-new input { flex: 1; min-width: 0; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--txt); }
.save-new select { padding: 8px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--txt); }

.lib-page { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 32px; max-width: 1300px; }
.lib-day { font-size: 17px; margin: 22px 0 12px; }
.lib-item { position: relative; display: flex; gap: 8px; align-items: flex-start; }
.lib-item > .vrow { flex: 1; min-width: 0; }
.lib-acts { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; flex: none; }
.lib-acts form { display: inline; }
.lib-acts .abtn[disabled] { opacity: .3; pointer-events: none; }
.lib-side { position: sticky; top: calc(var(--top) + 16px); align-self: start; display: flex; flex-direction: column; gap: 10px; }
.lib-search { display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--line); padding: 8px 2px; color: var(--txt-2); }
.lib-search input { flex: 1; border: 0; background: none; outline: 0; color: var(--txt); padding: 4px 0; }
.lib-btn { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; border-radius: 10px; background: none; border: 0; color: var(--txt); font-size: 14px; cursor: pointer; text-align: start; }
.lib-btn:hover { background: var(--bg-3); }

.you-head { display: flex; align-items: center; gap: 16px; margin: 6px 0 26px; }
.you-head h1 { margin: 0 0 4px; font-size: 24px; }
.shelf-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.shelf-top .shelf-h { margin: 0; }
.lib-row { grid-auto-columns: 250px; }
.lib-row .scard { width: 140px; }
.pl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px 14px; }
.plcard { display: flex; flex-direction: column; gap: 4px; }
.plcard-img { position: relative; aspect-ratio: 16/9; border-radius: var(--r); overflow: hidden; background: var(--bg-3); box-shadow: 0 -6px 0 -2px var(--bg-4), 0 -11px 0 -5px var(--bg-3); margin-top: 10px; }
.plcard-img img, .plcard-img .thumb-ph { width: 100%; height: 100%; object-fit: cover; }
.plcard-count { position: absolute; inset: auto 6px 6px auto; background: rgba(0, 0, 0, .8); border-radius: 6px; padding: 2px 8px; font-size: 12px; display: flex; gap: 4px; align-items: center; }

.pl-page { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 28px; max-width: 1300px; align-items: start; }
.pl-hero { position: sticky; top: calc(var(--top) + 12px); background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 35%, var(--bg-2)), var(--bg-2)); border-radius: 18px; padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.pl-hero h1 { margin: 4px 0 0; font-size: 24px; line-height: 1.3; word-break: break-word; }
.pl-cover { aspect-ratio: 16/9; border-radius: 12px; overflow: hidden; background: var(--bg-3); }
.pl-cover img, .pl-cover .thumb-ph { width: 100%; height: 100%; object-fit: cover; }
.pl-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.pl-edit summary { cursor: pointer; color: var(--txt-2); font-size: 14px; display: flex; gap: 6px; align-items: center; }
.pl-edit .form { display: flex; flex-direction: column; gap: 8px; margin: 10px 0; }
.pl-edit input, .pl-edit select { padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--txt); }
.danger-txt { color: #ff8a9b; }
.pl-items { display: flex; flex-direction: column; gap: 12px; }
.pl-num { width: 22px; flex: none; text-align: center; color: var(--txt-2); font-size: 13px; padding-top: 30px; }

.plpanel { background: var(--bg-2); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; margin-bottom: 14px; }
.plpanel-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 14px; background: var(--bg-3); }
.plpanel-h > div { display: flex; flex-direction: column; min-width: 0; }
.plpanel-h strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.plpanel-list { list-style: none; margin: 0; padding: 6px 0; max-height: 420px; overflow-y: auto; }
.plpanel-list a { display: flex; gap: 8px; align-items: center; padding: 6px 10px; }
.plpanel-list li.on a, .plpanel-list a:hover { background: var(--bg-3); }
.pl-n { width: 18px; flex: none; text-align: center; font-size: 12px; color: var(--txt-2); }
.plpanel-list li.on .pl-n { color: var(--accent); }
.pl-th { position: relative; width: 100px; flex: none; aspect-ratio: 16/9; border-radius: 6px; overflow: hidden; background: var(--bg-3); }
.pl-th img, .pl-th .thumb-ph { width: 100%; height: 100%; object-fit: cover; }
.pl-t { display: flex; flex-direction: column; min-width: 0; font-size: 13px; }
.pl-t strong { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-weight: 600; }

@media (max-width: 1000px) {
  .lib-page, .pl-page { grid-template-columns: 1fr; }
  .lib-side, .pl-hero { position: static; }
  .lib-side { order: -1; flex-direction: row; flex-wrap: wrap; }
  .lib-search { flex: 1 1 100%; }
  .lib-btn { width: auto; background: var(--bg-3); }
}
@media (max-width: 600px) {
  .lib-item { flex-wrap: wrap; }
  .lib-acts { width: 100%; }
  .lib-row { grid-auto-columns: 70vw; }
  .pl-num { display: none; }
  .you-head h1 { font-size: 20px; }
}

/* ================= الترجمة (1.10.0) ================= */
.mp video::cue { background: rgba(0, 0, 0, .78); color: #fff; font-family: var(--font); font-size: clamp(15px, 2.2vw, 26px); line-height: 1.4; }
.mp.mp-fs video::cue { font-size: clamp(18px, 2.6vw, 34px); }
.mp-cc.on { color: var(--accent); }
.mp-cc.on::after { content: ''; position: absolute; inset: auto 8px 6px; height: 2px; border-radius: 2px; background: var(--accent); }
.mp-cc { position: relative; }
.cc-ic { display: inline-grid; place-items: center; min-width: 26px; height: 18px; padding: 0 3px; border: 1.6px solid currentColor; border-radius: 4px; font-size: 10px; font-weight: 800; letter-spacing: .5px; }
.sub-list { display: flex; flex-direction: column; gap: 6px; }
.sub-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; background: var(--bg-3); }
.sub-row > span:nth-child(2) { flex: 1; }
.sub-form { display: flex; flex-direction: column; gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; }
.sub-form select { padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--txt); }

/* ================= إحصائيات القناة (1.10.0) ================= */
.an-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.an-head .page-h { margin-bottom: 4px; }
.seg { display: flex; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: 3px; }
.seg a { padding: 7px 14px; border-radius: 9px; font-size: 14px; color: var(--txt-2); }
.seg a.on { background: var(--bg-4); color: var(--txt); font-weight: 600; }
.an-kpis .kpi { text-align: start; cursor: default; color: var(--txt); font: inherit; }
.an-kpis button.kpi { cursor: pointer; }
.an-kpis .kpi.on { border-color: var(--accent); box-shadow: inset 0 -3px 0 var(--accent); }
.dl { font-size: 12px; font-weight: 600; }
.dl.up { color: #6fe3a1; }
.dl.down { color: #ff8a9b; }
.an-chart-panel { position: relative; padding: 14px 14px 8px; }
.an-chart { width: 100%; height: 240px; display: block; }
.an-line { fill: none; stroke: var(--accent); stroke-width: 2.5; vector-effect: non-scaling-stroke; }
.an-area { fill: color-mix(in srgb, var(--accent) 18%, transparent); }
.an-grid { stroke: var(--line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.an-axis { display: flex; justify-content: space-between; padding-top: 4px; }
.an-tip { position: absolute; top: 10px; inset-inline-start: 16px; background: var(--bg-4); padding: 4px 10px; border-radius: 8px; font-size: 13px; }
.an-h { font-size: 18px; margin: 26px 0 12px; }
.an-vid { display: flex; align-items: center; gap: 10px; min-width: 220px; }
.an-th { width: 72px; flex: none; aspect-ratio: 16/9; border-radius: 6px; overflow: hidden; background: var(--bg-3); }
.an-th img, .an-th .thumb-ph { width: 100%; height: 100%; object-fit: cover; }
.an-bar { display: inline-block; width: 60px; height: 6px; border-radius: 3px; background: var(--bg-3); vertical-align: middle; overflow: hidden; }
.an-bar i { display: block; height: 100%; background: var(--accent); }
.an-tbl td { white-space: nowrap; }

/* ============ 1.11 الربح: محفظة، دفع، عضويات، دورات، إعلانات، منتجات ============ */
.wal-kpis .kpi-n { font-size: 22px; direction: ltr; text-align: start; }
.wal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 18px; }
.wal-grid > .panel { margin: 0; }
.wal-form { display: flex; flex-direction: column; gap: 12px; }
.pay-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.pay-opt { display: flex; align-items: center; gap: 8px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; background: var(--bg); font-size: 14px; }
.pay-opt:has(input:checked) { border-color: var(--accent); background: rgba(255, 61, 90, .08); }
.pay-opt input { accent-color: var(--accent); }
.pay-opt[hidden] { display: none; }
.manual-box { display: flex; flex-direction: column; gap: 10px; padding: 12px; border: 1px dashed var(--line); border-radius: 12px; }
.manual-box[hidden] { display: none; }
.manual-info { background: var(--bg-3); border-radius: 10px; padding: 10px 12px; font-size: 14px; white-space: normal; unicode-bidi: plaintext; }
.manual-info:empty { display: none; }
.st { display: inline-block; font-size: 12px; font-weight: 600; padding: 1px 8px; border-radius: 999px; background: var(--bg-4); color: var(--txt-2); }
.st-paid, .st-approved { background: rgba(46, 204, 113, .15); color: #6fe3a1; }
.st-pending, .st-open { background: rgba(255, 193, 7, .14); color: #ffd36b; }
.st-rejected, .st-failed { background: rgba(255, 61, 90, .14); color: #ff8da0; }
.amt-in { color: #6fe3a1; font-weight: 600; direction: ltr; text-align: start; white-space: nowrap; }
.amt-out { color: #ff8da0; font-weight: 600; direction: ltr; text-align: start; white-space: nowrap; }
.row-pend td { opacity: .75; }
details.ref-d > summary { list-style: none; cursor: pointer; display: inline-flex; }
details.ref-d > summary::-webkit-details-marker { display: none; }
details.ref-d[open] .form { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; min-width: 220px; }
details.ref-d input { padding: 7px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: inherit; }
.mform { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.mform input, .mform-row input, .mform-row select, .prod-form input { padding: 7px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: inherit; font: inherit; font-size: 13px; min-width: 0; }
.mform-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
td.acts, .acts { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.abtn.ok { color: #6fe3a1; border-color: rgba(46, 204, 113, .35); }
.abtn.danger { color: #ff8da0; }
.fields3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 10px 0; }
.fields3 .check { align-self: center; }
.gw-h { font-size: 15px; margin: 16px 0 8px; display: flex; gap: 8px; align-items: center; }
.camp-prev { max-width: 160px; max-height: 90px; border-radius: 8px; display: block; margin-bottom: 4px; }
.wd-details { font-size: 13px; word-break: break-all; }
.small-n { font-size: 16px !important; }

/* باقات الإعلانات */
.pkg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; margin-bottom: 14px; }
.pkg-card { position: relative; display: flex; flex-direction: column; gap: 4px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg-2); cursor: pointer; transition: border-color .15s; }
.pkg-card input { position: absolute; inset-inline-end: 14px; top: 14px; accent-color: var(--accent); }
.pkg-card.on, .pkg-card:has(input:checked) { border-color: var(--accent); background: linear-gradient(180deg, rgba(255, 61, 90, .08), var(--bg-2)); }
.pkg-name { font-weight: 700; padding-inline-end: 22px; }
.pkg-price { font-size: 22px; font-weight: 700; direction: ltr; text-align: start; }

/* احترافي */
.pro-badge { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .5px; padding: 1px 7px; border-radius: 6px; background: linear-gradient(135deg, #ffd36b, #ff9f43); color: #1b1203; vertical-align: middle; direction: ltr; }
.pro-badge.big { font-size: 15px; padding: 3px 12px; }
.pro-hero { text-align: center; padding: 28px 16px 10px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.pro-hero h1 { margin: 6px 0 0; font-size: 28px; }
.pro-price { font-size: 30px; font-weight: 800; direction: ltr; }
.pro-price .small { font-weight: 400; }
.pro-feats { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; margin: 18px 0; }
.pro-feats .panel { margin: 0; }
.pro-feats .panel > svg { color: #ffc15e; }
.pro-feats h3 { margin: 8px 0 4px; font-size: 16px; }
.pro-feats p { margin: 0; font-size: 14px; }
.pro-cta { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.pro-cta > svg { color: #ffc15e; }
.pro-cta > div { flex: 1; min-width: 200px; }

/* محتوى مقفول */
.lock-gate { position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; display: grid; place-items: center; background: #000; isolation: isolate; }
.lock-gate::before { content: ''; position: absolute; inset: -20px; background: var(--lockbg, none) center / cover; filter: blur(18px) brightness(.35); z-index: -1; }
.lock-in { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 18px; max-width: 520px; max-height: 100%; overflow: auto; }
.lock-in > svg { color: #ffc15e; }
.lock-in h2 { margin: 0; font-size: 20px; }
.lock-in p { margin: 0; }
.tier-card { background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; text-align: start; width: 100%; }
.tier-card.on { border-color: #ffc15e; }
.tier-card form { margin: 0; }
.tier-price { color: #ffd36b; font-weight: 700; direction: ltr; display: inline-block; }
.tier-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; margin: 12px 0; }
.tier-grid > .panel { margin: 0; }
.btn-join { background: linear-gradient(135deg, #ffd36b, #ff9f43); color: #1b1203; }
.btn-join:hover { filter: brightness(1.06); }
.member-on { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.member-on > svg { color: #ffc15e; }
.member-on > div { flex: 1; }
.acc-badge { position: absolute; top: 8px; inset-inline-start: 8px; padding: 1px 7px; border-radius: 6px; font-size: 11.5px; font-weight: 700; background: rgba(0, 0, 0, .78); color: #ffd36b; direction: rtl; }
.watch-title .acc-badge, .st-main .acc-badge, .prod-row .acc-badge { position: static; display: inline-block; vertical-align: middle; font-size: 12px; background: var(--bg-3); }
.acc-pick { display: flex; flex-direction: column; gap: 8px; }
.acc-pick label { display: flex; flex-direction: column; gap: 6px; }
.acc-pick select, .acc-pick input { padding: 10px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: inherit; font: inherit; }
.acc-price[hidden] { display: none !important; }
.acc-hint { margin: 0; }

/* منتجات تحت الفيديو */
.prods { margin: 14px 0; }
.prods-h { display: flex; align-items: center; gap: 8px; font-weight: 600; margin-bottom: 8px; }
.aff-note { font-size: 11.5px; font-weight: 600; padding: 1px 8px; border-radius: 999px; background: var(--bg-3); color: var(--txt-2); cursor: help; }
.prods-row { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.prod { flex: 0 0 auto; display: flex; align-items: center; gap: 10px; max-width: 300px; padding: 10px 14px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line); transition: border-color .15s; }
.prod:hover { border-color: #3a3a44; }
.prod-ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--bg-3); flex: 0 0 auto; }
.prod-t { display: flex; flex-direction: column; min-width: 0; }
.prod-t strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
.prod-t small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prod-p { font-weight: 700; color: #6fe3a1; white-space: nowrap; }

/* الاستوديو */
.st-list { display: flex; flex-direction: column; gap: 8px; }
.st-item { display: grid; grid-template-columns: 140px 1fr auto; gap: 12px; align-items: center; padding: 8px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line); }
.st-item.open { border-color: #3a3a44; }
.st-thumb { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: 8px; overflow: hidden; }
.st-thumb img, .st-thumb .thumb-ph { width: 100%; height: 100%; object-fit: cover; }
.st-thumb .acc-badge, .st-thumb .dur { display: none; }
.st-main { display: flex; flex-direction: column; min-width: 0; }
.st-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-edit { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding: 8px 4px 4px; border-top: 1px solid var(--line); }
.st-edit .form { display: flex; flex-direction: column; gap: 10px; }
.st-prods .gw-h { margin-top: 0; }
.prod-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 8px 0; border-bottom: 1px solid var(--line); }
.prod-row .acts { margin-inline-start: auto; }
.prod-form { display: grid !important; grid-template-columns: 1fr 1fr; gap: 6px !important; margin-top: 10px; }
.prod-form button { grid-column: 1 / -1; justify-self: start; }

/* الدورات */
.course-hero .course-desc { color: var(--txt-2); font-size: 14px; margin: 8px 0; white-space: normal; }
.pl-item.locked { opacity: .6; }
.pl-item.locked .pl-num svg { color: #ffc15e; }
.course-card { display: flex; flex-direction: column; gap: 6px; padding: 18px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); }
.course-card:hover { border-color: #3a3a44; }
.course-ic { width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center; background: linear-gradient(135deg, rgba(255, 211, 107, .2), rgba(255, 159, 67, .1)); color: #ffc15e; }

/* القناة (احترافي) */
.ch-cover.has-img { background-size: cover; background-position: center; }
.ch-head[style*="--ch-accent"] .btn-white.js-follow { background: var(--ch-accent); color: #fff; }
.ch-links { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0; }
.ch-links a { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; padding: 3px 10px; border-radius: 999px; background: var(--bg-3); color: var(--txt); }
.ch-links a:hover { background: var(--bg-4); }
.ch-featured { display: grid; grid-template-columns: minmax(200px, 360px) 1fr; gap: 16px; align-items: center; margin-bottom: 20px; padding: 10px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); }
.ch-f-th { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; }
.ch-f-th img { width: 100%; height: 100%; object-fit: cover; }
.ch-featured > span:last-child { display: flex; flex-direction: column; gap: 4px; }
.ch-featured strong { font-size: 18px; }
.ch-banner-prev { max-width: 100%; max-height: 120px; border-radius: 10px; object-fit: cover; }
.menu-bal { margin-inline-start: auto; font-size: 12px; color: #6fe3a1; direction: ltr; }
.n-ic { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: rgba(46, 204, 113, .15); color: #6fe3a1; flex: 0 0 auto; }
.policy h2 { font-size: 18px; margin-top: 26px; }
.policy li { margin-bottom: 6px; }

@media (max-width: 860px) {
  .wal-grid, .st-edit, .fields3 { grid-template-columns: 1fr; }
  .st-item { grid-template-columns: 100px 1fr; }
  .st-item > .abtn { grid-column: 1 / -1; justify-self: start; }
  .ch-featured { grid-template-columns: 1fr; }
  .prod-form { grid-template-columns: 1fr; }
  .lock-gate { aspect-ratio: auto; min-height: 260px; border-radius: 0; margin: 0 -12px; }
}
.tabs { overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { white-space: nowrap; flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; }
@media (max-width: 860px) { .tabs a { padding: 10px 12px; } }

/* ============ 1.12 إدارة المستخدمين والمصاري ============ */
.u-tabs { margin-top: 8px; }
.nav-count.soft { background: var(--bg-4); color: var(--txt); }
.money-strip .kpi-n { font-size: 18px; direction: ltr; text-align: start; }
.sep-line { height: 1px; background: var(--line); margin: 14px 0; }
.nowrap { white-space: nowrap; }
.ref-card.is-open { border-color: rgba(255, 193, 7, .45); }
.ref-top { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
.ref-reason { margin: 10px 0; padding: 10px 12px; border-radius: 10px; background: var(--bg-3); font-size: 14px; unicode-bidi: plaintext; }
.ref-actions { display: grid; grid-template-columns: 2fr 1fr; gap: 14px; align-items: end; margin-top: 8px; }
.ref-form { display: flex; flex-direction: column; gap: 8px; }
.ref-form label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--txt-2); }
.ref-form label.check { flex-direction: row; align-items: center; }
.ref-form input, .ref-form select { padding: 8px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--txt); font: inherit; font-size: 14px; }
details.ref-d[open] .ref-form { margin-top: 8px; min-width: 260px; }
.danger-txt { color: #ff8da0 !important; }
.toolbar select optgroup { color: var(--txt-2); }
@media (max-width: 860px) { .ref-actions { grid-template-columns: 1fr; } }
/* القوائم المنسدلة بالفورمات (كانت تطلع بيضا) */
.form select, .mform select, .mform-row select, .ref-form select, .acc-pick select, .st-edit select, .fields2 select, .fields3 select {
  padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--txt); font: inherit; font-size: 14px; min-height: 40px; max-width: 100%;
}
.mform select { min-height: 32px; padding: 4px 8px; font-size: 13px; }
.form select:focus, .mform select:focus, .ref-form select:focus { border-color: var(--accent); outline: 0; }
select option { background: var(--bg-2); color: var(--txt); }
.audit-list { margin: 8px 0 0; padding-inline-start: 18px; display: flex; flex-direction: column; gap: 4px; font-size: 14px; }
.audit-item.sev-high { border-color: rgba(255, 61, 90, .45); }
.audit-item.sev-mid { border-color: rgba(255, 193, 7, .35); }
.audit-ok { display: flex; gap: 12px; align-items: center; color: #6fe3a1; }
