/* Altumint Remote Management Platform Styles */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #fff;
    height: 100vh;
    overflow: hidden;
}

/* Header */
.header {
    background:  rgb(2, 6, 23);
    border-bottom: 1px solid #334155;
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.header-content {
    display: flex;
    align-items: center;
    width: 100%;
    justify-content: space-between;
}

.logo {
    height: 40px;
    margin-right: 1rem;
    flex-shrink: 0;
}

.app-title {
    color: #fff;
    font-size: 1.5rem;
    font-weight: 300;
}

.header-actions {
    display: flex;
    gap: 2rem;
}

/* Main Layout */
.main-layout {
    display: flex;
    height: calc(100vh - 120px); /* Account for header and status bar */
}

/* Fullscreen mode styles */
body.fullscreen .header {
    display: none;
}

body.fullscreen .status-bar {
    display: none;
}

body.fullscreen .main-layout {
    height: 100vh;
}

body.fullscreen .host-sidebar {
    display: none;
}

body.fullscreen .work-area {
    width: 100%;
    margin-left: 0;
}

/* Host Sidebar */
.host-sidebar {
    width: 300px;
    background: rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(10px);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
}

.host-search-panel {
    margin: 0.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
}

.filters-row {
    margin-bottom: 1rem;
}

.search-row {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.search-row .search-input {
    flex: 1;
}

.search-row .btn {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
}

.host-list {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem;
    margin-bottom: 1px;
}

.host-item {
    padding: 0.75rem 1rem;
    margin: 0.25rem 0;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.host-item:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.host-item.selected {
    background: rgba(96, 165, 250, 0.15);
    border-color: #60a5fa;
    box-shadow: 0 0 0 1px rgba(96, 165, 250, 0.3);
}

.host-item-content {
    display: flex;
    align-items: center;
    gap: 1rem;
    position: relative;
}

.connection-indicator {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.connection-indicator.connected-by-me {
    background-color: #10b981;
    box-shadow: 0 0 4px rgba(16, 185, 129, 0.5);
}

.connection-indicator.connected-by-others {
    background-color: #f59e0b;
    box-shadow: 0 0 4px rgba(245, 158, 11, 0.5);
}

.connection-indicator.disconnected {
    background-color: #6b7280;
    box-shadow: 0 0 4px rgba(107, 114, 128, 0.3);
}

.host-item-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
    opacity: 0.8;
}

.host-item-details {
    flex: 1;
    min-width: 0; /* Allow text to truncate */
}

.host-item-name {
    font-weight: 500;
    color: #fff;
    font-size: 0.95rem;
}

.host-item-ip {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 0.25rem;
    font-family: 'Courier New', monospace;
}

.host-item-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.loading-hosts {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    color: rgba(255, 255, 255, 0.6);
}

.error-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    color: #ef4444;
    text-align: center;
    gap: 1rem;
}

.error-state i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.btn-retry {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.2s;
}

.btn-retry:hover {
    background: #2563eb;
}

.loading-files {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 2rem;
    color: rgba(255, 255, 255, 0.6);
}

/* Work Area */
.work-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: rgba(0, 0, 0, 0.15);
    height: 100%;
    max-height: 100%;
    min-height: 0;
    padding-bottom: 1rem;
}

.work-area-header {
    padding: 1rem 2rem;
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    margin: 1rem;
    margin-bottom: 0;
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* Dynamic Work Area Content */
#work-area-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    margin: 0 1rem 1rem 1rem;
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    height: 100%;
    max-height: 100%;
    min-height: 0;
}

.selected-host-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: space-between;
    flex: 1;
}

.fullscreen-toggle {
    background: transparent;
    border: none;
    color: #fff;
    padding: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 1.8rem;
    font-weight: bold;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-radius: 4px;
}

.fullscreen-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.1);
}

.fullscreen-toggle:active {
    transform: scale(0.95);
}

