/* ========== INGRAVIT 2.0 - Modern UI Styles ========== */
/* Basado en el mockup HTML de referencia */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* ========== THEME: DARK (default) ========== */
:root, [data-theme="dark"] {
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --secondary: #0ea5e9;
    --accent: #f59e0b;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;

    --bg-dark: #0f172a;
    --bg-card: #1e293b;
    --bg-hover: #334155;
    --bg-input: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;

    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --border: #334155;
    --border-light: #475569;

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-full: 9999px;
    --radius: 8px;

    --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
    --shadow-lg: 0 8px 24px rgba(0,0,0,0.5);

    --transition: all 0.2s ease;

    --editor-font-family: 'JetBrains Mono', 'Fira Code', monospace;
    --editor-font-size: 13px;
    --editor-line-height: 1.6;
}

/* ========== THEME: LIGHT ========== */
[data-theme="light"] {
    --bg-dark: #f8fafc;
    --bg-card: #ffffff;
    --bg-hover: #f1f5f9;
    --bg-input: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #e2e8f0;

    --text-primary: #1e293b;
    --text-secondary: #475569;
    --text-muted: #94a3b8;

    --border: #e2e8f0;
    --border-light: #cbd5e1;

    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 24px rgba(0,0,0,0.15);
}

/* ========== ACCENT COLORS ========== */
[data-accent="indigo"] { --primary: #6366f1; --primary-light: #818cf8; --primary-dark: #4f46e5; }
[data-accent="blue"] { --primary: #3b82f6; --primary-light: #60a5fa; --primary-dark: #2563eb; }
[data-accent="cyan"] { --primary: #06b6d4; --primary-light: #22d3ee; --primary-dark: #0891b2; }
[data-accent="green"] { --primary: #22c55e; --primary-light: #4ade80; --primary-dark: #16a34a; }
[data-accent="orange"] { --primary: #f97316; --primary-light: #fb923c; --primary-dark: #ea580c; }
[data-accent="pink"] { --primary: #ec4899; --primary-light: #f472b6; --primary-dark: #db2777; }

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    font-size: 14px;
    line-height: 1.5;
}

/* ========== HEADER ========== */
.header {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 18px;
}

.logo-text {
    font-weight: 600;
    font-size: 18px;
    background: linear-gradient(135deg, var(--text-primary), var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Quick Actions Toolbar */
.toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    justify-content: center;
}

.toolbar-group {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px;
    background: var(--bg-dark);
    border-radius: var(--radius-md);
}

.toolbar-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 600;
}

.toolbar-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.toolbar-btn.active {
    background: var(--primary);
    color: white;
}

.toolbar-btn svg {
    width: 18px;
    height: 18px;
}

/* Separator Dropdown */
.separator-dropdown {
    position: relative;
}

.separator-char {
    font-size: 14px;
    font-weight: 700;
    font-family: monospace;
}

.separator-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 4px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 8px;
    min-width: 180px;
    z-index: 1000;
    box-shadow: var(--shadow-lg);
}

.separator-menu-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-muted);
    padding: 4px 8px;
    margin-bottom: 4px;
}

.separator-option {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 8px;
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
}

.separator-option:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.separator-option.active {
    background: var(--primary);
    color: white;
}

.separator-option .sep-char {
    font-family: monospace;
    font-weight: 700;
    width: 40px;
    text-align: center;
}

.separator-option .sep-name {
    font-size: 12px;
}

.separator-custom {
    display: flex;
    gap: 8px;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
}

.separator-custom .input-field {
    flex: 1;
    width: 60px;
    text-align: center;
    font-family: monospace;
}

.toolbar-divider {
    width: 1px;
    height: 24px;
    background: var(--border);
    margin: 0 8px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border: none;
    background: var(--bg-dark);
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.btn-icon:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.btn-icon svg {
    width: 20px;
    height: 20px;
}

/* ========== MODAL SETTINGS ========== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-overlay.open {
    opacity: 1;
    visibility: visible;
}

.modal-container {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 900px;
    height: 80vh;
    max-height: 600px;
    display: flex;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transform: scale(0.95) translateY(20px);
    transition: transform 0.3s ease;
    overflow: hidden;
}

.modal-overlay.open .modal-container {
    transform: scale(1) translateY(0);
}

/* Modal Sidebar */
.modal-sidebar {
    width: 240px;
    background: var(--bg-dark);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.modal-sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border);
}

.modal-sidebar-header h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.modal-sidebar-nav {
    flex: 1;
    padding: 12px;
    overflow-y: auto;
}

.modal-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    margin-bottom: 4px;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    font-size: 14px;
}

.modal-nav-item:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.modal-nav-item.active {
    background: var(--primary);
    color: white;
}

.modal-nav-item svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.modal-nav-item .nav-badge {
    margin-left: auto;
    background: var(--primary);
    color: white;
    font-size: 10px;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-weight: 600;
}

.modal-nav-item.active .nav-badge {
    background: white;
    color: var(--primary);
}

.modal-nav-divider {
    height: 1px;
    background: var(--border);
    margin: 12px 0;
}

/* Modal Content */
.modal-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.modal-content-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-content-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.modal-close-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: var(--bg-dark);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close-btn:hover {
    background: var(--danger);
    color: white;
}

.modal-content-body {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
}

/* Modal Panel Sections */
.modal-panel {
    display: none;
    animation: fadeIn 0.2s ease;
}

.modal-panel.active {
    display: block;
}

.modal-section {
    margin-bottom: 32px;
}

.modal-section:last-child {
    margin-bottom: 0;
}

.modal-section-title {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.modal-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.modal-option:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
}

.modal-option .option-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal-option .option-info svg {
    width: 20px;
    height: 20px;
    color: var(--text-muted);
}

.modal-option .option-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

.modal-option .option-desc {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 2px;
}

.modal-option .shortcut {
    font-size: 11px;
    color: var(--text-muted);
    background: var(--bg-card);
    padding: 4px 10px;
    border-radius: 4px;
    font-family: monospace;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    width: 48px;
    height: 26px;
    background: var(--bg-hover);
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: var(--transition);
}

.toggle-switch.active {
    background: var(--primary);
}

.toggle-switch::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    top: 3px;
    left: 3px;
    transition: var(--transition);
}

