/* ============================================
   GETSETLIVE STREAMING ADMIN - MODERN UI v3.0
   Updated: 2025-12-02
   Theme: Light (default) / Dark
   Professional, Feature-Rich Design
   Font sizes updated: 0.75rem->0.9rem, 0.9rem->1.2rem, h3->1.5rem
   ============================================ */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

/* ============================================
   CSS VARIABLES - DESIGN TOKENS
   ============================================ */
:root {
    /* Light Theme Colors */
    --bg-body: #f0f4f8;
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --bg-card: #ffffff;
    --bg-sidebar: #1e293b;
    --bg-sidebar-hover: #334155;
    --bg-sidebar-active: #3b82f6;
    --bg-hover: #f1f5f9;
    --bg-active: #eff6ff;
    --bg-input: #ffffff;
    --bg-input-focus: #ffffff;

    /* Text Colors */
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --text-inverse: #ffffff;
    --text-sidebar: #cbd5e1;
    --text-sidebar-active: #ffffff;

    /* Border Colors */
    --border-color: #e2e8f0;
    --border-light: #f1f5f9;
    --border-focus: #3b82f6;
    --border-card: #e2e8f0;

    /* Brand & Accent Colors */
    --brand-primary: #2A3CD1;
    --brand-secondary: #f44336;
    --brand-gradient: linear-gradient(135deg, #2196f3 0%, #f44336 100%);

    --accent-primary: #3b82f6;
    --accent-primary-hover: #2563eb;
    --accent-primary-light: #dbeafe;
    --accent-success: #10b981;
    --accent-success-light: #d1fae5;
    --accent-warning: #f59e0b;
    --accent-warning-light: #fef3c7;
    --accent-danger: #ef4444;
    --accent-danger-light: #fee2e2;
    --accent-info: #06b6d4;
    --accent-info-light: #cffafe;
    --accent-purple: #8b5cf6;
    --accent-purple-light: #ede9fe;

    /* Shadows - More Prominent */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-card-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);

    /* Layout */
    --sidebar-width: 260px;
    --sidebar-collapsed-width: 70px;
    --header-height: 70px;
    --content-padding: 28px;

    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 200ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);

    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-xl: 18px;
    --radius-2xl: 24px;
    --radius-full: 9999px;
    /* 2025-12-05: Dedicated button border-radius - 6px across all buttons */
    --radius-btn: 6px;

    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-display: 'Space Grotesk', var(--font-sans);
    --font-mono: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
}

/* ============================================
   DARK THEME
   ============================================ */
[data-theme="dark"] {
    --bg-body: #0f172a;
    --bg-primary: #1e293b;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --bg-card: #1e293b;
    --bg-sidebar: #0f172a;
    --bg-sidebar-hover: #1e293b;
    --bg-hover: #334155;
    --bg-active: #1e3a5f;
    --bg-input: #1e293b;
    --bg-input-focus: #334155;

    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-muted: #64748b;
    --text-sidebar: #94a3b8;

    --border-color: #334155;
    --border-light: #1e293b;
    --border-card: #334155;

    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-card-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
}

/* ============================================
   BASE STYLES & RESET
   ============================================ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 14px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background: var(--bg-body);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color var(--transition-normal), color var(--transition-normal);
}

a {
    color: var(--accent-primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--accent-primary-hover);
}

/* Global H3 styling - Updated 2025-12-02 */
h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* ============================================
   ADMIN LAYOUT
   ============================================ */
.admin-layout {
    display: none;
    min-height: 100vh;
}

.admin-layout.authenticated {
    display: flex;
}

/* ============================================
   SIDEBAR - Modern Dark Design
   ============================================ */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-sidebar);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 100;
    transition: width var(--transition-slow), transform var(--transition-slow);
    box-shadow: 4px 0 15px rgba(0, 0, 0, 0.1);
}

.sidebar-header {
    height: var(--header-height);
    padding: 0 20px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.1);
}

.logo {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-inverse);
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    transition: opacity var(--transition-fast);
}

.logo:hover {
    opacity: 0.9;
    text-decoration: none;
}

.logo-img {
    height: 36px;
    width: auto;
    object-fit: contain;
    filter: brightness(1.1);
}

.logo span {
    background: var(--brand-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Navigation Menu */
.nav-menu {
    list-style: none;
    padding: 16px 12px;
    flex: 1;
    overflow-y: auto;
}

.nav-menu::-webkit-scrollbar {
    width: 4px;
}

.nav-menu::-webkit-scrollbar-track {
    background: transparent;
}

.nav-menu::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.nav-menu li {
    margin-bottom: 4px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    color: var(--text-sidebar);
    text-decoration: none;
    border-radius: var(--radius-md);
    font-weight: 500;
    font-size: 1.2rem;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden;
}

.nav-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--accent-primary);
    transform: scaleY(0);
    transition: transform var(--transition-fast);
    border-radius: 0 3px 3px 0;
}

.nav-link:hover {
    background: var(--bg-sidebar-hover);
    color: var(--text-inverse);
    text-decoration: none;
}

.nav-link.active {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.2) 0%, transparent 100%);
    color: var(--text-inverse);
}

.nav-link.active::before {
    transform: scaleY(1);
}

.nav-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    opacity: 0.7;
    transition: opacity var(--transition-fast);
}

.nav-link:hover .nav-icon,
.nav-link.active .nav-icon {
    opacity: 1;
}

/* ============================================
   MAIN CONTENT AREA
   ============================================ */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: var(--bg-body);
}

/* ============================================
   HEADER - Clean & Modern
   ============================================ */
.content-header {
    height: var(--header-height);
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    padding: 0 var(--content-padding);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 50;
    box-shadow: var(--shadow-sm);
}

.header-info h1,
#section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    font-family: var(--font-display);
    letter-spacing: -0.02em;
}

.header-info p,
#section-subtitle {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 4px 0 0;
    font-weight: 400;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Theme Toggle - Pill Design */
.theme-toggle {
    display: flex;
    align-items: center;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    padding: 4px;
    border: 1px solid var(--border-color);
}

.theme-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: all var(--transition-fast);
}

.theme-btn:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.theme-btn.active {
    background: var(--bg-primary);
    color: var(--accent-primary);
    box-shadow: var(--shadow-sm);
}

.theme-btn svg {
    width: 18px;
    height: 18px;
}

/* Status Indicator - Badge Style */
.status-indicator {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    background: var(--accent-success-light);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: var(--radius-full);
    font-size: 1rem;
    font-weight: 600;
}

[data-theme="dark"] .status-indicator {
    background: rgba(16, 185, 129, 0.15);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--accent-success);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
    animation: pulse 2s infinite;
}

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

.status-dot.warning {
    background: var(--accent-warning);
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.status-dot.danger, .status-dot.error {
    background: var(--accent-danger);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
    animation: none;
}

.status-text {
    color: var(--accent-success);
    font-weight: 600;
}

.current-time {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    font-family: var(--font-mono);
    background: var(--bg-tertiary);
    padding: 8px 14px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

/* User Menu - Logout Button */
.user-menu .logout-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all var(--transition-fast);
    border: 1px solid transparent;
}

.user-menu .logout-link:hover {
    background: var(--accent-danger-light);
    color: var(--accent-danger);
    border-color: rgba(239, 68, 68, 0.2);
}

[data-theme="dark"] .user-menu .logout-link:hover {
    background: rgba(239, 68, 68, 0.15);
}

.logout-icon {
    width: 18px;
    height: 18px;
}

/* ============================================
   CONTENT SECTIONS
   ============================================ */
.content-section {
    display: none;
    padding: var(--content-padding);
    flex: 1;
}

.content-section.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   DASHBOARD GAUGES ROW - 2025-12-04
   CPU and Memory gauges moved from Monitoring
   Title on top, gauge below, left-aligned
   ============================================ */
.dashboard-gauges-row {
    display: flex;
    justify-content: flex-start;
    gap: 24px;
    margin-bottom: 24px;
}

.dashboard-gauges-row .monitoring-widget {
    flex: 0 0 auto;
    min-width: 200px;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 12px 24px;
    gap: 0;  /* Remove gap between flex items */
}

.dashboard-gauges-row .monitoring-widget h4 {
    font-size: 1rem;
    color: #444f60;
    margin-bottom: 2px;
}

/* ============================================
   METRICS CARDS - Modern Design
   ============================================ */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 28px;
}

.metric-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all var(--transition-normal);
    box-shadow: var(--shadow-card);
    position: relative;
    overflow: hidden;
}

.metric-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--accent-primary);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.metric-card:hover {
    box-shadow: var(--shadow-card-hover);
    transform: translateY(-2px);
}

.metric-card:hover::before {
    opacity: 1;
}

.metric-card:nth-child(1)::before { background: var(--accent-primary); }
.metric-card:nth-child(2)::before { background: var(--accent-success); }
.metric-card:nth-child(3)::before { background: var(--accent-warning); }
.metric-card:nth-child(4)::before { background: var(--accent-purple); }

.metric-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.metric-card:nth-child(1) .metric-icon { background: var(--accent-primary-light); }
.metric-card:nth-child(2) .metric-icon { background: var(--accent-success-light); }
.metric-card:nth-child(3) .metric-icon { background: var(--accent-warning-light); }
.metric-card:nth-child(4) .metric-icon { background: var(--accent-purple-light); }

[data-theme="dark"] .metric-card:nth-child(1) .metric-icon { background: rgba(59, 130, 246, 0.2); }
[data-theme="dark"] .metric-card:nth-child(2) .metric-icon { background: rgba(16, 185, 129, 0.2); }
[data-theme="dark"] .metric-card:nth-child(3) .metric-icon { background: rgba(245, 158, 11, 0.2); }
[data-theme="dark"] .metric-card:nth-child(4) .metric-icon { background: rgba(139, 92, 246, 0.2); }
[data-theme="dark"] .metric-card:nth-child(5) .metric-icon { background: rgba(236, 72, 153, 0.2); }

/* System Status Card - Added 2025-11-26 */
.system-status-card.operational {
    border-color: var(--accent-success);
    background: linear-gradient(135deg, var(--bg-card) 0%, rgba(16, 185, 129, 0.05) 100%);
}

.system-status-card.operational .metric-icon {
    background: var(--accent-success-light);
}

.system-status-card.degraded {
    border-color: var(--accent-warning);
    background: linear-gradient(135deg, var(--bg-card) 0%, rgba(245, 158, 11, 0.05) 100%);
}

.system-status-card.degraded .metric-icon {
    background: var(--accent-warning-light);
}

.system-status-card.down {
    border-color: var(--accent-danger);
    background: linear-gradient(135deg, var(--bg-card) 0%, rgba(239, 68, 68, 0.05) 100%);
}

.system-status-card.down .metric-icon {
    background: var(--accent-danger-light);
}

.system-status-card .metric-value {
    font-size: 1.2rem;
}

.metric-content {
    flex: 1;
}

.metric-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.1;
    font-family: var(--font-display);
    letter-spacing: -0.02em;
}

/* 2025-12-05: Updated font-size to 1rem and color to #444f60 */
.metric-label {
    font-size: 1rem;
    color: #444f60;
    margin-top: 4px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ============================================
   WIDGETS - Card Components
   ============================================ */
.dashboard-widgets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
}

.widget {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: box-shadow var(--transition-normal);
}

.widget:hover {
    box-shadow: var(--shadow-md);
}

.widget-header {
    padding: 18px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-secondary);
}

/* 2025-12-05: Updated color to #444f60, font-size to 1.2rem */
.widget-header h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: #444f60;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.widget-header .header-actions {
    gap: 10px;
}

.widget-content {
    padding: 20px 24px;
}

/* ============================================
   BUTTONS - Modern & Consistent
   ============================================ */
/* 2025-12-05: Updated border-radius to 6px for all buttons */
button, .btn {
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 600;
    padding: 10px 18px;
    border-radius: var(--radius-btn);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all var(--transition-fast);
    text-decoration: none;
    white-space: nowrap;
}

button:disabled, .btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