.host-details {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.host-name {
    font-size: 2rem;
    font-weight: 600;
    color: #fff;
}

.host-ip {
    font-size: 0.9rem;
    color: #87ceeb;
    font-family: 'Courier New', monospace;
    display: flex;
    align-items: center;
    margin-top: 1rem;
    margin-left: 1rem;
}

.host-controls {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.host-controls .btn {
    padding: 0.5rem;
    min-width: 50px;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    border: none !important;
}

#connected-workspace {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    max-height: 100%;
    min-height: 0;
}

.dynamic-tabs {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    max-height: 100%;
    min-height: 0;
}

/* Work Tabs */
.work-tabs {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.tab-nav {
    display: flex;
    background: rgba(0, 0, 0, 0.25);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tab-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.tab-button:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.tab-button.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    border-bottom-color: #60a5fa;
}

.tab-button.disabled {
    cursor: not-allowed;
    opacity: 0.5;
    pointer-events: none;
}

.tab-button.disabled:hover {
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
}

.tab-icon {
    font-size: 1.1rem;
}

.tab-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.tab-pane {
    display: none;
    flex: 1;
    flex-direction: column;
    /* Prevent layout shifts during tab switching */
    position: relative;
    overflow: hidden;
}

.tab-pane.active {
    display: flex;
}

/* Console Styles */
.console-layout {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.console-status {
    color: #e2e8f0;
}

.console-actions {
    display: flex;
    gap: 0.5rem;
}

/* Content Area */
.content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.search-input {
    flex: 1;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 0.9rem;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.search-input:focus {
    outline: none;
    border-color: #87ceeb;
    box-shadow: 0 0 0 2px rgba(135, 206, 235, 0.2);
}

.form-select {
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 0.9rem;
    width: 100%;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.7rem center;
    background-size: 1em;
    padding-right: 2.5rem;
}

.form-select option {
    background: #333;
    color: #fff;
}

/* Buttons */
.btn {
    padding: 0.5rem;
    border: none !important;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    border-radius: 4px;
    min-width: 36px;
    min-height: 36px;
}

.btn:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    transform: scale(1.05);
}

.btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    pointer-events: none;
}

/* Connection button connecting state */
.btn.connecting {
    background: rgba(245, 158, 11, 0.2) !important;
    color: #f59e0b !important;
    animation: pulse 1.5s infinite;
    cursor: not-allowed;
    pointer-events: none;
}

/* =============================================================================
   UNIFIED DESIGN SYSTEM
   ============================================================================= */

/* Button Variants - Consistent across all components */
.btn-primary {
    background: rgba(96, 165, 250, 0.2);
    color: #60a5fa;
    border: 1px solid rgba(96, 165, 250, 0.3);
}

.btn-primary:hover:not(:disabled) {
    background: rgba(96, 165, 250, 0.3);
    border-color: #60a5fa;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.9);
    border-color: rgba(255, 255, 255, 0.4);
}

.btn-success {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.btn-success:hover:not(:disabled) {
    background: rgba(34, 197, 94, 0.3);
    border-color: #22c55e;
}

.btn-danger {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-danger:hover:not(:disabled) {
    background: rgba(239, 68, 68, 0.3);
    border-color: #ef4444;
}

.btn-warning {
    background: rgba(251, 191, 36, 0.2);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.3);
}

.btn-warning:hover:not(:disabled) {
    background: rgba(251, 191, 36, 0.3);
    border-color: #fbbf24;
}

.btn-info {
    background: rgba(96, 165, 250, 0.2);
    color: #60a5fa;
    border: 1px solid rgba(96, 165, 250, 0.3);
}

.btn-info:hover:not(:disabled) {
    background: rgba(96, 165, 250, 0.3);
    border-color: #60a5fa;
}

/* Button Sizes */
.btn-xs {
    padding: 0.2rem 0.4rem;
    font-size: 0.75rem;
    min-width: 24px;
    min-height: 24px;
    border-radius: 2px;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.85rem;
    min-width: 32px;
    min-height: 32px;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.1rem;
    min-width: 44px;
    min-height: 44px;
}

/* Status Indicators - Unified across all components */
.status {
    font-size: 0.85rem;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    width: fit-content;
    border: 1px solid;
}

.status-active {
    background-color: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    border-color: rgba(34, 197, 94, 0.3);
}

.status-enabled {
    background-color: rgba(96, 165, 250, 0.2);
    color: #60a5fa;
    border-color: rgba(96, 165, 250, 0.3);
}

.status-inactive,
.status-disabled {
    background-color: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    border-color: rgba(255, 255, 255, 0.2);
}

.status-error,
.status-failed {
    background-color: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.3);
}

.status-warning,
.status-partial {
    background-color: rgba(251, 191, 36, 0.2);
    color: #fbbf24;
    border-color: rgba(251, 191, 36, 0.3);
}

.status-success {
    background-color: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    border-color: rgba(34, 197, 94, 0.3);
}

.status-info {
    background-color: rgba(96, 165, 250, 0.2);
    color: #60a5fa;
    border-color: rgba(96, 165, 250, 0.3);
}

/* Card/Panel Components */
.card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.card-header {
    background: rgba(2, 6, 23, 0.9);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 8px 8px 0 0;
}

.card-body {
    padding: 20px;
    background: rgba(0, 0, 0, 0.15);
}

.card-title {
    margin: 0 0 5px 0;
    color: #fff;
    font-size: 1.2rem;
    font-weight: 600;
}

.card-subtitle {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    margin: 0;
}

/* Loading States */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.6);
    padding: 2rem;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top: 3px solid #60a5fa;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

/* Error States */
.error {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ef4444;
    padding: 2rem;
}

.error-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Utility Classes */
.text-muted {
    color: rgba(255, 255, 255, 0.6);
}

.text-white {
    color: #fff;
}

.text-center {
    text-align: center;
}

.d-flex {
    display: flex;
}

.flex-column {
    flex-direction: column;
}

.justify-content-between {
    justify-content: space-between;
}

.align-items-center {
    align-items: center;
}

.gap-1 {
    gap: 0.25rem;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 1rem;
}

.mb-0 {
    margin-bottom: 0;
}

.mb-1 {
    margin-bottom: 0.25rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.mb-3 {
    margin-bottom: 1rem;
}

.btn.connecting::after {
    content: " ⏳";
    margin-left: 0.25rem;
}

.btn-icon {
    padding: 0.375rem;
    min-width: 32px;
    min-height: 32px;
}

.btn-small {
    padding: 0.25rem;
    font-size: 0.875rem;
    min-width: 28px;
    min-height: 28px;
}

/* Global Notification/Toast Styles */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    min-width: 300px;
    max-width: 500px;
    background: rgba(30, 41, 59, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease-out;
}

.notification-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
}

.notification-message {
    color: #fff;
    font-size: 14px;
    line-height: 1.4;
    flex: 1;
    margin-right: 12px;
}

.notification-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.notification-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.notification-error {
    border-left: 4px solid #ef4444;
}

.notification-warning {
    border-left: 4px solid #f59e0b;
}

.notification-success {
    border-left: 4px solid #10b981;
}

.notification-info {
    border-left: 4px solid #3b82f6;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Global Loading Toast Styles */
.loading-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(2, 6, 23, 0.95);
    border: 1px solid rgba(135, 206, 235, 0.3);
    border-radius: 6px;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    z-index: 9999;
    backdrop-filter: blur(4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    animation: slideInFromTop 0.3s ease-out;
}

@keyframes slideInFromTop {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.loading-toast .loading-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(135, 206, 235, 0.3);
    border-top: 2px solid #87ceeb;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-toast .loading-message {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Global Sudo Badge Styles */
.sudo-badge {
    background: #d97706;
    color: #000;
    padding: 0.25rem 0.6rem;
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 500;
    margin-left: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    border: none;
    outline: none;
    box-shadow: none;
    height: fit-content;
    white-space: nowrap;
}

/* Smaller variant for package manager */
.sudo-badge-small {
    padding: 0.15rem 0.4rem;
    font-size: 0.7rem;
    border-radius: 12px;
}

/* Tab Content */
.tab-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    max-height: 100%;
    min-height: 0;
}

.tab-pane {
    display: none;
    flex: 1;
    flex-direction: column;
    height: 100%;
    max-height: 100%;
    min-height: 0;
}

.tab-pane.active {
    display: flex;
}

/* Connection Placeholder */
.connection-placeholder {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.1);
}

.placeholder-content {
    text-align: center;
    padding: 3rem 2rem;
    max-width: 400px;
}

.placeholder-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.6;
}

