/* shopnet.network console - professional SaaS design */

:root {
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-light: rgba(37, 99, 235, 0.1);
    --sidebar-bg: #0f172a;
    --sidebar-text: #b0bac7;
    --sidebar-text-hover: #f1f5f9;
    --sidebar-active: #2563eb;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --border: #d1d5db;
    --border-card: #c7ccd4;
    --success: #10b981;
    --success-bg: #d1fae5;
    --warning: #f59e0b;
    --warning-bg: #fef3c7;
    --error: #ef4444;
    --error-bg: #fee2e2;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
    --shadow: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --radius: 8px;
    --radius-lg: 12px;
    --ds-primary: #6366F1;
    --ds-primary-hover: #4F46E5;
    --ds-primary-light: #EEF2FF;
    --ds-secondary: #8B5CF6;
    --ds-success: #10B981;
    --ds-success-light: #D1FAE5;
    --ds-warning: #F59E0B;
    --ds-warning-light: #FEF3C7;
    --ds-danger: #EF4444;
    --ds-danger-light: #FEE2E2;
    --ds-text: #1F2937;
    --ds-text-light: #6B7280;
    --ds-text-muted: #9CA3AF;
    --ds-border: #E5E7EB;
    --ds-bg: #FFFFFF;
    --ds-surface: #F9FAFB;
    --ds-surface-hover: #F3F4F6;
    --ds-radius-sm: 0.25rem;
    --ds-radius: 0.375rem;
    --ds-radius-md: 0.5rem;
    --ds-radius-lg: 0.75rem;
    --ds-radius-xl: 1rem;
    --ds-shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --ds-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1);
    --ds-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --ds-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    --sidebar-width: 272px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-secondary);
    color: var(--text-primary);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* ===== LOGIN ===== */
body.login-page {
    height: 100vh;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    background: transparent;
}

.login-container {
    background: var(--bg-primary);
    padding: 0.375rem 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);
    width: 100%;
    max-width: 380px;
    text-align: center;
}

.login-logo { margin-bottom: 1.5rem; }
.login-logo-emoji { font-size: 4rem; }
.login-title { font-size: 2rem; font-weight: 600; margin-bottom: 0.25rem; }
.login-subtitle { color: var(--text-muted); font-size: 0.875rem; margin-bottom: 2rem; }

/* ===== FORMS ===== */
.form-group { margin-bottom: 1rem; text-align: left; }
.form-label { display: block; font-size: 0.8125rem; font-weight: 500; color: var(--text-secondary); margin-bottom: 0.375rem; }
.form-input {
    width: 100%;
    padding: 0.625rem 0.875rem;
    font-size: 0.9375rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-primary);
    transition: border-color 0.15s, box-shadow 0.15s;
}
.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}
.form-hint { font-size: 0.75rem; color: var(--text-muted); margin-top: 0.375rem; display: block; }

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    transition: all 0.15s;
    text-decoration: none;
}
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-hover); }
.btn-secondary { background: var(--bg-primary); color: var(--text-secondary); border: 1px solid var(--border); }
.btn-secondary:hover { background: var(--bg-tertiary); }
.btn-block { width: 100%; }
.btn-sm { padding: 0.5rem 0.75rem; font-size: 0.8125rem; }

/* BEM-style button variants (for data.shopnet compatibility) */
.btn--primary { background: var(--ds-primary); color: white; }
.btn--primary:hover { background: var(--ds-primary-hover); }
.btn--secondary { background: var(--ds-bg); color: var(--ds-text); border: 1px solid var(--ds-border); }
.btn--secondary:hover { background: var(--ds-surface); }
.btn--outline { background: transparent; color: var(--ds-text); border: 1px solid var(--ds-border); }
.btn--outline:hover { background: var(--ds-surface); border-color: var(--ds-primary); }
.btn--danger { background: var(--ds-danger); color: white; }
.btn--danger:hover { background: #dc2626; }
.btn--success { background: var(--ds-success); color: white; }
.btn--success:hover { background: #059669; }
.btn--sm { padding: 0.375rem 0.75rem; font-size: 0.8125rem; }
.btn--xs { padding: 0.25rem 0.5rem; font-size: 0.75rem; }

/* Input styles (for data.shopnet compatibility) */
.input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius);
    background: var(--ds-bg);
    transition: border-color 0.15s, box-shadow 0.15s;
}
.input:focus {
    outline: none;
    border-color: var(--ds-primary);
    box-shadow: 0 0 0 3px var(--ds-primary-light);
}
.input--sm { padding: 0.375rem 0.5rem; font-size: 0.8125rem; }

/* Select styles (for data.shopnet compatibility) */
.select {
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius);
    background: var(--ds-bg);
    cursor: pointer;
}
.select:focus {
    outline: none;
    border-color: var(--ds-primary);
}

/* ===== APP LAYOUT ===== */
.app-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ===== TOP NAV ===== */
.top-nav {
    height: 48px;
    background: #0a0f1a;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1.5rem;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 200;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.top-nav-left {
    display: flex;
    align-items: center;
}

.top-nav-logo {
    color: white !important;
    font-size: 1.5rem !important;
    font-weight: 600 !important;
    letter-spacing: -0.01em;
}

.top-nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.top-nav-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    font-size: 0.8125rem;
    cursor: pointer;
    transition: all 0.2s;
}

.top-nav-btn:hover {
    background: rgba(255,255,255,0.1);
    color: white;
    border-color: rgba(255,255,255,0.25);
}

.top-nav-btn svg {
    width: 16px;
    height: 16px;
}

.top-nav-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0 1rem;
    font-size: 0.8125rem;
    color: #e2e8f0;
}

.top-nav-status .status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
}

.top-nav-status .status-dot.error {
    background: #ef4444;
}

/* ===== SIDEBAR ===== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 48px;
    left: 0;
    bottom: 0;
    z-index: 100;
}

.sidebar-header {
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.sidebar-logo {
    color: var(--text-muted);
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
}

.sidebar-logo svg { color: var(--primary); }

.sidebar-nav {
    flex: 1;
    padding: 1rem 0;
    overflow-y: auto;
}

.nav-section { margin-bottom: 0.5rem; }

.nav-section-title {
    padding: 0.5rem 1.25rem;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: color 0.15s;
}

.nav-section-title:hover {
    color: var(--sidebar-text-hover);
}

.nav-section-title::after {
    content: '';
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid currentColor;
    transition: transform 0.2s;
}

.nav-section.collapsed .nav-section-title::after {
    transform: rotate(-90deg);
}

.nav-section-items {
    overflow: hidden;
    max-height: 2000px;
    transition: max-height 0.3s ease;
}

.nav-section.collapsed .nav-section-items {
    max-height: 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 1.25rem;
    padding-right: 2.5rem;
    color: var(--sidebar-text);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 300;
    cursor: pointer;
    transition: all 0.15s;
    border-left: 3px solid transparent;
    position: relative;
}

.nav-item:hover {
    color: var(--sidebar-text-hover);
    background: rgba(255,255,255,0.04);
}

.nav-item.active {
    color: white;
    background: rgba(37, 99, 235, 0.15);
    border-left-color: var(--primary);
}

.nav-icon { width: 18px; height: 18px; flex-shrink: 0; opacity: 0.7; }
.nav-item.active .nav-icon { opacity: 1; }

/* Nested nav for data.shopnet */
.nav-subsection {
    margin-left: 0;
}

.nav-item--parent {
    display: flex;
    align-items: center;
}

.nav-expand-icon {
    font-size: 0.6rem;
    opacity: 0.5;
    transition: transform 0.2s;
    margin-left: auto;
}

.nav-subsection:not(.collapsed) > a .nav-expand-icon,
.nav-subgroup:not(.collapsed) > a .nav-expand-icon {
    transform: rotate(90deg);
}

.nav-subsection-items {
    display: block;
    margin-left: 0.5rem;
    padding-left: 0.75rem;
    border-left: 1px solid rgba(255,255,255,0.1);
}

.nav-subsection.collapsed .nav-subsection-items {
    display: none;
}

.nav-subgroup {
    margin: 0.25rem 0;
}

.nav-subgroup-title {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.5rem;
    padding: 0.4rem 0.75rem;
    margin-left: -1.25rem;
    color: rgba(255,255,255,0.6);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    border-radius: 4px;
    text-align: left;
}

.nav-subgroup-title:hover {
    color: rgba(255,255,255,0.8);
    background: rgba(255,255,255,0.05);
}

.nav-subgroup-items {
    display: block;
}

.nav-subgroup.collapsed .nav-subgroup-items {
    display: none;
}

.nav-item--nested {
    display: block;
    padding: 0.4rem 0.75rem 0.4rem 1.5rem;
    color: rgba(255,255,255,0.7);
    font-size: 0.8rem;
    text-decoration: none;
    border-radius: 4px;
    cursor: pointer;
}

.nav-item--nested:hover {
    color: white;
    background: rgba(255,255,255,0.08);
}

.nav-item--nested.active {
    color: white;
    background: rgba(37, 99, 235, 0.15);
}

.sidebar-footer {
    padding: 1rem 1.25rem;
    border-top: 1px solid rgba(255,255,255,0.06);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
}

.user-details { flex: 1; min-width: 0; }
.user-name { font-size: 0.875rem; font-weight: 500; color: white; }
.user-email { font-size: 0.75rem; color: var(--sidebar-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===== MAIN CONTENT ===== */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    margin-top: 48px;
    padding: 2rem;
    min-height: calc(100vh - 48px);
    max-width: calc(100vw - var(--sidebar-width));
}

.panel { display: none; }
.panel.active { display: block; max-width: 1400px; }

.panel-header {
    margin-bottom: 2rem;
}
.panel-header h1 { font-size: 1.5rem; font-weight: 600; margin-bottom: 0.25rem; }
.panel-header p { color: var(--text-muted); font-size: 0.9375rem; }

.panel-section { margin-top: 2rem; }
.panel-section h2 { font-size: 1rem; font-weight: 600; margin-bottom: 1rem; }

/* ===== STATS GRID ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.stat-card {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.2s ease;
}

.stat-card:hover {
    border-color: var(--ds-primary, #8b5cf6);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.stat-card__label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.stat-card__value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--ds-primary, #8b5cf6);
    line-height: 1;
}

.stat-card__sub {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

.stat-card--clickable {
    cursor: pointer;
}

.stat-card--clickable:hover {
    background: var(--ds-primary-light, rgba(139, 92, 246, 0.1));
    transform: translateY(-2px);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
}
.stat-icon svg { width: 24px; height: 24px; }
.stat-icon-blue { background: #dbeafe; color: #2563eb; }
.stat-icon-green { background: #d1fae5; color: #059669; }
.stat-icon-purple { background: #ede9fe; color: #7c3aed; }
.stat-icon-orange { background: #ffedd5; color: #ea580c; }

.stat-info { }
.stat-value { font-size: 1.5rem; font-weight: 700; line-height: 1.2; }
.stat-label { font-size: 0.8125rem; color: var(--text-muted); }

/* ===== QUICK ACCESS ===== */
.quick-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.quick-card {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: inherit;
    transition: all 0.15s;
}
.quick-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}
.quick-icon { font-size: 2rem; }
.quick-label { font-size: 0.875rem; font-weight: 500; color: var(--text-secondary); }

/* ===== CARDS GRID ===== */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1rem;
}

/* ===== SITE CARDS ===== */
.site-card {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    text-decoration: none;
    color: inherit;
    transition: all 0.15s;
    display: block;
}
.site-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}
.site-card-disabled {
    opacity: 0.6;
    cursor: not-allowed;
}
.site-card-disabled:hover {
    border-color: var(--border);
    box-shadow: none;
}

.site-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}
.site-icon { font-size: 1.75rem; }
.site-card h3 { font-size: 1rem; font-weight: 600; margin-bottom: 0.5rem; }
.site-card p { font-size: 0.875rem; color: var(--text-muted); line-height: 1.5; margin-bottom: 1rem; }
.site-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* ===== COMING SOON ===== */
.coming-soon-container {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 1px dashed #0ea5e9;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.coming-soon-badge {
    display: inline-block;
    background: linear-gradient(135deg, #0ea5e9, #0891b2);
    color: white;
    font-size: 0.875rem;
    font-weight: 600;
    padding: 0.375rem 1rem;
    border-radius: 20px;
    margin-bottom: 0.75rem;
}

.coming-soon-text {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    margin: 0;
}

/* ===== CONTROL CARDS ===== */
.control-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: inherit;
    transition: all 0.15s;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
}
.control-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}
.control-card-disabled {
    opacity: 0.75;
    cursor: not-allowed;
}
.control-card-disabled:hover {
    border-color: var(--border-card);
    box-shadow: var(--shadow-sm);
}

