/* ==========================================================================
   DESIGN SYSTEM & VARIABLES
   ========================================================================== */

:root {
    /* Color Palette */
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --primary-rgb: 99, 102, 241;
    
    --secondary: #a855f7;
    --secondary-light: #c084fc;
    --secondary-rgb: 168, 85, 247;
    
    --accent: #06b6d4;
    --accent-rgb: 6, 182, 212;
    
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    /* Dark Theme Backgrounds */
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-tertiary: #1a1a2e;
    --bg-card: #16161f;
    --bg-card-hover: #1e1e2d;
    
    /* Borders */
    --border-color: rgba(255, 255, 255, 0.06);
    --border-color-hover: rgba(255, 255, 255, 0.12);
    
    /* Text Colors */
    --text-primary: #f0f0f5;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    
    /* Shadows */
    --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 30px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.6);
    
    /* Border Radii */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.25s ease;
    --transition-slow: 0.4s ease;
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary), var(--secondary));
    --gradient-accent: linear-gradient(135deg, var(--accent), var(--primary));
    --gradient-card: linear-gradient(180deg, rgba(255,255,255,0.02) 0%, rgba(255,255,255,0) 100%);
    
    /* Font Families */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-display: 'Outfit', sans-serif;
    --font-mono: 'Space Grotesk', monospace;
}

/* Light Theme Overrides */
body.light-mode {
    --bg-primary: #f8fafc;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f1f5f9;
    --bg-card: #ffffff;
    --bg-card-hover: #f8fafc;
    
    --border-color: rgba(0, 0, 0, 0.08);
    --border-color-hover: rgba(0, 0, 0, 0.15);
    
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.12);
    
    --gradient-card: linear-gradient(180deg, rgba(0,0,0,0.01) 0%, rgba(0,0,0,0) 100%);
}

/* ==========================================================================
   RESET & GLOBAL STYLES
   ========================================================================== */

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

html {
    scroll-behavior: smooth;
}

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

/* ==========================================================================
   GRIMONT GLOBAL HEADER (exact design)
   ========================================================================== */

.grimont-global-header {
    width: 100%;
    z-index: 1000;
    position: sticky;
    top: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding: 14px 0;
    font-family: var(--font-display);
    color: #e2e8f0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.15);
}

