/* ReadyLinks Design Center CSS - Premium Light Theme (UniFi Style) */

:root {
    --rl-blue: #005cf4;
    --rl-blue-hover: #004ecc;
    --rl-blue-soft: #ebf8ff;
    --rl-gray-bg: #f4f5f7;
    --rl-gray-border: #e2e8f0;
    --rl-gray-text: #718096;
    --rl-dark-text: #1a202c;
    --rl-light-bg: #ffffff;
    --rl-rack-u: 36px;
    --rl-rack-cage-bg: #edf2f7;
    --rl-rack-rail-bg: #d4d9e1;
}

body.rl-dc-body {
    background-color: var(--rl-gray-bg);
    color: var(--rl-dark-text);
    font-family: 'DM Sans', 'Open Sans', sans-serif;
    padding-bottom: 5rem; /* Space for persistent bottom bar */
}
/* The sitewide navbar is position:fixed with no top offset, so it pins to its
   static position (top of #header-main). Give the header wrapper real flow
   height so page content starts below the nav instead of underneath it. */
body.rl-dc-body #header-main {
    height: 53px;
}

/* Page header & intro */
.rl-dc-intro {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
}
.rl-dc-intro h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--rl-dark-text);
    margin-bottom: 0.25rem;
}
.rl-dc-intro p {
    color: var(--rl-gray-text);
    font-size: 0.9rem;
}
.rl-dc-intro-actions {
    display: flex;
    gap: 0.5rem;
}
.rl-dc-intro-actions .btn {
    font-size: 0.8rem;
    font-weight: 600;
    border-radius: 6px;
    padding: 0.35rem 0.75rem;
}

.rl-dc-project-row {
    margin-bottom: 1.5rem;
}

/* Unsaved-project banner (signed-out, UniFi-style) */
.rl-dc-auth-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.35rem;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 8px;
    color: #92400e;
    font-size: 0.85rem;
    padding: 0.55rem 1rem;
    margin-bottom: 1rem;
}
.rl-dc-auth-banner i {
    color: #f59e0b;
    margin-right: 0.25rem;
}
.rl-dc-auth-banner a {
    color: var(--rl-blue);
    font-weight: 600;
    text-decoration: none;
}
.rl-dc-auth-banner a:hover {
    text-decoration: underline;
}
.rl-dc-auth-banner-or {
    color: #b45309;
}

/* Project switcher (name + caret + saved-projects menu) */
.rl-dc-project-switcher {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    max-width: 100%;
}
.rl-dc-project-caret {
    border: 1px solid transparent;
    background: transparent;
    color: var(--rl-gray-text);
    border-radius: 6px;
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.15s;
}
.rl-dc-project-caret:hover {
    border-color: var(--rl-gray-border);
    background: var(--rl-light-bg);
    color: var(--rl-dark-text);
}
.rl-dc-save-btn {
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.2rem 0.65rem;
    flex-shrink: 0;
}
.rl-dc-save-status {
    font-size: 0.72rem;
    color: var(--rl-gray-text);
    white-space: nowrap;
}
.rl-dc-save-status.is-dirty {
    color: #b45309;
}
.rl-dc-save-status .fa-cloud {
    color: #10b981;
}
.rl-dc-save-status.is-error {
    color: #b45309;
}
.rl-dc-project-menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    z-index: 1060;
    min-width: 300px;
    max-width: 380px;
    background: #fff;
    border: 1px solid var(--rl-gray-border);
    border-radius: 10px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14);
    padding: 0.4rem;
    max-height: 340px;
    overflow-y: auto;
}
.rl-dc-pm-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    border: none;
    background: transparent;
    border-radius: 6px;
    padding: 0.5rem 0.6rem;
    font-size: 0.85rem;
    color: var(--rl-dark-text);
    cursor: pointer;
    text-align: left;
    text-decoration: none;
}
.rl-dc-pm-item:hover {
    background: var(--rl-light-bg);
    color: var(--rl-dark-text);
}
.rl-dc-pm-item.active {
    background: rgba(0, 92, 244, 0.08);
    color: var(--rl-blue);
    font-weight: 600;
}
.rl-dc-pm-item > i {
    color: var(--rl-gray-text);
    width: 16px;
    text-align: center;
    flex-shrink: 0;
}
.rl-dc-pm-item.active > i {
    color: var(--rl-blue);
}
.rl-dc-pm-name {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rl-dc-pm-date {
    font-size: 0.68rem;
    color: var(--rl-gray-text);
    flex-shrink: 0;
}
.rl-dc-pm-del {
    border: none;
    background: transparent;
    color: var(--rl-gray-text);
    border-radius: 4px;
    padding: 2px 5px;
    cursor: pointer;
    flex-shrink: 0;
    font-size: 0.75rem;
}
.rl-dc-pm-del:hover {
    color: #e53e3e;
    background: rgba(229, 62, 62, 0.08);
}
.rl-dc-pm-divider {
    height: 1px;
    background: var(--rl-gray-border);
    margin: 0.3rem 0.25rem;
}
.rl-dc-pm-action {
    color: var(--rl-blue);
    font-weight: 600;
}
.rl-dc-pm-action > i {
    color: var(--rl-blue);
}
.rl-dc-pm-empty {
    font-size: 0.78rem;
    color: var(--rl-gray-text);
    padding: 0.6rem 0.6rem 0.4rem;
}

.rl-dc-project-name {
    border: 1px solid transparent;
    border-radius: 6px;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--rl-dark-text);
    padding: 0.25rem 0.5rem;
    width: 100%;
    max-width: 28rem;
    background: transparent;
    transition: all 0.15s;
}
.rl-dc-project-name:hover {
    border-color: var(--rl-gray-border);
    background-color: var(--rl-light-bg);
}
.rl-dc-project-name:focus {
    border-color: var(--rl-blue);
    outline: none;
    background-color: var(--rl-light-bg);
    box-shadow: 0 0 0 1px var(--rl-blue);
}

/* Three-column layout grid */
.rl-dc-layout {
    display: grid;
    grid-template-columns: 380px minmax(440px, 1fr) 360px;
    gap: 1.5rem;
    align-items: start;
}

@media (max-width: 1199.98px) {
    .rl-dc-layout {
        grid-template-columns: 350px 1fr;
    }
    .rl-dc-right-column {
        grid-column: 1 / -1;
    }
}
@media (max-width: 767.98px) {
    .rl-dc-layout {
        grid-template-columns: 1fr;
    }
}

/* Card wrappers for columns */
.rl-dc-rack-column,
.rl-dc-catalog-container,
.rl-dc-int-group,
.rl-dc-edit-device-panel {
    background-color: var(--rl-light-bg);
    border: 1px solid var(--rl-gray-border);
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

/* Column 1: Rack Card Layout */
.rl-dc-rack-column {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
}
.rl-dc-rack-column-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--rl-gray-border);
    padding-bottom: 0.75rem;
    margin-bottom: 0.75rem;
}
.rl-dc-rack-column-header h2 {
    color: var(--rl-dark-text) !important;
    font-size: 0.95rem;
    font-weight: 700;
}

/* View toggle switch */
.rl-dc-rack-view-toggle {
    background: #edf2f7;
    padding: 2px;
    border-radius: 6px;
    display: inline-flex;
    gap: 1px;
}
.rl-dc-rack-view-toggle button {
    background: transparent;
    border: none;
    border-radius: 4px;
    color: var(--rl-gray-text);
    width: 30px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.15s;
    padding: 0;
}
.rl-dc-rack-view-toggle button:hover {
    color: var(--rl-dark-text);
}
.rl-dc-rack-view-toggle button.active {
    background-color: var(--rl-light-bg);
    color: var(--rl-blue);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Multiple rack tabs bar */
.rl-dc-rack-tabs-row {
    border-bottom: 1px solid var(--rl-gray-border);
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
}
.rl-dc-rack-tab {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--rl-gray-text);
    background-color: #edf2f7;
    border: 1px solid transparent;
    border-radius: 20px;
    padding: 3px 12px;
    cursor: pointer;
    transition: all 0.15s;
}
.rl-dc-rack-tab:hover {
    color: var(--rl-dark-text);
}
.rl-dc-rack-tab.active {
    color: var(--rl-light-bg);
    background-color: var(--rl-blue);
}
.rl-dc-rack-tab-add {
    border: 1px dashed #cbd5e0;
    background-color: transparent;
    color: var(--rl-gray-text);
}
.rl-dc-rack-tab-add:hover {
    border-color: var(--rl-blue);
    color: var(--rl-blue);
}