/* Primary Button - Solid Blue */
.btn-primary {
    background: var(--accent-primary);
    color: white;
    box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover:not(:disabled) {
    background: var(--accent-primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.btn-primary:active:not(:disabled) {
    transform: translateY(0);
}

/* Secondary Button - Outlined */
.btn-secondary {
    background: var(--bg-primary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-xs);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--bg-hover);
    border-color: var(--text-muted);
}

/* Success Button */
.btn-success {
    background: var(--accent-success);
    color: white;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
}

.btn-success:hover:not(:disabled) {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

/* Danger Button */
.btn-danger {
    background: var(--accent-danger);
    color: white;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

.btn-danger:hover:not(:disabled) {
    background: #dc2626;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

/* Warning Button */
.btn-warning {
    background: var(--accent-warning);
    color: white;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3);
}

.btn-warning:hover:not(:disabled) {
    background: #d97706;
    transform: translateY(-1px);
}

/* Service Management Buttons */
.btn-start {
    background: var(--accent-success);
    color: white;
    padding: 8px 14px;
    font-size: 1rem;
    font-weight: 600;
}

.btn-start:hover:not(:disabled) {
    background: #059669;
    transform: translateY(-1px);
}

.btn-stop {
    background: var(--accent-danger);
    color: white;
    padding: 8px 14px;
    font-size: 1rem;
    font-weight: 600;
}

.btn-stop:hover:not(:disabled) {
    background: #dc2626;
    transform: translateY(-1px);
}

.btn-restart {
    background: var(--accent-warning);
    color: white;
    padding: 8px 14px;
    font-size: 1rem;
    font-weight: 600;
}

.btn-restart:hover:not(:disabled) {
    background: #d97706;
    transform: translateY(-1px);
}

/* Small Buttons - 2025-12-05: Updated to use consistent 6px radius */
.btn-small {
    padding: 6px 12px;
    font-size: 1rem;
    border-radius: var(--radius-btn);
}

/* Refresh Button */
.refresh-btn {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    padding: 8px 14px;
    font-size: 1rem;
}

.refresh-btn:hover {
    background: var(--bg-hover);
    color: var(--accent-primary);
}

/* ============================================
   SERVICES LIST - Enhanced Design
   ============================================ */
.service-management-widget .widget-header {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
}

.services-header {
    display: grid;
    grid-template-columns: 1fr 120px 50px;
    gap: 16px;
    padding: 12px 0;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    border-bottom: 2px solid var(--border-color);
}

/* Center align the Status header text - Added 2025-12-04 */
.services-status-label {
    text-align: center;
}

.services-list {
    max-height: none;
    overflow-y: visible;
}

.service-row {
    display: grid;
    grid-template-columns: 1fr 120px 50px;
    gap: 16px;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-light);
    transition: background var(--transition-fast);
}

.service-row:hover {
    background: var(--bg-hover);
    margin: 0 -24px;
    padding-left: 24px;
    padding-right: 24px;
}

.service-row:last-child {
    border-bottom: none;
}

.service-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
}

.service-status-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Status column for grid layout - Added 2025-12-04 */
.service-status-column {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.service-status {
    font-size: 1.1rem;
    line-height: 1;
}

.service-status.running { color: var(--accent-success); }
.service-status.stopped, .service-status.error { color: var(--accent-danger); }

.refresh-service-btn {
    width: 28px;
    height: 28px;
    padding: 0;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.refresh-service-btn:hover {
    background: var(--accent-primary-light);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.refresh-service-btn svg {
    transition: transform 0.3s ease;
}

.refresh-service-btn:active svg {
    transform: rotate(180deg);
}

/* Checkboxes - Modern Style */
.service-checkbox input,
.master-checkbox input {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--accent-primary);
    border-radius: var(--radius-sm);
}

/* ============================================
   ACTIVITY LIST
   ============================================ */
.activity-list {
    max-height: 350px;
    overflow-y: auto;
}

.activity-item {
    display: flex;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-light);
    align-items: flex-start;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-time {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-muted);
    font-family: var(--font-mono);
    min-width: 55px;
    background: var(--bg-tertiary);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
}

.activity-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
    flex: 1;
}

/* ============================================
   TABLES - Professional Design
   ============================================ */
.streams-table,
.users-table {
    width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-card);
}

/* 2025-12-05: Adjusted column widths - reduced Data I/O, expanded Actions for buttons */
.table-header {
    display: grid;
    grid-template-columns: 2fr 0.8fr 0.8fr 0.8fr 1fr 2fr;
    gap: 8px;
    padding: 16px 24px;
    background: var(--bg-secondary);
    border-bottom: 2px solid var(--border-color);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.table-row {
    display: grid;
    grid-template-columns: 2fr 0.8fr 0.8fr 0.8fr 1fr 2fr;
    gap: 8px;
    padding: 18px 24px;
    border-bottom: 1px solid var(--border-light);
    align-items: center;
    transition: background var(--transition-fast);
}

/* Users Table with Actions - 7 columns for user management - Flex width with left alignment */
#users-table .table-header,
#users-table .table-row {
    display: grid;
    grid-template-columns: 2fr 1.2fr 1fr 0.8fr 0.8fr 1fr 1.5fr;
    gap: 12px;
    padding: 12px 16px;
    align-items: center;
}

#users-table .table-header {
    background: var(--bg-secondary);
    border-bottom: 2px solid var(--border-color);
}

#users-table .table-header .table-cell {
    font-weight: 700;
    font-size: 0.77rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
    text-align: left;
}

/* Column cells - left aligned with consistent styling */
#users-table .table-cell {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    font-size: 0.85rem;
    min-height: 40px;
}

#users-table .table-cell:last-child {
    justify-content: flex-end;
    gap: 6px;
}

#users-table .table-cell:last-child .btn-small {
    padding: 5px 10px;
    font-size: 1.1rem;
    white-space: nowrap;
}

/* User row hover effect with left accent */
#users-table .table-row {
    cursor: pointer;
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
    border-bottom: 1px solid var(--border-light);
}

#users-table .table-row:hover {
    background: var(--bg-hover);
    border-left-color: var(--accent-primary);
}

#users-table .table-row:last-child {
    border-bottom: none;
}

/* Loading state for users table */
#users-table .table-row.loading {
    display: flex;
    justify-content: center;
    padding: 40px;
    color: var(--text-muted);
}

#users-table .table-row.loading .table-cell {
    justify-content: center;
}

/* Organizations Table - 7 columns matching users table style - Added 2025-11-26 */
#organizations-table .table-header,
#organizations-table .table-row {
    display: grid;
    grid-template-columns: 2fr 1fr 0.8fr 0.8fr 1fr 1fr 1.2fr;
    gap: 12px;
    padding: 12px 16px;
    align-items: center;
}

#organizations-table .table-header {
    background: var(--bg-secondary);
    border-bottom: 2px solid var(--border-color);
}

#organizations-table .table-header .table-cell {
    font-weight: 600;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
    text-align: left;
}

#organizations-table .table-cell {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    font-size: 0.85rem;
    min-height: 40px;
}

#organizations-table .table-cell:last-child {
    justify-content: flex-end;
    gap: 6px;
}

#organizations-table .table-cell:last-child .btn-small {
    padding: 5px 10px;
    font-size: 1.1rem;
    white-space: nowrap;
}

#organizations-table .table-row {
    cursor: pointer;
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
    border-bottom: 1px solid var(--border-light);
}

#organizations-table .table-row:hover {
    background: var(--bg-hover);
    border-left-color: var(--accent-primary);
}

#organizations-table .table-row:last-child {
    border-bottom: none;
}

#organizations-table .table-row.loading {
    display: flex;
    justify-content: center;
    padding: 40px;
    color: var(--text-muted);
}

#organizations-table .table-row.loading .table-cell {
    justify-content: center;
}

.table-row:hover {
    background: var(--bg-hover);
}

.table-row:last-child {
    border-bottom: none;
}

/* Users & Groups Toolbar Card Styles */
.users-toolbar-card,
.groups-toolbar-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-card);
}

/* Split Toolbar Layout - Two containers side by side - Added 2025-11-26 */
.users-toolbar-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

.toolbar-card-left,
.toolbar-card-right {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 16px 20px;
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.toolbar-card-left {
    /* Search section */
}

.toolbar-card-left .search-box {
    flex: 1;
}

/* Standard button width - not full width */
.toolbar-card-left .btn-secondary,
.toolbar-card-right .btn-primary {
    align-self: flex-start;
    min-width: 140px;
    width: auto;
}

.toolbar-card-right {
    /* Filters and Create section */
}

.toolbar-card-right .filter-row {
    display: flex;
    gap: 12px;
}

.toolbar-card-right .filter-select {
    flex: 1;
    height: 42px;
    padding: 0 32px 0 12px;
    box-sizing: border-box;
}

@media (max-width: 768px) {
    .users-toolbar-split {
        grid-template-columns: 1fr;
    }
}

.toolbar-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 280px;
    max-width: 100%;
}

/* Search icon - right aligned to avoid overlap with placeholder */
.search-box .search-icon {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

/* Search input - standard height 42px to match dropdowns */
.search-input-lg {
    width: 100%;
    height: 42px;
    padding: 0 44px 0 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 1.2rem;
    background: var(--bg-input);
    color: var(--text-primary);
    transition: all var(--transition-fast);
    box-sizing: border-box;
}

.search-input-lg:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px var(--accent-primary-light);
}

.search-input-lg::placeholder {
    color: var(--text-muted);
}

.toolbar-filters {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.table-row.loading {
    justify-content: center;
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
}

.table-cell {
    font-size: 1.2rem;
    color: var(--text-primary);
}

/* Status Badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    text-transform: capitalize;
}

.status-badge.active,
.status-badge.live {
    background: var(--accent-success-light);
    color: var(--accent-success);
}

.status-badge.inactive,
.status-badge.offline {
    background: var(--bg-tertiary);
    color: var(--text-tertiary);
}

[data-theme="dark"] .status-badge.active,
[data-theme="dark"] .status-badge.live {
    background: rgba(16, 185, 129, 0.2);
}

[data-theme="dark"] .status-badge.inactive,
[data-theme="dark"] .status-badge.offline {
    background: rgba(107, 114, 128, 0.2);
}

/* Role Badges - Updated 2025-11-26: Very faint backgrounds with clearly visible text */
.role-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    text-transform: capitalize;
}

/* Super Admin - Very faint purple badge */
.role-badge.super_admin {
    background: rgba(139, 92, 246, 0.08);
    color: #7C3AED;
    border: 1px solid rgba(139, 92, 246, 0.2);
}

/* Admin - Very faint purple badge */
.role-badge.admin {
    background: rgba(139, 92, 246, 0.08);
    color: #7C3AED;
    border: 1px solid rgba(139, 92, 246, 0.2);
}

/* Broadcaster - Very faint blue badge */
.role-badge.broadcaster {
    background: rgba(59, 130, 246, 0.08);
    color: #2563EB;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

/* Viewer - Very faint gray badge */
.role-badge.viewer {
    background: rgba(107, 114, 128, 0.08);
    color: #6B7280;
    border: 1px solid rgba(107, 114, 128, 0.2);
}

/* Dark theme role badges - slightly more visible */
[data-theme="dark"] .role-badge.super_admin {
    background: rgba(139, 92, 246, 0.12);
    color: #C4B5FD;
    border: 1px solid rgba(139, 92, 246, 0.25);
}

[data-theme="dark"] .role-badge.admin {
    background: rgba(139, 92, 246, 0.12);
    color: #C4B5FD;
    border: 1px solid rgba(139, 92, 246, 0.25);
}

[data-theme="dark"] .role-badge.broadcaster {
    background: rgba(59, 130, 246, 0.12);
    color: #93C5FD;
    border: 1px solid rgba(59, 130, 246, 0.25);
}

[data-theme="dark"] .role-badge.viewer {
    background: rgba(107, 114, 128, 0.12);
    color: #D1D5DB;
    border: 1px solid rgba(107, 114, 128, 0.25);
}

/* System Admin Avatar - subtle purple gradient */
.user-avatar.system-admin-avatar {
    background: linear-gradient(135deg, rgba(42, 60, 209, 0.7), rgba(139, 92, 246, 0.7));
}

/* Data I/O Display */
.data-io {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 1rem;
    font-family: var(--font-mono);
}

.data-in {
    color: var(--accent-success);
}

.data-out {
    color: var(--accent-warning);
}

/* ============================================
   SECTION TOOLBAR
   ============================================ */
.section-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding: 20px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
}

.section-toolbar h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.toolbar-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* ============================================
   FORMS - Enhanced Inputs
   ============================================ */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="url"],
textarea,
select,
.form-input,
.form-select {
    width: 100%;
    padding: 12px 16px;
    font-size: 1.2rem;
    font-family: var(--font-sans);
    background: var(--bg-input);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

input:hover,
textarea:hover,
select:hover {
    border-color: var(--text-muted);
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
    background: var(--bg-input-focus);
}

input::placeholder,
textarea::placeholder {
    color: var(--text-muted);
}

/* Checkbox - Custom Style */
.form-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--accent-primary);
}

/* ============================================
   MONITORING - Gauges & Charts
   ============================================ */
.monitoring-dashboard {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.monitoring-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.monitoring-widget {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow-card);
    transition: all var(--transition-normal);
}

.monitoring-widget:hover {
    box-shadow: var(--shadow-md);
}

/* 2025-12-05: Updated font-size to 1rem and color to #444f60 */
.monitoring-widget h4 {
    font-size: 1rem;
    font-weight: 700;
    color: #444f60;
    margin: 0;
    text-transform: uppercase;
    white-space: nowrap;
    letter-spacing: 0.05em;
}

.gauge-container {
    display: flex;
    justify-content: center;
    align-items: center;
}

.gauge-chart {
    transform: rotate(-90deg);
}