.toggle-switch.active::after {
    left: 25px;
}

/* Select/Dropdown in modal */
.modal-select {
    padding: 10px 14px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 13px;
    min-width: 150px;
    cursor: pointer;
    transition: var(--transition);
}

.modal-select:hover {
    border-color: var(--primary);
}

.modal-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

/* Theme Preview Grid */
.theme-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.theme-card {
    padding: 16px;
    background: var(--bg-dark);
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}

.theme-card:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.theme-card.selected {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.theme-preview {
    width: 100%;
    height: 60px;
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
}

.theme-card .theme-name {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-primary);
}

/* Action Buttons Grid in Modal */
.modal-action-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.modal-action-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
}

.modal-action-btn:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
    transform: translateY(-1px);
}

.modal-action-btn svg {
    width: 20px;
    height: 20px;
    color: var(--text-muted);
}

.modal-action-btn:hover svg {
    color: var(--primary);
}

/* Recent Files List */
.recent-files-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.recent-file-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}

.recent-file-item:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
}

.recent-file-item svg {
    width: 18px;
    height: 18px;
    color: var(--text-muted);
}

.recent-file-item .file-name {
    flex: 1;
    font-size: 13px;
    color: var(--text-primary);
}

.recent-file-item .file-path {
    font-size: 11px;
    color: var(--text-muted);
}

/* ========== RIGHT PANEL STYLES ========== */
.right-tabs-container {
    display: flex;
    border-bottom: 1px solid var(--border);
}