/* Cabinet Rack visual drawing */
.rl-dc-rack-scroll-wrap {
    max-height: 640px;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0.5rem;
    border: 1px solid var(--rl-gray-border);
    border-radius: 8px;
    background-color: #f7fafc;
    margin-bottom: 0.75rem;
}
.rl-dc-cabling-svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
}
.rl-dc-rack {
    width: 100%;
    max-width: 330px;
    margin: 0 auto;
}
.rl-dc-rack-top, 
.rl-dc-rack-base {
    height: 14px;
    background: linear-gradient(#edf2f7, #cbd5e0);
    border: 1px solid #cbd5e0;
}
.rl-dc-rack-top {
    border-radius: 8px 8px 0 0;
    border-bottom: none;
}
.rl-dc-rack-base {
    border-radius: 0 0 8px 8px;
    border-top: none;
    height: 20px;
}
.rl-dc-rack-cage {
    background-color: var(--rl-rack-cage-bg);
    border-left: 1px solid #cbd5e0;
    border-right: 1px solid #cbd5e0;
    padding: 6px 22px;
    position: relative;
}
/* rack mounting rails styling */
.rl-dc-rack-cage::before, 
.rl-dc-rack-cage::after {
    content: '';
    position: absolute;
    top: 6px;
    bottom: 6px;
    width: 14px;
    background: 
        radial-gradient(circle at 50% 8px, #718096 1.8px, #cbd5e0 2.4px, transparent 3px) 0 0 / 14px var(--rl-rack-u) repeat-y,
        radial-gradient(circle at 50% 24px, #718096 1.8px, #cbd5e0 2.4px, transparent 3px) 0 0 / 14px var(--rl-rack-u) repeat-y,
        var(--rl-rack-rail-bg);
    border-radius: 1px;
}
.rl-dc-rack-cage::before { left: 4px; }
.rl-dc-rack-cage::after { right: 4px; }

.rl-dc-rack-units {
    position: relative;
}
.rl-dc-u-row {
    position: absolute;
    left: 0;
    right: 0;
    height: var(--rl-rack-u);
    border-top: 1px dashed rgba(74, 85, 104, 0.1);
    pointer-events: none;
}
.rl-dc-u-num {
    position: absolute;
    left: -20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.55rem;
    font-weight: 700;
    color: var(--rl-gray-text);
    width: 15px;
    text-align: center;
}
.rl-dc-u-num-right {
    left: auto;
    right: -20px;
}

/* Placed devices in rack */
.rl-dc-device {
    position: absolute;
    left: 0;
    right: 0;
    border-radius: 2px;
    overflow: hidden;
    cursor: grab;
    background-color: #20242d;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(0,0,0,0.3);
    z-index: 2;
    display: flex;
    align-items: center;
}
.rl-dc-device:active {
    cursor: grabbing;
}
.rl-dc-device img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
}
.rl-dc-device:hover {
    border-color: var(--rl-blue);
}
.rl-dc-device.selected {
    border-color: var(--rl-blue);
    box-shadow: 0 0 0 2px var(--rl-blue), 0 1px 4px rgba(0,0,0,0.4);
    z-index: 3;
}
.rl-dc-device-tag {
    position: absolute;
    right: 4px;
    top: 3px;
    font-size: 0.55rem;
    font-weight: 700;
    color: var(--rl-light-bg);
    background-color: rgba(0, 0, 0, 0.65);
    padding: 1px 4px;
    border-radius: 2px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
}
.rl-dc-device:hover .rl-dc-device-tag, 
.rl-dc-device.selected .rl-dc-device-tag {
    opacity: 1;
}

/* Contiguous empty slot placeholders (+ Add Device) */
.rl-dc-rack-placeholder {
    position: absolute;
    left: 0;
    right: 0;
    border: 1px dashed #a0aec0;
    border-radius: 4px;
    background-color: rgba(255, 255, 255, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1;
    transition: all 0.15s ease-in-out;
}
.rl-dc-rack-placeholder:hover {
    border-color: var(--rl-blue);
    background-color: rgba(235, 248, 255, 0.7);
}
.rl-dc-rack-placeholder-btn {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--rl-gray-text);
    display: flex;
    align-items: center;
    gap: 4px;
}
.rl-dc-rack-placeholder:hover .rl-dc-rack-placeholder-btn {
    color: var(--rl-blue);
}

/* Placed Switch Selected Overlay Row */
.rl-dc-device-selected-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(255, 255, 255, 0.96);
    border: 1.5px solid var(--rl-blue);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 10px;
    z-index: 5;
    animation: fadeIn 0.1s;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
.rl-dc-device-overlay-name {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--rl-dark-text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 70%;
}
.rl-dc-device-overlay-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}
.rl-dc-device-overlay-btn {
    background: none;
    border: none;
    font-size: 0.75rem;
    color: #e53e3e;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.12s;
}
.rl-dc-device-overlay-btn:hover {
    background-color: #fff5f5;
    color: #c53030;
}

/* CSS-drawn rack accessory plates */
.rl-dc-acc {
    display: flex;
    align-items: center;
    justify-content: center;
}
.rl-dc-acc-label {
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    color: rgba(255,255,255,0.6);
    background-color: rgba(0,0,0,0.4);
    padding: 1px 6px;
    border-radius: 2px;
}
.rl-dc-acc-blank {
    background: linear-gradient(#262c37, #181d25);
}
.rl-dc-acc-shelf {
    background: linear-gradient(#2d3648 0 35%, #181c24 35% 100%);
}
.rl-dc-acc-cablemgr {
    background: 
        linear-gradient(90deg, transparent 0 12px, #2a3240 12px 36px, transparent 36px 48px) 0 0 / 48px 100% repeat-x,
        #13171f;
}
.rl-dc-acc-pdu {
    background: 
        linear-gradient(90deg, transparent 0 14px, #000 14px 28px, transparent 28px 44px) 15px 0 / 44px 50% no-repeat,
        #2a3240;
}
.rl-dc-acc-patch24 {
    background: 
        radial-gradient(circle at 6px 50%, #000 3.2px, #3b4657 4.2px, transparent 5px) 10px 0 / 23px 100% repeat-x,
        #222933;
}
.rl-dc-acc-patch48 {
    background: 
        radial-gradient(circle at 6px 30%, #000 3.2px, #3b4657 4.2px, transparent 5px) 10px 0 / 23px 100% repeat-x,
        radial-gradient(circle at 6px 70%, #000 3.2px, #3b4657 4.2px, transparent 5px) 10px 0 / 23px 100% repeat-x,
        #222933;
}
.rl-dc-acc-ups {
    background: 
        linear-gradient(#000, #000) 10px 50% / 50px 35% no-repeat,
        linear-gradient(#2d3648, #181c24);
}

/* Column 2: Integrations / Middle Panel */
.rl-dc-middle-column {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* Integration categories white cards — compact when empty */
.rl-dc-int-group {
    padding: 0.45rem 0.65rem;
    margin-bottom: 0.45rem;
    display: flex;
    flex-direction: column;
}
.rl-dc-int-group.rl-dc-int-group-has-items {
    padding: 1rem 1.1rem;
    margin-bottom: 0.85rem;
}
.rl-dc-int-group-header {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    margin-bottom: 0;
    padding: 0.2rem 0.35rem;
    margin-left: -0.35rem;
    margin-right: -0.35rem;
}
.rl-dc-int-group-has-items .rl-dc-int-group-header {
    gap: 0.6rem;
    margin-bottom: 0.65rem;
    padding: 0.4rem 0.5rem;
    margin-left: -0.5rem;
    margin-right: -0.5rem;
}
.rl-dc-int-group-icon {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background-color: var(--rl-blue-soft);
    color: var(--rl-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    flex-shrink: 0;
}
.rl-dc-int-group-has-items .rl-dc-int-group-icon {
    width: 30px;
    height: 30px;
    font-size: 0.82rem;
}
.rl-dc-int-group[data-group="ipc"] .rl-dc-int-group-icon {
    background-color: #e6fffa;
    color: #319795;
}
.rl-dc-int-group[data-group="edge"] .rl-dc-int-group-icon {
    background-color: #faf5ff;
    color: #805ad5;
}

/* Clickable header row filter */
.rl-dc-int-bubble {
    cursor: pointer;
    user-select: none;
    border-radius: 8px;
    transition: background 0.15s, box-shadow 0.15s;
}
.rl-dc-int-bubble:hover {
    background: rgba(0, 92, 244, 0.05);
}
.rl-dc-int-bubble.active {
    background: rgba(0, 92, 244, 0.08);
    box-shadow: inset 0 0 0 1.5px var(--rl-blue);
}
.rl-dc-int-bubble.active .rl-dc-int-group-title {
    color: var(--rl-blue);
}
.rl-dc-int-bubble-arrow {
    font-size: 0.65rem;
    opacity: 0.35;
    transition: opacity 0.15s, transform 0.15s;
}
.rl-dc-int-bubble:hover .rl-dc-int-bubble-arrow {
    opacity: 0.6;
}
.rl-dc-int-bubble.active .rl-dc-int-bubble-arrow {
    opacity: 1;
    color: var(--rl-blue);
    transform: rotate(90deg);
}
.rl-dc-int-group-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--rl-dark-text);
}
.rl-dc-int-group-has-items .rl-dc-int-group-title {
    font-size: 0.9rem;
}
.rl-dc-int-group-add {
    background: none;
    border: none;
    color: var(--rl-blue);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 2px;
    line-height: 1;
    transition: color 0.15s;
}
.rl-dc-int-group-add:hover {
    color: var(--rl-blue-hover);
}

.rl-dc-int-group-items {
    padding-top: 0;
}
.rl-dc-int-group-has-items .rl-dc-int-group-items {
    border-top: 1px solid var(--rl-gray-border);
    padding-top: 0.5rem;
}
.rl-dc-int-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.65rem 0;
    border-bottom: 1px dashed var(--rl-gray-border);
}
.rl-dc-int-item:last-child {
    border-bottom: none;
}
.rl-dc-int-item-details {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-width: 0;
    flex: 1;
}
.rl-dc-int-item-thumb {
    width: 50px;
    height: 32px;
    background-color: #edf2f7;
    border: 1px solid var(--rl-gray-border);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}
.rl-dc-int-item-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.rl-dc-int-item-thumb i {
    color: var(--rl-gray-text);
    font-size: 0.95rem;
}
.rl-dc-int-item-meta {
    display: flex;
    flex-direction: column;
    min-width: 0;
    gap: 0.1rem;
}
.rl-dc-int-item-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: #1a202c;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.25;
}
.rl-dc-int-item-pn {
    font-size: 0.65rem;
    font-weight: 600;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    color: #718096;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.2;
}

/* Stepper input */
.rl-dc-int-item-stepper {
    display: flex;
    align-items: center;
    background-color: #f7fafc;
    border: 1px solid var(--rl-gray-border);
    border-radius: 18px;
    padding: 2px 4px;
}
.rl-dc-int-item-stepper button {
    background: transparent;
    border: none;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--rl-gray-text);
    cursor: pointer;
    user-select: none;
    transition: color 0.12s;
    padding: 0;
}
.rl-dc-int-item-stepper button:hover {
    color: var(--rl-dark-text);
}
.rl-dc-int-input,
.rl-dc-int-qty {
    width: 40px;
    border: none;
    background: transparent;
    text-align: center;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--rl-dark-text);
    -moz-appearance: textfield;
    appearance: textfield;
    pointer-events: none;
    padding: 0;
    display: inline-block;
    line-height: 24px;
}
/* Typeable quantity inputs (integrations panel + All Devices list) */
.rl-dc-int-qty-input {
    pointer-events: auto;
    border-radius: 4px;
}
.rl-dc-list-input {
    width: 40px;
    border: none;
    background: transparent;
    text-align: center;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--rl-dark-text);
    -moz-appearance: textfield;
    appearance: textfield;
    padding: 0;
    border-radius: 4px;
}
.rl-dc-bom-qty-input {
    width: 36px;
    border: none;
    background: transparent;
    text-align: center;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--rl-dark-text);
    -moz-appearance: textfield;
    appearance: textfield;
    padding: 0;
    border-radius: 4px;
}
.rl-dc-int-qty-input:focus,
.rl-dc-list-input:focus,
.rl-dc-bom-qty-input:focus {
    outline: none;
    background: #fff;
    box-shadow: 0 0 0 1px var(--rl-blue);
}
.rl-dc-int-qty-input::-webkit-outer-spin-button,
.rl-dc-int-qty-input::-webkit-inner-spin-button,
.rl-dc-list-input::-webkit-outer-spin-button,
.rl-dc-list-input::-webkit-inner-spin-button,
.rl-dc-bom-qty-input::-webkit-outer-spin-button,
.rl-dc-bom-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Edit Device Container (Column 2 Overlay when switch is selected) */
.rl-dc-edit-device-panel {
    padding: 1.25rem;
    margin-bottom: 1.25rem;
    display: flex;
    flex-direction: column;
}
.rl-dc-ed-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--rl-gray-border);
    padding-bottom: 0.75rem;
    margin-bottom: 1rem;
}
.rl-dc-ed-header h3 {
    color: var(--rl-dark-text) !important;
    font-size: 0.95rem;
    font-weight: 700;
    margin: 0;
}
.rl-dc-ed-body label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--rl-gray-text);
    letter-spacing: 0.05em;
    margin-bottom: 0.35rem;
    display: block;
}