/* 2025-12-04: Counter-rotate text to keep it horizontal when parent SVG is rotated */
.gauge-text {
    font-size: 1.1rem;
    font-weight: 700;
    fill: var(--text-primary);
    font-family: var(--font-display);
    transform: rotate(90deg);
    transform-origin: center center;
}

.gauge-fill {
    transition: stroke-dashoffset 0.5s ease-out;
}

/* Network Stats */
.network-stats {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.network-stat-item {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

.network-icon {
    font-size: 1.25rem;
}

.network-value {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
}

.network-label {
    font-size: 1rem;
    color: var(--text-muted);
    text-transform: uppercase;
    font-weight: 600;
}

.network-number {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    font-family: var(--font-mono);
}

/* Pie Chart */
.pie-chart-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 16px;
}

.pie-chart-legend {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 1rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 3px;
}

.legend-text {
    color: var(--text-secondary);
}

/* Charts Section */
.charts-section {
    margin-top: 20px;
}

.charts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
}

.chart-container {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-card);
}

/* 2025-12-04: Fixed height wrapper for Chart.js canvases to prevent infinite growth */
.chart-container canvas {
    max-height: 250px !important;
    height: 250px !important;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.chart-header h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.chart-controls select {
    padding: 6px 12px;
    font-size: 1rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* ============================================
   LOGS - Terminal Style
   ============================================ */
.logs-container {
    background: #0f172a;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-card);
}

.logs-viewer {
    background: #0f172a;
    color: #e2e8f0;
    padding: 20px;
    font-family: var(--font-mono);
    font-size: 1rem;
    line-height: 1.7;
    max-height: 500px;
    overflow-y: auto;
}

.log-entry {
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    margin-bottom: 4px;
}

.log-entry.error {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
}

.log-entry.warn {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
}

.log-entry.info {
    background: rgba(59, 130, 246, 0.1);
    color: #93c5fd;
}

.log-loading {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
}

/* ============================================
   SECURITY SECTION
   ============================================ */

/* 2025-12-05: Security Tabs for General/Firewall/WAF Config */
/* Purpose: Tab navigation for restructured Security page */
.security-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
    background: var(--bg-secondary);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding: 0 8px;
}

.security-tab {
    padding: 14px 28px;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 8px;
}

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

.security-tab:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.security-tab.active {
    color: var(--accent-primary);
    border-bottom-color: var(--accent-primary);
    background: var(--bg-card);
}

.security-panel {
    display: none;
    animation: fadeIn 0.2s ease-in-out;
}

.security-panel.active {
    display: block;
}

/* Security Overview Stats */
.security-overview-stats {
    margin-top: 24px;
}

.overview-stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-card);
}

.overview-stat-card .stat-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.overview-stat-card .stat-header .stat-icon {
    font-size: 1.5rem;
}

.overview-stat-card .stat-header h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.overview-stat-card .stat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.overview-stat-card .stat-item {
    text-align: center;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}

.overview-stat-card .stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.overview-stat-card .stat-value {
    display: block;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    font-family: var(--font-display);
}

/* CSF Inline Section - Firewall Tab */
.csf-inline-section {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-card);
}

.csf-rules-section,
.csf-logs-section,
.csf-config-section {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-card);
}

.csf-rules-section .csf-rules-list,
.csf-logs-section .csf-logs-content,
.csf-config-section .csf-config-content {
    max-height: 300px;
    overflow-y: auto;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 12px;
    font-family: var(--font-mono);
    font-size: 0.85rem;
}

/* WAF Logs Viewer */
.waf-logs-viewer {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 12px;
    max-height: 500px;
    overflow-y: auto;
}

.waf-logs-viewer .log-entry {
    padding: 10px 12px;
    border-bottom: 1px solid var(--border-light);
    font-family: var(--font-mono);
    font-size: 1rem;
}

.waf-logs-viewer .log-entry:last-child {
    border-bottom: none;
}

.waf-logs-viewer .log-entry.blocked {
    background: rgba(239, 68, 68, 0.1);
    border-left: 3px solid var(--status-error);
}

.waf-logs-viewer .log-entry.warning {
    background: rgba(245, 158, 11, 0.1);
    border-left: 3px solid var(--status-warning);
}

.waf-logs-viewer .log-entry .log-time {
    color: var(--text-muted);
    margin-right: 12px;
}

.waf-logs-viewer .log-entry .log-ip {
    color: var(--accent-primary);
    font-weight: 500;
}

.waf-logs-viewer .log-entry .log-rule {
    color: var(--accent-secondary);
}

.waf-logs-viewer .log-entry .log-message {
    color: var(--text-secondary);
}

/* Responsive for security tabs */
@media (max-width: 768px) {
    .security-tabs {
        flex-wrap: wrap;
    }

    .security-tab {
        flex: 1 1 auto;
        justify-content: center;
        padding: 12px 16px;
        font-size: 0.85rem;
    }

    .overview-stat-card .stat-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.security-dashboard {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.security-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.security-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    cursor: pointer;
    transition: all var(--transition-normal);
    box-shadow: var(--shadow-card);
}

.security-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.security-icon {
    font-size: 2rem;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
}

.security-content h4 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.security-status {
    font-size: 0.85rem;
    font-weight: 600;
}

.security-status.active {
    color: var(--accent-success);
}

.security-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    font-family: var(--font-display);
}

.security-logs {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-card);
}

.security-logs h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.security-events {
    max-height: 300px;
    overflow-y: auto;
}

.event-item {
    display: flex;
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-light);
}

.event-item:last-child {
    border-bottom: none;
}

.event-time {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-muted);
    font-family: var(--font-mono);
    min-width: 55px;
}

.event-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* ============================================
   SETTINGS - Grid Layout
   ============================================ */
.settings-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 24px;
}

.settings-group {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-card);
}

.settings-group-header {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-light);
}

.setting-item:last-child {
    border-bottom: none;
}

.setting-item label {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin: 0;
}

.setting-item input[type="text"],
.setting-item input[type="number"],
.setting-item select {
    width: 180px;
    padding: 10px 14px;
}

.settings-actions {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-card);
}

.settings-actions-group {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.settings-actions-group h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.settings-actions .header-actions {
    gap: 12px;
}

/* ============================================
   SERVICE CONFIGURATION - Settings Page
   Added: 2025-11-26
   ============================================ */
.settings-section-full {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-card);
    margin-top: 24px;
}

.settings-description {
    color: var(--text-secondary);
    font-size: 1.2rem;
    margin-bottom: 20px;
    line-height: 1.5;
}

.service-config-container {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.service-config-header {
    display: grid;
    grid-template-columns: 2fr 2fr 1.5fr 0.8fr 1fr;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.service-config-list {
    max-height: 400px;
    overflow-y: auto;
}

.service-config-row {
    display: grid;
    grid-template-columns: 2fr 2fr 1.5fr 0.8fr 1fr;
    gap: 12px;
    padding: 12px 16px;
    align-items: center;
    border-bottom: 1px solid var(--border-light);
    transition: background var(--transition-fast);
}

.service-config-row:hover {
    background: var(--bg-hover);
}

.service-config-row:last-child {
    border-bottom: none;
}

.service-config-row input[type="text"] {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    background: var(--bg-input);
    color: var(--text-primary);
    transition: border-color var(--transition-fast);
}

.service-config-row input[type="text"]:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.service-config-row input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--accent-primary);
}

.service-config-row .config-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.service-config-row .config-actions button {
    padding: 6px 10px;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 1rem;
    transition: all var(--transition-fast);
}

.service-config-row .btn-remove {
    background: var(--status-error-light);
    color: var(--status-error);
}

.service-config-row .btn-remove:hover {
    background: var(--status-error);
    color: white;
}

.service-config-actions {
    display: flex;
    gap: 12px;
    padding: 16px;
    background: var(--bg-tertiary);
    border-top: 1px solid var(--border-color);
}

.config-col, .config-col-actions {
    display: flex;
    align-items: center;
}

.config-col-actions {
    justify-content: flex-end;
}

/* Dark theme support */
.dark-theme .service-config-container {
    border-color: var(--border-color);
}

.dark-theme .service-config-header {
    background: var(--bg-secondary);
}

.dark-theme .service-config-row input[type="text"] {
    background: var(--bg-input);
    border-color: var(--border-color);
    color: var(--text-primary);
}

/* ============================================
   DOCUMENTATION
   ============================================ */
.documentation-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.doc-header {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-card);
}

.doc-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
    font-family: var(--font-display);
}

.doc-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.doc-tabs {
    display: flex;
    gap: 8px;
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 8px;
    box-shadow: var(--shadow-card);
}

.doc-tab {
    flex: 1;
    padding: 12px 20px;
    background: transparent;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.doc-tab:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.doc-tab.active {
    background: var(--accent-primary);
    color: white;
}

.doc-content {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
}

.doc-panel {
    display: none;
    padding: 28px;
}

.doc-panel.active {
    display: block;
}

.doc-panel h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 20px;
    font-family: var(--font-display);
}

.doc-section {
    margin-bottom: 28px;
}

.doc-section h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.doc-section p,
.doc-section li {
    color: var(--text-secondary);
    line-height: 1.7;
}

.doc-section ul,
.doc-section ol {
    padding-left: 24px;
    margin-top: 8px;
}

.doc-section li {
    margin-bottom: 8px;
}

/* API Documentation */
.api-section {
    margin-bottom: 32px;
}

.api-section h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--border-color);
}

.api-endpoint {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 16px;
}

.api-method {
    display: inline-block;
    padding: 4px 10px;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    background: var(--accent-primary);
    color: white;
    margin-right: 12px;
}

.api-path {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
}

.api-description {
    color: var(--text-secondary);
    margin: 12px 0;
    font-size: 1.2rem;
}

.api-example {
    margin-top: 12px;
}

.api-example strong {
    display: block;
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.api-example pre {
    background: #0f172a;
    border-radius: var(--radius-md);
    padding: 16px;
    overflow-x: auto;
}

.api-example code {
    font-family: var(--font-mono);
    font-size: 1rem;
    color: #e2e8f0;
}

/* Troubleshooting */
.trouble-item {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 16px;
}

.trouble-item h5 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.trouble-item p {
    margin-bottom: 8px;
}

/* Documentation Tables - Added 2025-12-05 */
.doc-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 1rem;
}

.doc-table th,
.doc-table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-card);
}

.doc-table th {
    background: var(--bg-tertiary);
    font-weight: 600;
    color: var(--text-primary);
}

.doc-table tr:hover {
    background: var(--bg-hover);
}

.doc-table td {
    color: var(--text-secondary);
}

/* API Method Colors */
.api-method.get {
    background: #10b981;
}

.api-method.post {
    background: #3b82f6;
}

.api-method.put {
    background: #f59e0b;
}

.api-method.delete {
    background: #ef4444;
}

/* ============================================
   DOCUMENTATION MANUAL LAYOUT - Added 2025-12-05
   Purpose: Styles for the comprehensive Operations Manual
   ============================================ */

/* Main Manual Container */
.documentation-manual {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    overflow: hidden;
}

/* Manual Header */
.manual-header {
    background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
    padding: 40px;
    text-align: center;
    border-bottom: 2px solid var(--accent-primary);
}

.manual-header h1 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 8px;
    font-family: var(--font-display);
}

.manual-header h2 {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--accent-primary);
    margin-bottom: 16px;
}

.manual-version {
    font-size: 1rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

/* Two Column Layout */
.manual-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    min-height: 600px;
}

/* Table of Contents Sidebar */
.manual-toc {
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-card);
    padding: 24px;
    position: sticky;
    top: 0;
    max-height: calc(100vh - 200px);
    overflow-y: auto;
}

.manual-toc h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--accent-primary);
}

.toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.toc-section {
    margin-bottom: 12px;
}

.toc-section > a {
    display: block;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 1rem;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    transition: var(--transition-fast);
}

.toc-section > a:hover {
    background: var(--bg-hover);
    color: var(--accent-primary);
}

.toc-section ul {
    list-style: none;
    padding-left: 16px;
    margin-top: 8px;
}

.toc-section ul li {
    margin-bottom: 4px;
}

.toc-section ul li a {
    display: block;
    color: var(--text-secondary);
    font-size: 0.9rem;
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    transition: var(--transition-fast);
    border-left: 2px solid transparent;
}

.toc-section ul li a:hover {
    color: var(--accent-primary);
    background: var(--bg-hover);
    border-left-color: var(--accent-primary);
}

/* Manual Content Area */
.manual-content {
    padding: 32px 40px;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
}

/* Manual Section */
.manual-section {
    margin-bottom: 48px;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--border-light);
}

.manual-section:last-of-type {
    border-bottom: none;
}

.manual-section > h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 3px solid var(--accent-primary);
    font-family: var(--font-display);
}

/* Manual Subsection */
.manual-subsection {
    margin-bottom: 32px;
}

.manual-subsection h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
    margin-top: 24px;
}

.manual-subsection h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--accent-primary);
    margin-bottom: 12px;
    margin-top: 20px;
}

.manual-subsection h5 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 8px;
    margin-top: 16px;
}

.manual-subsection p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 16px;
}