.right-tab {
    flex: 1;
    padding: 10px 4px;
    background: var(--bg-dark);
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.right-tab:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.right-tab.active {
    background: var(--bg-card);
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.right-panel {
    display: none;
    animation: fadeIn 0.2s ease;
}

.right-panel.active {
    display: block;
}

.right-btn {
    display: block;
    width: 100%;
    padding: 8px 12px;
    margin-bottom: 4px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 12px;
    text-align: left;
    cursor: pointer;
    transition: var(--transition);
}

.right-btn:hover {
    background: var(--bg-hover);
    border-color: var(--primary);
}

.right-separator {
    height: 1px;
    background: var(--border);
    margin: 10px 0;
}

.right-label {
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 6px;
    padding-left: 2px;
}

.right-row {
    display: flex;
    gap: 4px;
    margin-bottom: 6px;
}

.right-btn-small {
    padding: 6px 10px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 11px;
    cursor: pointer;
    transition: var(--transition);
}

.right-btn-small:hover {
    background: var(--bg-hover);
    border-color: var(--primary);
}

.right-btn-toggle {
    flex: 1;
    padding: 5px 8px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: 10px;
    cursor: pointer;
    transition: var(--transition);
}

.right-btn-toggle:hover {
    background: var(--bg-hover);
}

.right-btn-toggle.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.right-input {
    width: 40px;
    padding: 6px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 12px;
    text-align: center;
}

.right-input:focus {
    outline: none;
    border-color: var(--primary);
}

/* Memory Bar */
.memory-bar {
    padding: 8px;
    background: var(--bg-dark);
    border-top: 1px solid var(--border);
}

.memory-row {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

.mem-btn {
    padding: 5px 8px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 10px;
    cursor: pointer;
    transition: var(--transition);
}

.mem-btn:hover {
    background: var(--bg-hover);
    border-color: var(--primary);
}

.mem-btn.accent {
    background: var(--secondary);
    color: white;
    border-color: var(--secondary);
}

.mem-btn.primary {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.mem-btn.warning {
    background: var(--warning);
    color: var(--bg-dark);
    border-color: var(--warning);
}

.mem-select {
    padding: 4px 6px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 11px;
    width: 45px;
}

.memory-info {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid var(--border);
    font-size: 11px;
    color: var(--text-muted);
}

.nlin-value {
    color: var(--primary);
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
}

/* Language Selector */
.language-selector {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.language-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: var(--bg-dark);
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}

.language-option:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
}

.language-option.selected {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.language-option .flag {
    font-size: 20px;
}

.language-option .lang-name {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
}

.language-option .lang-native {
    font-size: 11px;
    color: var(--text-muted);
}

/* ========== MAIN LAYOUT ========== */
.main {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* ========== SIDEBAR LEFT ========== */
.sidebar-left {
    width: 300px;
    background: var(--bg-card);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    transition: var(--transition);
}

.sidebar-left.collapsed {
    width: 0;
    overflow: hidden;
}

/* Quick Tools Section */
.quick-tools {
    padding: 12px;
    border-bottom: 1px solid var(--border);
    display: flex;
    gap: 8px;
}

.quick-tool-btn {
    flex: 1;
    padding: 12px 8px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.quick-tool-btn:hover {
    background: var(--bg-hover);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.quick-tool-btn svg {
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
}

.quick-tool-btn:hover svg {
    color: var(--primary);
}

.sidebar-header {
    padding: 12px;
    border-bottom: 1px solid var(--border);
}

.mode-tabs {
    display: flex;
    gap: 4px;
    padding: 4px;
    background: var(--bg-dark);
    border-radius: var(--radius-md);
}

.mode-tab {
    flex: 1;
    padding: 10px 8px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    font-size: 12px;
    font-weight: 500;
}

.mode-tab:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.mode-tab.active {
    background: var(--primary);
    color: white;
    box-shadow: var(--shadow-sm);
}

.sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

/* Panel Styles */
.panel {
    display: none;
    animation: fadeIn 0.2s ease;
}

.panel.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.panel-section {
    margin-bottom: 20px;
}

.panel-section-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.input-group {
    margin-bottom: 12px;
}

.input-group label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.input-field {
    width: 100%;
    padding: 10px 12px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 13px;
    transition: var(--transition);
}

.input-field:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.input-field::placeholder {
    color: var(--text-muted);
}

textarea.input-field {
    resize: vertical;
    min-height: 80px;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 16px;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-dark);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-hover);
    border-color: var(--border-light);
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

.btn-block {
    width: 100%;
}

.btn-group {
    display: flex;
    gap: 8px;
}

.btn-group .btn {
    flex: 1;
}

.btn-sm {
    padding: 6px 10px;
    font-size: 11px;
}

/* Radio/Toggle Group */
.toggle-group {
    display: flex;
    padding: 4px;
    background: var(--bg-dark);
    border-radius: var(--radius-sm);
    gap: 4px;
}

.toggle-option {
    flex: 1;
    padding: 8px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
    font-size: 12px;
    font-weight: 500;
}

.toggle-option.active {
    background: var(--primary);
    color: white;
}

/* Action Buttons Grid */
.action-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.action-btn {
    padding: 12px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}

.action-btn:hover {
    background: var(--bg-hover);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.action-btn.full-width {
    grid-column: span 2;
}

/* Quick buttons */
.quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.quick-btn {
    padding: 8px 12px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.quick-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* ========== EDITOR AREA ========== */
.editor-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--bg-dark);
    overflow: hidden;
    min-height: 0;
}

.editor-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
}

.editor-tabs {
    display: flex;
    gap: 4px;
}

.editor-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    font-size: 13px;
}

.editor-tab:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.editor-tab.active {
    background: var(--bg-dark);
    color: var(--text-primary);
}

.editor-tab .dot {
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
}

.editor-tab .close {
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    opacity: 0;
    transition: var(--transition);
}

.editor-tab:hover .close {
    opacity: 1;
}

.editor-tab .close:hover {
    background: var(--danger);
    color: white;
}

.editor-info {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 12px;
    color: var(--text-muted);
}

.editor-info span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.editor-container {
    flex: 1;
    display: flex;
    overflow: hidden;
    min-height: 0;
}

/* Editor Mode Tabs */
.editor-mode-tabs {
    display: flex;
    background: var(--bg-dark);
    border-bottom: 1px solid var(--border);
}

.editor-mode-tab {
    padding: 8px 20px;
    background: var(--bg-dark);
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    transition: var(--transition);
}

.editor-mode-tab:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.editor-mode-tab.active {
    background: var(--bg-card);
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.editor-mode {
    display: none;
    flex: 1;
    flex-direction: column;
    overflow: hidden;
    min-height: 0;
}

.editor-mode.active {
    display: flex;
}

/* List Editor Styles */
.list-operations {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 8px;
    background: var(--bg-dark);
    border-bottom: 1px solid var(--border);
}

.list-op-btn {
    padding: 6px 12px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 11px;
    cursor: pointer;
    transition: var(--transition);
}

.list-op-btn:hover {
    background: var(--bg-hover);
    border-color: var(--primary);
}

.list-op-spacer {
    flex: 1;
}

.dual-editor-container {
    flex: 1;
    display: flex;
    gap: 2px;
    background: var(--border);
}

.list-editor-pane {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
}

.list-editor-content {
    flex: 1;
    overflow: hidden;
}

.list-editor-textarea {
    width: 100%;
    height: 100%;
    padding: 12px;
    background: var(--bg-card);
    border: none;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    line-height: 1.6;
    resize: none;
}

.list-editor-textarea:focus {
    outline: none;
}

.list-editor-footer {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 6px 8px;
    background: var(--bg-dark);
    border-top: 1px solid var(--border);
    flex-wrap: wrap;
}

.list-nlin {
    font-size: 11px;
    color: var(--text-muted);
    margin-left: auto;
}

.list-nlin span {
    color: var(--primary);
    font-weight: 600;
}

.list-label {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary);
    margin-left: 8px;
}

.line-numbers {
    width: 50px;
    padding: 16px 8px;
    background: var(--bg-card);
    border-right: 1px solid var(--border);
    text-align: right;
    font-family: var(--editor-font-family);
    font-size: var(--editor-font-size);
    line-height: var(--editor-line-height);
    color: var(--text-muted);
    user-select: none;
    overflow: hidden;
}

.editor-textarea {
    flex: 1;
    padding: 16px;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-family: var(--editor-font-family);
    font-size: var(--editor-font-size);
    line-height: var(--editor-line-height);
    resize: none;
    outline: none;
    overflow-y: auto;
    overflow-x: auto;
}

.editor-textarea::placeholder {
    color: var(--text-muted);
}

/* ========== SIDEBAR RIGHT ========== */
.sidebar-right {
    width: 280px;
    background: var(--bg-card);
    border-left: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.sidebar-right.collapsed {
    width: 40px;
    min-width: 40px;
    overflow: visible;
    pointer-events: none;
}

.sidebar-right.collapsed .panel-collapse-btn {
    pointer-events: auto;
}

.sidebar-right.collapsed > *:not(.panel-collapse-btn):not(.right-panel-container) {
    display: none;
}

.sidebar-right.collapsed .right-panel-container > *:not(.panel-collapse-btn) {
    display: none;
}

.sidebar-right .sidebar-header {
    padding: 16px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sidebar-right .sidebar-header h3 {
    font-size: 14px;
    font-weight: 600;
}

/* Header Toggle Acciones/Memorias */
.sidebar-right .sidebar-header {
    display: flex;
    gap: 0;
    padding: 0;
}

.header-toggle {
    flex: 1;
    padding: 12px 16px;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.header-toggle:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.header-toggle.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    background: var(--bg-dark);
}

/* Memories full panel */
.sidebar-content.memories-full {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

.sidebar-content.memories-full .memories-section {
    height: 100%;
    display: flex;
    flex-direction: column;
    border-top: none;
}

.sidebar-content.memories-full .memories-list {
    flex: 1;
    max-height: none;
    overflow-y: auto;
}

.sidebar-right .sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
}

.right-panel-container {
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

/* ========== MEMORIES SECTION ========== */
.memories-section {
    padding: 16px;
    border-top: 1px solid var(--border);
}

.memories-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.memories-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 250px;
    overflow-y: auto;
}

.memory-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.memory-item:hover {
    border-color: var(--primary);
}

.memory-item.selected {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.memory-item.has-data {
    border-color: var(--success);
}

.memory-item .add-btn {
    width: 28px;
    height: 28px;
    background: var(--bg-hover);
    border: none;
    border-radius: 4px;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    font-size: 16px;
    font-weight: 600;
}

.memory-item .add-btn:hover {
    background: var(--primary);
    color: white;
}

.memory-item .indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--text-muted);
}

.memory-item.has-data .indicator {
    background: var(--success);
    box-shadow: 0 0 8px var(--success);
}

.memory-item .number {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    width: 20px;
}

.memory-item .preview {
    flex: 1;
    font-size: 11px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.memory-item .rcl-btn {
    padding: 4px 10px;
    background: var(--bg-hover);
    border: none;
    border-radius: 4px;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 10px;
    font-weight: 600;
    transition: var(--transition);
}

.memory-item .rcl-btn:hover {
    background: var(--secondary);
    color: white;
}

.memories-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
    margin-top: 12px;
}

.memories-actions .btn {
    padding: 8px;
    font-size: 10px;
}

.btn-sto { background: var(--primary); color: white; }
.btn-rcl { background: var(--secondary); color: white; }
.btn-add { background: var(--success); color: white; }
.btn-clr { background: var(--danger); color: white; }

/* Stats Card */
.stats-card {
    padding: 16px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: var(--radius-md);
    margin: 16px;
}

.stats-card h4 {
    font-size: 12px;
    font-weight: 500;
    opacity: 0.9;
    margin-bottom: 8px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.stat-item {
    text-align: center;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
}

.stat-label {
    font-size: 10px;
    opacity: 0.8;
    text-transform: uppercase;
}

/* ========== BOTTOM PANEL ========== */
.bottom-panel {
    background: var(--bg-card);
    border-top: 1px solid var(--border);
}

.bottom-tabs {
    display: flex;
    padding: 0 16px;
    gap: 4px;
    border-bottom: 1px solid var(--border);
}

.bottom-tab {
    padding: 12px 16px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: var(--transition);
}

.bottom-tab:hover {
    color: var(--text-primary);
}

.bottom-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.bottom-content {
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-box {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    max-width: 800px;
}

.search-input-group {
    display: flex;
    align-items: center;
    gap: 6px;
}

.search-input-group .input-field {
    flex: 1;
    min-width: 200px;
}

.search-actions {
    display: flex;
    gap: 8px;
}

.btn-icon-small {
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 4px;
    cursor: pointer;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-icon-small:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.btn-sm {
    padding: 4px 8px;
    font-size: 12px;
}

.bottom-panel.hidden {
    display: none;
}

.bottom-panel-close {
    margin-left: auto;
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.bottom-panel-close:hover {
    color: var(--danger);
}

.bottom-content {
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.search-options {
    display: flex;
    gap: 16px;
    font-size: 12px;
}

.search-option {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    cursor: pointer;
}

.search-option input[type="checkbox"] {
    width: 14px;
    height: 14px;
    accent-color: var(--primary);
}

.search-result {
    font-size: 12px;
    color: var(--text-muted);
    padding: 4px 8px;
    background: var(--bg-dark);
    border-radius: var(--radius-sm);
}

.console-output {
    flex: 1;
    max-height: 150px;
    overflow-y: auto;
    background: var(--bg-dark);
    border-radius: var(--radius-sm);
    padding: 8px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
}

.console-line {
    color: var(--text-secondary);
    padding: 2px 0;
}

.history-list {
    flex: 1;
    max-height: 150px;
    overflow-y: auto;
}

.history-item {
    display: flex;
    gap: 12px;
    padding: 6px 8px;
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.history-item:hover {
    background: var(--bg-hover);
}

.history-time {
    color: var(--text-muted);
    font-size: 11px;
    font-family: monospace;
}

.history-action {
    color: var(--text-secondary);
    font-size: 12px;
}

/* ========== STATUS BAR ========== */
.status-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 16px;
    background: var(--primary-dark);
    font-size: 12px;
}

.status-left,
.status-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0.9;
}

.status-item svg {
    width: 14px;
    height: 14px;
}

/* ========== SCROLLBAR ========== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border-light);
}

/* ========== ANIMATIONS ========== */
.btn, .action-btn, .quick-btn, .memory-item, .toolbar-btn {
    transform: translateY(0);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
    .sidebar-left,
    .sidebar-right {
        width: 260px;
    }
}

@media (max-width: 992px) {
    .sidebar-right {
        display: none;
    }
}

@media (max-width: 768px) {
    .sidebar-left {
        position: fixed;
        left: -300px;
        top: 0;
        bottom: 0;
        z-index: 100;
        transition: left 0.3s ease;
    }

    .sidebar-left.open {
        left: 0;
    }

    .toolbar {
        display: none;
    }
}

/* Overlay for mobile menu */
.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
}

.overlay.visible {
    opacity: 1;
    visibility: visible;
}

/* ========== BLAZOR SPECIFIC ========== */
.page {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid var(--success);
}

.invalid {
    outline: 1px solid var(--danger);
}

.validation-message {
    color: var(--danger);
    font-size: 12px;
    margin-top: 4px;
}

#blazor-error-ui {
    background: var(--danger);
    color: white;
    padding: 12px 24px;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    display: none;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    margin-left: 16px;
}

/* ========== SETTINGS MODAL ========== */
.settings-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.settings-modal {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 900px;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border);
}

.settings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
}

.settings-header h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.settings-header .close-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 8px;
    border-radius: var(--radius);
    transition: var(--transition);
}

.settings-header .close-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.settings-content {
    display: flex;
    flex: 1;
    overflow: hidden;
}

.settings-tabs {
    width: 200px;
    background: var(--bg-dark);
    padding: 12px;
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
}

.settings-tab {
    background: none;
    border: none;
    padding: 10px 16px;
    text-align: left;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: var(--radius);
    font-size: 13px;
    transition: var(--transition);
}

.settings-tab:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.settings-tab.active {
    background: var(--primary);
    color: white;
}

.settings-panel {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
}

.settings-section h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 20px 0;
}

.settings-group {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border);
}

.settings-group:last-child {
    border-bottom: none;
}

.settings-group h4 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 12px 0;
}

.settings-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
}