.control-card-icon {
    font-size: 1.75rem;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border-radius: var(--radius);
    flex-shrink: 0;
}

.control-card-body { flex: 1; }
.control-card-body h3 { font-size: 0.9375rem; font-weight: 600; margin-bottom: 0.25rem; }
.control-card-body p { font-size: 0.8125rem; color: var(--text-secondary); margin-bottom: 0.5rem; }
.control-card-meta { display: flex; align-items: center; gap: 0.75rem; }
.meta-text { font-size: 0.75rem; color: var(--text-secondary); }
.control-card-arrow { color: var(--text-secondary); font-size: 1.25rem; }

/* ===== INFO CARD ===== */
.info-card {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}
.info-card-icon { font-size: 2rem; }
.info-card-content h3 { font-size: 1rem; font-weight: 600; margin-bottom: 0.5rem; }
.info-card-content p { font-size: 0.875rem; color: var(--text-muted); }

/* ===== SETTINGS ===== */
.settings-section { margin-bottom: 2rem; }
.settings-section h2 { font-size: 1rem; font-weight: 600; margin-bottom: 1rem; }
.settings-card {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}
.settings-table { width: 100%; }
.settings-table td { padding: 0.75rem 0; border-bottom: 1px solid var(--border); font-size: 0.875rem; }
.settings-table tr:last-child td { border-bottom: none; }
.settings-label { font-weight: 500; color: var(--text-secondary); width: 120px; }

/* ===== BADGES ===== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.625rem;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    border-radius: 9999px;
}
.badge-success { background: var(--success-bg); color: #047857; }
.badge-warning { background: var(--warning-bg); color: #b45309; }
.badge-error { background: var(--error-bg); color: var(--error); }
.badge-default { background: var(--bg-tertiary); color: var(--text-muted); }

/* ===== ALERTS ===== */
.alert { padding: 0.875rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: 0.875rem; }
.alert-error { background: var(--error-bg); color: var(--error); }
.alert-success { background: var(--success-bg); color: #047857; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
    .stats-grid, .quick-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .sidebar { transform: translateX(-100%); }
    .main-content { margin-left: 0; }
    .stats-grid, .quick-grid { grid-template-columns: 1fr; }
    .cards-grid { grid-template-columns: 1fr; }
}

