:root {
    --bg: #07111f;
    --card: #0d1b2a;
    --card2: #102338;
    --border: #20364d;
    --text: #eef6ff;
    --muted: #91a6bb;
    --accent: #29a8ff;
    --accent2: #1678c5;
    --danger: #ff5d73;
    --success: #49d17d;
}
* { box-sizing: border-box; }
body {
    margin: 0;
    background: linear-gradient(145deg, #06101c, #0b1828);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
    min-height: 100vh;
}
.app { width: 100%; }
.header {
    border-bottom: 1px solid var(--border);
    background: rgba(5, 14, 25, .92);
    padding: 22px;
}
.brand {
    max-width: 980px;
    margin: auto;
    display: flex;
    align-items: center;
    gap: 15px;
}
.brand-icon {
    width: 48px; height: 48px; border-radius: 12px;
    display: grid; place-items: center;
    background: var(--accent);
    color: #00111f; font-weight: 900; font-size: 22px;
}
h1, h2, p { margin: 0; }
.brand h1 { font-size: 21px; }
.brand p { margin-top: 4px; color: var(--muted); font-size: 13px; }
.container { max-width: 980px; margin: 28px auto; padding: 0 16px; }
.card {
    background: rgba(13, 27, 42, .96);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 22px;
    margin-bottom: 18px;
    box-shadow: 0 14px 40px rgba(0,0,0,.16);
}
.section-title { display: flex; gap: 13px; align-items: flex-start; margin-bottom: 20px; }
.section-title > span {
    width: 30px; height: 30px; border-radius: 50%;
    background: var(--accent); color: #00111f;
    display: grid; place-items: center; font-weight: 800; flex: 0 0 auto;
}
.section-title h2 { font-size: 17px; }
.section-title p { color: var(--muted); font-size: 13px; margin-top: 5px; }
.source-tabs { display: flex; gap: 8px; margin-bottom: 14px; }
.source-tab {
    border: 1px solid var(--border); background: #0a1725; color: var(--muted);
    border-radius: 9px; padding: 10px 14px; cursor: pointer;
}
.source-tab.active { color: white; background: var(--accent2); border-color: var(--accent); }
.file-picker {
    display: block; border: 1px dashed #3a5872; border-radius: 13px;
    background: #0a1725; cursor: pointer; padding: 30px 15px;
    text-align: center;
}
.file-picker input { display: none; }
.file-picker-content { display: grid; gap: 7px; }
.upload-icon { font-size: 30px; }
.file-picker strong { font-size: 15px; }
.file-picker span { color: var(--muted); font-size: 13px; }
.selected-file {
    margin-top: 14px; padding: 12px; border: 1px solid var(--border);
    border-radius: 11px; display: flex; align-items: center; gap: 12px;
}
.file-icon { font-size: 22px; }
.file-info { min-width: 0; flex: 1; display: grid; gap: 4px; }
.file-info strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-info span { color: var(--muted); font-size: 12px; }
.remove-button {
    border: 0; background: transparent; color: var(--danger);
    font-size: 26px; cursor: pointer;
}
.magnet-row { display: flex; gap: 9px; }
.text-input {
    width: 100%; min-width: 0; border: 1px solid var(--border);
    background: #071522; color: white; border-radius: 10px;
    padding: 13px; outline: none;
}
.text-input:focus { border-color: var(--accent); }
.primary-button {
    border: 0; background: var(--accent); color: #00111f;
    border-radius: 10px; padding: 0 20px; font-weight: 800; cursor: pointer;
}
.status {
    padding: 11px 13px; border-radius: 9px; background: #091725;
    color: var(--muted); font-size: 13px; margin-bottom: 12px;
}
.video-files { display: grid; gap: 9px; }
.video-file {
    border: 1px solid var(--border); border-radius: 11px;
    padding: 13px; display: flex; align-items: center; gap: 12px;
}
.video-file .meta { flex: 1; min-width: 0; }
.video-file strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.video-file small { color: var(--muted); display: block; margin-top: 5px; }
.stream-button {
    border: 1px solid var(--accent); color: white; background: var(--accent2);
    border-radius: 8px; padding: 8px 12px; cursor: pointer;
}
.player-wrapper {
    position: relative; background: #000; border-radius: 12px;
    overflow: hidden; aspect-ratio: 16 / 9;
}
video { width: 100%; height: 100%; display: block; background: #000; }
.player-overlay {
    position: absolute; inset: 0; display: grid; place-items: center;
    background: rgba(0,0,0,.52); pointer-events: none;
}
.play-placeholder { display: grid; place-items: center; gap: 10px; color: #c5d2df; }
.big-play {
    width: 62px; height: 62px; border-radius: 50%;
    background: var(--accent); color: #00111f; display: grid; place-items: center;
    font-size: 25px; padding-left: 3px;
}
.player-status { display: flex; align-items: center; gap: 8px; margin-top: 12px; color: var(--muted); font-size: 13px; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--success); }
.hidden { display: none !important; }
footer { text-align: center; color: #61788e; font-size: 12px; padding: 10px 16px 30px; }
@media (max-width: 600px) {
    .container { margin-top: 16px; }
    .card { padding: 16px; }
    .magnet-row { flex-direction: column; }
    .primary-button { padding: 12px; }
    .video-file { align-items: flex-start; }
}