.placeholder-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 1rem;
}

.placeholder-message {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}



/* Loading Animation */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    color: rgba(255, 255, 255, 0.7);
}

.loading-discovery {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 2rem;
}

.spinner {
    width: 24px;
    height: 24px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid #4fc3f7;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* File Manager Styles - FTP Dual Pane Layout */
.file-manager-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.file-manager-header {
    background: rgba(0, 0, 0, 0.4);
    padding: 0.75rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.file-manager-title {
    font-size: 1.1rem;
    font-weight: 500;
}

.file-manager-info {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.85rem;
}

.file-manager-content {
    flex: 1;
    display: flex;
    overflow: hidden;
}

/* Machine Info Styles */

.empty-state {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 16px;
    text-align: center;
    padding: 2rem;
}

/* Status Bar */
.status-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50px;
    background: rgb(2, 6, 23);
    border-top: 1px solid #334155;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    z-index: 1000;
}

.status-left {
    display: flex;
    gap: 2rem;
}

.status-right {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.status-counts {
    display: flex;
    gap: 1.5rem;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

.status-count-item {
    white-space: nowrap;
}

.status-count-item span {
    color: #87ceeb;
    font-weight: 500;
}

.connection-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

.connection-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #475569;
    transition: background-color 0.3s ease;
}

.connection-indicator.connected-by-me {
    background: #10b981;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
}

.connection-indicator.connected-by-others {
    background: #f59e0b;
    box-shadow: 0 0 8px rgba(245, 158, 11, 0.5);
}

.connection-indicator.connecting {
    background: #f59e0b;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* File Upload Area */
.file-upload-area {
    border: 2px dashed rgba(135, 206, 235, 0.3);
    border-radius: 8px;
    padding: 2rem;
    margin: 1rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(0, 0, 0, 0.1);
}

.file-upload-area:hover,
.file-upload-area.drag-over {
    border-color: #87ceeb;
    background: rgba(135, 206, 235, 0.1);
}

.upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.upload-icon {
    font-size: 3rem;
    opacity: 0.7;
}

.upload-text p {
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
}

.upload-hint {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
}

.uploaded-files-list {
    margin-top: 1rem;
}

.local-file {
    position: relative;
}

.file-actions {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.remove-file-btn {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid #ef4444;
    border-radius: 50%;
    color: #ef4444;
    cursor: pointer;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    line-height: 1;
    transition: all 0.2s ease;
}

.remove-file-btn:hover {
    background: rgba(239, 68, 68, 0.3);
    transform: scale(1.1);
}

/* Loading States */
.loading-files {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 2rem;
    color: rgba(255, 255, 255, 0.7);
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-top: 2px solid #87ceeb;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile Device Warning */
@media (max-width: 600px) {
    body::before {
        content: "This remote management platform requires a desktop computer. Please use a laptop or desktop for proper functionality.";
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(0, 0, 0, 0.95);
        color: #fff;
        display: flex;
        align-items: center;
        justify-content: center;
        text-align: center;
        font-size: 1.2rem;
        font-weight: 500;
        z-index: 9999;
        padding: 2rem;
        line-height: 1.5;
    }
}

/* Redirect Message Styles */
.redirect-message {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.1);
}

.redirect-content {
    text-align: center;
    padding: 3rem 2rem;
    max-width: 400px;
}

.redirect-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.6;
    color: rgba(255, 255, 255, 0.7);
}

.redirect-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 1rem;
}

.redirect-message {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

/* User Info Display */
.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
    min-width: 200px;
}

.user-details {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    text-align: right;
}

.user-name {
    font-size: 0.875rem;
    font-weight: 500;
    color: #fff;
    line-height: 1.2;
}

.user-email {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.2;
}

.logout-btn {
    padding: 0.5rem;
    min-width: 36px;
    min-height: 36px;
    color: rgba(255, 255, 255, 0.7);
}

.logout-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* Header responsive adjustments */
@media (max-width: 768px) {
    .header-content {
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .user-info {
        order: 3;
        width: 100%;
        justify-content: flex-end;
    }
}

/* Mobile responsive for user details */

/* =============================================================================
   UNIFIED MODAL SYSTEM
   ============================================================================= */

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.3s ease;
    box-sizing: border-box;
    padding: 20px;
}

.modal-overlay.show {
    opacity: 1;
}

/* Base Modal */
.modal {
    background: rgba(2, 6, 23, 0.95);
    border: 1px solid rgba(135, 206, 235, 0.3);
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    width: 100%;
    max-width: 500px;
    min-width: 300px;
    max-height: 80vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease-out;
    position: relative;
    box-sizing: border-box;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Modal Header */
.modal-header {
    padding: 1.5rem 1.5rem 1rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-sizing: border-box;
}

.modal-title {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    font-weight: 500;
    margin: 0;
    flex: 1;
}

.modal-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 1);
}

/* Modal Body */
.modal-body {
    padding: 1.5rem;
    box-sizing: border-box;
}

.modal-message {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0;
}

/* Modal Footer */
.modal-footer {
    padding: 1rem 1.5rem 1.5rem 1.5rem;
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    box-sizing: border-box;
}

/* Modal Buttons - Use existing btn system with specific styling */
.modal .btn {
    min-width: 80px;
    padding: 0.6rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.modal .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(96, 165, 250, 0.2);
}

/* Confirmation Dialog Specific */
.confirmation-modal .modal-message {
    text-align: center;
    margin-bottom: 1.5rem;
}

.confirmation-modal .warning-icon {
    font-size: 2.5rem;
    color: #f59e0b;
    display: block;
    margin-bottom: 1rem;
}

/* Loading States */
.modal-loading {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.85rem;
}

.modal .loading-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-top: 2px solid #87ceeb;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Button Loading State */
.modal .btn.loading {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

.modal .btn.loading::after {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-left: 0.5rem;
    border: 1px solid currentColor;
    border-top: 1px solid transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* Mobile responsive for user details */
@media (max-width: 480px) {
    .user-details {
        display: none; /* Hide text on mobile, show only logout button */
    }
}