/* Accordion sections inside Edit Device */
.rl-dc-ed-accordion {
    margin-top: 1rem;
}
.rl-dc-ed-acc-item {
    border: 1px solid var(--rl-gray-border);
    border-radius: 8px;
    margin-bottom: 0.75rem;
    overflow: hidden;
}
.rl-dc-ed-acc-trigger {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background-color: #f7fafc;
    border: none;
    font-size: 0.8rem;
    font-weight: 700;
    color: #4a5568;
    cursor: pointer;
    border-bottom: 1px solid transparent;
    transition: all 0.15s;
    outline: none;
}
.rl-dc-ed-acc-item.active .rl-dc-ed-acc-trigger {
    border-bottom-color: var(--rl-gray-border);
    background-color: #edf2f7;
}
.rl-dc-ed-acc-trigger i {
    font-size: 0.75rem;
    transition: transform 0.2s;
}
.rl-dc-ed-acc-item.active .rl-dc-ed-acc-trigger i {
    transform: rotate(180deg);
}

.rl-dc-ed-acc-content {
    padding: 1rem;
    background-color: var(--rl-light-bg);
    display: none;
}
.rl-dc-ed-acc-item.active .rl-dc-ed-acc-content {
    display: block;
}

/* Switch port grid styling */
.rl-dc-ed-ports-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    background-color: #f7fafc;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    margin-bottom: 1rem;
}
.rl-dc-port {
    width: 22px;
    height: 22px;
    background-color: #edf2f7;
    border: 1px solid #cbd5e0;
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: all 0.1s;
    user-select: none;
}
.rl-dc-port:hover {
    background-color: #e2e8f0;
    border-color: #a0aec0;
    transform: scale(1.05);
}
.rl-dc-port-led {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background-color: #cbd5e0;
    position: absolute;
    top: 2px;
    right: 2px;
}
.rl-dc-port-label {
    font-size: 0.5rem;
    font-weight: 700;
    color: #4a5568;
    pointer-events: none;
}

.rl-dc-port.connected {
    background-color: #005cf4;
    border-color: #2b6cb0;
}
.rl-dc-port.connected .rl-dc-port-label {
    color: #ffffff;
}
.rl-dc-port.connected.poe-active {
    background-color: #10b981;
    border-color: #2f855a;
}
.rl-dc-port.connected.poe-active .rl-dc-port-label {
    color: #ffffff;
}
.rl-dc-port.uplink-active {
    background-color: #f59e0b;
    border-color: #d69e2e;
}
.rl-dc-port.uplink-active .rl-dc-port-label {
    color: #ffffff;
}
/* 10Gb fiber (SFP+) ports — light blue */
.rl-dc-port.sfp {
    background-color: #bee3f8;
    border-color: #63b3ed;
}
.rl-dc-port.sfp .rl-dc-port-label {
    color: #2c5282;
}
/* 25Gb fiber (SFP28) ports — a step darker than SFP+ */
.rl-dc-port.sfp28 {
    background-color: #90cdf4;
    border-color: #4299e1;
}
.rl-dc-port.sfp28 .rl-dc-port-label {
    color: #2a4365;
}
/* 40/100Gb fiber (QSFP) ports — darkest blue */
.rl-dc-port.qsfp {
    background-color: #4299e1;
    border-color: #2b6cb0;
}
.rl-dc-port.qsfp .rl-dc-port-label {
    color: #ffffff;
}
/* Connected/uplink states still take over the fiber base colors */
.rl-dc-port.sfp.connected,
.rl-dc-port.sfp28.connected,
.rl-dc-port.qsfp.connected {
    background-color: #005cf4;
    border-color: #2b6cb0;
}
.rl-dc-port.sfp.connected.poe-active,
.rl-dc-port.sfp28.connected.poe-active,
.rl-dc-port.qsfp.connected.poe-active {
    background-color: #10b981;
    border-color: #2f855a;
}
.rl-dc-port.sfp.uplink-active,
.rl-dc-port.sfp28.uplink-active,
.rl-dc-port.qsfp.uplink-active {
    background-color: #f59e0b;
    border-color: #d69e2e;
}
.rl-dc-port.sfp.connected .rl-dc-port-label,
.rl-dc-port.sfp.uplink-active .rl-dc-port-label,
.rl-dc-port.sfp28.connected .rl-dc-port-label,
.rl-dc-port.sfp28.uplink-active .rl-dc-port-label,
.rl-dc-port.qsfp.connected .rl-dc-port-label,
.rl-dc-port.qsfp.uplink-active .rl-dc-port-label {
    color: #ffffff;
}
.rl-dc-port.connected .rl-dc-port-led,
.rl-dc-port.connected.poe-active .rl-dc-port-led,
.rl-dc-port.uplink-active .rl-dc-port-led {
    background-color: #fff;
    box-shadow: 0 0 3px #fff;
}
.rl-dc-port.selected {
    box-shadow: 0 0 0 1.5px #fff, 0 0 0 3.5px var(--rl-blue);
    z-index: 10;
}
/* GbE (G1/G2) ports turn orange when selected */
.rl-dc-port.gbe.selected {
    background-color: #f59e0b;
    border-color: #d97706;
    box-shadow: 0 0 0 1.5px #fff, 0 0 0 3.5px #f59e0b;
}
.rl-dc-port.gbe.selected .rl-dc-port-label {
    color: #ffffff;
}

.rl-dc-port.rl-dc-port-dragover {
    background-color: rgba(0, 92, 244, 0.3) !important;
    border-color: var(--rl-blue) !important;
    transform: scale(1.1);
}

.rl-dc-poe-progress-bar {
    width: 100%;
    height: 8px;
    background-color: #edf2f7;
    border-radius: 4px;
    overflow: hidden;
}
.rl-dc-poe-progress-bar .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #48bb78, #dd6b20);
    transition: width 0.2s;
}

/* Edit Device connected clients table */
.rl-dc-ed-port-table {
    width: 100%;
    font-size: 0.75rem;
    border-collapse: collapse;
    margin-bottom: 0;
}
.rl-dc-ed-port-table th {
    color: var(--rl-gray-text);
    text-transform: uppercase;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 6px 8px;
    border-bottom: 2px solid var(--rl-gray-border);
    text-align: left;
}
.rl-dc-ed-port-table td {
    padding: 8px;
    border-bottom: 1px solid var(--rl-gray-border);
    vertical-align: middle;
    color: #2d3748;
}
.rl-dc-ed-port-table tr:last-child td {
    border-bottom: none;
}

/* Column 3: Sidebar Catalog & Info Column */
.rl-dc-right-column {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.rl-dc-catalog-container {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    max-height: calc(100vh - 12rem);
    position: sticky;
    top: 5rem;
}
.rl-dc-sidebar-head {
    padding: 1rem;
    border-bottom: 1px solid var(--rl-gray-border);
}
.rl-dc-sidebar-head input {
    border-radius: 6px;
    font-size: 0.85rem;
    border: 1px solid var(--rl-gray-border);
    padding: 0.45rem 0.75rem;
}
.rl-dc-sidebar-head input:focus {
    border-color: var(--rl-blue);
    box-shadow: 0 0 0 1px var(--rl-blue);
    outline: none;
}

.rl-dc-catalog {
    overflow-y: auto;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.rl-dc-cat-head {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--rl-gray-text);
    padding: 0.5rem 0.25rem 0.2rem;
}

/* Catalog hardware card list */
.rl-dc-cat-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.55rem;
    border-radius: 8px;
    border: 1px solid var(--rl-gray-border);
    background-color: var(--rl-light-bg);
    cursor: grab;
    transition: all 0.15s;
}
.rl-dc-cat-item:hover {
    border-color: #cbd5e0;
    background-color: #f7fafc;
}
.rl-dc-cat-item:active {
    cursor: grabbing;
}
.rl-dc-cat-thumb {
    width: 50px;
    height: 30px;
    background-color: #edf2f7;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}
.rl-dc-cat-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.rl-dc-cat-thumb i {
    color: var(--rl-gray-text);
    font-size: 0.95rem;
}
.rl-dc-cat-meta {
    flex: 1;
    min-width: 0;
}
.rl-dc-cat-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--rl-dark-text);
    line-height: 1.25;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rl-dc-cat-sub {
    font-size: 0.7rem;
    color: var(--rl-gray-text);
    margin-top: 1px;
}
.rl-dc-cat-add {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: #ebf8ff;
    border: none;
    color: #3182ce;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.15s;
    padding: 0;
}
.rl-dc-cat-add:hover {
    background-color: var(--rl-blue);
    color: var(--rl-light-bg);
}

/* Floating bottom total bar (White card, blue primary action) */
.rl-dc-bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    background-color: var(--rl-light-bg);
    border-top: 1px solid var(--rl-gray-border);
    padding: 0.75rem 4rem;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.05);
}