.manual-subsection ul,
.manual-subsection ol {
    color: var(--text-secondary);
    margin-bottom: 16px;
    padding-left: 24px;
}

.manual-subsection li {
    margin-bottom: 8px;
    line-height: 1.6;
}

.manual-subsection li strong {
    color: var(--text-primary);
}

/* Code blocks in manual */
.manual-subsection pre {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin: 16px 0;
    overflow-x: auto;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    line-height: 1.5;
}

.manual-subsection pre code {
    color: var(--text-secondary);
    background: none;
    padding: 0;
}

.manual-subsection code {
    background: var(--bg-tertiary);
    color: var(--accent-primary);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.9em;
}

/* API Documentation Block */
.api-doc-block {
    background: var(--bg-secondary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin: 20px 0;
}

.api-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.api-method {
    display: inline-block;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 700;
    color: white;
    text-transform: uppercase;
    font-family: var(--font-mono);
}

.api-endpoint {
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--text-primary);
    font-weight: 600;
}

.api-desc {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

/* Troubleshooting Block */
.trouble-block {
    background: var(--bg-secondary);
    border: 1px solid var(--border-card);
    border-left: 4px solid var(--status-warning);
    border-radius: var(--radius-md);
    padding: 20px;
    margin: 16px 0;
}

.trouble-block h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
    margin-top: 0;
}

.trouble-block p {
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.trouble-block p strong {
    color: var(--text-primary);
}

/* Manual Footer */
.manual-footer {
    background: var(--bg-tertiary);
    padding: 24px 40px;
    text-align: center;
    border-top: 1px solid var(--border-card);
}

.manual-footer p {
    color: var(--text-muted);
    margin: 4px 0;
    font-size: 0.95rem;
}

.manual-footer .manual-version {
    color: var(--text-secondary);
    font-weight: 600;
}

/* Responsive Manual Layout */
@media (max-width: 1024px) {
    .manual-layout {
        grid-template-columns: 1fr;
    }

    .manual-toc {
        position: relative;
        max-height: none;
        border-right: none;
        border-bottom: 1px solid var(--border-card);
    }

    .manual-content {
        max-height: none;
    }
}

@media (max-width: 768px) {
    .manual-header {
        padding: 24px;
    }

    .manual-header h1 {
        font-size: 1.5rem;
    }

    .manual-header h2 {
        font-size: 1.1rem;
    }

    .manual-content {
        padding: 20px;
    }

    .manual-section > h2 {
        font-size: 1.3rem;
    }

    .manual-subsection h3 {
        font-size: 1.1rem;
    }

    .api-doc-block {
        padding: 16px;
    }

    .api-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

/* ============================================
   CUSTOMIZE UI SECTION
   ============================================ */
.customize-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.customize-header {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-card);
}

.customize-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.customize-header p {
    color: var(--text-secondary);
}

.customize-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 24px;
}

.customize-group {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-card);
}

.customize-group-header {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border-color);
}

.customize-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-light);
}

.customize-item:last-child {
    border-bottom: none;
}

.customize-item label {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.customize-range {
    width: 120px;
    cursor: pointer;
}

.customize-color {
    width: 50px;
    height: 36px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
}

.customize-select {
    width: 180px;
    padding: 8px 12px;
}

.range-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-muted);
    min-width: 40px;
    text-align: right;
    font-family: var(--font-mono);
}

.preview-area {
    display: flex;
    gap: 12px;
    padding-top: 16px;
    flex-wrap: wrap;
}

.customize-actions {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-card);
}

.customize-actions-group {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.customize-actions-group h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

/* ============================================
   NOTIFICATIONS - Centered Slide-Down Style (Updated 2025-11-26)
   Slides from browser top edge with 5px gap, centered in content area (right of sidebar)
   ============================================ */
.notification-container {
    position: fixed;
    top: 5px;
    left: calc(var(--sidebar-width, 260px) + ((100vw - var(--sidebar-width, 260px)) / 2));
    transform: translateX(-50%);
    width: 75%;
    max-width: 600px;
    min-width: 400px;
    z-index: 99999;
    pointer-events: none;
}

.notification {
    position: relative;
    pointer-events: auto;
    border-radius: 6px;
    padding: 14px 16px;
    padding-right: 40px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    animation: slideDown 0.3s ease-out;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 400;
    border-width: 1px;
    border-style: solid;
}

/* Slide down from top animation */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* AWS-style layered stacking effect - older notifications peek from bottom */
.notification-container .notification:nth-last-child(1) {
    z-index: 10;
    transform: translateY(0) scale(1);
    opacity: 1;
}

.notification-container .notification:nth-last-child(2) {
    z-index: 9;
    transform: translateY(8px) scale(0.98);
    opacity: 1;
}

.notification-container .notification:nth-last-child(3) {
    z-index: 8;
    transform: translateY(16px) scale(0.96);
    opacity: 0.95;
}

.notification-container .notification:nth-last-child(n+4) {
    z-index: 7;
    transform: translateY(22px) scale(0.94);
    opacity: 0;
    pointer-events: none;
}

/* Success notification - Light teal/green */
.notification.success {
    background: #d1f2eb;
    color: #0c5e4f;
    border-color: #b8e6d9;
}

/* Error notification - Light red/pink */
.notification.error {
    background: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

/* Warning notification - Light yellow/amber */
.notification.warning {
    background: #fff3cd;
    color: #856404;
    border-color: #ffeeba;
}

/* Info notification - Light blue/cyan */
.notification.info {
    background: #d1ecf1;
    color: #0c5460;
    border-color: #bee5eb;
}

/* Dark theme - slightly darker backgrounds */
[data-theme="dark"] .notification.success {
    background: #1a3d34;
    color: #7dd3c0;
    border-color: #2d5a4d;
}

[data-theme="dark"] .notification.error {
    background: #3d1a1e;
    color: #f5a3ab;
    border-color: #5a2d32;
}

[data-theme="dark"] .notification.warning {
    background: #3d3419;
    color: #f5d67a;
    border-color: #5a4d2d;
}

[data-theme="dark"] .notification.info {
    background: #1a333d;
    color: #7dc3d3;
    border-color: #2d4d5a;
}

.notification-message {
    font-size: 14px;
    font-weight: 500;
    flex: 1;
    text-align: center;
}

.notification-close {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    opacity: 0.6;
}

.notification.success .notification-close { color: #0c5e4f; }
.notification.error .notification-close { color: #721c24; }
.notification.warning .notification-close { color: #856404; }
.notification.info .notification-close { color: #0c5460; }

[data-theme="dark"] .notification.success .notification-close { color: #7dd3c0; }
[data-theme="dark"] .notification.error .notification-close { color: #f5a3ab; }
[data-theme="dark"] .notification.warning .notification-close { color: #f5d67a; }
[data-theme="dark"] .notification.info .notification-close { color: #7dc3d3; }

.notification-close:hover {
    opacity: 1;
}

/* ============================================
   MODALS - Modern Design
   ============================================ */
.modal-overlay,
.confirmation-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.modal,
.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-xl);
    padding: 28px;
    max-width: 480px;
    width: 100%;
    box-shadow: var(--shadow-xl);
    animation: modalIn 0.2s ease;
}

@keyframes modalIn {
    from { transform: scale(0.95); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-header h2,
.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    font-family: var(--font-display);
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-muted);
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.close-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.modal-body p {
    color: var(--text-secondary);
    line-height: 1.6;
}

.modal-footer,
.modal-actions,
.modal-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

/* CSF Modal */
.csf-modal-content {
    max-width: 700px;
}

.csf-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.csf-tab {
    flex: 1;
    padding: 10px 16px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.csf-tab:hover {
    background: var(--bg-hover);
}

.csf-tab.active {
    background: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

.csf-panel {
    display: none;
}

.csf-panel.active {
    display: block;
}

.csf-status-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 20px;
}

.csf-status-item {
    background: var(--bg-secondary);
    padding: 16px;
    border-radius: var(--radius-md);
    text-align: center;
}

.csf-label {
    display: block;
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.csf-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.csf-actions {
    display: flex;
    gap: 12px;
}

.csf-rule-actions {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.csf-rule-actions input {
    flex: 1;
}

.csf-rules-list,
.csf-logs-content,
.csf-config-content {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 16px;
    max-height: 300px;
    overflow-y: auto;
    font-family: var(--font-mono);
    font-size: 0.85rem;
}

/* ============================================
   LOGIN SCREEN - Modern Design
   ============================================ */
.auth-loading-screen {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.auth-loading-screen.hidden {
    display: none;
}

.auth-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid rgba(255,255,255,0.1);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.auth-loading-text {
    color: #e2e8f0;
    margin-top: 20px;
    font-size: 1.1rem;
    font-weight: 500;
}

.login-screen {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9998;
}

.login-screen.hidden {
    display: none;
}

.login-container {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    padding: 48px;
    width: 100%;
    max-width: 420px;
    backdrop-filter: blur(20px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.login-header {
    text-align: center;
    margin-bottom: 36px;
}

.login-logo-img {
    width: 100px;
    height: auto;
    margin: 0 auto 20px;
    display: block;
    filter: brightness(1.1);
}

.login-header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 8px;
    font-family: var(--font-display);
}

.login-header p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.2rem;
    margin: 0;
}

.login-form .form-group {
    margin-bottom: 20px;
}

.login-form label {
    display: block;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 8px;
    font-size: 0.85rem;
    font-weight: 600;
}

.login-form input {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
    font-size: 1.1rem;
    transition: all var(--transition-fast);
}

.login-form input:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2);
}

.login-form input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.login-btn {
    width: 100%;
    padding: 14px 20px;
    background: var(--accent-primary);
    border: none;
    border-radius: var(--radius-md);
    color: white;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.login-btn:hover:not(:disabled) {
    background: var(--accent-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -5px rgba(59, 130, 246, 0.4);
}

.login-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.login-btn .btn-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.login-btn .btn-spinner.hidden {
    display: none;
}

.login-error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
    padding: 14px 16px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
    font-size: 1.2rem;
    text-align: center;
    font-weight: 500;
}

.login-error.hidden {
    display: none;
}

.login-footer {
    text-align: center;
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.login-footer a {
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.2rem;
    font-weight: 500;
    transition: color var(--transition-fast);
}

.login-footer a:hover {
    color: var(--accent-primary);
}

/* ============================================
   SCROLLBAR STYLES
   ============================================ */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
    border: 2px solid transparent;
    background-clip: padding-box;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 1200px) {
    .dashboard-widgets {
        grid-template-columns: 1fr;
    }

    .charts-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }
}

@media (max-width: 768px) {
    :root {
        --content-padding: 16px;
    }

    .content-header {
        padding: 16px;
        height: auto;
        flex-wrap: wrap;
        gap: 16px;
    }

    .header-actions {
        width: 100%;
        justify-content: flex-end;
        flex-wrap: wrap;
    }

    .metrics-grid {
        grid-template-columns: 1fr 1fr;
    }

    .settings-grid,
    .customize-grid {
        grid-template-columns: 1fr;
    }

    .table-header,
    .table-row {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .table-header .table-cell:nth-child(n+3),
    .table-row .table-cell:nth-child(n+3) {
        display: none;
    }
}

@media (max-width: 480px) {
    .metrics-grid {
        grid-template-columns: 1fr;
    }

    .login-container {
        padding: 28px;
        margin: 16px;
    }

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

    .csf-status-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */
.hidden {
    display: none !important;
}

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

.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--accent-success); }
.text-danger { color: var(--accent-danger); }
.text-warning { color: var(--accent-warning); }

.bg-primary { background: var(--bg-primary); }
.bg-secondary { background: var(--bg-secondary); }
.bg-tertiary { background: var(--bg-tertiary); }

.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 16px; }
.mt-4 { margin-top: 24px; }
.mt-5 { margin-top: 32px; }

.mb-1 { margin-bottom: 4px; }
.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 16px; }
.mb-4 { margin-bottom: 24px; }
.mb-5 { margin-bottom: 32px; }

.p-1 { padding: 4px; }
.p-2 { padding: 8px; }
.p-3 { padding: 16px; }
.p-4 { padding: 24px; }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 4px; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 16px; }
.gap-4 { gap: 24px; }

.w-full { width: 100%; }
.h-full { height: 100%; }

.rounded { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-full { border-radius: var(--radius-full); }

.shadow { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }

.transition { transition: all var(--transition-normal); }

/* Animation Classes */
.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.animate-spin {
    animation: spin 1s linear infinite;
}

.animate-bounce {
    animation: bounce 1s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(-5%); animation-timing-function: cubic-bezier(0.8, 0, 1, 1); }
    50% { transform: translateY(0); animation-timing-function: cubic-bezier(0, 0, 0.2, 1); }
}

/* ============================================
   NAVIGATION SECTION HEADERS
   Added: 2025-11-25 - Sidebar section dividers
   ============================================ */
.nav-section-header {
    padding: 20px 20px 8px;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-top: 8px;
    border-top: 1px solid var(--border-color);
}

.nav-section-header:first-of-type {
    border-top: none;
    margin-top: 0;
}

[data-theme="dark"] .nav-section-header {
    color: #64748b;
    border-top-color: #334155;
}

/* ============================================
   ORGANIZATIONS SECTION
   Added: 2025-11-25
   ============================================ */
.org-stats-grid,
.user-stats-grid,
.subscription-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 28px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--shadow-card);
    transition: var(--transition-normal);
    border: 1px solid var(--border-card);
}

.stat-card:hover {
    box-shadow: var(--shadow-card-hover);
    transform: translateY(-2px);
}

.stat-card.highlight {
    background: var(--brand-gradient);
    border: none;
}

.stat-card.highlight .stat-value,
.stat-card.highlight .stat-label,
.stat-card.highlight .stat-change {
    color: #ffffff;
}

.stat-icon {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background: var(--bg-tertiary);
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.stat-label {
    font-size: 1rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.stat-change {
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 6px;
}

.stat-change.positive {
    color: var(--accent-success);
}

.stat-change.negative {
    color: var(--accent-danger);
}

/* Organization Info in Table */
.org-info,
.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.org-avatar,
.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: var(--brand-gradient);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.org-details,
.user-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.org-name,
.user-name {
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.org-domain,
.user-email {
    font-size: 1.1rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Plan Badges */
.plan-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.plan-badge.starter {
    background: #e0f2fe;
    color: #0369a1;
}

.plan-badge.professional {
    background: #fef3c7;
    color: #b45309;
}

.plan-badge.enterprise {
    background: #ede9fe;
    color: #7c3aed;
}

.plan-badge.custom {
    background: #fce7f3;
    color: #be185d;
}

[data-theme="dark"] .plan-badge.starter {
    background: rgba(14, 165, 233, 0.2);
    color: #38bdf8;
}

[data-theme="dark"] .plan-badge.professional {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
}

[data-theme="dark"] .plan-badge.enterprise {
    background: rgba(139, 92, 246, 0.2);
    color: #a78bfa;
}

[data-theme="dark"] .plan-badge.custom {
    background: rgba(236, 72, 153, 0.2);
    color: #f472b6;
}

/* ============================================
   GROUPS SECTION
   Added: 2025-11-25
   ============================================ */
.groups-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.group-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-card);
    transition: var(--transition-normal);
}

.group-card:hover {
    box-shadow: var(--shadow-card-hover);
    transform: translateY(-2px);
}

.group-card.add-new {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 220px;
    border: 2px dashed var(--border-color);
    background: transparent;
    cursor: pointer;
    color: var(--text-muted);
}

.group-card.add-new:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
    background: var(--accent-primary-light);
}

.group-card.add-new .add-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-full);
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 12px;
}

.group-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
}

.group-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.group-info {
    flex: 1;
    min-width: 0;
}

.group-info h4 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.group-org {
    font-size: 1.1rem;
    color: var(--text-muted);
}

.group-actions {
    display: flex;
    gap: 4px;
}

.btn-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.btn-icon:hover {
    background: var(--bg-hover);
}

.group-stats {
    display: flex;
    gap: 24px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-light);
    margin-bottom: 12px;
}

.group-stat {
    display: flex;
    flex-direction: column;
}

.group-stat .stat-number {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-primary);
}

.group-stat .stat-label {
    font-size: 1rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.group-permissions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
}

.permission-badge {
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 500;
    background: var(--accent-primary-light);
    color: var(--accent-primary);
}

.permission-badge.admin {
    background: var(--accent-purple-light);
    color: var(--accent-purple);
}

.group-members {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.member-avatars {
    display: flex;
}

.member-avatar {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    background: var(--brand-gradient);
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: -8px;
    border: 2px solid var(--bg-card);
}

.member-avatar:first-child {
    margin-left: 0;
}

.member-avatar.more {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}

.btn-text {
    background: none;
    border: none;
    color: var(--accent-primary);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0;
    transition: var(--transition-fast);
}

.btn-text:hover {
    color: var(--accent-primary-hover);
    text-decoration: underline;
}

/* ============================================
   ROLES & PERMISSIONS SECTION
   Added: 2025-11-25
   ============================================ */
.roles-container {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.roles-category {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    border: 1px solid var(--border-card);
}

.category-header {
    margin: 0 0 20px 0;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.roles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.role-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 20px;
    border: 1px solid var(--border-light);
    transition: var(--transition-normal);
}

.role-card:hover {
    border-color: var(--accent-primary);
    box-shadow: var(--shadow-md);
}

.role-card.system-role {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
    border-color: rgba(59, 130, 246, 0.2);
}

.role-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.role-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    background: var(--bg-tertiary);
}

.role-icon.super-admin {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
}

.role-icon.org-admin {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
}

.role-icon.broadcaster {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
}

.role-icon.viewer {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.role-icon.moderator {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

.role-info {
    flex: 1;
}

.role-info h5 {
    margin: 0;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-primary);
}

.role-type {
    font-size: 1rem;
    color: var(--text-muted);
}

.role-users {
    font-size: 1.1rem;
    color: var(--text-muted);
    padding: 4px 8px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
}

.role-description {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 16px;
}

.permissions-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.permission-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
}

.permission-item.granted {
    color: var(--accent-success);
}

.permission-item.denied {
    color: var(--text-muted);
}

.permission-icon {
    width: 18px;
    height: 18px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 700;
}

.permission-item.granted .permission-icon {
    background: var(--accent-success-light);
    color: var(--accent-success);
}

.permission-item.denied .permission-icon {
    background: var(--bg-tertiary);
    color: var(--text-muted);
}

/* ============================================
   SUBSCRIPTIONS SECTION
   Added: 2025-11-25
   ============================================ */
.pricing-plans-container {
    margin-bottom: 32px;
}

.subsection-header {
    margin: 0 0 20px 0;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.pricing-plans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
}

.pricing-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-card);
    overflow: hidden;
    transition: var(--transition-normal);
    position: relative;
}

.pricing-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.pricing-card.popular {
    border-color: var(--accent-primary);
    box-shadow: var(--shadow-lg);
}

.popular-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--accent-primary);
    color: #ffffff;
    padding: 4px 12px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 0 0 0 var(--radius-md);
}