.settings-item label {
    color: var(--text-primary);
    font-size: 14px;
}

.settings-item.toggle {
    padding: 12px 0;
}

.settings-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* Botones de idioma */
.idioma-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.idioma-btn {
    padding: 8px 16px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    font-size: 13px;
}

.idioma-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.idioma-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* Switch toggle */
.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch .slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: var(--bg-tertiary);
    border-radius: 24px;
    transition: var(--transition);
}

.switch .slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: var(--transition);
}

.switch input:checked + .slider {
    background: var(--primary);
}

.switch input:checked + .slider:before {
    transform: translateX(20px);
}

/* Theme selector */
.theme-selector {
    display: flex;
    gap: 12px;
}

.theme-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: var(--bg-tertiary);
    border: 2px solid transparent;
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition);
}

.theme-option:hover {
    border-color: var(--border);
}

.theme-option.active {
    border-color: var(--primary);
}

.theme-preview {
    width: 60px;
    height: 40px;
    border-radius: var(--radius-sm);
}

.theme-preview.dark {
    background: linear-gradient(135deg, #1e293b 50%, #0f172a 50%);
}

.theme-preview.light {
    background: linear-gradient(135deg, #f8fafc 50%, #e2e8f0 50%);
}

.theme-preview.system {
    background: linear-gradient(135deg, #1e293b 50%, #f8fafc 50%);
}

/* Color selector */
.color-selector {
    display: flex;
    gap: 8px;
}

.color-option {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--color);
    border: 2px solid transparent;
    cursor: pointer;
    transition: var(--transition);
}

.color-option:hover {
    transform: scale(1.1);
}

.color-option.active {
    border-color: white;
    box-shadow: 0 0 0 2px var(--color);
}

/* Shortcuts list */
.shortcuts-list {
    max-height: 400px;
    overflow-y: auto;
}

.shortcuts-category {
    margin-bottom: 16px;
}

.shortcuts-category h4 {
    margin-bottom: 8px;
}

.shortcut-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 12px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    margin-bottom: 4px;
}

.shortcut-action {
    color: var(--text-primary);
    font-size: 13px;
}

.shortcut-keys {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-muted);
    background: var(--bg-dark);
    padding: 2px 8px;
    border-radius: var(--radius-sm);
}