/* ===== STATUS INDICATORS (Traffic Lights) ===== */
.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}
.status-dot-lg {
    width: 14px;
    height: 14px;
}
.status-dot.green { background: #22c55e; box-shadow: 0 0 6px rgba(34, 197, 94, 0.5); }
.status-dot.orange { background: #f59e0b; box-shadow: 0 0 6px rgba(245, 158, 11, 0.5); }
.status-dot.red { background: #ef4444; box-shadow: 0 0 6px rgba(239, 68, 68, 0.5); }
.status-dot.grey { background: #9ca3af; }

/* Pulsing animation for active status */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}
.status-dot.green { animation: pulse 2s ease-in-out infinite; }

/* Nav status dots - positioned at right of nav item */
.nav-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-left: auto;
    flex-shrink: 0;
}
.nav-status-dot.green { background: #22c55e; box-shadow: 0 0 4px rgba(34, 197, 94, 0.5); animation: pulse 2s ease-in-out infinite; }
.nav-status-dot.orange { background: #f59e0b; box-shadow: 0 0 4px rgba(245, 158, 11, 0.5); }
.nav-status-dot.red { background: #ef4444; box-shadow: 0 0 4px rgba(239, 68, 68, 0.5); }
.nav-status-dot.grey { background: #6b7280; }

/* WIP Badge */
.wip-badge {
    background: #ef4444;
    color: white;
    font-size: 0.625rem;
    font-weight: 600;
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex-shrink: 0;
}

.nav-item .wip-badge {
    position: absolute;
    right: 2rem;
}

/* Card status dots */
.card-status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    vertical-align: middle;
    margin-left: 0.5rem;
}
.card-status-dot.green { background: #22c55e; box-shadow: 0 0 6px rgba(34, 197, 94, 0.5); animation: pulse 2s ease-in-out infinite; }
.card-status-dot.orange { background: #f59e0b; box-shadow: 0 0 6px rgba(245, 158, 11, 0.5); }
.card-status-dot.red { background: #ef4444; box-shadow: 0 0 6px rgba(239, 68, 68, 0.5); }
.card-status-dot.grey { background: #9ca3af; }

/* Ensure info-card has position for absolute positioned status dot */
.info-card {
    position: relative;
}

/* ===== NETWORK MAP ===== */
.network-map-container {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    position: relative;
    overflow: hidden;
}

.network-map-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.network-map-title {
    font-size: 1.125rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.network-map-controls {
    display: flex;
    gap: 0.5rem;
}

.network-map-svg {
    width: 100%;
    height: 500px;
    background: var(--bg-secondary);
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 200"><circle cx="100" cy="100" r="95" fill="none" stroke="%2393c5fd" stroke-width="2" opacity="0.15"/><ellipse cx="100" cy="100" rx="95" ry="40" fill="none" stroke="%2393c5fd" stroke-width="2" opacity="0.15"/><ellipse cx="100" cy="100" rx="95" ry="60" fill="none" stroke="%2393c5fd" stroke-width="2" opacity="0.15"/><ellipse cx="100" cy="100" rx="40" ry="95" fill="none" stroke="%2393c5fd" stroke-width="2" opacity="0.15"/><ellipse cx="100" cy="100" rx="60" ry="95" fill="none" stroke="%2393c5fd" stroke-width="2" opacity="0.15"/><line x1="5" y1="100" x2="195" y2="100" stroke="%2393c5fd" stroke-width="2" opacity="0.15"/><line x1="100" y1="5" x2="100" y2="195" stroke="%2393c5fd" stroke-width="2" opacity="0.15"/></svg>');
    /* ⚠️ WARNING: DO NOT CHANGE THIS POSITION VALUE! ⚠️
     * Globe position (52.4% 42.5%) is precisely calibrated to align with
     * the connect.shopnet node center in the SVG network map.
     * This took extensive manual tuning. Changing it will break alignment.
     * If you need to move the map, move the SVG elements, not this value.
     * Last calibrated: January 22, 2026 */
    background-position: 52.4% 42.5%;
    background-repeat: no-repeat;
    /* Globe size scales proportionally with SVG height (400/500 = 0.8 ratio) */
    background-size: 400px 400px;
    border-radius: var(--radius);
}

/* Network map visual container - needs position for badge */
#network-map-visual {
    position: relative;
}

/* Network map header badge - centered above Management Console */
/* Management Console is at x=465 center in 900-wide SVG = 51.67% */
.network-map-header-badge {
    position: absolute;
    top: -20px;
    left: 51.67%;
    transform: translateX(-50%);
    font-family: 'Helvetica Neue', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 56px;
    font-weight: 500;
    color: #000;
    pointer-events: none;
    z-index: 5;
    white-space: nowrap;
    padding: 0;
    line-height: 1;
}
.network-map-header-badge .red-dot {
    color: #ef4444;
}

/* Network map footer badge - matches screensaver style */
.network-map-badge {
    position: absolute;
    bottom: 40px;
    right: 80px;
    font-family: 'Helvetica Neue', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 36px;
    font-weight: 500;
    color: #000;
    pointer-events: none;
    z-index: 5;
}
.network-map-badge .red-dot {
    color: #ef4444;
}

/* Scale up network map on larger screens - globe scales proportionally */
@media (min-width: 1400px) {
    .network-map-svg {
        height: 620px;
        background-size: 496px 496px; /* 620 * 0.8 */
    }
}
@media (min-width: 1800px) {
    .network-map-svg {
        height: 750px;
        background-size: 600px 600px; /* 750 * 0.8 */
    }
}
@media (min-width: 2200px) {
    .network-map-svg {
        height: 900px;
        background-size: 720px 720px; /* 900 * 0.8 */
    }
}

/* Map nodes */
.map-node {
    cursor: pointer;
    transition: transform 0.15s;
}
.map-node:hover {
    transform: scale(1.02);
}
.map-node-box {
    fill: var(--bg-primary);
    stroke: var(--border);
    stroke-width: 1.5;
    rx: 8;
}
.map-node:hover .map-node-box {
    stroke: var(--primary);
    stroke-width: 2;
}
.map-node-label {
    font-size: 15px;
    font-weight: 600;
    fill: var(--text-primary);
}
.map-node-sublabel {
    font-size: 12px;
    fill: var(--text-muted);
}

/* Map connections */
.map-connection {
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
}
.map-connection.green { stroke: #22c55e; }
.map-connection.orange { stroke: #f59e0b; }
.map-connection.red { stroke: #ef4444; }
.map-connection.grey { stroke: #d1d5db; stroke-dasharray: 4 4; }

/* Animated flow on active connections */
@keyframes flow {
    from { stroke-dashoffset: 20; }
    to { stroke-dashoffset: 0; }
}
.map-connection.green.active {
    stroke-dasharray: 10 10;
    animation: flow 1s linear infinite;
}

/* Central hub styling */
.map-hub {
    fill: var(--primary-light);
    stroke: var(--primary);
    stroke-width: 2;
}

/* Connection dots on hub */
.map-connector {
    r: 5;
    cursor: pointer;
    transition: r 0.15s;
}
.map-connector:hover { r: 7; }
.map-connector.green { fill: #22c55e; }
.map-connector.orange { fill: #f59e0b; }
.map-connector.red { fill: #ef4444; }
.map-connector.grey { fill: #9ca3af; }

/* Status summary bar */
.status-summary {
    display: flex;
    gap: 1.5rem;
    padding: 1rem;
    background: var(--bg-tertiary);
    border-radius: var(--radius);
    margin-top: 1rem;
}
.status-summary-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}
.status-summary-count {
    font-weight: 600;
    font-size: 1.25rem;
}

/* Data view table */
.network-data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}
.network-data-table th {
    text-align: left;
    padding: 0.75rem 0.5rem;
    border-bottom: 2px solid var(--border);
    font-weight: 600;
    color: var(--text-secondary);
}
.network-data-table td {
    padding: 0.625rem 0.5rem;
    border-bottom: 1px solid var(--border);
}
.network-data-table tr:hover td {
    background: var(--bg-tertiary);
}

/* Map timestamp */
.map-timestamp {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: right;
    margin-top: 0.75rem;
}

/* ===== GOLDEN TABLE (Shared Table Styling) ===== */

/* Endpoint Registry Tabs */
.endpoint-registry-tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--border);
    margin-bottom: 1rem;
}

.endpoint-registry-tab {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s;
}

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

.endpoint-registry-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    background: transparent;
}

.endpoint-registry-tab-content {
    display: none;
}

.endpoint-registry-tab-content.active {
    display: block;
}

.golden-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}

.golden-table th {
    text-align: left;
    padding: 0.625rem 0.75rem;
    background: var(--bg-tertiary);
    border-bottom: 2px solid var(--border);
    font-weight: 600;
    color: var(--text-secondary);
    position: sticky;
    top: 0;
    z-index: 1;
}

.golden-table td {
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

.golden-table td.indent {
    padding-left: 1.5rem;
    color: var(--text-muted);
}

.golden-table tr:hover td {
    background: var(--bg-tertiary);
}

.golden-table a {
    color: var(--primary);
    text-decoration: none;
}

.golden-table a:hover {
    text-decoration: underline;
}

/* ===== ENDPOINT REGISTRY (Redesigned) ===== */
.registry-stats-bar {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    align-items: center;
}

.stat-pill {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.stat-pill:hover {
    background: var(--bg-tertiary);
    border-color: var(--pill-color, var(--primary));
}

.stat-pill.active {
    background: var(--pill-color, var(--primary));
    border-color: var(--pill-color, var(--primary));
}

.stat-pill.active .stat-value,
.stat-pill.active .stat-label {
    color: white;
}

.stat-pill .stat-value {
    font-weight: 700;
    font-size: 1rem;
    color: var(--pill-color, var(--primary));
}

.stat-pill .stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.stat-info {
    margin-left: auto;
    font-size: 0.8rem;
    color: var(--text-secondary);
    padding: 0.5rem 1rem;
    background: var(--bg-tertiary);
    border-radius: 4px;
}

.registry-table-wrapper {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-primary);
}

.registry-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}

.registry-table th {
    text-align: left;
    padding: 0.75rem 0.875rem;
    background: var(--bg-secondary);
    border-bottom: 2px solid var(--border);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    color: var(--text-secondary);
    white-space: nowrap;
    cursor: pointer;
    user-select: none;
    transition: background 0.15s ease;
}

.registry-table th:hover {
    background: var(--bg-tertiary);
}

.registry-table th.sorted-asc::after {
    content: ' ▲';
    font-size: 0.6rem;
    opacity: 0.7;
}

.registry-table th.sorted-desc::after {
    content: ' ▼';
    font-size: 0.6rem;
    opacity: 0.7;
}

.registry-table td {
    padding: 0.625rem 0.875rem;
    border-bottom: 1px solid var(--border-light, rgba(128,128,128,0.1));
    vertical-align: middle;
}

.registry-table tbody tr:hover td {
    background: var(--bg-secondary);
}

.registry-table tbody tr:last-child td {
    border-bottom: none;
}

.registry-footer {
    border-top: 1px solid var(--border);
    margin-top: 0.5rem;
}

/* Registry Table Cell Styles */
.registry-uid {
    font-family: 'SF Mono', Monaco, 'Courier New', monospace;
    font-size: 0.75rem;
    background: #e0f2fe;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    color: #0369a1;
    border: 1px solid #bae6fd;
    white-space: nowrap;
}

.registry-badge {
    display: inline-block;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    white-space: nowrap;
}

.registry-badge.type-w { background: #3b82f6; color: white; }
.registry-badge.type-a { background: #8b5cf6; color: white; }
.registry-badge.type-d { background: #22c55e; color: white; }
.registry-badge.type-nd { background: #f59e0b; color: white; }

.registry-badge.protocol-w2 { background: #6b7280; color: white; }
.registry-badge.protocol-w3 { background: #8b5cf6; color: white; }

.registry-badge.status-live { background: #22c55e; color: white; }
.registry-badge.status-wip { background: #f59e0b; color: white; }
.registry-badge.status-planned { background: #6b7280; color: white; }

.registry-domain {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.registry-notes {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.registry-muted {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Config Modal Styles */
.config-section {
    margin-bottom: 1.5rem;
}

.config-section:last-child {
    margin-bottom: 0;
}

.config-section h4 {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.config-radio-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.config-radio {
    display: flex;
    flex-direction: column;
    padding: 0.75rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.config-radio:hover {
    border-color: var(--primary);
    background: var(--bg-tertiary);
}

.config-radio input[type="radio"] {
    margin-right: 0.5rem;
}

.config-hint {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    margin-left: 1.25rem;
}

.config-checkbox-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.config-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.15s ease;
}

.config-checkbox:hover {
    border-color: var(--primary);
}

.config-checkbox input[type="checkbox"] {
    accent-color: var(--primary);
}

.config-checkbox.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Modal improvements */
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 1.25rem;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--border);
    background: var(--bg-secondary);
}

.modal-content {
    background: var(--bg-primary);
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
    max-height: 90vh;
    overflow-y: auto;
}

.btn-link {
    background: none;
    border: none;
    color: var(--primary);
    cursor: pointer;
    padding: 0;
    font-size: inherit;
}

.btn-link:hover {
    text-decoration: underline;
}

/* ===== ENDPOINTS TABLE ===== */
.endpoints-table-container {
    margin-top: 2rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.endpoints-table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    background: var(--bg-tertiary);
}

.endpoints-table-header h2 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.endpoints-count {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.endpoints-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}

.endpoints-table th {
    text-align: left;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    color: var(--text-secondary);
    background: var(--bg-tertiary);
}

.endpoints-table td {
    padding: 0.625rem 1rem;
    border-bottom: 1px solid var(--border);
}

.endpoints-table tr:hover td {
    background: var(--bg-tertiary);
}

.endpoints-table tr.section-header td {
    background: var(--bg-primary);
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.5rem 1rem;
}

.endpoints-table .endpoint-name {
    font-weight: 500;
}

.endpoints-table .endpoint-url {
    color: var(--primary);
    text-decoration: none;
}

.endpoints-table .endpoint-url:hover {
    text-decoration: underline;
}

.endpoints-table .ip-address {
    font-family: 'SF Mono', Monaco, 'Cascadia Code', monospace;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.endpoints-table .instance-badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    font-weight: 500;
}

.instance-badge.ec2 { background: #fef3c7; color: #92400e; }
.instance-badge.lightsail { background: #dbeafe; color: #1e40af; }
.instance-badge.lambda { background: #fce7f3; color: #9d174d; }
.instance-badge.rds { background: #d1fae5; color: #065f46; }
.instance-badge.s3 { background: #ede9fe; color: #5b21b6; }
.instance-badge.shopify { background: #cffafe; color: #0e7490; }
.instance-badge.partner { background: #f3f4f6; color: #374151; }
.instance-badge.default { background: var(--bg-tertiary); color: var(--text-muted); }

/* ===== ADD ENDPOINT WIZARD ===== */

/* Wizard Progress Bar */
.wizard-progress {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    overflow-x: auto;
}

.wizard-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    min-width: 80px;
    opacity: 0.5;
    transition: opacity 0.2s;
}

.wizard-step.active {
    opacity: 1;
}

.wizard-step.completed {
    opacity: 1;
}

.wizard-step-number {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 2px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-muted);
    transition: all 0.2s;
}

.wizard-step.active .wizard-step-number {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.wizard-step.completed .wizard-step-number {
    background: #22c55e;
    border-color: #22c55e;
    color: white;
}

.wizard-step-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
}

.wizard-step.active .wizard-step-label {
    color: var(--text-primary);
    font-weight: 500;
}

/* Wizard Content */
.wizard-content {
    min-height: 300px;
}

.wizard-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2rem;
}

.wizard-card h2 {
    margin-bottom: 0.5rem;
    font-size: 1.25rem;
}

.wizard-hint {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* Wizard Options */
.wizard-options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.wizard-option {
    display: block;
    cursor: pointer;
}

.wizard-option input[type="radio"],
.wizard-option input[type="checkbox"] {
    display: none;
}

.wizard-option-content {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: var(--bg-primary);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    transition: all 0.15s;
}

.wizard-option:hover .wizard-option-content {
    border-color: var(--primary-light);
    background: var(--bg-tertiary);
}

.wizard-option input:checked + .wizard-option-content {
    border-color: var(--primary);
    background: var(--primary-light);
}

.wizard-option-icon {
    font-size: 1.5rem;
    width: 40px;
    text-align: center;
}

.wizard-option-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.wizard-option-text strong {
    font-size: 0.9375rem;
}

.wizard-option-text span {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* Wizard Form Fields */
.wizard-form-section {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.wizard-form-section h3 {
    margin-bottom: 1rem;
    font-size: 1rem;
}

.wizard-form-fields {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--bg-tertiary);
    border-radius: var(--radius);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.wizard-form-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.wizard-form-field label {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.wizard-form-field input[type="text"] {
    padding: 0.625rem 0.875rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.875rem;
    color: var(--text-primary);
}

.wizard-form-field input[type="text"]:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.wizard-form-field input[readonly] {
    background: var(--bg-secondary);
    color: var(--text-muted);
    cursor: not-allowed;
}

/* Wizard Navigation */
.wizard-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.wizard-nav .btn-success {
    background: #22c55e;
    color: white;
}

.wizard-nav .btn-success:hover {
    background: #16a34a;
}

/* Example Configuration Section */
.example-config {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    margin-bottom: 1.5rem;
    overflow-x: auto;
}

.example-config pre {
    margin: 0;
    font-family: 'SF Mono', 'Monaco', 'Menlo', monospace;
    font-size: 0.8125rem;
    line-height: 1.5;
    color: var(--text-primary);
}

.example-config code {
    color: #22c55e;
}

.example-description {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
}

.example-description h3 {
    margin-bottom: 1rem;
    font-size: 1rem;
}

.config-table {
    width: 100%;
    font-size: 0.875rem;
}

.config-table tr {
    border-bottom: 1px solid var(--border);
}

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

.config-table td {
    padding: 0.75rem 0;
    vertical-align: top;
}

.config-table td:first-child {
    width: 120px;
    color: var(--text-secondary);
}

@media (max-width: 768px) {
    .wizard-progress {
        gap: 0.5rem;
    }
    .wizard-step {
        min-width: 60px;
    }
    .wizard-step-label {
        display: none;
    }
    .wizard-card {
        padding: 1.25rem;
    }
}

/* ===== DEATHSTAR PANEL ===== */
.deathstar-content {
    max-width: 900px;
}

.deathstar-intro {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 2rem;
    font-size: 1rem;
    line-height: 1.6;
}

.deathstar-actions {
    margin-bottom: 2rem;
}

.deathstar-actions .btn {
    display: inline-flex;
    align-items: center;
}

.deathstar-sections {
    margin-bottom: 2rem;
}

.deathstar-sections h2 {
    margin-bottom: 1rem;
}

.deathstar-status {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}

.deathstar-status h2 {
    margin-bottom: 1rem;
}

.deathstar-status .config-table td:first-child {
    width: 30px;
    padding-right: 0.5rem;
}

.deathstar-status .config-table td:nth-child(2) {
    width: 180px;
}

/* ===== BROCHURE SITES ===== */
.brochure-status-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
}

.brochure-status-bar .card-status-dot {
    width: 10px;
    height: 10px;
}

.brochure-loading {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
}

.brochure-section {
    margin-bottom: 2rem;
}

.brochure-section-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--border);
    margin-bottom: 1rem;
}

.brochure-section-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
}

.brochure-section-header .section-icon {
    font-size: 1.25rem;
}

.brochure-section-header.product-assist { color: #2563eb; }
.brochure-section-header.domain-assist { color: #059669; }
.brochure-section-header.ai-agents { color: #7c3aed; }
.brochure-section-header.github-modules { color: #f97316; }
.brochure-section-header.gateway { color: #dc2626; }
.brochure-section-header.test-page { color: #f59e0b; }

.brochure-subsection {
    margin-bottom: 1rem;
}

.brochure-subsection h4 {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.brochure-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 380px));
    gap: 1rem;
    max-width: 100%;
}

.brochure-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius);
    padding: 1rem;
    transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
    position: relative;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-sm);
    min-height: 160px;
    max-width: 400px;
}

.brochure-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}

.brochure-card.inactive {
    opacity: 0.75;
    background: var(--bg-secondary);
}

.brochure-card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.brochure-card-icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    object-fit: cover;
}

.brochure-card-icon-emoji {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background: var(--bg-tertiary);
    border-radius: 6px;
}

.brochure-card h4 {
    font-size: 0.9375rem;
    font-weight: 600;
    margin: 0;
    flex: 1;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.brochure-card-status,
.brochure-card > .brochure-card-status,
span.brochure-card-status {
    position: absolute !important;
    top: 14px !important;
    right: 44px !important;
    left: auto !important;
    width: 10px !important;
    height: 10px !important;
    border-radius: 50% !important;
    z-index: 100 !important;
    display: block !important;
}

.brochure-card-status.active { background: var(--success); }
.brochure-card-status.inactive { background: var(--text-muted); }

/* S3 Label - Bottom right of card for domains with S3 content */
.brochure-card-s3-label {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: #f59e0b;
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 3px;
    letter-spacing: 0.5px;
}

/* Hosting Type Label - Next to S3 label (L=Lambda, R=Radius) */
.brochure-card-hosting-label {
    position: absolute;
    bottom: 8px;
    right: 8px;
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 3px;
    letter-spacing: 0.5px;
}

.brochure-card-hosting-label.lambda {
    background: #6366f1;  /* Purple for Lambda */
}

.brochure-card-hosting-label.radius {
    background: #10b981;  /* Green for Radius */
}

/* When S3 label present, shift hosting label left */
.brochure-card-s3-label ~ .brochure-card-hosting-label {
    right: 34px;
}

/* Site UID Label - Site Index ID (top left) */
.brochure-card-site-uid {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #0ea5e9;  /* Sky blue for Site UID */
    color: white;
    font-size: 9px;
    font-weight: 700;
    padding: 2px 5px;
    border-radius: 3px;
    letter-spacing: 0.3px;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
}

/* Generic badge for footer (instance type, platform, etc.) */
.brochure-card-badge {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* THE LAW Site Cards - New Styles */
.site-uid-badge {
    background: #e0f2fe;
    color: #0369a1;
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    font-family: 'SF Mono', 'Monaco', monospace;
    display: inline-block;
    margin-bottom: 8px;
}

.card-meta {
    display: flex;
    gap: 6px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.badge {
    font-size: 9px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 3px;
    text-transform: uppercase;
}

.badge-platform {
    background: #dbeafe;
    color: #1d4ed8;
}

.badge-managed {
    background: #fef3c7;
    color: #92400e;
}

.card-url {
    display: block;
    font-size: 12px;
    color: var(--primary);
    text-decoration: none;
    margin-bottom: 6px;
    word-break: break-all;
}

.card-url:hover {
    text-decoration: underline;
}

.card-notes {
    font-size: 11px;
    color: var(--text-muted);
    line-height: 1.3;
    max-height: 40px;
    overflow: hidden;
}

.taxonomy-status {
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 3px;
}

.taxonomy-status.live {
    background: #dcfce7;
    color: #166534;
}

.taxonomy-status.wip {
    background: #fef3c7;
    color: #92400e;
}

.taxonomy-status.planned {
    background: #e5e7eb;
    color: #374151;
}

.live-status {
    font-size: 10px;
    color: var(--text-muted);
}

.section-badge {
    font-size: 10px;
    background: #0ea5e9;
    color: white;
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: auto;
}

/* DNS/SSL Indicator Dots */
.brochure-card-indicators {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    display: flex;
    gap: 4px;
}

.indicator-dot {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 9px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: help;
}

.indicator-dot.green { background: #22c55e; }
.indicator-dot.yellow { background: #f59e0b; }
.indicator-dot.red { background: #ef4444; }
.indicator-dot.grey { background: #9ca3af; }

.brochure-card p {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.brochure-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-card);
    font-size: 0.75rem;
    color: var(--text-secondary);
    flex-wrap: wrap;
    gap: 0.25rem;
}

.brochure-card-updated {
    font-size: 0.65rem;
    color: var(--text-muted, #6b7280);
    opacity: 0.7;
    width: 100%;
    text-align: center;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: none;
    order: 99;
}

.brochure-card-arrow {
    color: var(--primary);
    font-weight: 600;
}

.brochure-error {
    background: var(--error-bg);
    border: 1px solid var(--error);
    border-radius: var(--radius);
    padding: 1.5rem;
    text-align: center;
    color: var(--error);
}

.brochure-error h3 {
    margin-bottom: 0.5rem;
}

.brochure-error button {
    margin-top: 1rem;
}

/* Web3 Card Meta */
.brochure-card-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
}

.brochure-card-meta .meta-text {
    background: var(--bg-tertiary);
    padding: 0.2rem 0.5rem;
    border-radius: var(--radius-sm);
}

/* Web3 cards use same styling as brochure cards - no special border */

.brochure-card-status.unknown {
    background: var(--text-muted);
}

.brochure-card-status.degraded {
    background: #f59e0b;
}

/* Status text in card footer */
.status-text.green { color: var(--success); font-weight: 500; }
.status-text.orange { color: #f59e0b; font-weight: 500; }
.status-text.red { color: var(--danger); font-weight: 500; }
.status-text.grey { color: var(--text-muted); }

/* Web3 server section header - teal color to match network theme */
.brochure-section-header.web3-server {
    color: #0891b2;
}

/* Web3 Gateway section header - purple for CloudFront hosted sites */
.brochure-section-header.web3-gateway {
    color: #7c3aed;
}

/* ===== LAMBDA ADMIN MODALS ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

/* Delete and Duplicate modals need higher z-index since they open on top of config modal */
#deleteModal,
#duplicateModal {
    z-index: 2000 !important;
}

#deleteModal .modal-content,
#duplicateModal .modal-content {
    z-index: 2001 !important;
}

.modal-content {
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-height: 90vh;
    overflow-y: auto;
}

.modal-small { width: 100%; max-width: 400px; }
.modal-medium { width: 100%; max-width: 500px; }
.modal-large { width: 100%; max-width: 800px; }

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border);
}

.modal-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-muted);
    cursor: pointer;
    line-height: 1;
    padding: 0;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border);
    background: var(--bg-secondary);
}

/* Progress Steps */
.progress-steps {
    margin: 1.5rem 0;
}

.progress-step {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: var(--radius);
    margin-bottom: 0.5rem;
    transition: background 0.2s;
}

.progress-step.pending { color: var(--text-muted); }
.progress-step.active { background: var(--primary-light); color: var(--primary); }
.progress-step.complete { color: var(--success); }
.progress-step.error { color: var(--error); }

.progress-icon {
    font-size: 1.25rem;
    width: 1.5rem;
    text-align: center;
}

.progress-text {
    font-size: 0.875rem;
}

/* Nameserver List */
.nameserver-list {
    list-style: none;
    padding: 0;
    margin: 0;
    background: var(--bg-tertiary);
    border-radius: var(--radius);
    padding: 1rem;
}

.nameserver-list li {
    padding: 0.375rem 0;
    font-family: monospace;
    font-size: 0.875rem;
    color: var(--text-primary);
}

.nameserver-list li:not(:last-child) {
    border-bottom: 1px solid var(--border);
}

/* Modal Result/Error */
.modal-result {
    background: var(--success-bg);
    border: 1px solid var(--success);
    border-radius: var(--radius);
    padding: 1rem;
    margin-top: 1rem;
}

.modal-result h3 {
    color: var(--success);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.modal-error {
    background: var(--error-bg);
    border: 1px solid var(--error);
    border-radius: var(--radius);
    padding: 1rem;
    margin-top: 1rem;
}

.modal-error h3 {
    color: var(--error);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

/* Warning Text */
.warning-text {
    color: var(--error);
    font-weight: 500;
}

/* Danger Button */
.btn-danger {
    background: var(--error);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

/* Disabled button states */
.btn:disabled,
.btn-danger:disabled,
.btn-primary:disabled,
.btn-secondary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* Config Tabs */
.config-tabs {
    display: flex;
    gap: 0.25rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1.5rem;
}

.config-tab {
    padding: 0.75rem 1.25rem;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.15s;
}

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

.config-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.config-tab-content {
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.config-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border);
}

.config-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.config-section h3 {
    font-size: 0.9375rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.config-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding-top: 1rem;
}

/* Form Enhancements */
.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-input-color {
    width: 60px;
    height: 36px;
    padding: 2px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
}

.radio-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
}

/* Image Grid */
.image-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.image-upload-box {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem;
    text-align: center;
    background: var(--bg-secondary);
}

.image-upload-box label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.image-preview {
    max-width: 100%;
    max-height: 80px;
    border-radius: var(--radius);
    margin-bottom: 0.5rem;
}

.image-upload-box input[type="file"] {
    font-size: 0.75rem;
    width: 100%;
}

/* Status Grid */
.status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.status-item {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.status-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius);
    font-size: 0.75rem;
    font-weight: 500;
}

.status-badge.success {
    background: var(--success-bg);
    color: var(--success);
}

.status-badge.warning {
    background: var(--warning-bg);
    color: var(--warning);
}

.status-badge.error {
    background: var(--error-bg);
    color: var(--error);
}

.status-badge.status-green {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

.status-badge.status-red {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

.status-badge.status-gray {
    background: rgba(107, 114, 128, 0.15);
    color: #6b7280;
}

/* Toast Notifications */
.toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    padding: 0.875rem 1.25rem;
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 500;
    box-shadow: var(--shadow-md);
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 2000;
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

.toast-success {
    background: var(--success);
    color: white;
}

.toast-error {
    background: var(--error);
    color: white;
}

/* Brochure Card Visit Link */
.brochure-card-visit {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius);
    transition: background 0.15s;
}

.brochure-card-visit:hover {
    background: var(--primary-light);
}

/* Live Site Link - Top Right of Card */
.brochure-card-live-link {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    text-decoration: none;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.2s ease;
    z-index: 10;
}

.brochure-card-live-link:hover {
    background: #0056b3;
    transform: scale(1.1);
}

/* Mobile touch support for live link */
@media (hover: none) and (pointer: coarse) {
    .brochure-card-live-link {
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    .brochure-card-live-link:active {
        background: #0056b3;
        transform: scale(0.95);
    }
}

/* Ensure touch targets are large enough on mobile */
@media (max-width: 768px) {
    .brochure-card {
        -webkit-tap-highlight-color: transparent;
    }

    .brochure-card-live-link {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }
}

/* Console Home Logo Link */
.top-nav-logo {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    transition: opacity 0.2s;
}

.top-nav-logo:hover {
    opacity: 0.8;
}

/* Match console top nav to data admin blue gradient */
.top-nav {
    background: linear-gradient(135deg, #6366F1 0%, #8B5CF6 100%) !important;
    border-bottom: none !important;
}

/* Breadcrumb for level 2 sections */
.top-nav-breadcrumb {
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.125rem;
    font-weight: 400;
    margin-left: 0.5rem;
}
        /* Login Screen */
        .login-screen {
            width: 100%;
            min-height: 100vh;
            display: flex;
            align-items: center;
            justify-content: center;
            background: linear-gradient(135deg, #6366F1 0%, #8B5CF6 100%);
            padding: 1rem;
        }

        .login-card {
            border: none;
            box-sizing: border-box;
            background: #FFFFFF;
            border-radius: 1rem;
            box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1);
            padding: 0.375rem 1.5rem 2rem 1.5rem;
            width: 100%;
            max-width: 380px;
        }

        .login-card__title {
            text-align: center;
            font-size: 2rem;
            font-weight: 600;
            color: #1F2937;
            margin-bottom: 0.25rem;
        }

        .login-card__subtitle {
            text-align: center;
            color: #6B7280;
            font-size: 0.875rem;
            margin-bottom: 2rem;
        }

        .login-card__error {
            background: #FEE2E2;
            border: 1px solid #EF4444;
            color: #991B1B;
            padding: 0.75rem 1rem;
            border-radius: 0.5rem;
            font-size: 0.875rem;
            margin-bottom: 1rem;
            display: none;
        }

        .login-card__error.show {
            display: block;
        }

        .login-card .form-group {
            margin-bottom: 1.25rem;
            text-align: left;
        }

        .login-card .form-group label {
            display: block;
            font-size: 0.8125rem;
            font-weight: 500;
            color: #475569;
            margin-bottom: 0.375rem;
        }

        .login-card .input,
        .login-card input[type="email"],
        .login-card input[type="password"] {
            width: 240px;
            max-width: 100%;
            padding: 0.625rem 0.875rem;
            font-size: 0.9375rem;
            border: 1px solid #e2e8f0;
            border-radius: 8px;
            background: #ffffff;
            transition: border-color 0.15s, box-shadow 0.15s;
        }

        .login-card .input:focus,
        .login-card input[type="email"]:focus,
        .login-card input[type="password"]:focus {
            outline: none;
            border-color: #6366F1;
            box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
        }

        .login-card .btn--primary,
        .login-card button[type="submit"] {
            width: 240px;
            max-width: 100%;
            padding: 0.625rem 1rem;
            font-size: 0.875rem;
            font-weight: 500;
            background: #6366F1;
            color: white;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            transition: background 0.15s;
            margin-top: 0.5rem;
        }

        .login-card .btn--primary:hover,
        .login-card button[type="submit"]:hover {
            background: #4F46E5;
        }

        .login-card__footer {
            text-align: center;
            margin-top: 1.5rem;
            font-size: 0.75rem;
            color: #9CA3AF;
        }

        .app-container {
            display: none;
        }

        .app-container.authenticated {
            display: block;
        }

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

        /* User menu in header */
        .header__user {
            display: flex;
            align-items: center;
            gap: 1rem;
        }

        .header__user-info {
            text-align: right;
            font-size: 0.875rem;
        }

        .header__user-email {
            opacity: 0.9;
        }

        .header__logout {
            background: rgba(255,255,255,0.15);
            border: 1px solid rgba(255,255,255,0.3);
            color: white;
            padding: 0.5rem 1rem;
            border-radius: var(--ds-radius-md);
            cursor: pointer;
            font-size: 0.875rem;
            transition: all 0.15s ease;
        }

        .header__logout:hover {
            background: rgba(255,255,255,0.25);
        }

        /* ========== TLD List Panel Styles ========== */
        .tld-list-panel {
            position: fixed;
            top: 0;
            right: -420px;
            width: 400px;
            height: 100vh;
            background: var(--ds-bg);
            box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15);
            z-index: 1100;
            display: flex;
            flex-direction: column;
            transition: right 0.3s ease;
        }

        .tld-list-panel.open {
            right: 0;
        }

        .tld-list-panel__backdrop {
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.3);
            z-index: 1099;
            opacity: 0;
            visibility: hidden;
            transition: opacity 0.3s ease, visibility 0.3s ease;
        }

        .tld-list-panel__backdrop.open {
            opacity: 1;
            visibility: visible;
        }

        .tld-list-panel__header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 1rem 1.25rem;
            border-bottom: 1px solid var(--ds-border);
            background: linear-gradient(135deg, var(--ds-primary) 0%, var(--ds-secondary) 100%);
            color: white;
        }

        .tld-list-panel__header h3 {
            font-size: 1.125rem;
            font-weight: 600;
            margin: 0;
        }

        .tld-list-panel__close {
            background: rgba(255, 255, 255, 0.2);
            border: none;
            color: white;
            font-size: 1.5rem;
            width: 32px;
            height: 32px;
            border-radius: var(--ds-radius);
            cursor: pointer;
            line-height: 1;
        }

        .tld-list-panel__close:hover {
            background: rgba(255, 255, 255, 0.3);
        }

        .tld-list-panel__stats {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 0.75rem 1.25rem;
            background: var(--ds-surface);
            border-bottom: 1px solid var(--ds-border);
            font-size: 0.875rem;
        }

        .login-card form {
            border: none;
            padding: 0;
            margin: 0;
        }

/* Force login screen centering - override any conflicts */
body.login-page .login-screen {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 1rem !important;
}

/* ===== USEFUL INFO PANEL ===== */
.info-section {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.info-section h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.info-section > p {
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
    font-size: 0.875rem;
}

.info-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.info-table thead {
    background: var(--bg-primary);
}

.info-table th {
    text-align: left;
    padding: 0.75rem 1rem;
    font-weight: 600;
    color: var(--text-primary);
    border-bottom: 2px solid var(--border);
}

.info-table td {
    padding: 0.75rem 1rem;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

.info-table tbody tr:last-child td {
    border-bottom: none;
}

.info-table tbody tr:hover {
    background: var(--bg-primary);
}

.info-table td:first-child {
    width: 80px;
    text-align: center;
}

.info-table td:nth-child(2) {
    width: 150px;
    font-weight: 500;
    color: var(--text-primary);
}

.info-table .status-dot {
    width: 12px;
    height: 12px;
}

.info-table .wip-badge {
    font-size: 0.625rem;
}

/* ===== DOMAIN CLOUD VISUALIZATION ===== */
.domain-cloud-section {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.domain-cloud-header {
    margin-bottom: 1rem;
}

.domain-cloud-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

.domain-cloud-header p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.domain-cloud-wrapper {
    background: #000000;
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 1rem;
    position: relative;
    transition: background 0.3s ease;
    min-height: calc(100vh - 200px);
    height: calc(100vh - 200px);
}

/* Theme: Night (default) - pure black background */
.domain-cloud-wrapper.theme-night {
    background: #000000 !important;
}

/* Theme: Day - white background, black text */
.domain-cloud-wrapper.theme-day {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 50%, #ffffff 100%) !important;
}

.domain-cloud-wrapper.fullscreen,
.domain-cloud-wrapper:fullscreen,
.domain-cloud-wrapper:-webkit-full-screen {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    z-index: 9999;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 0;
    background: #000000;
}

.domain-cloud-wrapper.fullscreen #domain-cloud-container,
.domain-cloud-wrapper:fullscreen #domain-cloud-container,
.domain-cloud-wrapper:-webkit-full-screen #domain-cloud-container {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
}

.cloud-fullscreen-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 10;
}

.cloud-fullscreen-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}

.domain-cloud-wrapper.fullscreen .cloud-fullscreen-btn {
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    font-size: 24px;
}

#domain-cloud-container {
    width: 100%;
    height: 100%;
    min-height: 100%;
    position: relative;
}

.domain-cloud-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    align-items: center;
}

.cloud-mode-selector,
.cloud-source-selector,
.cloud-size-selector,
.cloud-movement-selector,
.cloud-addnew-selector,
.cloud-spawn-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cloud-size-selector input[type="range"] {
    width: 80px;
    cursor: pointer;
}

.cloud-size-selector #cloudFontSizeLabel {
    min-width: 2.5rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.control-label {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.cloud-mode-btn,
.cloud-source-btn,
.cloud-theme-btn,
.cloud-movement-btn,
.cloud-addnew-btn,
.cloud-spawn-btn,
.cloud-clickbuy-btn,
.cloud-network-btn,
.cloud-overlay-btn,
.cloud-overlay-mode-btn {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 0.375rem 0.75rem;
    border-radius: var(--radius);
    font-size: 0.8125rem;
    cursor: pointer;
    transition: all 0.15s;
}

.cloud-mode-btn:hover,
.cloud-source-btn:hover,
.cloud-theme-btn:hover,
.cloud-movement-btn:hover,
.cloud-addnew-btn:hover,
.cloud-spawn-btn:hover,
.cloud-clickbuy-btn:hover,
.cloud-network-btn:hover,
.cloud-overlay-btn:hover,
.cloud-overlay-mode-btn:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--border-hover);
}

.cloud-mode-btn.active,
.cloud-source-btn.active,
.cloud-theme-btn.active,
.cloud-movement-btn.active,
.cloud-addnew-btn.active,
.cloud-spawn-btn.active,
.cloud-clickbuy-btn.active,
.cloud-network-btn.active,
.cloud-overlay-btn.active,
.cloud-overlay-mode-btn.active,
.cloud-linecolor-btn.active {
    background: #3b82f6;
    border-color: #3b82f6;
    color: white;
}

.cloud-clickbuy-selector,
.cloud-network-selector,
.cloud-overlay-selector,
.cloud-overlay-mode-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cloud-theme-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cloud-reset-selector {
    margin-left: auto;
}

.cloud-reset-btn {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
    padding: 0.375rem 0.75rem;
    border-radius: 6px;
    font-size: 0.6875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cloud-reset-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #fca5a5;
    border-color: rgba(239, 68, 68, 0.5);
}

/* ===== UNIVERSE CONTROLLER ===== */
.universe-controller {
    background: linear-gradient(135deg, #0d1117 0%, #161b22 100%);
    border: 1px solid rgba(84, 213, 7, 0.3);
    border-radius: 16px;
    overflow: hidden;
    width: 100%;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(84, 213, 7, 0.05);
}

.universe-controller-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    background: linear-gradient(180deg, rgba(84, 213, 7, 0.1) 0%, rgba(84, 213, 7, 0.02) 100%);
    border-bottom: 1px solid rgba(84, 213, 7, 0.2);
}

.universe-controller-header h3 {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #54D507;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.universe-controller-header h3::before {
    content: '👽';
    font-size: 1rem;
}

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

.controller-grid {
    display: grid !important;
    grid-template-columns: repeat(5, 1fr) !important;
    gap: 1rem;
    padding: 1rem;
    background: transparent;
}

@media (max-width: 1400px) {
    .controller-grid {
        grid-template-columns: repeat(4, 1fr) !important;
    }
}

@media (max-width: 1100px) {
    .controller-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 800px) {
    .controller-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 500px) {
    .controller-grid {
        grid-template-columns: 1fr !important;
    }
}

.control-group {
    background: rgba(0, 0, 0, 0.3);
    padding: 0.75rem;
    min-width: 0;
    border-radius: 12px;
    border: 1px solid rgba(84, 213, 7, 0.25);
    transition: all 0.2s ease;
    overflow: hidden;
}

.control-group:hover {
    background: rgba(0, 0, 0, 0.4);
    border-color: rgba(84, 213, 7, 0.5);
}

.control-group-title {
    font-size: 0.6875rem;
    font-weight: 700;
    color: #54D507;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.875rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(84, 213, 7, 0.2);
}

.control-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-bottom: 0.5rem;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.control-row:last-child {
    margin-bottom: 0;
}

.control-row .control-label {
    font-size: 0.625rem;
    color: #ffffff;
    font-weight: 500;
    min-width: 50px;
    flex-shrink: 0;
}

.control-buttons {
    display: flex;
    gap: 0.25rem;
    flex-wrap: wrap;
}

/* Universe controller buttons - alien green theme */
.universe-controller .control-buttons button {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    font-size: 0.6875rem;
    cursor: pointer;
    transition: all 0.15s ease;
}

.universe-controller .control-buttons button:hover {
    background: rgba(84, 213, 7, 0.15);
    color: #ffffff;
    border-color: rgba(84, 213, 7, 0.4);
}

.universe-controller .control-buttons button.active {
    background: #54D507;
    border-color: #54D507;
    color: #000000;
    font-weight: 600;
    box-shadow: 0 0 12px rgba(84, 213, 7, 0.5);
}

.control-slider {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
}

/* Custom range slider for dark theme */
.universe-controller .control-slider input[type="range"] {
    flex: 1;
    min-width: 50px;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    outline: none;
}

.universe-controller .control-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    background: #54D507;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 8px rgba(84, 213, 7, 0.5);
}

.universe-controller .control-slider input[type="range"]::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: #54D507;
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: 0 0 8px rgba(84, 213, 7, 0.5);
}

.control-slider span {
    font-size: 0.6875rem;
    color: #ffffff;
    min-width: 35px;
    text-align: right;
    font-family: 'SF Mono', 'Monaco', monospace;
}

.control-input {
    flex: 1;
}

.universe-controller .control-input input[type="text"] {
    width: 100%;
    padding: 0.375rem 0.5rem;
    font-size: 0.6875rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    color: #e2e8f0;
}

.universe-controller .control-input input[type="text"]:focus {
    outline: none;
    border-color: #54D507;
    box-shadow: 0 0 0 2px rgba(84, 213, 7, 0.2);
}

.universe-controller .control-input input[type="text"]::placeholder {
    color: #475569;
}

/* Alien decoration in Interaction panel */
.alien-decoration {
    text-align: center;
    margin-top: 1rem;
    animation: alienGlow 2s ease-in-out infinite;
}

.alien-decoration img {
    width: 80px;
    height: 80px;
    filter: drop-shadow(0 0 15px rgba(84, 213, 7, 0.5));
}

@keyframes alienGlow {
    0%, 100% {
        filter: drop-shadow(0 0 10px rgba(84, 213, 7, 0.4));
        transform: scale(1);
    }
    50% {
        filter: drop-shadow(0 0 20px rgba(84, 213, 7, 0.7));
        transform: scale(1.03);
    }
}

/* Powered By Badge */
.powered-by-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding-bottom: 1rem;
}

.powered-by-group .alien-decoration {
    margin-bottom: 1rem;
}

.powered-by-badge {
    text-align: center;
}

.powered-by-text {
    display: block;
    font-size: 0.625rem;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
}

.powered-by-brand {
    display: block;
    font-size: 1rem;
    font-weight: 600;
    color: #54D507;
    text-shadow: 0 0 10px rgba(84, 213, 7, 0.4);
}

/* Overlay text buttons */
.cloud-overlay-text-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.6875rem;
    cursor: pointer;
    transition: all 0.15s;
}

.cloud-overlay-text-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
    border-color: rgba(255, 255, 255, 0.2);
}

.cloud-overlay-text-btn.active {
    background: #3b82f6;
    border-color: #3b82f6;
    color: white;
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.4);
}

/* Preset buttons - stacked vertically with radio style */
.preset-buttons {
    flex-direction: column;
    width: 100%;
    gap: 0.375rem !important;
}

.preset-buttons .cloud-mode-btn {
    width: 100%;
    padding: 0.625rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #94a3b8;
    border-radius: 8px;
    transition: all 0.15s ease;
}

.preset-buttons .cloud-mode-btn::before {
    content: '';
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
    transition: all 0.15s ease;
}

.preset-buttons .cloud-mode-btn:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(59, 130, 246, 0.3);
    color: #e2e8f0;
}

.preset-buttons .cloud-mode-btn.active {
    background: rgba(59, 130, 246, 0.15);
    border-color: #3b82f6;
    color: #e2e8f0;
}

.preset-buttons .cloud-mode-btn.active::before {
    background: #3b82f6;
    border-color: #3b82f6;
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.6);
}

/* Green active state for "On" toggles */
.cloud-network-btn.active[data-enabled="true"],
.cloud-overlay-btn.active[data-enabled="true"],
.cloud-addnew-btn.active[data-enabled="true"],
.cloud-clickbuy-btn.active[data-enabled="true"] {
    background: rgba(34, 197, 94, 0.2) !important;
    border-color: #22c55e !important;
    color: #22c55e !important;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.3);
}

/* Red active state for "Off" toggles */
.cloud-network-btn.active[data-enabled="false"],
.cloud-overlay-btn.active[data-enabled="false"],
.cloud-addnew-btn.active[data-enabled="false"],
.cloud-clickbuy-btn.active[data-enabled="false"] {
    background: rgba(239, 68, 68, 0.2) !important;
    border-color: #ef4444 !important;
    color: #ef4444 !important;
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.3);
}

/* Line color buttons */
.cloud-linecolor-btn.active[data-color="green"] {
    background: rgba(34, 197, 94, 0.2) !important;
    border-color: #22c55e !important;
    color: #22c55e !important;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.3);
}

.cloud-linecolor-btn.active[data-color="red"] {
    background: rgba(239, 68, 68, 0.2) !important;
    border-color: #ef4444 !important;
    color: #ef4444 !important;
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.3);
}

/* Responsive adjustments for control rows */
@media (max-width: 768px) {
    .control-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .control-buttons,
    .control-slider,
    .control-input {
        width: 100%;
    }
}

/* Home Stats Grid */
.home-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.stat-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    text-align: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: #8b5cf6;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

@media (max-width: 768px) {
    #domain-cloud-container {
        height: 300px;
    }

    .domain-cloud-controls {
        flex-direction: column;
        align-items: flex-start;
    }

    .home-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===== ENDPOINT OVERVIEW ===== */
.endpoint-overview {
    max-width: 900px;
    margin-bottom: 2rem;
}

.endpoint-overview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.endpoint-overview-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Stats Cards */
.endpoint-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.endpoint-stat-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius);
    padding: 1rem;
    text-align: center;
}

.endpoint-stat-card.error .endpoint-stat-value {
    color: #ef4444;
}

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

.endpoint-stat-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.25rem;
}

/* Endpoint Table */
.endpoint-table-container {
    background: var(--bg-primary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.endpoint-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}

.endpoint-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border);
}

.endpoint-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

.endpoint-table tbody tr:hover {
    background: var(--bg-secondary);
}

.endpoint-table tbody tr:last-child td {
    border-bottom: none;
}

.endpoint-th-actions {
    width: 100px;
    text-align: right;
}

/* Endpoint Status Badge */
.endpoint-status {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
}

.endpoint-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.endpoint-status-dot.active { background: #22c55e; }
.endpoint-status-dot.inactive { background: #9ca3af; }
.endpoint-status-dot.error { background: #ef4444; }
.endpoint-status-dot.pending { background: #f59e0b; }

/* Sync Mode Badge */
.endpoint-mode {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    font-size: 0.6875rem;
    font-weight: 500;
    border-radius: 999px;
    text-transform: uppercase;
}

.endpoint-mode.pull { background: #dbeafe; color: #1d4ed8; }
.endpoint-mode.push { background: #dcfce7; color: #15803d; }
.endpoint-mode.manual { background: #f3f4f6; color: #6b7280; }

/* Action Buttons */
.endpoint-actions {
    display: flex;
    gap: 0.375rem;
    justify-content: flex-end;
}

.endpoint-action-btn {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    color: var(--text-muted);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s;
}

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

.endpoint-action-btn.sync:hover {
    background: #dbeafe;
    color: #1d4ed8;
}

.endpoint-action-btn svg {
    width: 14px !important;
    height: 14px !important;
}

.endpoint-empty-row td {
    text-align: center;
    padding: 2rem;
    color: var(--text-muted);
}

/* Content Browser Section Header */
.content-browser-section {
    max-width: 900px;
    margin-bottom: 1rem;
}

.content-browser-section h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

@media (max-width: 768px) {
    .endpoint-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===== S3 MANAGER ===== */
.s3-manager-container {
    display: flex;
    flex-direction: column;
    gap: 0;
    max-width: 900px;
    background: var(--bg-primary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

/* Prevent SVG overflow in S3 Manager */
.s3-manager-container svg {
    max-width: 48px !important;
    max-height: 48px !important;
}

.s3-toolbar svg {
    max-width: 14px !important;
    max-height: 14px !important;
}

/* Toolbar */
.s3-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
}

.s3-toolbar-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.s3-toolbar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.s3-select {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.8125rem;
    min-width: 200px;
    cursor: pointer;
}

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

.s3-search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.s3-search-icon {
    position: absolute;
    left: 10px;
    width: 14px !important;
    height: 14px !important;
    max-width: 14px !important;
    max-height: 14px !important;
    min-width: 14px;
    min-height: 14px;
    color: var(--text-muted);
    pointer-events: none;
}

.s3-search-input {
    padding: 0.5rem 0.75rem 0.5rem 32px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.8125rem;
    width: 220px;
}

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

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

.s3-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 0.75rem;
    border: none;
    border-radius: 6px;
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
}

.s3-btn svg {
    width: 14px;
    height: 14px;
}

.s3-btn-secondary {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    color: var(--text-secondary);
}

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

.s3-btn-primary {
    background: var(--primary);
    color: white;
}

.s3-btn-primary:hover {
    background: #1d4ed8;
}

.s3-btn-primary:disabled {
    background: var(--text-muted);
    cursor: not-allowed;
}

/* Table */
.s3-table-container {
    background: var(--bg-primary);
    overflow: hidden;
    max-height: 500px;
    overflow-y: auto;
}

.s3-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.s3-table thead {
    position: sticky;
    top: 0;
    z-index: 1;
}

.s3-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--text-secondary);
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-card);
}

.s3-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
    color: var(--text-primary);
}

.s3-table tbody tr:hover {
    background: var(--bg-secondary);
}

.s3-table tbody tr:last-child td {
    border-bottom: none;
}

.s3-th-preview { width: 56px; }
.s3-th-name { min-width: 200px; }
.s3-th-size { width: 100px; }
.s3-th-modified { width: 140px; }
.s3-th-actions { width: 120px; text-align: right; }

/* S3 Footer / Stats Bar */
.s3-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1.25rem;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.s3-footer-stats {
    display: flex;
    gap: 1.5rem;
}

.s3-footer-stat {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.s3-footer-stat strong {
    color: var(--text-primary);
    font-weight: 600;
}

.s3-footer-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-style: italic;
}

/* Thumbnail */
.s3-thumbnail {
    width: 40px !important;
    height: 40px !important;
    max-width: 40px !important;
    max-height: 40px !important;
    border-radius: 4px;
    object-fit: cover;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
}

.s3-thumbnail-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

/* File name cell */
.s3-file-name {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
    overflow: hidden;
}

.s3-file-name-main {
    font-weight: 500;
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.s3-file-name-type {
    font-size: 0.6875rem;
    color: var(--text-muted);
    text-transform: uppercase;
}

.s3-file-size {
    color: var(--text-secondary);
    font-family: 'SF Mono', Monaco, monospace;
    font-size: 0.75rem;
}

.s3-file-date {
    color: var(--text-muted);
    font-size: 0.75rem;
}

/* Actions */
.s3-actions-cell {
    display: flex;
    gap: 0.25rem;
    justify-content: flex-end;
}

.s3-action-btn {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 4px;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.15s;
}

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

.s3-action-btn.delete:hover {
    background: #fee2e2;
    color: #dc2626;
}

.s3-action-btn svg {
    width: 14px !important;
    height: 14px !important;
    max-width: 14px !important;
    max-height: 14px !important;
}

/* Empty state */
.s3-empty-row td {
    padding: 0;
}

.s3-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    color: var(--text-muted);
    text-align: center;
}

.s3-empty-state svg {
    width: 48px !important;
    height: 48px !important;
    max-width: 48px !important;
    max-height: 48px !important;
    min-width: 48px;
    min-height: 48px;
    opacity: 0.3;
    margin-bottom: 1rem;
}

.s3-empty-state p {
    font-size: 0.875rem;
}

.s3-loading {
    padding: 2rem;
    text-align: center;
    color: var(--text-secondary);
}

.s3-error {
    padding: 1rem;
    background: #fef2f2;
    color: #dc2626;
    border-radius: 6px;
    margin: 1rem;
    font-size: 0.875rem;
}

/* Footer */
.s3-footer {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    font-size: 0.75rem;
    color: var(--text-muted);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-card);
    border-top: none;
    border-radius: 0 0 8px 8px;
}

.s3-footer-divider {
    opacity: 0.5;
}

/* Sortable columns */
.s3-sortable {
    cursor: pointer;
    user-select: none;
    transition: color 0.15s;
}

.s3-sortable:hover {
    color: var(--text-primary);
}

.s3-sort-icon {
    display: inline-flex;
    flex-direction: column;
    margin-left: 6px;
    font-size: 0.5rem;
    line-height: 1;
    vertical-align: middle;
    opacity: 0.4;
}

.s3-sort-icon::before {
    content: '▲';
}

.s3-sort-icon::after {
    content: '▼';
    margin-top: -2px;
}

.s3-sortable.sorted-asc .s3-sort-icon::before {
    opacity: 1;
    color: var(--primary);
}

.s3-sortable.sorted-asc .s3-sort-icon::after {
    opacity: 0.3;
}

.s3-sortable.sorted-asc .s3-sort-icon,
.s3-sortable.sorted-desc .s3-sort-icon {
    opacity: 1;
}

.s3-sortable.sorted-desc .s3-sort-icon::before {
    opacity: 0.3;
}

.s3-sortable.sorted-desc .s3-sort-icon::after {
    opacity: 1;
    color: var(--primary);
}

/* S3 Preview Panel */
.s3-preview-panel {
    position: fixed;
    bottom: 0;
    right: 0;
    width: 500px;
    max-height: 60vh;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius) var(--radius) 0 0;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    overflow: hidden;
}

.s3-preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border);
}

.s3-preview-header h3 {
    font-size: 0.875rem;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin: 0;
}

.s3-preview-content {
    padding: 1rem;
    max-height: calc(60vh - 60px);
    overflow: auto;
}

/* S3 Upload Dropzone */
.s3-upload-dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 2rem;
    border: 2px dashed var(--border);
    border-radius: var(--radius);
    background: var(--bg-secondary);
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.s3-upload-dropzone:hover,
.s3-upload-dropzone.dragover {
    border-color: var(--primary);
    background: var(--bg-tertiary);
}

.s3-upload-dropzone p {
    margin: 0;
    color: var(--text-secondary);
}

.s3-upload-dropzone a {
    color: var(--primary);
    text-decoration: none;
}

.s3-upload-dropzone a:hover {
    text-decoration: underline;
}

/* Extra small button variant */
.btn-xs {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
}

@media (max-width: 768px) {
    .s3-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .s3-domain-selector {
        flex-direction: column;
        align-items: stretch;
    }

    .s3-domain-selector select {
        min-width: 100%;
    }

    .s3-files-header,
    .s3-file-row {
        grid-template-columns: 1fr 60px 60px;
    }

    .s3-col-modified,
    .s3-col-actions {
        display: none;
    }

    .s3-preview-panel {
        width: 100%;
        left: 0;
    }
}

/* =============================================================================
   DATA.SHOPNET DASHBOARD STYLES
   Styles for the integrated data.shopnet RDS admin panels
   Added: January 22, 2026
   ============================================================================= */

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

/* Dashboard Sections */
.dashboard-section {
    background: var(--ds-bg);
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius-xl);
    margin-bottom: 1.5rem;
}

.dashboard-section__header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--ds-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.dashboard-section__title {
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dashboard-section__body {
    padding: 1.5rem;
}

/* Dashboard Meta (Last Updated) */
.dashboard-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    color: var(--ds-text-muted);
    font-size: 0.875rem;
}

/* Progress Bar */
.progress-bar {
    height: 8px;
    background: var(--ds-surface);
    border-radius: 4px;
    overflow: hidden;
    flex: 1;
}

.progress-bar__fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
}

.progress-bar__fill--primary { background: var(--ds-primary); }
.progress-bar__fill--success { background: var(--ds-success); }
.progress-bar__fill--warning { background: var(--ds-warning); }
.progress-bar__fill--danger { background: var(--ds-danger); }

/* Group Breakdown Row */
.group-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--ds-border);
}

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

.group-row__name {
    width: 100px;
    font-weight: 500;
}

.group-row__count {
    width: 80px;
    text-align: right;
    font-weight: 600;
}

.group-row__percent {
    width: 60px;
    text-align: right;
    color: var(--ds-text-muted);
    font-size: 0.875rem;
}

.group-row--clickable {
    cursor: pointer;
    transition: background 0.15s ease;
}

.group-row--clickable:hover {
    background: var(--ds-primary-light);
}

/* Characteristic Grid */
.char-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.char-item {
    background: var(--ds-surface);
    padding: 1rem;
    border-radius: var(--ds-radius-md);
}

.char-item__label {
    font-size: 0.75rem;
    color: var(--ds-text-muted);
    margin-bottom: 0.25rem;
}

.char-item__value {
    font-size: 1.25rem;
    font-weight: 600;
}

.char-item__percent {
    font-size: 0.875rem;
    color: var(--ds-text-light);
}

/* Quality Score */
.quality-score {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.quality-score__circle {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--ds-primary) 0%, var(--ds-secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.75rem;
    font-weight: 700;
}

.check-pass { color: var(--ds-success); }
.check-fail { color: var(--ds-danger); }

/* Stats Table (Categories Overview, etc.) */
.stats-table {
    width: 100%;
}

.stats-table th {
    text-align: left;
    padding: 0.75rem;
    background: var(--ds-surface);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--ds-text-muted);
    text-transform: uppercase;
}

.stats-table td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--ds-border);
}

.stats-table td.value {
    font-weight: 600;
    text-align: right;
}

.stats-table td.status {
    text-align: center;
}

/* Character Types Table */
.char-types-container {
    margin-bottom: 1rem;
}

.char-types-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.char-types-table th,
.char-types-table td {
    padding: 0.5rem 0.25rem;
    text-align: center;
    border: 1px solid var(--ds-border);
    font-size: 0.8rem;
}

.char-types-header {
    background: var(--ds-surface);
    font-weight: 600;
    font-size: 0.65rem;
    color: var(--ds-text-muted);
    white-space: nowrap;
}

.char-types-cell {
    vertical-align: middle;
    background: var(--ds-bg);
}

.char-types-cell--total {
    background: var(--ds-surface);
    font-weight: 600;
}

.char-types-cell--clickable {
    cursor: pointer;
    transition: background 0.15s ease;
}

.char-types-cell--clickable:hover {
    background: var(--ds-primary-light);
}

.char-types-icon {
    display: block;
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
}

.char-types-count {
    display: block;
    font-weight: 600;
    font-size: 1rem;
    color: var(--ds-text);
}

.char-types-percent {
    display: block;
    font-size: 0.75rem;
    color: var(--ds-text-muted);
}

.char-types-filter,
.cat-count-filter {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--ds-border);
}

.char-types-filter__label,
.cat-count-filter__label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--ds-text-muted);
    margin-bottom: 0.5rem;
}

