.stream-product {
    --orange: #3F51B5;
    --orange-hover: #303F9F;
    --orange-pressed: #1A237E;
    --danger: #C62828;
    --danger-hover: #B71C1C;
    --danger-pressed: #8E0000;
    --dark: #0b0b0b;
    --accent: #C5CAE9;
    --warning: #F5C518;
    --gray: #8a8a8a;
    --light: #f3f3f3;
    --white: #ffffff;
    --green: #39FF14;
    --green-hover: #2EE60F;
    --green-pressed: #24CC0A;
    --dot-off: #d2d0d1;
    --slate-immediate: #C62828;
    --slate-scheduled: #7b1fa2;
    --secondary-pressed: #E8EAF6;
    --srs: #2c3e50;
    --font: "Segoe UI", Tahoma, sans-serif;
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.stream-product .app-shell {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.stream-product .product-bar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: baseline;
    padding: 10px 20px;
    background: var(--white);
    border-bottom: 1px solid #ececec;
    flex-shrink: 0;
}

.stream-product .product-bar .brand {
    display: flex;
    align-items: baseline;
    gap: 8px;
    justify-self: start;
}

.stream-product .product-bar .brand-name {
    color: var(--dark);
    font-size: 1.125rem;
    font-weight: 700;
    line-height: 1;
}

.stream-product .product-bar .brand-admin {
    margin-top: 0;
    color: var(--orange);
    font-size: 0.875rem;
    font-weight: 700;
}

.stream-product .product-bar .mode-label {
    justify-self: center;
    color: var(--orange);
    font-size: 0.875rem;
    font-weight: 700;
}

.stream-product .product-bar .service-status {
    justify-self: end;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
}

.stream-product .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--gray);
}

.stream-product .dot.ok { background: var(--green); }
.stream-product .dot.warn { background: var(--warning); }
.stream-product .dot.off { background: var(--danger); }

.stream-product .workspace {
    padding: 20px;
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 20px;
    min-height: 0;
    flex: 1;
}

.stream-product .card {
    background: var(--white);
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
    padding: 16px;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.stream-product .side-title {
    margin: 0 0 4px;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--dark);
}

.stream-product .side-sub {
    margin: 0 0 16px;
    font-size: 0.75rem;
    color: var(--orange);
}

.stream-product .search-box {
    background: var(--light);
    border-radius: 6px;
    padding: 10px 16px;
    margin-bottom: 10px;
}

.stream-product .search-box input {
    width: 100%;
    border: none;
    outline: none;
    background: transparent;
    font-size: 1rem;
    color: var(--dark);
}

.stream-product .search-box input::placeholder {
    color: var(--orange);
    opacity: 0.7;
}

.stream-product .channel-list {
    flex: 1;
    overflow: auto;
    margin: 0 -4px;
    padding: 0 4px;
}

.stream-product .channel-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 10px 12px;
    margin: 2px 0;
    border-radius: 6px;
    cursor: pointer;
    border: none;
    width: 100%;
    text-align: left;
    background: transparent;
}

.stream-product .channel-item:hover { background: var(--light); }

.stream-product .channel-item.selected {
    background: var(--orange);
    color: var(--white);
}

.stream-product .channel-item.selected .meta,
.stream-product .channel-item.selected .hint {
    color: rgba(255,255,255,0.9);
}

.stream-product .dots-col {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
}