/* Toast warning/information notification style */
.rl-dc-toast {
    position: fixed;
    bottom: 4.5rem;
    left: 50%;
    transform: translate(-50%, 1rem);
    background-color: #2d3748;
    color: var(--rl-light-bg);
    font-size: 0.85rem;
    padding: 0.6rem 1.25rem;
    border-radius: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    opacity: 0;
    pointer-events: none;
    transition: all 0.18s;
    z-index: 1090;
}
.rl-dc-toast.show {
    opacity: 1;
    transform: translate(-50%, 0);
    pointer-events: auto;
}
.rl-dc-toast a {
    color: var(--rl-blue-soft);
    font-weight: 700;
    margin-left: 6px;
    text-decoration: underline;
}

/* BOM bill of materials panel overlay in column 2 */
.rl-dc-bom-panel {
    background-color: var(--rl-light-bg);
    border: 1px solid var(--rl-gray-border);
    border-radius: 12px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
}
.rl-dc-bom-title {
    color: var(--rl-dark-text);
    font-size: 0.95rem;
    font-weight: 700;
    border-bottom: 1px solid var(--rl-gray-border);
    padding-bottom: 0.75rem;
    margin-bottom: 1rem;
}
.rl-dc-bom-line {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--rl-gray-border);
}
.rl-dc-bom-line:last-child {
    border-bottom: none;
}
.rl-dc-bom-thumb {
    width: 48px;
    height: 28px;
    background-color: #edf2f7;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}
.rl-dc-bom-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.rl-dc-bom-thumb i {
    color: var(--rl-gray-text);
    font-size: 0.9rem;
}
.rl-dc-bom-meta {
    flex: 1;
    min-width: 0;
}
.rl-dc-bom-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--rl-dark-text);
    line-height: 1.25;
}
.rl-dc-bom-pn {
    font-size: 0.7rem;
    color: var(--rl-gray-text);
}
.rl-dc-bom-qty {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 700;
}
.rl-dc-qty-btn {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1px solid var(--rl-gray-border);
    background-color: var(--rl-light-bg);
    color: var(--rl-gray-text);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    cursor: pointer;
    padding: 0;
    transition: all 0.12s;
}
.rl-dc-qty-btn:hover {
    border-color: var(--rl-blue);
    color: var(--rl-blue);
}
.rl-dc-bom-price {
    font-size: 0.8rem;
    font-weight: 700;
    min-width: 70px;
    text-align: right;
}
.rl-dc-bom-footer {
    border-top: 1px solid var(--rl-gray-border);
    padding-top: 1rem;
    margin-top: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.rl-dc-bom-total {
    font-size: 0.85rem;
    color: var(--rl-gray-text);
}
.rl-dc-bom-total strong {
    font-size: 1.1rem;
    color: var(--rl-dark-text);
    margin-left: 4px;
}

/* Wizard Overlay card styling */
.rl-dc-wizard {
    position: fixed;
    inset: 0;
    z-index: 1080;
    background-color: rgba(26, 32, 44, 0.6);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}
.rl-dc-wiz-card-outer {
    background-color: var(--rl-light-bg);
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    max-width: 600px;
    width: 100%;
    padding: 2rem;
    display: flex;
    flex-direction: column;
}
.rl-dc-wiz-head h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--rl-dark-text);
}
.rl-dc-wiz-head p {
    color: var(--rl-gray-text);
    font-size: 0.9rem;
    margin-top: 0.25rem;
}
.rl-dc-wiz-dots {
    display: flex;
    gap: 6px;
    margin-top: 1rem;
}
.rl-dc-wiz-dot {
    width: 24px;
    height: 4px;
    border-radius: 2px;
    background-color: var(--rl-gray-border);
}
.rl-dc-wiz-dot.active {
    background-color: var(--rl-blue);
}
.rl-dc-wiz-q {
    font-size: 1.05rem;
    font-weight: 700;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}
.rl-dc-wiz-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}
.rl-dc-wiz-card {
    border: 1px solid var(--rl-gray-border);
    border-radius: 8px;
    padding: 1rem;
    text-align: left;
    background: none;
    cursor: pointer;
    transition: all 0.15s;
}
.rl-dc-wiz-card:hover {
    border-color: var(--rl-blue);
    background-color: #f7fafc;
}
.rl-dc-wiz-card.active {
    border-color: var(--rl-blue);
    background-color: var(--rl-blue-soft);
    box-shadow: 0 0 0 1px var(--rl-blue);
}
.rl-dc-wiz-card i {
    font-size: 1.25rem;
    color: var(--rl-blue);
    margin-bottom: 0.5rem;
    display: block;
}
.rl-dc-wiz-card span {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--rl-dark-text);
    display: block;
}
.rl-dc-wiz-card small {
    color: var(--rl-gray-text);
    font-size: 0.75rem;
    margin-top: 2px;
    display: block;
}
.rl-dc-wiz-scale {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.rl-dc-wiz-fields {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 0.5rem;
}
.rl-dc-wiz-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    flex: 1 1 180px;
    font-weight: 600;
    color: #2d3748;
    font-size: 0.85rem;
}
.rl-dc-wiz-field input {
    font-weight: 400;
}
.rl-dc-wiz-hint {
    margin-top: 0.85rem;
    font-size: 0.78rem;
    color: #718096;
}
.rl-dc-wiz-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2rem;
}
.rl-dc-rack-footer-tools {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
}
.rl-dc-rack-footer-tools label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--rl-gray-text);
    text-transform: uppercase;
    margin-bottom: 0;
}
.rl-dc-rack-footer-tools select {
    background-color: #fff !important;
    color: var(--rl-dark-text) !important;
    border: 1px solid var(--rl-gray-border) !important;
    border-radius: 6px !important;
    font-size: 0.8rem !important;
    font-weight: 600 !important;
    padding: 0.25rem 1.75rem 0.25rem 0.5rem !important;
    width: auto !important;
    cursor: pointer;
}
.rl-dc-rack-footer-tools select:focus {
    border-color: var(--rl-blue) !important;
    outline: none;
    box-shadow: none !important;
}
.rl-dc-rack-footer-tools .btn-outline-danger {
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 6px;
    padding: 0.25rem 0.5rem;
}

/* Off-screen rack capture for PDF export */
.rl-dc-pdf-capture-host {
    position: fixed;
    left: -10000px;
    top: 0;
    z-index: -1;
    pointer-events: none;
    background: #fff;
    padding: 16px;
}
.rl-dc-pdf-rack-item {
    width: 330px;
    margin-bottom: 8px;
}
.rl-dc-pdf-rack-item-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-bottom: 4px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #4a5568;
}
.rl-dc-pdf-rack-item-header .rl-dc-rack-block-size {
    font-size: 0.65rem;
    font-weight: 700;
    color: #a0aec0;
}
.rl-dc-pdf-rack .rl-dc-device-tag {
    opacity: 1;
}

/* Print cover page (hidden on screen) */
.rl-dc-print-cover {
    display: none;
}

/* Print Styles */
@media print {
    body.rl-dc-body {
        background-color: #fff;
        padding-bottom: 0;
    }
    #header-main,
    .rl-dc-right-column,
    .rl-dc-middle-column,
    .rl-dc-intro,
    .rl-dc-auth-banner,
    .rl-dc-project-row,
    .rl-dc-rack-toolbar,
    .rl-dc-stats,
    .rl-dc-toast,
    .rl-dc-wizard,
    .rl-dc-bottom-bar,
    .rl-dc-device-overlay-actions,
    .rl-dc-rack-placeholder,
    .rl-dc-rack-column-header,
    .rl-dc-rack-tabs-row,
    .rl-dc-rack-footer-tools,
    .rl-dc-rack-scroll-wrap,
    .rl-dc-rack-list-wrap,
    .rl-dc-qty-btn,
    .rl-dc-save-btn,
    #rlDcAddAllToCart {
        display: none !important;
    }
    .rl-dc-print-cover {
        display: flex !important;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        min-height: 100vh;
        page-break-after: always;
        break-after: page;
        padding: 2rem;
        text-align: center;
    }
    .rl-dc-print-cover-logo {
        max-width: 220px;
        height: auto;
        margin-bottom: 2rem;
    }
    .rl-dc-print-cover-title {
        font-size: 1.75rem;
        font-weight: 700;
        color: #1a202c;
        margin: 0 0 0.75rem;
        max-width: 90%;
    }
    .rl-dc-print-cover-date {
        font-size: 1rem;
        color: #718096;
        margin: 0;
    }
    .rl-dc-layout {
        display: block;
    }
    .rl-dc-rack-column,
    .rl-dc-bom-panel {
        border: none;
        box-shadow: none;
        padding: 0;
        margin-bottom: 2rem;
    }
    #rlDcBomPanelWrap {
        display: block !important;
    }
    #rlDcBom {
        max-height: none !important;
        overflow: visible !important;
    }
    .rl-dc-bom-line {
        break-inside: avoid;
    }
}

/* Mini Port Dot Classes (Stack Ports View) */
.rl-dc-mini-port-dot {
    display: inline-block;
    width: 5px;
    height: 5px;
    border-radius: 1px;
    transition: transform 0.1s;
    flex-shrink: 0;
}
.rl-dc-mini-port-row {
    gap: 1px !important;
}
.rl-dc-mini-seg {
    gap: 2px !important;
}
.rl-dc-mini-port-dot:hover {
    transform: scale(1.3);
}
/* Unconnected ports are greyed out; connections fill with the port-type color */
.rl-dc-mini-port-dot.empty {
    background-color: #d7dce3;
}
.rl-dc-mini-port-dot.fill-rl,
.rl-dc-mini-port-dot.fill-eth {
    background-color: #4a5568;
}
.rl-dc-mini-port-dot.fill-sfp {
    background-color: #bee3f8;
    border: 0.5px solid #63b3ed;
}
.rl-dc-mini-port-dot.fill-sfp28 {
    background-color: #90cdf4;
}
.rl-dc-mini-port-dot.fill-qsfp {
    background-color: #4299e1;
}
.rl-dc-mini-port-dot.fill-gbe {
    background-color: #f59e0b;
}
.rl-dc-mini-port-dot.data-active {
    background-color: #005cf4;
}
.rl-dc-mini-port-dot.poe-active {
    background-color: #10b981;
}
.rl-dc-mini-port-dot.uplink-active {
    background-color: #f59e0b;
}