.char-types-filter__options,
.cat-count-filter__options {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.char-types-checkbox,
.cat-count-checkbox {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    background: var(--ds-bg);
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius);
    cursor: pointer;
    font-size: 0.875rem;
    transition: all 0.15s ease;
}

.char-types-checkbox:hover,
.cat-count-checkbox:hover {
    border-color: var(--ds-primary);
    background: var(--ds-primary-light);
}

.char-types-checkbox input,
.cat-count-checkbox input {
    margin: 0;
    cursor: pointer;
}

.char-types-checkbox input:checked + span,
.cat-count-checkbox input:checked + span {
    color: var(--ds-primary);
    font-weight: 500;
}

/* =============================================================================
   TLD MANAGER STYLES
   Styles for TLD tables, filters, and bulk actions
   ============================================================================= */

/* Generic Table Styles for data.shopnet panels */
#panel-tlds table,
#panel-categories table,
#panel-dashboard table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

#panel-tlds th,
#panel-tlds td,
#panel-categories th,
#panel-categories td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--ds-border);
}

#panel-tlds th,
#panel-categories th {
    background: var(--ds-surface);
    font-weight: 600;
    color: var(--ds-text-light);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

#panel-tlds tr:hover td,
#panel-categories tr:hover td {
    background: var(--ds-surface);
}

