:root {
    --bg-primary: #F9FAFB;
    --bg-secondary: #FFFFFF;
    --bg-tertiary: #F3F4F6;
    --text-primary: #1A1A1A;
    --text-secondary: #6B7280;
    --text-muted: #9CA3AF;
    --accent-green: #10B981;
    --accent-blue: #3B82F6;
    --accent-red: #EF4444;
    --accent-orange: #F59E0B;
    --accent-purple: #8B5CF6;
    --border-light: #E5E7EB;
    --border-medium: #D1D5DB;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --radius-md: 8px;
    --radius-lg: 12px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
}
h2 {
    margin-top: 20px;
}
.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* ===== NAVIGATION & BREADCRUMBS ===== */
.breadcrumb {
    margin-top: 10px;
    margin-bottom: 8px;
    color: var(--text-secondary);
    font-size: 14px;
}

.breadcrumb a {
    color: var(--accent-blue);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

/* ===== HEADERS ===== */
.header {
    backgroundX: var(--bg-secondary);
    padding: 24px;
    border-radiusX: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: 24px;
    text-align: center;
}

.header h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.header p {
    color: var(--text-secondary);
    font-size: 16px;
}

.card {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 24px;
    margin-bottom: 24px;
    
    /* Add these responsive properties */
    overflow-x: auto;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.card-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 0px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.log-output {
    background: #1a1a1a;
    color: #00ff00;
    padding: 16px;
    border-radius: var(--radius-md);
    font-family: 'Courier New', monospace;
    font-size: 12px;
    max-height: 400px;
    overflow-y: auto;
    white-space: pre-wrap;
}

/* ===== BUTTONS ===== */
.btn {
    padding: 12px 20px;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

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

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

.btn-primary:hover:not(:disabled) {
    background: #2563EB;
}

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

.btn-secondary:hover:not(:disabled) {
    background: var(--border-light);
}

.actions {
    display: flex;
    gap: 12px;
}
/* ===== STATUS INDICATORS ===== */
.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--text-muted);
}

.status-indicator.connected {
    background: var(--accent-green);
}

.status-indicator.error {
    background: var(--accent-red);
}

.status-indicator.loading {
    background: var(--accent-orange);
    animation: pulse 1.5s infinite;
}

/* ===== ANIMATIONS ===== */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

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

.loading-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid var(--border-light);
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* ===== MESSAGE COMPONENTS ===== */
.config-info {
    background: var(--bg-tertiary);
    padding: 16px;
    border-radius: var(--radius-md);
    font-family: 'Courier New', monospace;
    font-size: 13px;
    color: var(--text-secondary);
    margin: 16px 0;
    white-space: pre-line;
}

.success-message {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: var(--accent-green);
    padding: 16px;
    border-radius: var(--radius-md);
    margin: 16px 0;
    font-size: 14px;
}

.error-message {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--accent-red);
    padding: 16px;
    border-radius: var(--radius-md);
    margin: 16px 0;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    line-height: 1.4;
}

.warning-message {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: var(--accent-orange);
    padding: 16px;
    border-radius: var(--radius-md);
    margin: 16px 0;
    font-size: 14px;
}

/* ===== SPECIALIZED COMPONENTS ===== */
.test-result {
    margin-top: 16px;
    padding: 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-light);
}

.test-result h4 {
    margin-bottom: 8px;
    font-size: 16px;
}

.test-result .details {
    font-family: 'Courier New', monospace;
    font-size: 12px;
    background: var(--bg-tertiary);
    padding: 12px;
    border-radius: var(--radius-md);
    margin-top: 8px;
    white-space: pre-wrap;
}

.gemini-icon {
    width: 24px;
    height: 24px;
    background: linear-gradient(45deg, #4C1D95, #8B5CF6);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
    margin: 16px 0;
}

.info-item {
    background: var(--bg-tertiary);
    padding: 12px;
    border-radius: var(--radius-md);
}

.info-item strong {
    color: var(--text-primary);
}

/* ===== LAYOUT OVERRIDES ===== */
/* Ensure all content containers respect viewport width */
.container, .card, .readme-content {
    min-width: 0;
    overflow-wrap: break-word;
}

/* Fix for standalone navigation layout - desktop only */
@media (min-width: 769px) {
    .main-content {
        min-width: 0;
        overflow-x: auto;
    }
}

/* Specific fix for code blocks that are too wide */
pre, pre code {
    max-width: 100%; /* Use container width, not viewport width */
    overflow-x: auto !important;
    white-space: pre !important;
    word-wrap: normal !important;
    width: 100%;
    box-sizing: border-box;
    /* Ensure code blocks can't expand beyond their container */
    min-width: 0;
}

/* Additional fix for readme content within navigation layout */
.main-content .readme-content,
.main-content .card {
    max-width: 100%;
    overflow-x: auto;
    min-width: 0;
}