.stream-product .dot-lg {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.stream-product .dot-sm {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.stream-product .dot-active { background: var(--green); }
.stream-product .dot-inactive { background: var(--dot-off); }

.stream-product .ch-name {
    font-size: 0.875rem;
    font-weight: 600;
    margin: 0 0 2px;
}

.stream-product .ch-name.inactive-weight { font-weight: 400; }

.stream-product .hint {
    font-size: 0.7rem;
    opacity: 0.72;
    margin: 0 0 4px;
}

.stream-product .meta {
    font-size: 0.7rem;
    color: var(--gray);
    margin: 0;
}

.stream-product .slate-mark {
    margin: 4px 0 0;
    font-size: 0.625rem;
    font-weight: 600;
    color: var(--dark);
}

.stream-product .channel-item.selected .slate-mark {
    color: var(--white);
}

.stream-product .live-pill {
    background: var(--green);
    color: var(--dark);
    font-size: 0.56rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
}

.stream-product .live-pill.slate {
    background: var(--dark);
    color: var(--white);
}

.stream-product .side-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 16px;
}

.stream-product .edit-footer-checks {
    margin-top: 16px;
    margin-bottom: 8px;
}

.stream-product .edit-actions {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
    align-items: center;
}

.stream-product .btn {
    border-radius: 6px;
    height: 42px;
    padding: 0 14px;
    cursor: pointer;
    border: 2px solid transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-weight: 500;
    font-size: 0.875rem;
}

.stream-product .btn:disabled { opacity: 0.5; cursor: not-allowed; }

.stream-product .btn i {
    font-size: 1em;
    line-height: 1;
}

.stream-product .btn-secondary {
    background: var(--white);
    color: var(--orange);
    border-color: var(--orange);
}

.stream-product .btn-secondary:hover:not(:disabled) { background: var(--light); }

.stream-product .btn-secondary:active:not(:disabled) { background: var(--secondary-pressed); }

.stream-product .btn-primary {
    background: var(--orange);
    color: var(--white);
    border-color: var(--orange);
}

.stream-product .btn-primary:hover:not(:disabled) { background: var(--orange-hover); border-color: var(--orange-hover); }

.stream-product .btn-primary:active:not(:disabled) { background: var(--orange-pressed); border-color: var(--orange-pressed); }

.stream-product .btn-success {
    background: var(--green);
    color: var(--dark);
    border-color: var(--green);
}

.stream-product .btn-success:hover:not(:disabled) { background: var(--green-hover); border-color: var(--green-hover); }

.stream-product .btn-success:active:not(:disabled) { background: var(--green-pressed); border-color: var(--green-pressed); }

.stream-product .btn-danger {
    background: var(--danger);
    color: var(--white);
    border-color: var(--danger);
}

.stream-product .btn-danger:hover:not(:disabled) { background: var(--danger-hover); border-color: var(--danger-hover); }

.stream-product .btn-danger:active:not(:disabled) { background: var(--danger-pressed); border-color: var(--danger-pressed); }

.stream-product .btn-sm {
    height: 36px;
    min-width: 110px;
    font-size: 0.85rem;
}

.stream-product .main-card {
    padding: 12px 16px 16px;
}

.stream-product .tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.stream-product .tab {
    border: none;
    background: transparent;
    padding: 12px 20px;
    border-radius: 6px 6px 0 0;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--dark);
}

.stream-product .tab:hover { background: var(--light); }

.stream-product .tab.active {
    background: var(--orange);
    color: var(--white);
}

.stream-product .panel-scroll {
    overflow: auto;
    flex: 1;
    padding-right: 4px;
}

.stream-product .section-title {
    margin: 0 0 16px;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--dark);
}

.stream-product .section-sub {
    margin: -10px 0 16px;
    font-size: 0.75rem;
    color: var(--orange);
}

.stream-product .inner-card {
    background: var(--white);
    border: 1px solid #ececec;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 16px;
}

.stream-product .inner-card h3 {
    margin: 0 0 12px;
    font-size: 0.95rem;
}

.stream-product .info-label {
    margin: 10px 0 0;
    font-size: 0.75rem;
    color: var(--dark);
    font-weight: 500;
}

.stream-product .info-value {
    margin: 2px 0 8px;
    font-size: 0.95rem;
    word-break: break-word;
}

.stream-product .url-row {
    margin-bottom: 12px;
}

.stream-product .url-row-controls {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    align-items: center;
}

.stream-product .url-input {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 8px 10px;
    background: var(--light);
}

.stream-product .field {
    margin-bottom: 12px;
}

.stream-product .field label {
    display: block;
    font-size: 0.875rem;
    color: var(--dark);
    font-weight: 600;
    margin-bottom: 4px;
}

.stream-product .field-hint {
    margin: 6px 0 0;
    font-size: 0.75rem;
    color: var(--orange);
}

.stream-product .multiview-slot {
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}

.stream-product .multiview-slot:last-of-type {
    border-bottom: none;
}

.stream-product .field input[type="text"],
.stream-product .field input[type="password"],
.stream-product .field select,
.stream-product .field textarea {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 8px 10px;
    background: var(--white);
}

.stream-product .field input:disabled {
    background: var(--light);
    color: var(--gray);
    cursor: not-allowed;
}

.stream-product .checks {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin: 8px 0 14px;
}

.stream-product .checks label {
    display: flex;
    gap: 0.4rem;
    align-items: center;
    font-size: 0.875rem;
    font-weight: 400;
}

.stream-product .empty-state {
    background: var(--light);
    border-radius: 6px;
    padding: 48px 32px;
    text-align: center;
}

.stream-product .empty-state .icon {
    font-size: 2rem;
    margin-bottom: 12px;
    color: var(--dark);
}
.stream-product .empty-state strong { display: block; margin-bottom: 4px; }
.stream-product .empty-state p { margin: 0; color: var(--orange); font-size: 0.9rem; }