.plan-header {
    padding: 24px;
    text-align: center;
}

.plan-header.starter {
    background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
}

.plan-header.professional {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
}

.plan-header.enterprise {
    background: linear-gradient(135deg, #ede9fe 0%, #ddd6fe 100%);
}

.plan-header.custom {
    background: linear-gradient(135deg, #fce7f3 0%, #fbcfe8 100%);
}

.plan-header h4 {
    margin: 0 0 12px 0;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-primary);
}

.plan-price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 2px;
}

.plan-price .currency {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.plan-price .amount {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
}

.plan-price .period {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.plan-price.custom-text span {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.plan-features {
    padding: 24px;
}

.plan-features ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.plan-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.plan-features li.disabled {
    color: var(--text-muted);
}

.plan-features .check {
    color: var(--accent-success);
    font-weight: 600;
}

.plan-features .cross {
    color: var(--text-muted);
}

.plan-stats {
    padding: 0 24px 16px;
    border-top: 1px solid var(--border-light);
    padding-top: 16px;
}

.plan-stats .subscribers {
    font-size: 1rem;
    color: var(--text-muted);
}

.plan-actions {
    padding: 0 24px 24px;
    display: flex;
    gap: 8px;
}

/* ============================================
   BILLING SECTION
   Added: 2025-11-25
   ============================================ */
.billing-overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 28px;
}

.billing-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-card);
}

.billing-card.revenue {
    border-left: 4px solid var(--accent-success);
}

.billing-card.pending {
    border-left: 4px solid var(--accent-warning);
}

.billing-card.overdue {
    border-left: 4px solid var(--accent-danger);
}

.billing-card.collected {
    border-left: 4px solid var(--accent-primary);
}

.billing-icon {
    font-size: 1.75rem;
}

.billing-content {
    flex: 1;
}

.billing-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.billing-label {
    font-size: 1rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.billing-subtext {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-top: 8px;
}

.billing-chart {
    margin-top: 12px;
}

/* Billing Tabs */
.billing-tabs {
    display: flex;
    gap: 4px;
    background: var(--bg-tertiary);
    padding: 4px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
}

.billing-tab {
    flex: 1;
    padding: 10px 16px;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition-fast);
}

.billing-tab:hover {
    color: var(--text-primary);
}

.billing-tab.active {
    background: var(--bg-card);
    color: var(--text-primary);
    box-shadow: var(--shadow-sm);
}

.billing-panel {
    display: none;
}

.billing-panel.active {
    display: block;
}

/* Invoice Number */
.invoice-number,
.transaction-id {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 500;
    color: var(--accent-primary);
}

/* Payment Method */
.payment-method {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 1rem;
}

/* Payment Methods Grid */
.payment-methods-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

.payment-method-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 20px;
    border: 1px solid var(--border-card);
}

.pm-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.pm-type {
    font-weight: 600;
    color: var(--text-primary);
}

.pm-status {
    padding: 4px 8px;
    border-radius: var(--radius-full);
    font-size: 1rem;
    font-weight: 600;
}

.pm-status.enabled {
    background: var(--accent-success-light);
    color: var(--accent-success);
}

.pm-status.disabled {
    background: var(--bg-tertiary);
    color: var(--text-muted);
}

.pm-providers {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.provider-logo {
    font-size: 1rem;
    color: var(--text-secondary);
}

.pm-actions {
    margin-top: auto;
}

/* Payment Gateway Config */
.payment-gateway-config {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    border: 1px solid var(--border-card);
}

.payment-gateway-config h4 {
    margin: 0 0 20px 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.gateway-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    align-items: end;
}

/* Billing Settings */
.billing-settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 24px;
}

.settings-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    border: 1px solid var(--border-card);
}

.settings-card h4 {
    margin: 0 0 20px 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-light);
}

.checkbox-group {
    margin-bottom: 12px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--accent-primary);
}

.settings-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* Form Elements */
.form-textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 0.875rem;
    font-family: var(--font-sans);
    resize: vertical;
    min-height: 80px;
    transition: var(--transition-fast);
}

.form-textarea:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--accent-primary-light);
}

/* Filter Select Styles */
.filter-select {
    padding: 8px 32px 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 0.875rem;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23475569' 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 10px center;
}

.filter-select:focus {
    outline: none;
    border-color: var(--border-focus);
}

/* Search Input */
.search-input {
    padding: 8px 14px 8px 36px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 0.875rem;
    min-width: 200px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: 10px center;
}

.search-input:focus {
    outline: none;
    border-color: var(--border-focus);
}

/* Toolbar Actions */
.toolbar-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

/* Button Small Success */
.btn-small.btn-success {
    background: var(--accent-success);
    color: #ffffff;
    border-color: var(--accent-success);
}

.btn-small.btn-success:hover {
    background: #059669;
    border-color: #059669;
}

/* Button Small Warning */
.btn-small.btn-warning {
    background: var(--accent-warning);
    color: #ffffff;
    border-color: var(--accent-warning);
}

.btn-small.btn-warning:hover {
    background: #d97706;
    border-color: #d97706;
}

/* ============================================
   WAF (Web Application Firewall) Styles - Added 2025-11-26
   ============================================ */

.waf-section {
    margin-top: 30px;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    border: 1px solid var(--border-color);
}

.waf-section .section-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.waf-section .section-header-bar h3 {
    margin: 0;
    font-size: 1.25rem;
    color: var(--text-primary);
}

/* WAF Status Grid */
.waf-status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.waf-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--border-color);
}

.waf-card-icon {
    font-size: 2rem;
}

.waf-card-content h4 {
    margin: 0 0 4px 0;
    font-size: 1.1rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.waf-value {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* WAF Panels */
.waf-panels {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 24px;
}

@media (max-width: 900px) {
    .waf-panels {
        grid-template-columns: 1fr;
    }
}

.waf-panel {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 16px;
    border: 1px solid var(--border-color);
}

.waf-panel h4 {
    margin: 0 0 16px 0;
    font-size: 1.2rem;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

/* WAF Rules List */
.waf-rules-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 300px;
    overflow-y: auto;
}

.waf-rule-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.rule-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.rule-icon {
    font-size: 1.2rem;
}

.rule-name {
    font-size: 0.875rem;
    color: var(--text-primary);
}

.rule-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.rule-status {
    font-size: 1.1rem;
    padding: 2px 8px;
    border-radius: 10px;
}

.rule-status.enabled {
    background: rgba(34, 197, 94, 0.1);
    color: var(--accent-success);
}

.rule-status.disabled {
    background: rgba(239, 68, 68, 0.1);
    color: var(--accent-error);
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--border-color);
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--accent-success);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(20px);
}

/* WAF IP Tabs */
.waf-ip-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 16px;
    border-bottom: 2px solid var(--border-color);
}

.waf-ip-tab {
    padding: 8px 16px;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 0.875rem;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: var(--transition-fast);
}