/* Cabling animations and overlay */
@keyframes dash {
  to {
    stroke-dashoffset: -40;
  }
}

/* List view styling */
.rl-dc-list-thumb {
    transition: background-color 0.2s;
}
.rl-dc-list-thumb img {
    transition: transform 0.2s;
}
.rl-dc-list-thumb:hover img {
    transform: scale(1.1);
}
.rl-dc-list-cat-header {
    user-select: none;
    border-top: 1px solid #e2e8f0;
}

/* Left Add Device Panel Styling */
.rl-dc-left-add-device-panel {
    background-color: #ffffff;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    margin-bottom: 1rem;
}

.rl-dc-lad-category-item {
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 500;
    color: #4a5568;
    border-bottom: 1px solid #edf2f7;
}

.rl-dc-lad-category-item:hover {
    background-color: #f7fafc;
    color: #1a202c;
}

.rl-dc-lad-category-item i.category-icon {
    width: 20px;
    margin-right: 0.5rem;
    color: #718096;
}

.rl-dc-lad-product-item {
    cursor: pointer;
    transition: background-color 0.15s ease;
    padding: 0.5rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid #edf2f7;
}

.rl-dc-lad-product-item:hover {
    background-color: #f7fafc;
}

.rl-dc-lad-product-thumb {
    width: 48px;
    height: 32px;
    background-color: #f7fafc;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
}

.rl-dc-lad-product-thumb img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
}

/* Active Ports filter styling */
.rl-dc-ports-filter-toggle {
    font-size: 0.75rem;
    color: #005cf4;
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
    display: inline-block;
    margin-top: 0.5rem;
}

.rl-dc-ports-filter-toggle:hover {
    text-decoration: underline;
}

/* Styled select for Uplink Port selection */
select#rlDcEdUplinkPort {
    font-size: 0.85rem;
    border-color: #cbd5e0;
}

/* Rack focus modal */
.rl-dc-rack-focus-modal {
    position: fixed;
    inset: 0;
    z-index: 1070;
    background: rgba(26, 32, 44, 0.65);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    animation: fadeIn 0.15s;
}
.rl-dc-rack-focus-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 440px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.rl-dc-rack-focus-header {
    padding: 1rem 1.25rem 0.75rem;
    border-bottom: 1px solid var(--rl-gray-border);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-shrink: 0;
}
.rl-dc-rfm-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--rl-dark-text);
    margin: 0 0 2px;
}
.rl-dc-rfm-sub {
    font-size: 0.8rem;
    color: var(--rl-gray-text);
    margin: 0;
}
.rl-dc-rfm-close {
    background: none;
    border: none;
    color: var(--rl-gray-text);
    font-size: 1rem;
    cursor: pointer;
    padding: 2px 4px;
    line-height: 1;
    flex-shrink: 0;
    margin-left: 0.5rem;
}
.rl-dc-rfm-close:hover {
    color: var(--rl-dark-text);
}
.rl-dc-rack-focus-body {
    overflow-y: auto;
    padding: 1rem;
    background: #f7fafc;
    flex: 1;
    min-height: 0;
}
.rl-dc-rack-focus-footer {
    padding: 0.75rem 1.25rem;
    border-top: 1px solid var(--rl-gray-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}
.rl-dc-rfm-done {
    background: var(--rl-blue) !important;
    border-color: var(--rl-blue) !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    border-radius: 6px !important;
}
.rl-dc-rfm-continue {
    background: #fff !important;
    border: 1px solid var(--rl-gray-border) !important;
    color: var(--rl-gray-text) !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    border-radius: 6px !important;
}
.rl-dc-rfm-continue:hover {
    background: #f7fafc !important;
    color: var(--rl-dark-text) !important;
}
.rl-dc-rfm-hint {
    font-size: 0.72rem;
    color: var(--rl-gray-text);
    margin: 0 0 0.6rem;
    text-align: center;
}
.rl-dc-rfm-hint i {
    color: var(--rl-blue);
    margin-right: 0.25rem;
}

/* Inline PoE wattage editor in the connected-devices table */
.rl-dc-poe-inline-input {
    width: 64px;
    font-size: 0.7rem;
    padding: 1px 4px;
    border: 1px solid var(--rl-blue);
    border-radius: 4px;
    text-align: right;
    outline: none;
}

/* Drop-target preview shown while dragging a unit on the rack */
.rl-dc-ghost {
    position: absolute;
    left: 0;
    right: 0;
    border-radius: 2px;
    background: rgba(0, 92, 244, 0.16);
    border: 1.5px dashed var(--rl-blue);
    z-index: 5;
    pointer-events: none;
}
.rl-dc-ghost.invalid {
    background: rgba(229, 62, 62, 0.16);
    border-color: #e53e3e;
}
.rl-dc-device.rl-dc-dragging {
    opacity: 0.4;
}

/* Newly added device pulsing highlight */
@keyframes newDevicePulse {
    0%   { box-shadow: 0 0 0 2px var(--rl-blue), 0 0 10px rgba(0, 92, 244, 0.5); }
    50%  { box-shadow: 0 0 0 3px var(--rl-blue), 0 0 22px rgba(0, 92, 244, 0.9); }
    100% { box-shadow: 0 0 0 2px var(--rl-blue), 0 0 10px rgba(0, 92, 244, 0.5); }
}
.rl-dc-device-new {
    border-color: var(--rl-blue) !important;
    animation: newDevicePulse 1.2s ease-in-out infinite;
    z-index: 4;
}

/* Port-context banner shown atop the catalog when a switch port is selected */
.rl-dc-port-context-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    background: rgba(0, 92, 244, 0.08);
    border: 1px solid rgba(0, 92, 244, 0.3);
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.6rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--rl-blue);
}
.rl-dc-port-context-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rl-dc-port-context-clear {
    background: none;
    border: none;
    color: var(--rl-blue);
    font-size: 1.1rem;
    line-height: 1;
    padding: 0 0.2rem;
    cursor: pointer;
    flex-shrink: 0;
}
.rl-dc-port-context-clear:hover {
    color: #003da8;
}

/* Stacked multi-rack view */
.rl-dc-rack-tabs {
    flex-wrap: wrap;
    row-gap: 4px;
}
.rl-dc-rack-block {
    margin-bottom: 1.1rem;
}
.rl-dc-rack-block-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    max-width: 330px;
    margin: 0 auto 4px;
}
.rl-dc-rack-block-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--rl-gray-text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rl-dc-rack-block.active .rl-dc-rack-block-name {
    color: var(--rl-blue);
}
.rl-dc-rack-block-size {
    font-size: 0.65rem;
    font-weight: 700;
    color: #a0aec0;
}
.rl-dc-rack-rename-btn {
    background: none;
    border: none;
    padding: 0;
    color: #a0aec0;
    font-size: 0.65rem;
    line-height: 1;
    cursor: pointer;
}
.rl-dc-rack-rename-btn:hover {
    color: var(--rl-blue);
}
.rl-dc-rack-name-input {
    width: 140px;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 1px 6px;
    border: 1px solid var(--rl-blue);
    border-radius: 4px;
    color: var(--rl-dark-text);
}
.rl-dc-rack-block.active .rl-dc-rack-cage {
    box-shadow: inset 0 0 0 1px rgba(0, 92, 244, 0.25);
}
.rl-dc-view-all-btn {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 2px 10px;
    border-radius: 14px;
}

/* A/B/C switch designation badge on rack faceplates */
.rl-dc-device-letter {
    position: absolute;
    left: 3px;
    top: 50%;
    transform: translateY(-50%);
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background-color: var(--rl-blue);
    color: #fff;
    font-size: 0.55rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    pointer-events: none;
}

/* ------------------------------------------------------------------ */
/* Stack Ports View cables (uplinks + LAGs)                            */
/* ------------------------------------------------------------------ */
.rl-dc-stack-cables {
    position: absolute;
    left: 0;
    top: 0;
    pointer-events: none;
    overflow: visible;
    z-index: 3;
}

/* Catalog group headers (full product list, right panel) */
.rl-dc-cat-group-header {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #718096;
    padding: 0.6rem 0.25rem 0.25rem;
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 0.35rem;
}

/* LAG member rows in the edit panel */
.rl-dc-lag-member-head {
    font-size: 0.62rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 2px;
}
.rl-dc-lag-member-row {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 0.4rem;
}
.rl-dc-lag-member-row .form-select {
    flex: 1 1 0;
    min-width: 0;
}
.rl-dc-lag-arrow {
    color: #a0aec0;
    font-size: 0.6rem;
    flex: 0 0 auto;
}
.rl-dc-lag-member-rm {
    background: none;
    border: none;
    color: #e53e3e;
    cursor: pointer;
    padding: 0 2px;
    flex: 0 0 auto;
    font-size: 0.8rem;
}
.rl-dc-lag-member-rm:hover {
    color: #c53030;
}
.rl-dc-lag-member-ro {
    font-size: 0.72rem;
    color: #4a5568;
    padding: 2px 0;
}

/* WAN uplink pill labels in the Stack Ports View */
.rl-dc-wan-badge-text {
    fill: #fff;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 0.03em;
}

/* ------------------------------------------------------------------ */
/* View rail + Ports page                                              */
/* ------------------------------------------------------------------ */
.rl-dc-view-shell {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}
.rl-dc-view-rail {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    position: sticky;
    top: 90px;
    flex: 0 0 auto;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0.4rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}
.rl-dc-rail-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    width: 56px;
    padding: 0.5rem 0.25rem;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #718096;
    cursor: pointer;
    transition: background-color 0.15s, color 0.15s;
}
.rl-dc-rail-btn i {
    font-size: 1rem;
}
.rl-dc-rail-btn span {
    font-size: 0.6rem;
    font-weight: 600;
}
.rl-dc-rail-btn:hover {
    background: #f7fafc;
    color: #2d3748;
}
.rl-dc-rail-btn.active {
    background: #ebf2ff;
    color: #005cf4;
}
.rl-dc-view-content {
    flex: 1 1 auto;
    min-width: 0;
}