/* TLD Search Tool */
.tld-search-tool {
    background: #E8F4FD;
    border: 1px solid #B8DCF5;
    border-radius: var(--ds-radius-md);
    padding: 1.25rem;
    margin-bottom: 1rem;
}

.tld-search-tool__header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    gap: 1rem;
}

.tld-search-tool__header {
    font-size: 1rem;
    font-weight: 600;
    color: var(--ds-text);
    margin: 0;
}

.tld-search-tool__header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.tld-search-tool__header-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tld-search-tool__header-control label {
    font-size: 0.85rem;
    color: var(--ds-text);
    white-space: nowrap;
}

.tld-search-tool__row {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.tld-search-tool__row:last-child {
    margin-bottom: 0;
}

.tld-search-tool__input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-width: 120px;
}

.tld-search-tool__input-group label {
    font-size: 0.813rem;
    font-weight: 500;
    color: var(--ds-text);
}

.tld-search-tool .input,
.tld-search-tool .select,
.tld-search-tool select {
    height: 38px;
    padding: 0.5rem 0.75rem;
    box-sizing: border-box;
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius);
    font-size: 0.875rem;
}

/* TLD Type Filter Buttons */
.tld-type-filters {
    display: flex;
    gap: 0.25rem;
    flex-wrap: wrap;
    align-items: center;
}