.waf-ip-tab:hover {
    color: var(--text-primary);
}

.waf-ip-tab.active {
    color: var(--accent-primary);
    border-bottom-color: var(--accent-primary);
}

.waf-ip-panel {
    display: none;
}

.waf-ip-panel.active {
    display: block;
}

.waf-ip-add {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
}

.waf-ip-add .form-input {
    flex: 1;
    padding: 8px 12px;
    font-size: 0.875rem;
}

.waf-ip-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 200px;
    overflow-y: auto;
}

.ip-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.ip-address {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    color: var(--text-primary);
}

/* WAF Logs Section */
.waf-logs-section {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 16px;
    border: 1px solid var(--border-color);
    margin-bottom: 24px;
}

.waf-logs-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.waf-logs-header h4 {
    margin: 0;
    font-size: 1.2rem;
    color: var(--text-primary);
}

/* Log Tabs - Added 2025-11-26 */
.waf-logs-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 12px;
    border-bottom: 2px solid var(--border-color);
}

.waf-logs-tab {
    padding: 10px 20px;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.2rem;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: var(--transition-fast);
}

.waf-logs-tab:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.waf-logs-tab.active {
    color: var(--accent-primary);
    border-bottom-color: var(--accent-primary);
}

.waf-logs-panel {
    display: none;
}

.waf-logs-panel.active {
    display: block;
}

/* Caddy log item has extra status column */
.caddy-log-item {
    grid-template-columns: 140px 120px 50px 60px 1fr;
}

.log-status {
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
    text-align: center;
}

.log-status.status-success {
    color: var(--accent-success);
    background: rgba(34, 197, 94, 0.1);
}

.log-status.status-redirect {
    color: var(--accent-warning);
    background: rgba(234, 179, 8, 0.1);
}

.log-status.status-client-error {
    color: var(--accent-error);
    background: rgba(239, 68, 68, 0.1);
}

.log-status.status-server-error {
    color: #dc2626;
    background: rgba(220, 38, 38, 0.15);
}

.waf-logs-list {
    max-height: 300px;
    overflow-y: auto;
    font-family: var(--font-mono);
    font-size: 1rem;
}

.waf-log-item {
    display: grid;
    grid-template-columns: 140px 120px 60px 1fr;
    gap: 12px;
    padding: 8px 10px;
    border-bottom: 1px solid var(--border-color);
    align-items: center;
}

.waf-log-item:last-child {
    border-bottom: none;
}

.log-time {
    color: var(--text-secondary);
}

.log-ip {
    color: var(--accent-warning);
}

.log-method {
    color: var(--accent-primary);
    font-weight: 500;
}

.log-uri {
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* WAF Attack Types Card - Compact view in status grid */
.waf-attack-types-card {
    grid-column: span 1;
}

.waf-attack-types-card .waf-card-content {
    flex: 1;
}

.waf-attack-types-compact {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
}

.waf-attack-types-compact .attack-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    font-size: 1rem;
}

.waf-attack-types-compact .attack-tag .attack-name {
    color: var(--text-secondary);
}

.waf-attack-types-compact .attack-tag .attack-count {
    font-weight: 600;
    color: var(--accent-error);
}

.waf-attack-types-compact .no-attacks {
    color: var(--text-muted);
    font-size: 1rem;
}

.loading-sm {
    color: var(--text-muted);
    font-size: 1rem;
}

.no-data {
    color: var(--text-muted);
    font-size: 0.875rem;
    padding: 20px;
    text-align: center;
}

.loading {
    color: var(--text-secondary);
    font-size: 0.875rem;
    padding: 20px;
    text-align: center;
}

/* Button Small Variants - 2025-12-05: Updated to 6px radius */
.btn-sm {
    padding: 6px 12px;
    font-size: 1rem;
    border-radius: var(--radius-btn);
}

.btn-icon {
    padding: 6px 8px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition-fast);
}

.btn-icon:hover {
    color: var(--accent-primary);
}

.btn-icon.btn-danger:hover {
    color: var(--accent-error);
}

/* Refresh button style - Added 2025-12-03 */
.btn-secondary.btn-icon {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 8px 12px;
    font-size: 1.2rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-secondary.btn-icon:hover {
    background: var(--bg-hover);
    color: var(--accent-primary);
}

/* ============================================
   System Logs Section Tabs - Added 2025-11-26
   ============================================ */

.system-logs-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 16px;
    border-bottom: 2px solid var(--border-color);
}

.system-logs-tab {
    padding: 12px 24px;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: var(--transition-fast);
}

.system-logs-tab:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.system-logs-tab.active {
    color: var(--accent-primary);
    border-bottom-color: var(--accent-primary);
}

.system-logs-panel {
    display: none;
}

.system-logs-panel.active {
    display: block;
}

.logs-filter-bar {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 12px;
    padding: 10px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}

/* Caddy Access Log Entry Styles */
.caddy-logs-viewer {
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: 12px;
    max-height: 600px;
    overflow-y: auto;
    font-family: var(--font-mono);
    font-size: 1.2rem;
}

.caddy-access-entry {
    display: grid;
    grid-template-columns: 160px 130px 50px 70px 1fr;
    gap: 12px;
    padding: 8px 12px;
    border-bottom: 1px solid var(--border-color);
    align-items: center;
}

.caddy-access-entry:hover {
    background: var(--bg-hover);
}

.caddy-access-entry:last-child {
    border-bottom: none;
}

.log-timestamp {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.log-ip-addr {
    color: var(--accent-warning);
}

.log-http-status {
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    text-align: center;
    font-size: 0.85rem;
}

.log-http-status.status-success {
    color: var(--accent-success);
    background: rgba(34, 197, 94, 0.15);
}

.log-http-status.status-redirect {
    color: var(--accent-warning);
    background: rgba(234, 179, 8, 0.15);
}

.log-http-status.status-client-error {
    color: var(--accent-error);
    background: rgba(239, 68, 68, 0.15);
}

.log-http-status.status-server-error {
    color: #dc2626;
    background: rgba(220, 38, 38, 0.2);
}

.log-http-method {
    color: var(--accent-primary);
    font-weight: 500;
}

.log-request-uri {
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Stream URLs with copy buttons - Added 2025-12-02 */
.stream-key-cell {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.stream-urls {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 6px;
}

.url-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 1rem;
}

.url-label {
    color: var(--text-secondary);
    font-weight: 500;
    min-width: 50px;
}

.url-value {
    background: rgba(255, 255, 255, 0.05);
    padding: 3px 8px;
    border-radius: 4px;
    font-family: 'Fira Code', 'Monaco', monospace;
    font-size: 1.1rem;
    color: var(--accent-primary);
    max-width: 280px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.url-truncate {
    max-width: 200px;
}

.copy-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    padding: 2px 6px;
    cursor: pointer;
    font-size: 1.1rem;
    transition: all 0.2s ease;
    color: var(--text-secondary);
}

.copy-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.copy-btn:active {
    transform: scale(0.95);
}

/* Table top actions - right aligned above table - Added 2025-12-02 */
/* Updated 2025-12-03: Added gap between buttons */
.table-top-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 10px;
    padding-right: 5px;
}

/* Data I/O styling - Updated 2025-12-03: Increased font size */
.data-io {
    font-size: 1.2rem;
    line-height: 1.4;
}

.data-in {
    color: var(--accent-success);
}

.data-out {
    color: var(--accent-primary);
}

/* Modal input field styling - Added 2025-12-03 */
.modal-input {
    width: 100%;
    padding: 10px 12px;
    margin-top: 10px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 1rem;
}

.modal-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.modal-input::placeholder {
    color: var(--text-tertiary);
}

/* Banned IPs management - Added 2025-12-03 */
.banned-ips-section {
    background: var(--bg-card);
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
    border: 1px solid var(--border-color);
}

.banned-ips-section h4 {
    margin-bottom: 15px;
    color: var(--text-primary);
    font-size: 1.2rem;
}

.banned-ip-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: var(--bg-secondary);
    border-radius: 6px;
    margin-bottom: 8px;
    border: 1px solid var(--border-color);
}

.banned-ip-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.banned-ip-address {
    font-family: 'Fira Code', monospace;
    font-size: 1rem;
    font-weight: 600;
    color: var(--accent-error);
}

.banned-ip-ttl {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.btn-success {
    background: var(--accent-success);
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1.1rem;
    transition: all 0.2s ease;
}

.btn-success:hover {
    background: #059669;
    transform: translateY(-1px);
}

/* ============================================
   CUSTOMIZE UI TABS - 2025-12-04
   Purpose: Tab navigation for Customize UI section
   ============================================ */

.customize-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 24px;
    border-bottom: 2px solid var(--border-light);
}

.customize-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 24px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    font-weight: 500;
    font-size: 1.1rem;
    transition: all 0.2s ease;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
}

.customize-tab:hover {
    color: var(--primary-color);
    background: var(--bg-tertiary);
}

.customize-tab.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
    background: transparent;
}

.customize-tab svg {
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.customize-tab:hover svg,
.customize-tab.active svg {
    opacity: 1;
}

/* Tab Panel Visibility */
.customize-tab-panel {
    display: none;
}

.customize-tab-panel.active {
    display: block;
    animation: fadeIn 0.2s ease;
}

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

/* Notification Style Section wrapper for proper spacing */
.notification-style-section {
    padding: 0;
}

.notification-style-section .settings-description {
    margin-bottom: 20px;
    color: var(--text-secondary);
}

/* Dark mode adjustments for customize tabs */
[data-theme="dark"] .customize-tab {
    color: var(--text-secondary);
}

[data-theme="dark"] .customize-tab:hover,
[data-theme="dark"] .customize-tab.active {
    color: var(--primary-light);
}

[data-theme="dark"] .customize-tab.active {
    border-bottom-color: var(--primary-light);
}

/* ============================================
   NOTIFICATION STYLING CUSTOMIZATION - 2025-12-04
   ============================================ */

/* Notification Style Tabs */
.notification-style-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--border-light);
    padding-bottom: 12px;
}

.notif-style-tab {
    padding: 10px 20px;
    border: none;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border-radius: 6px 6px 0 0;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
    font-size: 1.1rem;
}

.notif-style-tab:hover {
    background: var(--bg-secondary);
}

.notif-style-tab.active {
    background: var(--accent-primary);
    color: white;
}

.notif-style-tab[data-notif-type="success"].active {
    background: #10b981;
}

.notif-style-tab[data-notif-type="error"].active {
    background: #ef4444;
}

.notif-style-tab[data-notif-type="warning"].active {
    background: #f59e0b;
}

.notif-style-tab[data-notif-type="info"].active {
    background: #3b82f6;
}

/* Notification Style Container - Two Column Layout */
.notification-style-container {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 24px;
    margin-bottom: 20px;
}

@media (max-width: 1200px) {
    .notification-style-container {
        grid-template-columns: 1fr;
    }
}

/* Left Panel - Settings */
.notif-style-settings {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

/* Settings Groups */
.notif-style-group {
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 16px;
}

.notif-style-group-header {
    margin: 0 0 12px 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-light);
}

/* Settings Rows */
.notif-style-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    gap: 12px;
}

.notif-style-row:last-child {
    margin-bottom: 0;
}

.notif-style-row label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    min-width: 120px;
    flex-shrink: 0;
}

/* Color Picker Wrapper */
.color-picker-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    justify-content: flex-end;
}

.color-picker-wrapper input[type="color"] {
    width: 36px;
    height: 36px;
    border: 2px solid var(--border-light);
    border-radius: 6px;
    padding: 2px;
    cursor: pointer;
    background: var(--bg-primary);
}

.color-picker-wrapper input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 2px;
}

.color-picker-wrapper input[type="color"]::-webkit-color-swatch {
    border-radius: 4px;
    border: none;
}

.color-text-input {
    width: 80px;
    padding: 6px 8px;
    border: 1px solid var(--border-light);
    border-radius: 4px;
    font-size: 0.85rem;
    font-family: monospace;
    background: var(--bg-primary);
    color: var(--text-primary);
    text-transform: uppercase;
}

/* Slider Wrapper */
.slider-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    justify-content: flex-end;
}

.slider-wrapper input[type="range"] {
    width: 120px;
    height: 6px;
    border-radius: 3px;
    background: var(--bg-tertiary);
    outline: none;
    -webkit-appearance: none;
}

.slider-wrapper input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.slider-wrapper input[type="range"]::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.slider-value {
    min-width: 45px;
    text-align: right;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
    background: var(--bg-tertiary);
    padding: 4px 8px;
    border-radius: 4px;
}

/* Right Panel - Preview */
.notif-style-preview {
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 16px;
    display: flex;
    flex-direction: column;
}

.preview-header {
    margin: 0 0 16px 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    text-align: center;
}

.preview-container {
    flex: 1;
    min-height: 200px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    position: relative;
    overflow: hidden;
}