.rl-dc-ports-page {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}
.rl-dc-pp-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a202c;
    margin: 0;
}
.rl-dc-pp-sub {
    font-size: 0.8rem;
    color: #718096;
    margin: 0.15rem 0 1rem;
}
.rl-dc-pp-rack-header {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #718096;
    margin: 1.25rem 0 0.5rem;
}
.rl-dc-pp-card {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0.9rem 1rem;
    margin-bottom: 0.9rem;
    background: #ffffff;
}
.rl-dc-pp-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 0.7rem;
}
.rl-dc-pp-card-id {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    min-width: 0;
}
.rl-dc-pp-letter {
    width: 28px;
    height: 28px;
    min-width: 28px;
    border-radius: 6px;
    background: #1a202c;
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.rl-dc-pp-card-name {
    font-size: 0.85rem;
    font-weight: 700;
    color: #1a202c;
}
.rl-dc-pp-card-sub {
    font-size: 0.68rem;
    color: #718096;
    font-family: var(--bs-font-monospace, monospace);
}
.rl-dc-pp-poe {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.68rem;
    color: #718096;
}
.rl-dc-pp-poe .rl-dc-poe-progress-bar {
    width: 120px;
    margin: 0;
}
.rl-dc-pp-poe-num {
    font-family: var(--bs-font-monospace, monospace);
    color: #2d3748;
    font-weight: 600;
}
.rl-dc-pp-grid {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    overflow-x: auto;
    padding-bottom: 0.25rem;
}
.rl-dc-pp-seg {
    display: flex;
    gap: 3px;
}
.rl-dc-pp-seg-divided {
    padding-left: 0.6rem;
}
.rl-dc-pp-col {
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.rl-dc-pp-wan-ico {
    font-size: 0.55rem;
    color: #ffffff;
}
.rl-dc-pp-card-foot {
    margin-top: 0.6rem;
    font-size: 0.7rem;
    color: #4a5568;
    font-family: var(--bs-font-monospace, monospace);
}
.rl-dc-pp-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    align-items: center;
    margin-top: 1rem;
    padding-top: 0.9rem;
    border-top: 1px solid #e2e8f0;
    font-size: 0.7rem;
    color: #4a5568;
}
.rl-dc-pp-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}
.rl-dc-pp-legend-chip {
    width: 16px;
    height: 16px;
    cursor: default;
    pointer-events: none;
}

@media (max-width: 767.98px) {
    .rl-dc-view-shell {
        flex-direction: column;
    }
    .rl-dc-view-rail {
        flex-direction: row;
        position: static;
        width: 100%;
        justify-content: center;
    }
}

/* High-resolution PDF rack capture: geometry runs at 2x (PDF_RACK_SCALE),
   so chrome elements scale up with it and PN pills stay hidden for a
   clean faceplate render. */
.rl-dc-pdf-rack-item .rl-dc-pdf-rack-item-header {
    font-size: 1.3rem;
    margin-bottom: 10px;
}
.rl-dc-pdf-rack-item .rl-dc-pdf-rack-item-header .rl-dc-rack-block-size {
    font-size: 1rem;
}
.rl-dc-pdf-rack-hd .rl-dc-rack-top,
.rl-dc-pdf-rack-hd .rl-dc-rack-base {
    height: 26px;
}
.rl-dc-pdf-rack-hd .rl-dc-device-tag {
    display: none;
}
.rl-dc-pdf-rack-hd .rl-dc-u-num {
    font-size: 0.8rem;
}
.rl-dc-pdf-rack-hd .rl-dc-device-letter {
    width: 36px;
    height: 36px;
    font-size: 1.05rem;
    line-height: 36px;
}