body.light-mode .grimont-global-header {
    background: rgba(255, 255, 255, 0.85);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    color: #0f172a;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

.ggh-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ggh-left {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.ggh-logo-group {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    text-decoration: none;
    transition: transform 0.2s ease;
}

.ggh-logo-group:hover {
    transform: scale(1.02);
}

.ggh-logo-box {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #2563eb, #7c3aed);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.25rem;
    border: 1px solid rgba(255,255,255,0.15);
    box-shadow: 0 0 20px rgba(37, 99, 235, 0.25);
    flex-shrink: 0;
}

.ggh-logo-text {
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.2rem;
    color: white;
    letter-spacing: 0.05em;
    display: none;
}

body.light-mode .ggh-logo-text {
    color: #0f172a;
}

.ggh-logo-text span {
    color: #00f2ff;
}

body.light-mode .ggh-logo-text span {
    color: #2563eb;
}

.ggh-separator {
    width: 1px;
    height: 36px;
    background-color: rgba(255, 255, 255, 0.1);
    display: none;
}

body.light-mode .ggh-separator {
    background-color: rgba(0, 0, 0, 0.1);
}

@media (min-width: 640px) {
    .ggh-logo-text { display: block; }
}

@media (min-width: 768px) {
    .ggh-separator { display: block; }
}

.ggh-app-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.ggh-app-title-group {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.ggh-app-icon-container {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(30, 41, 59, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: #60a5fa;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    flex-shrink: 0;
}

body.light-mode .ggh-app-icon-container {
    background: #f1f5f9;
    border-color: rgba(0,0,0,0.08);
    color: #2563eb;
}

.ggh-app-name {
    font-weight: 700;
    color: white;
    font-size: 1.05rem;
    letter-spacing: 0.02em;
}

body.light-mode .ggh-app-name {
    color: #0f172a;
}

.ggh-app-desc {
    font-size: 0.8rem;
    color: #94a3b8;
    max-width: 500px;
    display: none;
    margin: 4px 0 0 0;
    line-height: 1.4;
    font-weight: 300;
}

@media (min-width: 1024px) {
    .ggh-app-desc { display: block; }
}

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

.ggh-theme-toggle {
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.ggh-theme-toggle:hover {
    background: rgba(30, 41, 59, 1);
    color: white;
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

body.light-mode .ggh-theme-toggle {
    background: rgba(241, 245, 249, 0.8);
    border-color: rgba(0,0,0,0.08);
    color: #475569;
}

body.light-mode .ggh-theme-toggle:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.hidden {
    display: none !important;
}

/* ==========================================================================
   APP CONTAINER & HERO
   ========================================================================== */

.app-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 1.5rem 80px;
}

.hero-section {
    text-align: center;
    margin-bottom: 48px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 100px;
    color: var(--primary-light);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 16px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

body.light-mode .hero-badge {
    background: rgba(99, 102, 241, 0.05);
}

.hero-title {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.15;
    margin-bottom: 16px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.15rem;
    color: var(--text-secondary);
    font-weight: 400;
}

/* ==========================================================================
   CONFIG CARDS & LAYOUTS
   ========================================================================== */

.config-section {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.config-card {
    background: var(--bg-card);
    background-image: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow-md);
    transition: border-color var(--transition-normal), box-shadow var(--transition-normal);
}

.config-card:hover {
    border-color: var(--border-color-hover);
    box-shadow: var(--shadow-lg);
}

.config-card-header {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 24px;
}

.config-icon {
    width: 48px;
    height: 48px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-light);
    font-size: 1.5rem;
    flex-shrink: 0;
}

body.light-mode .config-icon {
    background: rgba(99, 102, 241, 0.05);
    color: var(--primary);
}

.config-card-header h2 {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.config-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Models Grid */
.models-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
    margin-top: 8px;
}

.model-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    cursor: pointer;
    transition: all var(--transition-normal);
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    overflow: hidden;
}

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

.model-card.active {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.08);
    box-shadow: 0 0 0 1px var(--primary);
}

.model-icon {
    font-size: 1.8rem;
}

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

.model-desc {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* ==========================================================================
   FORM CONTROLS & MANAGERS
   ========================================================================== */

.form-group {
    margin-bottom: 24px;
}

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

.form-select {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    outline: none;
    transition: border-color var(--transition-fast);
    cursor: pointer;
}

.form-select:focus {
    border-color: var(--primary);
}

/* Sliders Grid */
.criteria-sliders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 16px;
}

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

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

.slider-label {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
}

.slider-value {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary-light);
    background: rgba(99, 102, 241, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
}

.slider-control-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.form-range {
    -webkit-appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: var(--bg-tertiary);
    outline: none;
}

.form-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--gradient-primary);
    cursor: pointer;
    border: 2px solid var(--bg-primary);
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition-fast);
}

.form-range::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

/* Elements list manager */
.elements-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}

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

.element-input {
    flex-grow: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    outline: none;
    font-weight: 500;
}

.btn-remove {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px;
    transition: color var(--transition-fast);
}

.btn-remove:hover {
    color: var(--danger);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-family: var(--font-sans);
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
}

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

.btn-secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-color-hover);
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.35);
}

.btn-primary:hover {
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
    transform: translateY(-1px);
}

.btn-lg {
    padding: 16px 36px;
    font-size: 1.1rem;
    border-radius: var(--radius-lg);
}

.generate-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 16px;
}

/* ==========================================================================
   RATINGS TABLE GRID
   ========================================================================== */