/* Preview Notification */
.notification-preview {
    position: relative;
    pointer-events: auto;
    border-radius: 6px;
    padding: 14px 16px;
    padding-right: 40px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    font-weight: 400;
    border-width: 1px;
    border-style: solid;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    /* Default success colors */
    background: #d1f2eb;
    color: #0c5e4f;
    border-color: #b8e6d9;
}

.notification-preview .notification-message {
    flex: 1;
    text-align: center;
}

.notification-preview .notification-close {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    opacity: 0.6;
    color: inherit;
}

.preview-actions {
    display: flex;
    gap: 10px;
    margin-top: 16px;
    justify-content: center;
}

/* Notification Style Actions */
.notif-style-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    padding-top: 16px;
    border-top: 1px solid var(--border-light);
}

.notif-style-actions .btn-primary,
.notif-style-actions .btn-secondary {
    padding: 10px 20px;
    font-size: 1.1rem;
}

/* Dark theme adjustments */
[data-theme="dark"] .notif-style-group {
    background: var(--bg-tertiary);
}

[data-theme="dark"] .preview-container {
    background: #1a1a2e;
}

[data-theme="dark"] .color-text-input {
    background: var(--bg-tertiary);
    border-color: var(--border-dark);
}

[data-theme="dark"] .slider-value {
    background: var(--bg-primary);
}

/* Hidden file input for import */
#notif-style-import-input {
    display: none;
}

/* ============================================
   SETTINGS TABS - 2025-12-04
   Config File Editor Tabs in Settings Section
   ============================================ */

.settings-header-container {
    margin-bottom: 24px;
}

.settings-header {
    margin-bottom: 16px;
}

.settings-header h2 {
    margin: 0 0 8px 0;
    color: var(--text-primary);
}

.settings-header p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.settings-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    border-bottom: 2px solid var(--border-light);
}

.settings-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 18px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    font-weight: 500;
    font-size: 1.1rem;
    transition: all 0.2s ease;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    white-space: nowrap;
}

.settings-tab:hover {
    color: var(--primary-color);
    background: var(--bg-tertiary);
}

.settings-tab.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
    background: transparent;
}

.settings-tab svg {
    opacity: 0.7;
    transition: opacity 0.2s ease;
    flex-shrink: 0;
}

.settings-tab:hover svg,
.settings-tab.active svg {
    opacity: 1;
}

/* Settings Tab Panel Visibility */
.settings-tab-panel {
    display: none;
}

.settings-tab-panel.active {
    display: block;
    animation: settingsFadeIn 0.2s ease;
}

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

/* Config Panel Header */
.config-panel-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-light);
}

.config-panel-header h3 {
    margin: 0;
    color: var(--text-primary);
}

.config-description {
    flex: 1;
    margin: 0;
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.config-description code {
    background: var(--bg-tertiary);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.config-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.config-readonly-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    background: var(--warning-bg, #fef3c7);
    color: var(--warning-text, #92400e);
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
}

/* Config Editor Container */
.config-editor-container {
    background: var(--bg-secondary);
    border-radius: 8px;
    padding: 20px;
    border: 1px solid var(--border-light);
}

.config-form .settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.config-form .settings-group.full-width {
    grid-column: 1 / -1;
}

.config-hint {
    margin: 0 0 12px 0;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.field-hint {
    display: block;
    margin-top: 4px;
    color: var(--text-muted);
    font-size: 1rem;
}

/* Config Viewer for Read-Only files */
.config-viewer {
    max-height: 500px;
    overflow: auto;
    margin-bottom: 16px;
}

.config-code {
    background: var(--bg-tertiary);
    border-radius: 6px;
    padding: 16px;
    margin: 0;
    font-size: 0.85rem;
    line-height: 1.5;
    overflow-x: auto;
    white-space: pre;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.config-edit-notice {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: var(--info-bg, #dbeafe);
    color: var(--info-text, #1e40af);
    border-radius: 6px;
    font-size: 0.85rem;
}

.config-edit-notice svg {
    flex-shrink: 0;
}

.config-edit-notice code {
    background: rgba(0, 0, 0, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 1rem;
}

/* Whitelist IP Styles */
.whitelist-container {
    max-width: 800px;
}

.whitelist-ips-list {
    margin-bottom: 16px;
}

.whitelist-ip-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    margin-bottom: 8px;
}

.whitelist-ip-item .ip-address {
    font-family: monospace;
    font-weight: 600;
}

.whitelist-ip-item .ip-description {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.whitelist-add-form {
    display: flex;
    gap: 12px;
    margin-top: 16px;
}

.whitelist-add-form .form-input {
    flex: 1;
}

/* ABR Quality Profiles */
.abr-qualities-list {
    margin-bottom: 16px;
}

.abr-quality-item {
    display: grid;
    grid-template-columns: 100px 1fr 1fr 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    margin-bottom: 8px;
}

.abr-quality-item label {
    font-weight: 600;
    font-size: 1.1rem;
}

.abr-quality-item input {
    width: 100%;
}

.loading-placeholder {
    padding: 24px;
    text-align: center;
    color: var(--text-muted);
}

/* Dark mode adjustments for settings tabs */
[data-theme="dark"] .settings-tab {
    color: var(--text-secondary);
}

[data-theme="dark"] .settings-tab:hover,
[data-theme="dark"] .settings-tab.active {
    color: var(--primary-light);
}

[data-theme="dark"] .settings-tab.active {
    border-bottom-color: var(--primary-light);
}

[data-theme="dark"] .config-editor-container {
    background: var(--bg-tertiary);
}

[data-theme="dark"] .config-code {
    background: #1e1e2e;
    color: #cdd6f4;
}

[data-theme="dark"] .config-readonly-badge {
    background: rgba(250, 204, 21, 0.2);
    color: #fbbf24;
}

[data-theme="dark"] .config-edit-notice {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

[data-theme="dark"] .whitelist-ip-item,
[data-theme="dark"] .abr-quality-item {
    background: var(--bg-primary);
}

/* Responsive adjustments for settings tabs */
@media (max-width: 1024px) {
    .settings-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .settings-tab {
        padding: 10px 14px;
        font-size: 0.85rem;
    }

    .config-panel-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .abr-quality-item {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 640px) {
    .settings-tab span:not(.sr-only) {
        display: none;
    }

    .settings-tab {
        padding: 10px 12px;
    }

    .whitelist-add-form {
        flex-direction: column;
    }
}

/* ============================================
   PER-SERVICE RESOURCE USAGE STYLES
   Added 2025-12-05
   Purpose: Display real-time CPU and memory bars for each service
   ============================================ */

.service-resources-section {
    margin-top: 24px;
    padding: 20px;
    background: var(--bg-card);
    border-radius: 12px;
    border: 1px solid var(--border-card);
    box-shadow: var(--shadow-card);
}

.service-resources-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-light);
}

.service-resources-section .section-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.refresh-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    color: var(--text-muted);
}

.refresh-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--status-running);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.9); }
}

/* 2025-12-05: Per-Service Resource Usage section on Monitoring page */
/* Updated to full-row layout with real-time CPU/Memory graphs per service */
.service-resources-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.service-resource-card {
    background: var(--bg-tertiary);
    border-radius: 10px;
    padding: 16px 20px;
    border: 1px solid var(--border-light);
    transition: all 0.2s ease;
    width: 100%;
}

.service-resource-card:hover {
    border-color: var(--accent-primary);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1);
}

.service-resource-card .service-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.service-resource-card .service-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.service-resource-card .service-name {
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--text-primary);
}

.service-resource-card .service-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 1rem;
    padding: 5px 12px;
    border-radius: 12px;
    font-weight: 500;
}

.service-resource-card .service-status.running {
    background: rgba(34, 197, 94, 0.1);
    color: var(--status-running);
}

.service-resource-card .service-status.stopped {
    background: rgba(239, 68, 68, 0.1);
    color: var(--status-error);
}

.service-resource-card .status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

/* 2025-12-05: Service graphs container - CPU and Memory side by side */
/* 2025-12-05: Per-service resource row layout with real-time graphs */
.service-resource-row {
    background: var(--bg-tertiary);
    border-radius: 10px;
    padding: 8px 20px 16px 20px;
    border: 1px solid var(--border-light);
    transition: all 0.2s ease;
}

.service-resource-row:hover {
    border-color: var(--accent-primary);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1);
}

.service-resource-row.system-total-row {
    border: 2px solid var(--accent-primary);
    background: var(--bg-active);
}

.service-row-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2px;
}

.service-row-header .service-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.service-row-header .service-name {
    font-weight: 600;
    font-size: 1.2rem;
    color: var(--text-primary);
}

.service-row-header .service-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 1rem;
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 500;
}

.service-row-header .service-status.running {
    background: rgba(34, 197, 94, 0.1);
    color: var(--status-running);
}

.service-row-header .service-status.stopped {
    background: rgba(239, 68, 68, 0.1);
    color: var(--status-error);
}

.service-row-header .status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

.service-meta-inline {
    display: flex;
    gap: 16px;
    font-size: 1rem;
    color: var(--text-muted);
}

.service-meta-inline .meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Container for both CPU and Memory graphs side by side */
.service-graphs-container {
    display: flex;
    gap: 24px;
}

.service-graph-widget {
    flex: 1;
    min-width: 0;
}

.service-graph-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.service-graph-header .graph-label {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.service-graph-header .graph-value {
    font-size: 1.2rem;
    font-weight: 700;
    font-family: 'JetBrains Mono', monospace;
}

.service-graph-header .graph-value.cpu-value {
    color: #3b82f6;
}

.service-graph-header .graph-value.memory-value {
    color: #10b981;
}

/* Service chart container with fixed height */
.service-chart-container {
    position: relative;
    width: 100%;
    height: 120px;
    overflow: hidden;
    background: var(--bg-secondary);
    border-radius: 8px;
}

.service-chart-container canvas {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 120px !important;
    max-height: 120px !important;
}

.service-resource-card .service-meta {
    display: flex;
    justify-content: flex-start;
    gap: 24px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-light);
    font-size: 1rem;
    color: var(--text-muted);
}

.service-resource-card .meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.service-resource-card .meta-item strong {
    color: var(--text-secondary);
}

/* 2025-12-05: Paired service row - displays two services at 50% width each */
.service-paired-row {
    display: flex;
    gap: 16px;
    width: 100%;
}

.service-paired-row .service-resource-row {
    flex: 1;
    min-width: 0;
}

/* 2025-12-05: Compact service card - 50% width with reduced chart height */
.service-resource-row.compact-service {
    padding: 6px 16px 12px 16px;
}

.service-resource-row.compact-service .service-row-header .service-name {
    font-size: 1rem;
}

.service-resource-row.compact-service .service-meta-inline {
    font-size: 0.85rem;
}

.service-resource-row.compact-service .service-graphs-container {
    gap: 16px;
}

.service-resource-row.compact-service .service-graph-header .graph-label {
    font-size: 1.1rem;
}

.service-resource-row.compact-service .service-graph-header .graph-value {
    font-size: 1rem;
}

.service-resource-row.compact-service .service-chart-container {
    height: 80px;
}

.service-resource-row.compact-service .service-chart-container canvas {
    height: 80px !important;
    max-height: 80px !important;
}

/* Responsive: Stack graphs on smaller screens */
@media (max-width: 768px) {
    .service-graphs-container {
        flex-direction: column;
        gap: 16px;
    }

    .service-row-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .service-meta-inline {
        margin-top: 4px;
    }

    /* Stack paired rows on mobile */
    .service-paired-row {
        flex-direction: column;
    }
}

/* Dark mode adjustments for service resources */
[data-theme="dark"] .service-resources-section {
    background: var(--bg-card);
}

[data-theme="dark"] .service-resource-card {
    background: var(--bg-primary);
}

[data-theme="dark"] .service-resource-row {
    background: var(--bg-primary);
}

[data-theme="dark"] .service-chart-container {
    background: var(--bg-tertiary);
}