.tld-filter-btn {
    padding: 0.5rem 0.75rem;
    height: 38px;
    font-size: 0.813rem;
    font-weight: 500;
    border: 1px solid var(--ds-border);
    background: var(--ds-bg);
    border-radius: var(--ds-radius);
    cursor: pointer;
    transition: all 0.15s ease;
    color: var(--ds-text);
}

.tld-filter-btn:hover {
    border-color: var(--ds-primary);
    background: var(--ds-primary-light);
}

.tld-filter-btn--active {
    background: #818CF8;
    color: white;
    border-color: #818CF8;
}

.tld-filter-btn--active:hover {
    background: #6366F1;
    border-color: #6366F1;
}

/* Bulk Actions Bar */
.bulk-actions-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.bulk-actions-bar {
    background: var(--ds-primary-light);
    border: 1px solid var(--ds-primary);
    border-radius: var(--ds-radius-md);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    flex: 1;
}

.bulk-actions-bar span {
    font-weight: 600;
    color: var(--ds-primary);
}

/* Table Toolbar */
.table-toolbar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    margin-bottom: 0.5rem;
    border-bottom: 1px solid var(--ds-border);
}

.table-toolbar__info {
    margin-left: auto;
    font-size: 0.75rem;
    color: var(--ds-text-light);
}