.table-responsive {
    width: 100%;
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.ratings-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    background: var(--bg-secondary);
}

.ratings-table th, .ratings-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
}

.ratings-table th {
    background: var(--bg-tertiary);
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

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

.element-cell-name {
    font-weight: 600;
    color: var(--text-primary);
    min-width: 180px;
}

.rating-select {
    width: 70px;
    padding: 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    outline: none;
    font-family: var(--font-mono);
    font-weight: 700;
    cursor: pointer;
    text-align: center;
}

.rating-select:focus {
    border-color: var(--primary);
}

/* ==========================================================================
   RESULTS SECTION & HEADER BAR
   ========================================================================== */

.results-section {
    margin-top: 48px;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.results-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 20px;
}

.results-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    background: rgba(168, 85, 247, 0.1);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: 100px;
    color: var(--secondary-light);
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.results-title-group h2 {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-primary);
}

.export-bar {
    display: flex;
    gap: 12px;
}

.export-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    border: none;
    transition: all var(--transition-fast);
}

.export-pdf-btn {
    background: var(--gradient-primary);
    color: white;
}

.export-pdf-btn:hover {
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
    transform: translateY(-1px);
}

.export-word-btn {
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    color: white;
}

.export-word-btn:hover {
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
    transform: translateY(-1px);
}

.export-pptx-btn {
    background: linear-gradient(135deg, #ea580c, #f97316);
    color: white;
}

.export-pptx-btn:hover {
    box-shadow: 0 4px 12px rgba(234, 88, 12, 0.35);
    transform: translateY(-1px);
}

.export-zip-btn {
    background: linear-gradient(135deg, #7c3aed, #8b5cf6);
    color: white;
}

.export-zip-btn:hover {
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.35);
    transform: translateY(-1px);
}

.export-png-btn {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.export-png-btn:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-color-hover);
    transform: translateY(-1px);
}

/* ==========================================================================
   RESULT DELIVERABLE CARDS
   ========================================================================== */

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

.result-card:hover {
    border-color: var(--border-color-hover);
}

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

.result-card-header h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.result-card-header h3 i {
    color: var(--primary-light);
}

.export-single-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--radius-sm);
    color: var(--primary-light);
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.export-single-btn:hover {
    background: var(--primary);
    color: white;
}

.result-card-body {
    padding: 28px;
}

.deliverable-intro {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

/* ==========================================================================
   LIVRABLE 1 : VISUAL MATRIX STYLE
   ========================================================================== */

.matrix-canvas-wrapper {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: 20px;
}

.matrix-grid-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 16px;
}

.matrix-quadrant {
    padding: 20px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    display: flex;
    flex-direction: column;
    min-height: 200px;
    transition: transform var(--transition-fast);
}

.matrix-quadrant:hover {
    transform: translateY(-2px);
}

.quadrant-header {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* Quadrant Specific Colors */
.matrix-quadrant.do-now {
    background: rgba(16, 185, 129, 0.05);
    border-color: rgba(16, 185, 129, 0.15);
}
.matrix-quadrant.do-now .quadrant-header {
    color: var(--success);
}

.matrix-quadrant.plan {
    background: rgba(99, 102, 241, 0.05);
    border-color: rgba(99, 102, 241, 0.15);
}
.matrix-quadrant.plan .quadrant-header {
    color: var(--primary-light);
}

.matrix-quadrant.delegate {
    background: rgba(245, 158, 11, 0.05);
    border-color: rgba(245, 158, 11, 0.15);
}
.matrix-quadrant.delegate .quadrant-header {
    color: var(--warning);
}

.matrix-quadrant.postpone {
    background: rgba(239, 68, 68, 0.05);
    border-color: rgba(239, 68, 68, 0.15);
}
.matrix-quadrant.postpone .quadrant-header {
    color: var(--danger);
}

.quadrant-items {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-content: flex-start;
    flex-grow: 1;
}

.matrix-item-chip {
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    color: var(--text-primary);
    cursor: default;
    transition: all var(--transition-fast);
}

.matrix-item-chip:hover {
    border-color: var(--primary);
    transform: scale(1.02);
}

/* ==========================================================================
   LIVRABLE 2 : RANKING LIST STYLE
   ========================================================================== */

.ranking-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.ranking-item {
    display: flex;
    align-items: center;
    background: var(--bg-secondary);
    padding: 16px 20px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    gap: 16px;
    position: relative;
    overflow: hidden;
}

.ranking-badge {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--text-primary);
    flex-shrink: 0;
}