/* Loading state */
.service-resources-grid .loading-indicator {
    padding: 32px;
    text-align: center;
    color: var(--text-muted);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .service-resources-section .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

/* ============================================
   SVG GAUGE - SPEEDOMETER STYLE WITH NEEDLE
   Added 2025-12-05
   Purpose: Semicircular gauge with colored threshold arcs,
   inner value arc, and triangular needle pointer
   Matching style from images/gauge_style.png
   ============================================ */

/* 2025-12-05: Dashboard Mini Charts Row - Real-time CPU/Memory graphs (60% size) */
.dashboard-mini-charts-row {
    display: flex;
    gap: 20px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    justify-content: flex-start;
}

.mini-chart-widget {
    background: var(--bg-card);
    border-radius: 10px;
    padding: 12px 16px;
    border: 1px solid var(--border-card);
    box-shadow: var(--shadow-card);
    min-width: 260px;
    max-width: 300px;
    flex: 1 1 260px;
}

.mini-chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.mini-chart-header h4 {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.mini-chart-value {
    font-size: 14px;
    font-weight: 700;
    color: var(--accent-primary);
    font-family: 'JetBrains Mono', monospace;
}

.mini-chart-container {
    position: relative;
    width: 100%;
    height: 80px;
    overflow: hidden;
}

.mini-chart-widget canvas {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 80px !important;
    max-height: 80px !important;
}

/* Dark mode for mini charts */
[data-theme="dark"] .mini-chart-widget {
    background: var(--bg-card);
}

[data-theme="dark"] .mini-chart-header h4 {
    color: var(--text-primary);
}

[data-theme="dark"] .mini-chart-value {
    color: var(--accent-primary);
}

/* Responsive mini charts */
@media (max-width: 640px) {
    .dashboard-mini-charts-row {
        flex-direction: column;
    }

    .mini-chart-widget {
        max-width: 100%;
    }
}

/* Legacy gauge styles kept for compatibility */
.dashboard-gauges-row {
    display: flex;
    gap: 24px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    justify-content: flex-start;
}

/* Legacy SVG Gauge Widget Container - kept for compatibility */
.svg-gauge-widget {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 16px;
    border: 1px solid var(--border-card);
    box-shadow: var(--shadow-card);
    text-align: center;
    min-width: 240px;
    max-width: 280px;
    flex: 0 0 auto;
}

.svg-gauge {
    width: 100%;
    height: auto;
    max-width: 224px;
    margin: 0 auto;
    display: block;
}

/* Outer threshold arcs */
.svg-gauge-threshold-arc {
    opacity: 0.9;
}

/* Inner value arc (filled portion showing current value) */
.svg-gauge-value-arc {
    opacity: 1;
}

/* Inner empty arc (unfilled portion) */
.svg-gauge-empty-arc {
    opacity: 0.3;
}

/* Needle with smooth animation */
.svg-gauge-needle {
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 2px 3px rgba(0,0,0,0.2));
}

/* Percentage labels around the arc */
.svg-gauge-label {
    font-size: 11px;
    font-weight: 500;
    fill: var(--text-secondary);
    font-family: 'Inter', sans-serif;
}

/* Center value display */
.svg-gauge-value {
    font-family: 'JetBrains Mono', 'Space Grotesk', monospace;
}

.svg-gauge-value-number {
    font-size: 36px;
    font-weight: 700;
    fill: var(--text-primary);
}

.svg-gauge-value-unit {
    font-size: 20px;
    font-weight: 500;
    fill: var(--text-secondary);
}

/* Description label at bottom */
.svg-gauge-description {
    font-size: 14px;
    font-weight: 600;
    fill: var(--text-secondary);
    font-family: 'Inter', sans-serif;
}

/* Dark mode adjustments */
[data-theme="dark"] .svg-gauge-widget {
    background: var(--bg-card);
}

[data-theme="dark"] .svg-gauge-empty-arc {
    fill: #3a3a4a;
}

[data-theme="dark"] .svg-gauge-label {
    fill: var(--text-muted);
}

[data-theme="dark"] .svg-gauge-value-number {
    fill: var(--text-primary);
}

[data-theme="dark"] .svg-gauge-value-unit {
    fill: var(--text-muted);
}

[data-theme="dark"] .svg-gauge-description {
    fill: var(--text-muted);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .dashboard-gauges-row {
        justify-content: center;
    }

    .svg-gauge-widget {
        min-width: 200px;
        max-width: 240px;
    }
}

@media (max-width: 480px) {
    .dashboard-gauges-row {
        flex-direction: column;
        align-items: center;
    }

    .svg-gauge-widget {
        width: 100%;
        max-width: 260px;
    }
}

/* Empty arc styling */
.svg-gauge-empty-arc {
    fill: #e8e8e8;
}

[data-theme="dark"] .svg-gauge-empty-arc {
    fill: #404050;
}

/* Value text styling */
.svg-gauge-value-text {
    font-family: 'JetBrains Mono', 'Space Grotesk', monospace;
}

.svg-gauge-value-number {
    fill: var(--text-primary);
}

.svg-gauge-value-unit {
    fill: var(--text-secondary);
}

/* Label styling */
.svg-gauge-label {
    fill: var(--text-secondary);
    font-family: 'Inter', sans-serif;
}

[data-theme="dark"] .svg-gauge-label {
    fill: var(--text-muted);
}

[data-theme="dark"] .svg-gauge-value-number {
    fill: #ffffff;
}

/* ============================================
   WAF Configuration Controls - 2025-12-05
   Purpose: Styling for WAF config UI elements
   ============================================ */

.waf-config-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 16px;
}

.waf-mode-control {
    display: flex;
    align-items: center;
    gap: 12px;
}

.waf-mode-control label {
    font-weight: 500;
    color: var(--text-primary);
}

.waf-mode-select {
    padding: 8px 16px;
    border: 1px solid var(--border-input);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 1.1rem;
    cursor: pointer;
    min-width: 200px;
}

.waf-mode-select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(var(--accent-primary-rgb), 0.1);
}

.waf-mode-status {
    font-size: 0.85rem;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
}

.waf-mode-status.saving {
    background: var(--warning-bg);
    color: var(--warning-text);
}

.waf-mode-status.saved {
    background: var(--success-bg);
    color: var(--success-text);
}

.waf-mode-status.error {
    background: var(--error-bg);
    color: var(--error-text);
}

.waf-actions {
    display: flex;
    gap: 10px;
}

.waf-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.waf-panel-header h4 {
    margin: 0;
}

.waf-panel-actions {
    display: flex;
    gap: 8px;
}

.waf-panel-actions .btn-link {
    background: none;
    border: none;
    color: var(--accent-primary);
    cursor: pointer;
    font-size: 0.85rem;
    padding: 4px 8px;
}

.waf-panel-actions .btn-link:hover {
    text-decoration: underline;
}

/* WAF Rules with Toggle Switches */
.waf-rule-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
    margin-bottom: 10px;
    transition: all 0.2s ease;
}

.waf-rule-item:hover {
    border-color: var(--accent-primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.waf-rule-item .rule-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.waf-rule-item .rule-icon {
    font-size: 1.5rem;
}

.waf-rule-item .rule-name {
    font-weight: 500;
    color: var(--text-primary);
}

.waf-rule-item .rule-desc {
    display: block;
    font-size: 1rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.waf-rule-item .rule-count {
    font-size: 1rem;
    background: var(--accent-primary);
    color: white;
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    margin-left: 8px;
}

.waf-rule-item .rule-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.waf-rule-item .rule-id {
    font-size: 1rem;
    color: var(--text-muted);
    font-family: monospace;
}

/* Toggle Switch for Rules */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--border-card);
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--accent-primary);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

.toggle-switch input:disabled + .toggle-slider {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Custom Rule Form */
.waf-custom-rule-section {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-card);
}

.waf-custom-rule-section h5 {
    margin: 0 0 12px 0;
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.waf-custom-rule-form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.waf-custom-rule-form .form-input,
.waf-custom-rule-form .form-select {
    flex: 1;
    min-width: 150px;
    padding: 8px 12px;
    border: 1px solid var(--border-input);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 1.1rem;
}

.waf-custom-rule-form .form-select {
    min-width: 120px;
    flex: 0 0 auto;
}

/* IP Management Enhanced */
.waf-ip-add {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.waf-ip-add .form-input {
    flex: 1;
    min-width: 150px;
    padding: 8px 12px;
    border: 1px solid var(--border-input);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    color: var(--text-primary);
}

.waf-ip-list {
    max-height: 250px;
    overflow-y: auto;
}

.ip-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
}

.ip-list-item .ip-address {
    font-family: monospace;
    font-weight: 500;
    color: var(--text-primary);
}

.ip-list-item .ip-comment {
    font-size: 1rem;
    color: var(--text-muted);
    margin-left: 10px;
}

.ip-list-item .btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.ip-list-item .btn-icon.btn-danger {
    color: var(--error-text);
}

.ip-list-item .btn-icon.btn-danger:hover {
    background: var(--error-bg);
}

/* WAF Config Info Footer */
.waf-config-info {
    display: flex;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    margin-top: 20px;
}

.waf-config-info small {
    color: var(--text-muted);
    font-size: 1rem;
}

.waf-config-info code {
    font-family: monospace;
    background: var(--bg-secondary);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    color: var(--accent-primary);
}

/* Attack Types Enhanced */
.waf-attack-types {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.attack-type-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
}

.attack-type-item .attack-type {
    font-weight: 500;
    color: var(--text-primary);
}

.attack-type-item .attack-stats {
    display: flex;
    align-items: center;
    gap: 8px;
}

.attack-type-item .attack-count {
    font-weight: 600;
    color: var(--error-text);
}

.attack-type-item .attack-percentage {
    font-size: 1rem;
    color: var(--text-muted);
}

/* Responsive WAF Config */
@media (max-width: 768px) {
    .waf-config-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .waf-mode-control {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }

    .waf-mode-select {
        width: 100%;
    }

    .waf-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .waf-custom-rule-form {
        flex-direction: column;
    }

    .waf-custom-rule-form .form-input,
    .waf-custom-rule-form .form-select {
        width: 100%;
    }

    .waf-config-info {
        flex-direction: column;
        gap: 8px;
    }
}

/* ============================================
   WAF Backup & Restore Modals - 2025-12-05
   Purpose: Modal styling for backup and restore
   ============================================ */

.waf-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(4px);
}

.waf-modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 420px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.2s ease-out;
}

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

.waf-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-card);
}

.waf-modal-header h4 {
    margin: 0;
    font-size: 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.waf-modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s ease;
}

.waf-modal-close:hover {
    color: var(--text-primary);
}

.waf-modal-body {
    padding: 20px;
}

.waf-backup-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.waf-backup-form .form-input {
    width: 100%;
    padding: 10px 12px;
}

.waf-backup-buttons {
    display: flex;
    gap: 12px;
}

.waf-backup-buttons button {
    flex: 1;
    padding: 10px 16px;
}

/* Restore Modal Tabs */
.waf-restore-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.waf-restore-tab {
    flex: 1;
    padding: 10px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.1rem;
    transition: all 0.2s ease;
}

.waf-restore-tab:hover {
    border-color: var(--accent-primary);
}

.waf-restore-tab.active {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

.waf-restore-panel {
    display: none;
    flex-direction: column;
    gap: 12px;
}

.waf-restore-panel.active {
    display: flex;
}

.waf-restore-panel .form-select,
.waf-restore-panel .form-input {
    width: 100%;
    padding: 10px 12px;
}

.waf-restore-panel button {
    padding: 10px 16px;
}

.waf-backup-preview {
    padding: 12px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-family: monospace;
    max-height: 120px;
    overflow-y: auto;
    color: var(--text-secondary);
}

/* Responsive */
@media (max-width: 480px) {
    .waf-modal-content {
        width: 95%;
        margin: 10px;
    }

    .waf-backup-buttons {
        flex-direction: column;
    }

    .waf-restore-tabs {
        flex-direction: column;
    }
}

/* ============================================
   About Section Styles - Added 2025-12-05
   ============================================ */

.about-container {
    max-width: 1200px;
    margin: 0 auto;
}

.about-header {
    margin-bottom: 32px;
}

.about-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
    font-family: var(--font-display);
}

.about-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.about-section {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-card);
}

.about-section h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border-card);
}

/* Technology Stack Grid */
.tech-stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.tech-category {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 20px;
}

.tech-category h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--accent-primary);
    margin-bottom: 16px;
}

.tech-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tech-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-card);
}

.tech-icon {
    font-size: 1.5rem;
    width: 40px;
    text-align: center;
}

.tech-info {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.tech-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1rem;
}

.tech-version {
    font-size: 1.1rem;
    color: var(--accent-secondary);
    font-family: var(--font-mono);
}

.tech-desc {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-left: auto;
}

/* Architecture Info */
.architecture-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
}

.arch-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
}

.arch-label {
    font-weight: 600;
    color: var(--text-primary);
    min-width: 120px;
}

.arch-item code {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--accent-secondary);
    background: var(--bg-tertiary);
    padding: 4px 8px;
    border-radius: var(--radius-xs);
}

/* Service Ports Grid */
.ports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
}

.port-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    text-align: center;
    border: 1px solid var(--border-card);
    transition: all var(--transition-fast);
}

.port-item:hover {
    border-color: var(--accent-primary);
    transform: translateY(-2px);
}

.port-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--accent-primary);
    font-family: var(--font-mono);
    margin-bottom: 8px;
}

.port-service {
    font-size: 1rem;
    color: var(--text-secondary);
}

/* Credits Section */
.about-credits {
    text-align: center;
    background: linear-gradient(135deg, var(--bg-card), var(--bg-secondary));
}

.about-credits p {
    margin: 8px 0;
    color: var(--text-primary);
    font-size: 1.1rem;
}

.about-version {
    color: var(--text-secondary) !important;
    font-size: 0.95rem !important;
}

/* Responsive About Section */
@media (max-width: 768px) {
    .tech-stack-grid {
        grid-template-columns: 1fr;
    }

    .tech-desc {
        display: none;
    }

    .architecture-info {
        grid-template-columns: 1fr;
    }

    .arch-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .ports-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