/* Sortable Headers */
th.sortable {
    cursor: pointer;
    user-select: none;
}

th.sortable:hover {
    background: var(--ds-border);
}

th.sortable .sort-indicator {
    display: inline-block;
    margin-left: 4px;
    opacity: 0.3;
    font-size: 0.65rem;
}

th.sortable.sort-asc .sort-indicator,
th.sortable.sort-desc .sort-indicator {
    opacity: 1;
}

/* Table Row Selection */
.table-row--selectable {
    cursor: pointer;
}

.table-row--selectable:hover {
    background: var(--ds-surface);
}

.table-row--selected {
    background: var(--ds-primary-light) !important;
}

/* TLD Count Badge */
.tld-count {
    font-size: 0.938rem;
    font-weight: 600;
    color: var(--ds-text);
    padding: 0.5rem 1rem;
    background: var(--ds-primary-light);
    border-radius: var(--ds-radius);
}

/* =============================================================================
   GLOBAL TABLE STYLES FOR DATA.SHOPNET
   These apply to all tables within data.shopnet panels
   ============================================================================= */

#panel-tlds table,
#panel-categories table,
#panel-dashboard table,
#panel-tlds-search table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

#panel-tlds th, #panel-tlds td,
#panel-categories th, #panel-categories td,
#panel-tlds-search th, #panel-tlds-search td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--ds-border);
}

#panel-tlds th, #panel-categories th, #panel-tlds-search th {
    background: var(--ds-surface);
    font-weight: 600;
    color: var(--ds-text-light);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    position: sticky;
    top: 0;
}

#panel-tlds tr:hover td,
#panel-categories tr:hover td,
#panel-tlds-search tr:hover td {
    background: var(--ds-surface);
}

/* Table Wrapper */
.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius-md);
    background: var(--ds-bg);
}

.table-wrap--scrollable {
    overflow-x: auto;
    max-width: 100%;
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 9999px;
}

.badge--forsale { background: var(--ds-success-light); color: #065F46; }
.badge--hmcgown { background: var(--ds-primary-light); color: var(--ds-primary); }
.badge--tpbrands { background: var(--ds-warning-light); color: #92400E; }
.badge--test { background: #F3E8FF; color: #6B21A8; }
.badge--active { background: var(--ds-success-light); color: #065F46; }
.badge--inactive { background: var(--ds-danger-light); color: #991B1B; }

/* Pagination */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    border-top: 1px solid var(--ds-border);
}

.pagination__info {
    color: var(--ds-text-light);
    font-size: 0.875rem;
    margin: 0 1rem;
}

.pagination__btn {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--ds-border);
    background: var(--ds-bg);
    border-radius: var(--ds-radius);
    cursor: pointer;
    font-size: 0.875rem;
}

.pagination__btn:hover {
    background: var(--ds-surface);
    border-color: var(--ds-primary);
}

.pagination__btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Panel BEM Styles */
.panel__header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--ds-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.panel__title {
    font-size: 1.125rem;
    font-weight: 600;
}

.panel__actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.panel__body {
    padding: 1.5rem;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
}

.modal-overlay.active { display: flex; }

.modal {
    background: var(--ds-bg);
    border-radius: var(--ds-radius-xl);
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: var(--ds-shadow-lg);
}

.modal--lg { max-width: 800px; }
.modal--xl { max-width: 1100px; }

.modal__header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--ds-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal__title {
    font-size: 1.125rem;
    font-weight: 600;
}

.modal__close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--ds-text-muted);
    padding: 0.25rem;
}

.modal__close:hover {
    color: var(--ds-text);
}

.modal__body {
    padding: 1.5rem;
    overflow-y: auto;
    flex: 1;
}

.modal__footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--ds-border);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    background: var(--ds-surface);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: var(--ds-text-muted);
}

/* Loading Spinner */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 2rem;
    color: var(--ds-text-muted);
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--ds-border);
    border-top-color: var(--ds-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Text Utilities */
.text-muted { color: var(--ds-text-muted); }
.text-success { color: var(--ds-success); }
.text-danger { color: var(--ds-danger); }
.text-warning { color: var(--ds-warning); }

/* Truncate */
.truncate {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ===== RADIUS CONTROL PANEL ===== */

/* Status Grid */
.radius-status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.status-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius-lg);
    transition: box-shadow 0.2s, border-color 0.2s;
}

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

.status-card__icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--ds-primary-light);
    border-radius: var(--ds-radius-md);
    color: var(--ds-primary);
}

.status-card__icon svg {
    width: 20px;
    height: 20px;
}

.status-card__label {
    font-size: 0.75rem;
    color: var(--ds-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-card__value {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--ds-text);
}

/* Actions Section */
.radius-actions-section {
    margin-bottom: 2rem;
}

.section-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ds-text);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--ds-border);
}

.radius-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.action-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem 1rem;
    background: var(--ds-bg);
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius-lg);
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}

.action-card:hover {
    border-color: var(--ds-primary);
    box-shadow: var(--ds-shadow-md);
    transform: translateY(-2px);
}