.ranking-item:nth-child(1) .ranking-badge {
    background: linear-gradient(135deg, #ffd700, #ffa500);
    color: #000;
}
.ranking-item:nth-child(2) .ranking-badge {
    background: linear-gradient(135deg, #c0c0c0, #a9a9a9);
    color: #000;
}
.ranking-item:nth-child(3) .ranking-badge {
    background: linear-gradient(135deg, #cd7f32, #8b4513);
    color: #fff;
}

.ranking-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
    width: 25%;
    min-width: 150px;
}

.ranking-bar-wrapper {
    flex-grow: 1;
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
    margin: 0 16px;
}

.ranking-progress-bar {
    height: 100%;
    border-radius: 4px;
    transition: width var(--transition-slow);
}

.ranking-score-value {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.1rem;
    width: 80px;
    text-align: right;
    color: var(--text-primary);
}

/* ==========================================================================
   LIVRABLE 3 : CATEGORIZATION COLUMNS STYLE
   ========================================================================== */

.categories-columns {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.category-column {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: 20px;
    display: flex;
    flex-direction: column;
    min-height: 250px;
}

.category-column-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
}

.category-column-header h4 {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.category-items-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-grow: 1;
}

.category-item-card {
    background: var(--bg-card);
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Colors */
.category-column.do-now {
    border-top: 4px solid var(--success);
}
.category-column.do-now h4 {
    color: var(--success);
}

.category-column.plan {
    border-top: 4px solid var(--primary-light);
}
.category-column.plan h4 {
    color: var(--primary-light);
}

.category-column.delegate {
    border-top: 4px solid var(--warning);
}
.category-column.delegate h4 {
    color: var(--warning);
}

.category-column.postpone {
    border-top: 4px solid var(--danger);
}
.category-column.postpone h4 {
    color: var(--danger);
}

/* ==========================================================================
   LIVRABLE 4 : SCORES AND EXPLANATIONS STYLE
   ========================================================================== */

.explanations-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.explanation-item {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: 24px;
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 24px;
}

.explanation-left {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.explanation-left h4 {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--text-primary);
}

.explanation-badge-cat {
    align-self: flex-start;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.explanation-score-details {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.explanation-score-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--text-secondary);
    border-bottom: 1px dashed var(--border-color);
    padding-bottom: 4px;
}

.explanation-score-row span:last-child {
    font-family: var(--font-mono);
    font-weight: 600;
}

.explanation-right {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.explanation-text-title {
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 6px;
}

.explanation-text-content {
    font-size: 0.95rem;
    color: var(--text-primary);
    line-height: 1.6;
}

.analysis-part {
    margin-bottom: 18px;
}

.analysis-part:last-child {
    margin-bottom: 0;
}

.analysis-part strong {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--primary-light);
    margin-bottom: 6px;
    font-family: var(--font-display);
}

body.light-mode .analysis-part strong {
    color: var(--primary-dark);
}

.analysis-part p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    text-align: justify;
}

/* ==========================================================================
   LIVRABLE 5 : RECOMMENDATIONS STYLE
   ========================================================================== */

.recommendations-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.rec-section {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: 24px;
}

.rec-section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.05rem;
    margin-bottom: 20px;
}

.rec-section.do-now {
    border-left: 4px solid var(--success);
}
.rec-section.do-now .rec-section-header {
    color: var(--success);
}

.rec-section.plan {
    border-left: 4px solid var(--primary-light);
}
.rec-section.plan .rec-section-header {
    color: var(--primary-light);
}

.rec-section.delegate {
    border-left: 4px solid var(--warning);
}
.rec-section.delegate .rec-section-header {
    color: var(--warning);
}

.rec-section.postpone {
    border-left: 4px solid var(--danger);
}
.rec-section.postpone .rec-section-header {
    color: var(--danger);
}

.rec-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.rec-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: var(--bg-card);
    padding: 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.rec-item-icon {
    font-size: 1.1rem;
    color: var(--primary-light);
    flex-shrink: 0;
    margin-top: 2px;
}

.rec-item-text {
    font-size: 0.92rem;
    color: var(--text-primary);
    line-height: 1.5;
}

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

/* ==========================================================================
   LIVRABLE 6 : SOURCES & METHODOLOGY
   ========================================================================== */

.sources-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.source-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all var(--transition-fast);
}