/* ------------------------------------------------------------------ */
/* UniFi-style port chips (Ports page)                                 */
/* ------------------------------------------------------------------ */
.rl-dc-up-col {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
}
.rl-dc-up-chip {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    background: #e4e7eb;
    color: #8a94a3;
    position: relative;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.12s, transform 0.08s;
    user-select: none;
}
.rl-dc-up-chip:hover {
    background: #d7dce2;
    transform: scale(1.04);
}
.rl-dc-up-num {
    position: absolute;
    left: 4px;
    bottom: 3px;
    font-size: 0.58rem;
    font-weight: 600;
    color: #8a94a3;
    line-height: 1;
}
.rl-dc-up-sfp {
    font-size: 0.55rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    margin-top: -10px;
}
.rl-dc-up-glyph {
    font-size: 0.7rem;
    margin-top: -10px;
}
.rl-dc-up-chip.active {
    color: #ffffff;
}
.rl-dc-up-chip.active .rl-dc-up-num {
    color: rgba(255, 255, 255, 0.95);
}
.rl-dc-up-chip.active-gbe { background: #38cc65; }
.rl-dc-up-chip.active-rl { background: #99c5ff; }
.rl-dc-up-chip.active-10g { background: #3a9fcb; }
.rl-dc-up-chip.active-25g { background: #c696ee; }
.rl-dc-up-chip.active-100g { background: #0049a8; }
.rl-dc-up-chip.active:hover {
    filter: brightness(0.95);
}
.rl-dc-up-chip.selected {
    outline: 2px solid #005cf4;
    outline-offset: 1px;
}

/* Connected device hangs below the column (line, picture, name) or sits
   above it for top-row ports (name, picture, line). Every column gets a
   fixed-height top slot when any top-row device exists so ports align. */
.rl-dc-up-devslot {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
}
.rl-dc-pp-grid.rl-dc-has-topdev .rl-dc-up-devslot {
    min-height: 54px;
}
.rl-dc-pp-rowpow {
    font-size: 0.7rem;
    font-weight: 600;
    color: #718096;
    text-align: right;
    font-family: var(--bs-font-monospace, monospace);
}
.rl-dc-pp-rowpow-top {
    margin-bottom: 0.15rem;
}
.rl-dc-pp-rowpow-bottom {
    margin-top: 0.15rem;
}
.rl-dc-up-dev {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    cursor: pointer;
    max-width: 46px;
}
.rl-dc-up-dev-line {
    width: 1px;
    height: 12px;
    background: #cbd5e0;
}
.rl-dc-up-dev-thumb {
    width: 34px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #718096;
}
.rl-dc-up-dev-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.rl-dc-up-dev-name {
    font-size: 0.55rem;
    color: #4a5568;
    max-width: 46px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rl-dc-up-legend-chip {
    width: 14px;
    height: 14px;
    border-radius: 4px;
    cursor: default;
    pointer-events: none;
}
.rl-dc-up-legend-ico {
    color: #718096;
    margin-right: 3px;
}

/* Right slide-over: add a device to the clicked port */
.rl-dc-pp-side {
    position: fixed;
    top: 96px;
    right: 16px;
    width: 340px;
    max-width: 90vw;
    max-height: calc(100vh - 130px);
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.16);
    z-index: 1080;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateX(calc(100% + 32px));
    transition: transform 0.22s ease;
}
.rl-dc-pp-side.open {
    transform: translateX(0);
}
.rl-dc-pp-side-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 1rem 1rem 0.5rem;
}
.rl-dc-pp-side-head-l {
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
}
.rl-dc-pp-side-back {
    background: none;
    border: none;
    font-size: 0.9rem;
    line-height: 1;
    color: #718096;
    cursor: pointer;
    padding: 0.3rem 0.2rem 0 0;
}
.rl-dc-pp-side-back:hover {
    color: #1a202c;
}
.rl-dc-pp-side-title {
    font-weight: 700;
    color: #1a202c;
}
.rl-dc-pp-side-sub {
    font-size: 0.72rem;
    color: #718096;
    font-family: var(--bs-font-monospace, monospace);
}
.rl-dc-pp-side-close {
    background: none;
    border: none;
    font-size: 1.4rem;
    line-height: 1;
    color: #718096;
    cursor: pointer;
}
.rl-dc-pp-side-search {
    padding: 0.25rem 1rem 0.5rem;
}
.rl-dc-pp-side-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 0.25rem 1rem 1rem;
}
.rl-dc-pp-side-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 0.2rem;
    border-bottom: 1px solid #edf2f7;
    cursor: pointer;
}
.rl-dc-pp-side-item:hover {
    background: #f7fafc;
}
.rl-dc-pp-side-item-thumb {
    width: 40px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #718096;
    flex: 0 0 auto;
}
.rl-dc-pp-side-item-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.rl-dc-pp-side-item-meta {
    flex: 1 1 auto;
    min-width: 0;
    font-size: 0.78rem;
    color: #1a202c;
}
.rl-dc-pp-side-item-meta small {
    color: #718096;
    font-family: var(--bs-font-monospace, monospace);
}
.rl-dc-pp-side-add {
    background: #ebf2ff;
    color: #005cf4;
    border: none;
    border-radius: 50%;
    width: 26px;
    height: 26px;
    cursor: pointer;
    flex: 0 0 auto;
}
.rl-dc-pp-side-add:hover {
    background: #d8e6ff;
}
.rl-dc-pp-side-current {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 0.2rem;
    font-size: 0.8rem;
}
.rl-dc-pp-side-cur-thumb {
    width: 44px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
}
.rl-dc-pp-side-cur-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.rl-dc-pp-side-cur-meta {
    flex: 1 1 auto;
    min-width: 0;
}
.rl-dc-pp-side-cur-meta small {
    color: #718096;
    font-family: var(--bs-font-monospace, monospace);
}
.rl-dc-pp-side-note {
    font-size: 0.78rem;
    color: #4a5568;
    padding: 0.75rem 0.2rem;
}
.rl-dc-pp-side-foot {
    padding: 0.75rem 1rem;
    border-top: 1px solid #e2e8f0;
}

/* PoE level markers: bolt + stacked plus marks (PoE+ one, PoE++ two, +++ three) */
.rl-dc-up-poe {
    display: inline-flex;
    align-items: center;
    line-height: 1;
}
.rl-dc-up-poe-chip {
    margin-top: -10px;
}
.rl-dc-up-poe .fa-bolt {
    font-size: 0.62rem;
}
.rl-dc-up-poe-plus {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-left: 1.5px;
    font-size: 8px;
    line-height: 7px;
    font-weight: 800;
    letter-spacing: 0;
}
.rl-dc-up-poe-plus span {
    display: block;
}
.rl-dc-up-sfp-sm {
    font-size: 0.42rem;
    letter-spacing: 0;
}
.rl-dc-up-legend-poe {
    color: #4a5568;
}
.rl-dc-up-legend-poe .rl-dc-up-poe {
    margin-right: 3px;
    color: #718096;
}

/* Shared fixed hover bubble (Port / Speed / Power), UniFi-style */
.rl-dc-up-pop {
    position: fixed;
    z-index: 1100;
    background: #1a202c;
    color: #fff;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 0.72rem;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.1s;
    min-width: 130px;
}
.rl-dc-up-pop.show {
    opacity: 1;
}
.rl-dc-up-pop-title {
    font-weight: 700;
    margin-bottom: 2px;
}
.rl-dc-up-pop-row {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    color: #cbd5e0;
    padding: 1px 0;
}
.rl-dc-up-pop-row > span:last-child {
    color: #fff;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.rl-dc-up-pop-swatch {
    width: 8px;
    height: 8px;
    border-radius: 2px;
    display: inline-block;
}
.rl-dc-up-pop-status {
    margin-top: 3px;
    padding-top: 3px;
    border-top: 1px solid #2d3748;
    color: #a0aec0;
    max-width: 220px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ------------------------------------------------------------------ */
/* BOM page (full-width preview + PDF export)                          */
/* ------------------------------------------------------------------ */
.rl-dc-bom-page {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
}
.rl-dc-bp-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}
.rl-dc-bp-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a202c;
    margin: 0;
}
.rl-dc-bp-sub {
    font-size: 0.8rem;
    color: #718096;
    margin: 0.15rem 0 0;
    max-width: 36rem;
}
.rl-dc-bp-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.rl-dc-bp-document {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.rl-dc-bp-section {
    position: relative;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    transition: opacity 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}
.rl-dc-bp-section-excluded {
    opacity: 0.52;
    border-style: dashed;
    border-color: #cbd5e0;
    background: #f8fafc;
}
.rl-dc-bp-section-hd {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}
.rl-dc-bp-section-hd-main {
    flex: 1;
    min-width: 0;
}
.rl-dc-bp-section-hd .rl-dc-bp-section-title {
    margin-bottom: 0;
}
.rl-dc-bp-section-hd-inset {
    padding: 1.25rem 1.5rem 0;
    margin-bottom: 0.75rem;
}
.rl-dc-bp-section-sub {
    font-size: 0.8rem;
    color: #718096;
    margin: 0.35rem 0 0;
}
.rl-dc-bp-section-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: #4a5568;
    white-space: nowrap;
    cursor: pointer;
    user-select: none;
    flex-shrink: 0;
    padding: 0.35rem 0.65rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: #f7fafc;
    margin: 0;
}
.rl-dc-bp-section-toggle:hover {
    border-color: #005cf4;
    color: #005cf4;
}
.rl-dc-bp-section-toggle input {
    accent-color: #005cf4;
    margin: 0;
    cursor: pointer;
}
.rl-dc-bp-section-flush {
    padding: 0;
    overflow: hidden;
}
.rl-dc-bp-section-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1a202c;
    margin: 0 0 1rem;
}
.rl-dc-bp-section-title-inset {
    padding: 1.25rem 1.5rem 0;
    margin-bottom: 0.75rem;
}
.rl-dc-bp-cover-preview {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    min-height: 420px;
    padding: 2rem 2rem 1.5rem;
}
.rl-dc-bp-cover-preview .rl-dc-bp-section-hd {
    text-align: left;
}
.rl-dc-bp-cover-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0 1rem;
}
.rl-dc-bp-cover-logo {
    max-width: 200px;
    height: auto;
    margin-bottom: 1.5rem;
}
.rl-dc-bp-cover-title-input {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a202c;
    text-align: center;
    border: none;
    border-bottom: 1px dashed #cbd5e0;
    background: transparent;
    width: min(100%, 36rem);
    padding: 0.35rem 0.5rem;
    margin-bottom: 0.5rem;
}
.rl-dc-bp-cover-title-input:focus {
    outline: none;
    border-bottom-color: #005cf4;
    background: #f7fafc;
}
.rl-dc-bp-cover-date-input {
    font-size: 0.95rem;
    color: #718096;
    text-align: center;
    border: none;
    border-bottom: 1px dashed #e2e8f0;
    background: transparent;
    width: min(100%, 16rem);
    padding: 0.25rem 0.5rem;
}
.rl-dc-bp-cover-date-input:focus {
    outline: none;
    border-bottom-color: #005cf4;
    background: #f7fafc;
}
.rl-dc-bp-cover-date-input::placeholder {
    color: #a0aec0;
}
.rl-dc-bp-cover-parties {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    text-align: left;
    margin-top: 0.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid #e2e8f0;
}
.rl-dc-bp-cover-party-title {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #718096;
    margin: 0 0 0.75rem;
}
.rl-dc-bp-cover-field {
    margin-bottom: 0.65rem;
}
.rl-dc-bp-cover-field label {
    display: block;
    font-size: 0.68rem;
    font-weight: 600;
    color: #a0aec0;
    margin-bottom: 0.2rem;
}
.rl-dc-bp-cover-field input,
.rl-dc-bp-cover-field textarea {
    display: block;
    width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #f7fafc;
    padding: 0.4rem 0.55rem;
    font-size: 0.85rem;
    color: #1a202c;
}
.rl-dc-bp-cover-field input:focus,
.rl-dc-bp-cover-field textarea:focus {
    outline: none;
    border-color: #005cf4;
    background: #ffffff;
    box-shadow: 0 0 0 2px rgba(0, 92, 244, 0.12);
}
.rl-dc-bp-cover-field textarea {
    resize: vertical;
    min-height: 2.6rem;
}
@media (max-width: 767.98px) {
    .rl-dc-bp-cover-parties {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
}
.rl-dc-bp-racks {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
}
.rl-dc-bp-racks .rl-dc-pdf-rack-item {
    width: 330px;
    margin-bottom: 0;
}
.rl-dc-bp-section-ports .rl-dc-pp-card {
    margin-bottom: 0.9rem;
}
.rl-dc-bp-section-ports .rl-dc-pp-card-static {
    cursor: default;
}
.rl-dc-bp-section-ports .rl-dc-up-chip-static {
    cursor: default;
}
.rl-dc-bp-section-topo .rl-dc-tp-main-preview {
    display: block;
}
.rl-dc-bp-section-topo .rl-dc-tp-canvas-wrap-preview {
    height: 520px;
    min-height: 360px;
    cursor: default;
}
.rl-dc-bp-topo-sub {
    font-size: 0.8rem;
    color: #718096;
    margin: -0.35rem 0 1rem;
}
.rl-dc-tp-preview-host .rl-dc-tp-main-preview {
    display: block;
}
.rl-dc-tp-preview-host .rl-dc-tp-canvas-wrap-preview {
    height: 520px;
    min-height: 360px;
}
.rl-dc-tp-pdf-capture .rl-dc-tp-canvas-wrap-preview {
    height: 520px;
    overflow: hidden;
}
.rl-dc-bp-footer-note {
    text-align: center;
    font-size: 0.75rem;
    color: #a0aec0;
    margin: 0;
}
.rl-dc-bp-panel {
    border: none;
    border-radius: 0;
    overflow: hidden;
}
.rl-dc-bp-table thead th {
    background: #292b2c;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border: none;
    padding: 0.65rem 0.75rem;
    white-space: nowrap;
}
.rl-dc-bp-table tbody td {
    font-size: 0.82rem;
    color: #2d3748;
    vertical-align: top;
    padding: 0.7rem 0.75rem;
    border-color: #edf2f7;
}
.rl-dc-bp-table tbody tr:nth-child(even) {
    background: #f8f9fa;
}
.rl-dc-bp-summary {
    padding: 1rem 1.25rem;
    border-top: 1px solid #e2e8f0;
    background: #ffffff;
}
.rl-dc-bp-summary-row {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    font-size: 0.85rem;
    color: #4a5568;
    padding: 0.25rem 0;
}
.rl-dc-bp-subtotal {
    margin-top: 0.5rem;
    padding-top: 0.65rem;
    border-top: 1px solid #e2e8f0;
    font-size: 0.95rem;
    color: #1a202c;
}
.rl-dc-bp-signin {
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: #718096;
}
.rl-dc-bp-disclaimer {
    margin: 0;
    padding: 0.85rem 1.25rem 1.1rem;
    font-size: 0.72rem;
    color: #718096;
    line-height: 1.45;
    border-top: 1px solid #edf2f7;
    background: #fbfcfd;
}
.rl-dc-bp-acc {
    padding: 1rem 1.25rem;
    border-top: 1px solid #e2e8f0;
    background: #ffffff;
}
.rl-dc-bp-acc-title {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #718096;
    margin: 0 0 0.5rem;
}
.rl-dc-bp-acc-list {
    margin: 0;
    padding-left: 1.1rem;
    font-size: 0.82rem;
    color: #4a5568;
}
.rl-dc-bp-empty,
.rl-dc-bp-empty-inline {
    text-align: center;
    color: #718096;
    font-size: 0.9rem;
    padding: 2.5rem 1rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}
.rl-dc-bp-empty p {
    margin: 0;
    max-width: 28rem;
    margin-left: auto;
    margin-right: auto;
}
.rl-dc-pp-legend-pdf {
    margin-top: 0.5rem;
}
.rl-dc-pp-legend-wan {
    font-size: 0.75rem;
    color: #4a5568;
}

/* ------------------------------------------------------------------ */
/* Topology view (network simulation)                                  */
/* ------------------------------------------------------------------ */
.rl-dc-topo-page {
    padding: 0 0.25rem 2rem;
}
.rl-dc-tp-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.85rem;
}
.rl-dc-tp-bar-spacer {
    flex: 1;
}
.rl-dc-tp-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: #2d3748;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.35rem 0.65rem;
    cursor: pointer;
    user-select: none;
}
.rl-dc-tp-toggle input {
    accent-color: #005cf4;
}
.rl-dc-tp-main {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}
.rl-dc-tp-canvas-wrap {
    flex: 1;
    min-width: 0;
    position: relative;
    overflow: hidden;
    height: 68vh;
    min-height: 440px;
    background: linear-gradient(180deg, #fbfcfe 0%, #f4f7fb 100%);
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    cursor: grab;
}
.rl-dc-tp-canvas-wrap.rl-dc-tp-grabbing {
    cursor: grabbing;
}
.rl-dc-tp-canvas {
    position: absolute;
    top: 0;
    left: 0;
    transform-origin: 0 0;
    will-change: transform;
}
.rl-dc-tp-zoom {
    position: absolute;
    right: 14px;
    bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    z-index: 5;
}
.rl-dc-tp-zoom button {
    width: 34px;
    height: 34px;
    border: 1px solid #d7dce2;
    border-radius: 8px;
    background: #ffffff;
    color: #4a5568;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(16, 24, 40, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
}
.rl-dc-tp-zoom button:hover {
    background: #f4f7fb;
    color: #1a202c;
}
.rl-dc-tp-canvas svg {
    position: absolute;
    left: 0;
    top: 0;
    pointer-events: none;
}
.rl-dc-tp-edge {
    fill: none;
    stroke: #c6cfdb;
    stroke-width: 2;
}
.tp-e-k-lag { stroke-width: 3.5; }
.tp-e-k-stack { stroke: #5ec1b5; stroke-width: 2.5; }
.tp-e-sug { stroke-dasharray: 6 5; opacity: 0.85; }
.tp-e-blocked {
    stroke: #f0a93b;
    stroke-dasharray: 4 6;
    opacity: 0.8;
}
.tp-e-down {
    stroke: #e53e3e;
    stroke-dasharray: 3 7;
    opacity: 0.55;
}
.tp-e-storm { stroke: #e53e3e; stroke-width: 3; opacity: 0.9; }
.tp-e-storm-slow { stroke: #e98c8c; }
.tp-e-trace { stroke: #005cf4; stroke-width: 3.5; opacity: 1; }
.tp-e-ring { stroke: #5ec1b5; }

.rl-dc-tp-node {
    position: absolute;
    cursor: pointer;
}
.rl-dc-tp-node-sw {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #ffffff;
    border: 1px solid #dbe2ea;
    border-radius: 12px;
    padding: 0.45rem 0.6rem;
    height: 56px;
    box-shadow: 0 1px 3px rgba(26, 32, 44, 0.06);
    transition: box-shadow 0.12s, transform 0.12s;
}
.rl-dc-tp-node-sw:hover {
    box-shadow: 0 4px 12px rgba(26, 32, 44, 0.12);
    transform: translateY(-1px);
}
.rl-dc-tp-node-sw.tp-n-tracing {
    outline: 2px solid #005cf4;
    outline-offset: 2px;
}
.rl-dc-tp-letter {
    flex: 0 0 auto;
}
.rl-dc-tp-sw-meta {
    min-width: 0;
}
.rl-dc-tp-sw-name {
    font-size: 0.72rem;
    font-weight: 700;
    color: #1a202c;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 104px;
}
.rl-dc-tp-sw-sub {
    font-size: 0.62rem;
    color: #718096;
    font-family: var(--bs-font-monospace, monospace);
}
.rl-dc-tp-status-dot {
    position: absolute;
    right: 7px;
    top: 7px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}
.tp-dot-up { background: #38cc65; }
.tp-dot-offline { background: #a0aec0; }
.tp-dot-storm { background: #e53e3e; }
.rl-dc-tp-root-tag {
    position: absolute;
    top: -11px;
    left: 8px;
    background: #fff7e0;
    border: 1px solid #f0c558;
    color: #92690c;
    font-size: 0.56rem;
    font-weight: 700;
    border-radius: 6px;
    padding: 1px 6px;
    white-space: nowrap;
}
.rl-dc-tp-node.tp-n-offline {
    opacity: 0.5;
    filter: grayscale(0.8);
}
.rl-dc-tp-offline-badge {
    position: absolute;
    bottom: -9px;
    left: 50%;
    transform: translateX(-50%);
    background: #e53e3e;
    color: #fff;
    font-size: 0.55rem;
    font-weight: 700;
    border-radius: 6px;
    padding: 1px 7px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
@keyframes rlDcTpStormPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(229, 62, 62, 0.45); border-color: #e53e3e; }
    50% { box-shadow: 0 0 0 7px rgba(229, 62, 62, 0); border-color: #e53e3e; }
}
.rl-dc-tp-node-sw.tp-n-storm,
.rl-dc-tp-node-cl.tp-n-storm {
    animation: rlDcTpStormPulse 0.9s ease-in-out infinite;
    border-color: #e53e3e;
}
.rl-dc-tp-node-inet {
    text-align: center;
    cursor: default;
}
.rl-dc-tp-globe {
    width: 50px;
    height: 50px;
    margin: 0 auto;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #eaf3ff, #cfe3ff);
    border: 1px solid #b9d4f8;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2f7af5;
    font-size: 1.3rem;
}
.rl-dc-tp-node-inet.tp-n-offline .rl-dc-tp-globe {
    color: #a0aec0;
    background: #edf0f4;
    border-color: #d5dbe3;
}
.rl-dc-tp-inet-lbl {
    margin-top: 4px;
    font-size: 0.62rem;
    font-weight: 700;
    color: #4a5568;
}
.rl-dc-tp-node-cl {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #ffffff;
    border: 1px dashed #cbd5e0;
    border-radius: 12px;
    padding: 0.4rem 0.6rem;
    height: 58px;
}
.rl-dc-tp-cl-ico {
    font-size: 1.05rem;
    color: #718096;
}
.rl-dc-tp-cl-count {
    font-size: 0.7rem;
    font-weight: 700;
    color: #2d3748;
    white-space: nowrap;
}
.rl-dc-tp-cl-draw {
    font-size: 0.6rem;
    color: #718096;
    font-family: var(--bs-font-monospace, monospace);
}
.rl-dc-tp-stackbox {
    position: absolute;
    border: 1.5px dashed #5ec1b5;
    background: rgba(94, 193, 181, 0.05);
    border-radius: 14px;
    pointer-events: none;
}
.rl-dc-tp-stackbox-lbl {
    position: absolute;
    bottom: 3px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.58rem;
    font-weight: 700;
    color: #2c8d80;
    white-space: nowrap;
}
.rl-dc-tp-pill {
    position: absolute;
    transform: translate(-50%, -50%);
    min-width: 20px;
    height: 17px;
    border-radius: 5px;
    background: #e4e7eb;
    color: #ffffff;
    font-size: 0.58rem;
    font-weight: 700;
    line-height: 17px;
    text-align: center;
    padding: 0 4px;
    cursor: default;
    box-shadow: 0 1px 2px rgba(26, 32, 44, 0.15);
}
.tp-pill-blocked { background: #f0a93b !important; }
.tp-pill-down { background: #b9c2cd !important; color: #ffffff; }
.tp-pill-storm, .tp-pill-storm-slow { background: #e53e3e !important; }
.tp-pill-sug { opacity: 0.9; }
.rl-dc-tp-cut {
    position: absolute;
    transform: translate(-50%, -50%);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #ffffff;
    border: 1px solid #d5dbe3;
    color: #718096;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6rem;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(26, 32, 44, 0.14);
    transition: transform 0.1s, color 0.1s, border-color 0.1s;
    z-index: 3;
}
.rl-dc-tp-cut:hover {
    transform: translate(-50%, -50%) scale(1.18);
    color: #e53e3e;
    border-color: #e53e3e;
}
.rl-dc-tp-cut.tp-cut-down {
    color: #38a169;
    border-color: #9ae6b4;
}
.rl-dc-tp-cut.tp-cut-down:hover {
    color: #2f855a;
    border-color: #2f855a;
}
.rl-dc-tp-lagbadge {
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.52rem;
    font-weight: 700;
    color: #4a5568;
    background: #edf2f7;
    border-radius: 4px;
    padding: 0 4px;
    white-space: nowrap;
}
.rl-dc-tp-dot {
    position: absolute;
    left: 0;
    top: 0;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    pointer-events: none;
    offset-rotate: 0deg;
    animation-name: rlDcTpFlow;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    z-index: 2;
}
@keyframes rlDcTpFlow {
    from { offset-distance: 0%; }
    to { offset-distance: 100%; }
}
.rl-dc-tp-dot.tp-dot-trace {
    width: 9px;
    height: 9px;
    box-shadow: 0 0 8px 2px rgba(0, 92, 244, 0.55);
}
.rl-dc-tp-dot.tp-dot-storm {
    box-shadow: 0 0 7px 2px rgba(229, 62, 62, 0.6);
}
.rl-dc-tp-log {
    flex: 0 0 290px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    max-height: 70vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.rl-dc-tp-log-hd {
    font-size: 0.78rem;
    font-weight: 700;
    color: #1a202c;
    padding: 0.7rem 0.9rem;
    border-bottom: 1px solid #edf2f7;
}
.rl-dc-tp-log-hd i {
    color: #718096;
    margin-right: 4px;
}
.rl-dc-tp-log-body {
    overflow-y: auto;
    padding: 0.4rem 0.6rem 0.7rem;
}
.rl-dc-tp-log-row {
    display: flex;
    gap: 0.45rem;
    font-size: 0.7rem;
    color: #2d3748;
    line-height: 1.35;
    padding: 0.4rem 0.45rem;
    border-radius: 8px;
    margin-top: 0.25rem;
    background: #f7fafc;
    border-left: 3px solid #cbd5e0;
}
.rl-dc-tp-log-n {
    flex: 0 0 auto;
    font-size: 0.58rem;
    color: #a0aec0;
    font-family: var(--bs-font-monospace, monospace);
    padding-top: 1px;
}
.rl-dc-tp-log-bad { border-left-color: #e53e3e; background: #fff5f5; }
.rl-dc-tp-log-warn { border-left-color: #f0a93b; background: #fffaf0; }
.rl-dc-tp-log-good { border-left-color: #38cc65; background: #f0fff4; }
.rl-dc-tp-log-trace { border-left-color: #005cf4; background: #ebf4ff; }
.rl-dc-tp-log-empty {
    font-size: 0.7rem;
    color: #718096;
    padding: 0.8rem 0.6rem;
    line-height: 1.5;
}
@media (max-width: 991.98px) {
    .rl-dc-tp-main {
        flex-direction: column;
    }
    .rl-dc-tp-log {
        flex: 1 1 auto;
        width: 100%;
        max-height: 260px;
    }
}