.stream-product .metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 16px;
}

.stream-product .monitor-actions {
    display: flex;
    justify-content: flex-start;
    margin: 0 0 24px;
}

.stream-product .monitor-actions .btn {
    min-width: 120px;
}

.stream-product .metric {
    border: 1px solid var(--gray);
    border-radius: 8px;
    padding: 16px;
    background: var(--white);
}

.stream-product .metric .label { font-size: 0.75rem; margin-bottom: 4px; }
.stream-product .metric .value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--orange);
    line-height: 1.1;
}
.stream-product .metric .value-accent { color: var(--warning); }
.stream-product .metric .value-dark { color: var(--dark); }
.stream-product .metric .caption { font-size: 0.75rem; color: var(--dark); }

.stream-product .dirty-banner {
    background: #fff6dd;
    color: #856404;
    border: 1px solid var(--warning);
    border-radius: 6px;
    padding: 10px 12px;
    font-size: 0.9rem;
    font-weight: 600;
}

.stream-product .evt-pill {
    display: inline-block;
    border-radius: 12px;
    padding: 4px 8px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.stream-product .evt-success { background: #eaf7ee; color: #155724; }
.stream-product .evt-warn { background: #fff3cd; color: #856404; }
.stream-product .evt-error { background: #ffebee; color: #b71c1c; }
.stream-product .evt-slate { background: #f3e5f5; color: #6a1b9a; }
.stream-product .evt-info { background: #d1ecf1; color: #0c5460; }
.stream-product .evt-amber { background: #fff8e1; color: #f57f17; }
.stream-product .evt-muted { background: #eceff1; color: #455a64; }
.stream-product .evt-neutral { background: #e2e3e5; color: #383d41; }

.stream-product .events-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}

.stream-product .events-table th,
.stream-product .events-table td {
    text-align: left;
    padding: 8px 10px;
    border-bottom: 1px solid #eee;
}

.stream-product .footerbar {
    background: var(--dark);
    color: var(--white);
    padding: 8px 20px;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.stream-product .footerbar.srs { background: var(--srs); }

.stream-product .msg {
    margin: 0 0 12px;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 0.88rem;
}

.stream-product .msg-error { background: #ffebee; color: #b71c1c; }
.stream-product .msg-ok { background: #eaf7ee; color: #155724; }

.stream-product .slate-time {
    margin-top: -4px !important;
    font-size: 0.85rem !important;
    color: var(--gray);
}

.stream-product .slate-badge {
    display: inline-block;
    background: var(--orange);
    color: var(--white);
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 0.7rem;
    margin-left: 8px;
    font-weight: 600;
}

.stream-product .slate-badge.immediate {
    background: var(--slate-immediate);
}

.stream-product .slate-badge.scheduled {
    background: var(--slate-scheduled);
}

@media (max-width: 980px) {

    .stream-product .workspace { grid-template-columns: 1fr; }
    .stream-product .metrics { grid-template-columns: 1fr; }
    .stream-product .url-row-controls { grid-template-columns: 1fr; }
}


.stream-product .core-banner {
    background: var(--danger);
    color: var(--white);
    text-align: center;
    font-weight: 700;
    font-size: 1rem;
    padding: 12px 20px;
}

.stream-product .confirm-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(11, 11, 11, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    padding: 20px;
}

.stream-product .confirm-dialog {
    background: var(--white);
    border: 2px solid var(--orange);
    border-radius: 8px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
    width: min(450px, 100%);
    max-width: 450px;
    padding: 20px;
}

.stream-product .confirm-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.stream-product .confirm-header h3 {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--danger);
}

.stream-product .confirm-close {
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 1rem;
    color: var(--dark);
    padding: 4px 8px;
    border-radius: 4px;
    line-height: 1;
}

.stream-product .confirm-close:hover {
    background: var(--light);
    color: var(--danger);
}

.stream-product .confirm-message {
    margin: 0 0 16px;
    font-size: 0.95rem;
    color: var(--dark);
    line-height: 1.45;
}

.stream-product .confirm-instruction {
    margin: 0 0 4px;
    font-size: 0.78rem;
    color: var(--dark);
    font-weight: 500;
}

.stream-product .confirm-input {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 8px 10px;
    margin-bottom: 20px;
}

.stream-product .confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.stream-product .confirm-busy {
    margin: 12px 0 0;
    text-align: center;
    color: var(--orange);
    font-weight: 600;
}