.source-card:hover {
    transform: translateY(-2px);
    border-color: var(--border-color-hover);
}

.source-card h4 {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.source-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.4;
}

.source-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-light);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.source-link:hover {
    color: var(--primary);
}

/* ==========================================================================
   EDITABLE TEXT STYLING (Contenteditable)
   ========================================================================== */

.editable-content {
    outline: none;
    border-radius: 4px;
    transition: background var(--transition-fast), box-shadow var(--transition-fast);
    padding: 2px 6px;
    margin: -2px -6px;
}

.editable-content:hover {
    background: rgba(99, 102, 241, 0.06);
    box-shadow: 0 0 0 1px rgba(99, 102, 241, 0.15);
    cursor: text;
}

.editable-content:focus {
    background: rgba(99, 102, 241, 0.1);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.3);
}

/* ==========================================================================
   APP FOOTER
   ========================================================================== */

.app-footer {
    border-top: 1px solid var(--border-color);
    padding: 32px 0;
    text-align: center;
    background: var(--bg-secondary);
    margin-top: 80px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.footer-content p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer-content a {
    color: var(--primary-light);
    text-decoration: none;
    font-weight: 500;
}

.footer-content a:hover {
    text-decoration: underline;
}

/* ==========================================================================
   EXPORT CLEAN STYLING (Cloned node rendering adjustments)
   ========================================================================== */

.result-card.exporting {
    padding: 40px !important;
    background-color: #0a0a0f !important;
    color: #f0f0f5 !important;
    border: none !important;
}

.result-card.exporting .result-card-header {
    border-bottom: 2px solid rgba(255,255,255,0.08) !important;
    padding-bottom: 20px !important;
    background: none !important;
}

.result-card.exporting .result-card-body {
    padding: 24px 0 0 0 !important;
}

/* ==========================================================================
   RESPONSIVE STYLES
   ========================================================================== */

@media (max-width: 1024px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .categories-columns {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .app-container {
        padding-top: 24px;
        padding-bottom: 48px;
    }

    .hero-title {
        font-size: 2rem;
    }
    
    .config-card {
        padding: 20px;
    }
    
    .criteria-sliders-grid {
        grid-template-columns: 1fr;
    }
    
    .matrix-grid-container {
        grid-template-columns: 1fr;
    }
    
    .explanation-item {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .ranking-name {
        width: 40%;
    }
    
    .results-header-bar {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .export-bar {
        width: 100%;
        justify-content: stretch;
    }
    
    .export-btn {
        flex-grow: 1;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .categories-columns {
        grid-template-columns: 1fr;
    }
    
    .ranking-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .ranking-name {
        width: 100%;
    }
    
    .ranking-bar-wrapper {
        margin: 0;
        width: 100%;
    }
    
    .ranking-score-value {
        width: 100%;
        text-align: left;
    }
    
    .result-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .export-single-btn {
        align-self: stretch;
        justify-content: center;
    }
}