.action-card--danger:hover {
    border-color: var(--ds-danger);
}

.action-card__icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--ds-radius-md);
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.action-card__icon svg {
    width: 24px;
    height: 24px;
}

.action-card__icon--create {
    background: var(--ds-success-light);
    color: var(--ds-success);
}

.action-card__icon--update {
    background: var(--ds-primary-light);
    color: var(--ds-primary);
}

.action-card__icon--infra {
    background: #FEF3C7;
    color: var(--ds-warning);
}

.action-card__icon--rebuild {
    background: #E0E7FF;
    color: #4F46E5;
}

.action-card__icon--health {
    background: #CCFBF1;
    color: #14B8A6;
}

.action-card__icon--delete {
    background: var(--ds-danger-light);
    color: var(--ds-danger);
}

.action-card__title {
    font-weight: 600;
    font-size: 0.9375rem;
    color: var(--ds-text);
    margin-bottom: 0.25rem;
}

.action-card__desc {
    font-size: 0.75rem;
    color: var(--ds-text-muted);
}

/* AI Assistant Section */
.radius-ai-section {
    margin-bottom: 2rem;
}

.ai-assistant-card {
    background: linear-gradient(135deg, #EEF2FF 0%, #E0E7FF 100%);
    border: 1px solid #C7D2FE;
    border-radius: var(--ds-radius-lg);
    overflow: hidden;
}

.ai-assistant-card__header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: rgba(99, 102, 241, 0.1);
    font-weight: 600;
    color: #4F46E5;
}

.ai-assistant-card__header .ai-icon {
    width: 24px;
    height: 24px;
}

.ai-assistant-card__body {
    padding: 1.25rem;
}

.ai-assistant-card__body p {
    color: var(--ds-text);
    margin-bottom: 0.75rem;
}

.ai-assistant-card__body ul {
    list-style: none;
    margin-bottom: 1rem;
}

.ai-assistant-card__body li {
    padding: 0.25rem 0;
    padding-left: 1.25rem;
    position: relative;
    color: var(--ds-text-light);
    font-size: 0.875rem;
}

.ai-assistant-card__body li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--ds-success);
}

/* Quick Links */
.radius-links-section {
    margin-bottom: 1rem;
}

.quick-links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.75rem;
}

.quick-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1rem;
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius-md);
    color: var(--ds-text);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.875rem;
}

.quick-link:hover {
    background: var(--ds-surface-hover);
    border-color: var(--ds-primary);
    color: var(--ds-primary);
}

.quick-link svg {
    width: 18px;
    height: 18px;
    opacity: 0.7;
}

/* Modules Status Grid */
.modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.module-card {
    padding: 1rem 1.25rem;
    background: var(--ds-bg);
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius-md);
    transition: border-color 0.2s;
}

.module-card:hover {
    border-color: var(--ds-primary);
}

.module-card--ai {
    background: linear-gradient(135deg, #FEF3C7 0%, #FDE68A 100%);
    border-color: #F59E0B;
}

.module-card__header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.module-status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.module-status-dot.grey { background: #9CA3AF; }
.module-status-dot.green { background: #10B981; }
.module-status-dot.yellow { background: #F59E0B; animation: pulse 1.5s infinite; }
.module-status-dot.red { background: #EF4444; }
.module-status-dot.blue { background: #3B82F6; animation: pulse 1.5s infinite; }

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

.module-name {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--ds-text);
    font-family: 'SF Mono', Monaco, monospace;
}

.module-card__desc {
    font-size: 0.75rem;
    color: var(--ds-text-muted);
    line-height: 1.4;
}

/* Workflow Progress */
.workflow-progress-section {
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius-lg);
    padding: 1.25rem;
    margin-bottom: 2rem;
}

.workflow-progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.workflow-progress-header h4 {
    font-size: 0.9375rem;
    color: var(--ds-text);
}

.workflow-progress-bar {
    height: 8px;
    background: var(--ds-border);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.workflow-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--ds-primary) 0%, var(--ds-secondary) 100%);
    border-radius: 4px;
    transition: width 0.5s ease;
}

.workflow-step-indicator {
    font-size: 0.75rem;
    color: var(--ds-text-muted);
    text-align: right;
}

/* Execution Log */
.execution-log-section h4 {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ds-text);
    margin-bottom: 0.75rem;
}

.execution-log {
    background: #1E293B;
    border-radius: var(--ds-radius-md);
    padding: 1rem;
    max-height: 300px;
    overflow-y: auto;
    font-family: 'SF Mono', Monaco, monospace;
    font-size: 0.8125rem;
}

.log-entry {
    padding: 0.25rem 0;
    color: #94A3B8;
}

.log-entry--info { color: #60A5FA; }
.log-entry--success { color: #34D399; }
.log-entry--warning { color: #FBBF24; }
.log-entry--error { color: #F87171; }
.log-entry--step { color: #A78BFA; }

/* ========================================
   UNIFIED CARD SYSTEM - THE LAW v3.1
   Network Cards (Type 1) + GitHub Cards (Type 2)
   ======================================== */

/* Card Grid Layout */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}

/* Base Unified Card */
.unified-card {
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    padding: 1rem;
    border: 1px solid var(--border);
    min-height: 160px;
    position: relative;
    display: flex;
    flex-direction: column;
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
    cursor: pointer;
}

.unified-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

/* Card Header */
.card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

/* Status Dot */
.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-dot.green { background: var(--success); }
.status-dot.orange { background: var(--warning); }
.status-dot.red { background: var(--error); }
.status-dot.grey { background: var(--text-muted); }
.status-dot.blue { background: var(--primary); }

/* Card ID Badge */
.card-id-badge {
    font-family: 'SF Mono', Monaco, monospace;
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 500;
}

/* Card Title */
.card-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Card Badges */
.card-badges {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.card-badge {
    font-size: 0.65rem;
    padding: 2px 6px;
    border-radius: 3px;
    font-weight: 600;
    color: white;
}

/* Card Description */
.card-description {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.4;
    flex-grow: 1;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Card Footer */
.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 8px;
    margin-top: auto;
    border-top: 1px solid var(--border);
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* Card External Link Button */
.card-link {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 14px;
    transition: background 0.2s;
}

.card-link:hover {
    background: var(--primary-hover);
}

/* ========================================
   NETWORK CARD SPECIFIC STYLES (Type 1)
   ======================================== */
.network-card .card-id-badge {
    background: #e0f2fe;
    color: #0369a1;
    border: 1px solid #bae6fd;
}

/* Endpoint Type Badges */
.network-card .badge-type-W { background: #3b82f6; }
.network-card .badge-type-A { background: #8b5cf6; }
.network-card .badge-type-D { background: #22c55e; }
.network-card .badge-type-ND { background: #f59e0b; }

/* Platform Type Badges */
.network-card .badge-platform-CO { background: #06b6d4; }
.network-card .badge-platform-CP { background: #8b5cf6; }
.network-card .badge-platform-WP { background: #0ea5e9; }
.network-card .badge-platform-WW { background: #7c3aed; }
.network-card .badge-platform-SH { background: #84cc16; }

/* Managed By Badges */
.network-card .badge-managed-L { background: #f59e0b; }
.network-card .badge-managed-R { background: #8b5cf6; }
.network-card .badge-managed-M { background: #6b7280; }

/* Status Text */
.network-card .status-text {
    text-transform: uppercase;
    font-weight: 600;
}

.network-card .status-text.online { color: var(--success); }
.network-card .status-text.wip { color: var(--warning); }
.network-card .status-text.planned { color: var(--text-muted); }
.network-card .status-text.offline { color: var(--error); }
.network-card .status-text.degraded { color: var(--warning); }

/* ========================================
   GITHUB CARD SPECIFIC STYLES (Type 2)
   ======================================== */
.github-card .card-id-badge {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

/* Module Type Badges */
.github-card .badge-type-template { background: #8b5cf6; }
.github-card .badge-type-plugin { background: #06b6d4; }
.github-card .badge-type-docs { background: #22c55e; }
.github-card .badge-type-config { background: #f59e0b; }
.github-card .badge-type-module { background: #3b82f6; }

/* GitHub Link Button */
.github-card .card-link {
    background: #24292e;
}

.github-card .card-link:hover {
    background: #444d56;
}

/* Commit Info */
.github-card .commit-info {
    display: flex;
    align-items: center;
    gap: 4px;
}

.github-card .commit-info svg {
    width: 12px;
    height: 12px;
}

/* Freshness Text */
.github-card .freshness-text {
    font-weight: 500;
}

.github-card .freshness-text.recent { color: var(--success); }
.github-card .freshness-text.active { color: var(--primary); }
.github-card .freshness-text.stable { color: var(--text-muted); }
.github-card .freshness-text.stale { color: var(--warning); }

/* ========================================
   RESPONSIVE CARD GRID
   ======================================== */
@media (max-width: 768px) {
    .card-grid {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 1200px) {
    .card-grid {
        grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    }
}

/* ========================================
   TEAM CARDS - Executive & Human Resources
   ======================================== */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.5rem;
    padding: 1rem 0;
}

.team-card {
    display: flex;
    gap: 0;
    padding: 0;
    background: var(--bg-primary);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    transition: all 0.2s ease;
    overflow: hidden;
}

.team-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: #8b5cf6;
}

.team-card.special.inactive {
    opacity: 0.7;
}

/* Team Avatar (fallback when no photo) */
.team-avatar {
    width: 120px;
    min-height: 100px;
    border-radius: 8px 0 0 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
    align-self: stretch;
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
}

/* C-Suite role colors */
.team-avatar.ceo { background: linear-gradient(135deg, #7c3aed, #4f46e5); }
.team-avatar.coo { background: linear-gradient(135deg, #2563eb, #0284c7); }
.team-avatar.cfo { background: linear-gradient(135deg, #059669, #0d9488); }
.team-avatar.cto { background: linear-gradient(135deg, #7c3aed, #9333ea); }
.team-avatar.cmo { background: linear-gradient(135deg, #db2777, #e11d48); }
.team-avatar.cro { background: linear-gradient(135deg, #ea580c, #d97706); }
.team-avatar.cio { background: linear-gradient(135deg, #0284c7, #0891b2); }
.team-avatar.crevo { background: linear-gradient(135deg, #16a34a, #059669); }

/* Human avatars */
.team-avatar.human-avatar {
    background: linear-gradient(135deg, #10b981, #14b8a6);
    border: 3px solid #d1fae5;
}

/* Special consultant avatars */
.team-avatar.alien-avatar {
    background: linear-gradient(135deg, #22c55e, #84cc16);
    font-size: 20px;
}

.team-avatar.slacker-avatar {
    background: linear-gradient(135deg, #6b7280, #9ca3af);
}

/* Team Info */
.team-info {
    flex: 1;
    min-width: 0;
    padding: 0.5rem 0.5rem 0.5rem 0.6rem;
}

.team-name {
    margin: 0 0 0.1rem 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
}

.team-title {
    display: block;
    font-size: 0.7rem;
    font-weight: 500;
    color: #8b5cf6;
    margin-bottom: 0.3rem;
}

.team-card.human .team-title {
    color: #10b981;
}

.team-card.special .team-title {
    color: #f59e0b;
}

.team-bio {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Team Bio List (bullet points) */
.team-bio-list {
    margin: 0;
    padding-left: 0.9rem;
    font-size: 0.68rem;
    color: var(--text-secondary);
    line-height: 1.35;
}

.team-bio-list li {
    margin-bottom: 0.1rem;
}

.team-bio-list li:last-child {
    margin-bottom: 0;
}

/* Claude clickable links */
.claude-link {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.claude-link:hover {
    color: #8b5cf6;
    text-decoration: underline;
}

/* Team Photo Avatars - Full height, left side */
.team-avatar-photo {
    width: 120px;
    height: 100%;
    min-height: 100px;
    border-radius: 8px 0 0 8px;
    object-fit: cover;
    object-position: center center;
    flex-shrink: 0;
    align-self: stretch;
}

.team-avatar-photo.mugshot {
    /* No filter - show image normally */
}

/* Responsive team grid */
@media (max-width: 768px) {
    .team-grid {
        grid-template-columns: 1fr;
    }

    .team-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .team-avatar {
        width: 80px;
        height: 80px;
        font-size: 28px;
    }
}