/* About section */
.about-section {
    text-align: center;
}

.about-header {
    margin-bottom: 24px;
}

.about-logo .logo-icon.large {
    width: 80px;
    height: 80px;
    font-size: 36px;
    margin: 0 auto 16px;
}

.about-header h2 {
    font-size: 24px;
    margin: 0 0 8px 0;
}

.about-header .version {
    color: var(--text-muted);
    font-size: 14px;
}

.about-description {
    max-width: 500px;
    margin: 0 auto 24px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.features-list {
    text-align: left;
    max-width: 400px;
    margin: 0 auto;
    padding-left: 20px;
}

.features-list li {
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.system-info {
    text-align: left;
    max-width: 400px;
    margin: 0 auto;
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
}

.info-label {
    color: var(--text-muted);
}

.info-value {
    color: var(--text-primary);
}

.about-links {
    display: flex;
    justify-content: center;
    gap: 24px;
}

.about-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    text-decoration: none;
    font-size: 14px;
}

.about-link:hover {
    text-decoration: underline;
}

.about-footer {
    margin-top: 24px;
    color: var(--text-muted);
    font-size: 12px;
}

/* Danger zone */
.danger-zone {
    background: rgba(239, 68, 68, 0.1);
    padding: 16px;
    border-radius: var(--radius);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.danger-zone h4 {
    color: var(--danger);
}

/* Settings footer */
.settings-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid var(--border);
}

/* Input field small */
.input-field.small {
    width: 80px;
}

.textarea {
    min-height: 100px;
    resize: vertical;
}

.settings-path-group {
    display: flex;
    gap: 8px;
}

.settings-path-group .input-field {
    flex: 1;
}

.btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

.slider-input {
    width: 150px;
    cursor: pointer;
}

.slider-value {
    min-width: 50px;
    text-align: right;
    color: var(--text-muted);
}

/* ========== PANEL COLLAPSE BUTTONS ========== */
.panel-collapse-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: var(--transition);
}

.panel-collapse-btn:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--primary);
}

.panel-collapse-btn.right {
    right: auto;
    left: 8px;
}

/* Panel colapsado muestra solo el boton */
.sidebar-left.collapsed {
    width: 40px;
    min-width: 40px;
    padding: 0;
    overflow: visible;
    pointer-events: none;
}

.sidebar-left.collapsed .panel-collapse-btn {
    pointer-events: auto;
}

.sidebar-left.collapsed > *:not(.panel-collapse-btn) {
    display: none;
}

.sidebar-left.collapsed .panel-collapse-btn,
.sidebar-right.collapsed .panel-collapse-btn {
    position: relative;
    top: auto;
    right: auto;
    left: auto;
    margin: 6px auto;
}

/* Posicion relativa para los sidebars */
.sidebar-left,
.sidebar-right {
    position: relative;
}
