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

:root {
    --primary-color: #667eea;
    --primary-dark: #5568d3;
    --secondary-color: #764ba2;
    --accent-color: #f093fb;
    --success-color: #4caf50;
    --danger-color: #e74c3c;
    --warning-color: #ff9800;
    --info-color: #2196f3;
    --bg-light: #f5f7fa;
    --bg-white: #ffffff;
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --border-color: #e0e4e8;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.15);
    --shadow-lg: 0 10px 30px rgba(0,0,0,0.2);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
}

/* Dashboard Layout */
.dashboard {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    z-index: 100;
}

.sidebar-header {
    padding: 30px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-header h1 {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.sidebar-header .version {
    font-size: 0.75rem;
    opacity: 0.8;
}

.sidebar-nav {
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    transition: all 0.3s;
    border-left: 3px solid transparent;
}

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

.nav-item.active {
    background: rgba(255,255,255,0.15);
    border-left-color: white;
    color: white;
}

.nav-icon {
    font-size: 1.3rem;
    margin-right: 12px;
    width: 30px;
}

/* Main Content */
.main-content {
    margin-left: 260px;
    flex: 1;
    background: var(--bg-light);
}

.top-bar {
    background: white;
    padding: 20px 30px;
    box-shadow: var(--shadow-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 50;
}

.page-title h2 {
    font-size: 1.8rem;
    color: var(--text-dark);
}

.top-bar-actions {
    display: flex;
    gap: 10px;
}

.content-area {
    padding: 30px;
}

/* Views */
.view {
    display: none;
}

.view.active {
    display: block;
}

/* Cards */
.card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.card h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.3rem;
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: var(--shadow-sm);
    border-left: 4px solid var(--primary-color);
}

.stat-card h3 {
    font-size: 0.9rem;
    color: var(--text-light);
    font-weight: 500;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

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

/* Form Styles */
.form-header {
    margin-bottom: 30px;
}

.form-header h3 {
    margin-bottom: 20px;
}

.stage-progress {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.stage-indicator {
    flex: 1;
    min-width: 100px;
    text-align: center;
    padding: 12px 8px;
    background: var(--bg-light);
    border-radius: 8px;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.stage-indicator.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.stage-indicator.completed {
    background: var(--success-color);
    color: white;
}

.stage-number {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.stage-name {
    font-size: 0.75rem;
    font-weight: 500;
}

.form-stage {
    display: none;
}

.form-stage.active {
    display: block;
}

.form-stage h4 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.stage-description {
    color: var(--text-light);
    margin-bottom: 25px;
    font-style: italic;
}

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

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

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

.form-group input[type="text"],
.form-group select,
.form-group textarea,
.form-control {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus,
.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.slider-group {
    margin-bottom: 15px;
}

.slider-group label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 500;
}

.slider-group input[type="range"] {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: linear-gradient(to right, #e0e4e8 0%, var(--primary-color) 50%, #e0e4e8 100%);
    outline: none;
    -webkit-appearance: none;
}

.slider-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    transition: all 0.3s;
}

.slider-group input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 3px 8px rgba(102, 126, 234, 0.4);
}

.slider-group input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    transition: all 0.3s;
}

.slider-group input[type="range"]::-moz-range-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 3px 8px rgba(102, 126, 234, 0.4);
}

.slider-group small {
    display: block;
    color: var(--text-light);
    font-size: 12px;
    margin-top: 4px;
}

/* Need State Radio Cards */
.need-state-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.radio-card {
    position: relative;
    cursor: pointer;
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.radio-card-content {
    padding: 20px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: white;
    transition: all 0.3s;
}

.radio-card input[type="radio"]:checked + .radio-card-content {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
}

.radio-card-content strong {
    display: block;
    font-size: 1.1rem;
    color: var(--text-dark);
    margin-bottom: 5px;
}

.radio-card-content p {
    font-size: 0.85rem;
    color: var(--text-light);
    margin: 0;
}

/* Buttons */
.btn-primary, .btn-secondary, .btn-danger {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

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

.btn-secondary:hover {
    background: white;
    border-color: var(--primary-color);
    color: var(--primary-color);
}

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

.btn-danger:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(231, 76, 60, 0.3);
}

.form-navigation {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid var(--border-color);
}

.form-navigation button {
    flex: 1;
    max-width: 200px;
}

/* History */
.history-controls {
    margin-bottom: 20px;
    display: flex;
    gap: 10px;
}

#history-list {
    max-height: 600px;
    overflow-y: auto;
}

.history-item {
    padding: 20px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 15px;
    transition: all 0.3s;
    background: white;
}

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

.history-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.history-item-title {
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--text-dark);
}

.history-item-brand {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-left: 10px;
}

.history-item-type {
    display: inline-block;
    padding: 4px 12px;
    background: var(--primary-color);
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    margin-left: 10px;
    text-transform: uppercase;
    font-weight: 600;
}

.history-item-date {
    font-size: 0.85rem;
    color: var(--text-light);
}

.history-item-notes {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-top: 10px;
    font-style: italic;
}

.delete-btn {
    background: var(--danger-color);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.3s;
}

.delete-btn:hover {
    background: #c0392b;
}

/* Comparison Tool */
.comparison-selector {
    padding: 20px 0;
}

.comparison-product-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.comparison-checkbox {
    display: flex;
    align-items: center;
    padding: 15px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.comparison-checkbox:hover {
    border-color: var(--primary-color);
    background: rgba(102, 126, 234, 0.05);
}

.comparison-checkbox input[type="checkbox"] {
    margin-right: 10px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

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

.comparison-checkbox label {
    cursor: pointer;
    font-weight: 500;
}

/* Comparison Summary Cards */
.comparison-summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.summary-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: var(--shadow-md);
}

.summary-card h4 {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.summary-card .value {
    font-size: 1.8rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.summary-card .label {
    font-size: 0.85rem;
    opacity: 0.8;
}

/* Comparison Matrix */
.comparison-matrix {
    overflow-x: auto;
    margin-top: 15px;
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
    background: white;
}

.comparison-table th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 10px;
    text-align: left;
    font-weight: 600;
    position: sticky;
    top: 0;
    z-index: 10;
}

.comparison-table th.product-col {
    text-align: center;
    min-width: 120px;
}

.comparison-table th.delta-col {
    text-align: center;
    min-width: 80px;
}

.comparison-table td {
    padding: 10px;
    border-bottom: 1px solid var(--border-color);
}

.comparison-table tr:hover {
    background: #f8f9fa;
}

.comparison-table .stage-header {
    background: #e3f2fd;
    font-weight: bold;
    color: var(--primary-color);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.comparison-table .attribute-name {
    font-weight: 500;
    color: var(--text-dark);
    padding-left: 20px;
}

.comparison-table .value-cell {
    text-align: center;
    font-weight: 600;
    font-size: 1rem;
    padding: 12px;
    border-radius: 4px;
    transition: all 0.2s;
}

/* Blue gradient color coding for values (0-10 scale) */
.value-cell[data-value="0"],
.value-cell[data-value="1"] {
    background: #e3f2fd;
    color: #0d47a1;
}

.value-cell[data-value="2"],
.value-cell[data-value="3"] {
    background: #bbdefb;
    color: #1565c0;
}

.value-cell[data-value="4"],
.value-cell[data-value="5"] {
    background: #90caf9;
    color: #1976d2;
}

.value-cell[data-value="6"],
.value-cell[data-value="7"] {
    background: #64b5f6;
    color: #0d47a1;
}

.value-cell[data-value="8"],
.value-cell[data-value="9"],
.value-cell[data-value="10"] {
    background: #2196f3;
    color: white;
    font-weight: bold;
}

.delta-cell {
    text-align: center;
    font-weight: bold;
    font-size: 0.9rem;
}

.delta-positive {
    color: #2196f3;
}

.delta-negative {
    color: #ff9800;
}

.delta-significant {
    background: #fff3cd;
    padding: 5px 8px;
    border-radius: 4px;
    font-weight: bold;
}

.delta-arrow {
    font-size: 1.1rem;
    margin-right: 3px;
}

/* Emotional Heatmap */
.emotion-heatmap {
    overflow-x: auto;
    margin-top: 15px;
}

.heatmap-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.heatmap-table th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 8px;
    text-align: center;
    font-weight: 600;
    position: sticky;
    top: 0;
    z-index: 10;
    font-size: 0.85rem;
}

.heatmap-table th.product-header {
    text-align: left;
    padding-left: 15px;
    min-width: 150px;
}

.heatmap-table td.product-name {
    font-weight: 600;
    padding: 12px 15px;
    background: #f8f9fa;
    border-right: 2px solid #dee2e6;
}

.heatmap-table td.heatmap-cell {
    text-align: center;
    padding: 12px 8px;
    font-weight: 600;
    transition: all 0.2s;
    cursor: pointer;
    position: relative;
}

.heatmap-table td.heatmap-cell:hover {
    transform: scale(1.1);
    z-index: 5;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Heatmap color scale - blue gradient */
.heatmap-cell[data-intensity="0"] {
    background: #f8f9fa;
    color: #6c757d;
}

.heatmap-cell[data-intensity="1"] {
    background: #e3f2fd;
    color: #0d47a1;
}

.heatmap-cell[data-intensity="2"] {
    background: #d1e7fd;
    color: #1565c0;
}

.heatmap-cell[data-intensity="3"] {
    background: #bbdefb;
    color: #1565c0;
}

.heatmap-cell[data-intensity="4"] {
    background: #a3d5f9;
    color: #1976d2;
}

.heatmap-cell[data-intensity="5"] {
    background: #90caf9;
    color: #1976d2;
}

.heatmap-cell[data-intensity="6"] {
    background: #7ec0f7;
    color: #0d47a1;
}

.heatmap-cell[data-intensity="7"] {
    background: #64b5f6;
    color: #0d47a1;
}

.heatmap-cell[data-intensity="8"] {
    background: #42a5f5;
    color: white;
    font-weight: bold;
}

.heatmap-cell[data-intensity="9"] {
    background: #2196f3;
    color: white;
    font-weight: bold;
}

.heatmap-cell[data-intensity="10"] {
    background: #1976d2;
    color: white;
    font-weight: bold;
}

/* Insights */
.insight-item {
    padding: 20px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    border-left: 4px solid var(--primary-color);
    margin-bottom: 20px;
    border-radius: 8px;
}

.insight-item strong {
    color: var(--primary-color);
    font-size: 1.1rem;
    display: block;
    margin-bottom: 8px;
}

.insight-item p {
    margin: 0;
    line-height: 1.6;
}

/* Empty States */
.empty-state {
    text-align: center;
    color: var(--text-light);
    padding: 60px 20px;
    font-style: italic;
    font-size: 1.1rem;
}

/* Charts */
canvas {
    max-height: 500px;
}

/* Responsive */
@media (max-width: 1024px) {
    .sidebar {
        width: 220px;
    }

    .main-content {
        margin-left: 220px;
    }

    .grid-2col {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s;
    }

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

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

    .stage-progress {
        overflow-x: auto;
        justify-content: flex-start;
    }

    .stage-indicator {
        min-width: 90px;
        flex: 0 0 90px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .need-state-options {
        grid-template-columns: 1fr;
    }

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

    .form-navigation {
        flex-direction: column;
    }

    .form-navigation button {
        max-width: 100%;
    }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-light);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 5px;
}

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

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Validation Errors */
.validation-errors {
    background: rgba(231, 76, 60, 0.1);
    border-left: 4px solid var(--danger-color);
    padding: 20px;
    margin-bottom: 25px;
    border-radius: 8px;
    animation: shake 0.4s;
}

.validation-error-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    color: var(--danger-color);
    font-size: 1.1rem;
}

.error-icon {
    font-size: 1.5rem;
}

.validation-errors ul {
    margin: 0;
    padding-left: 30px;
}

.validation-errors li {
    color: var(--danger-color);
    font-weight: 500;
    margin: 8px 0;
}

.validation-error {
    border-color: var(--danger-color) !important;
    background: rgba(231, 76, 60, 0.05) !important;
}

.validation-error:focus {
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.2) !important;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

@media (prefers-reduced-motion: reduce) {
    .validation-errors {
        animation: none;
    }
}

/* Accessibility - Focus Styles */
*:focus {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

button:focus,
a:focus,
.nav-item:focus {
    outline: 3px solid var(--accent-color);
    outline-offset: 3px;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.heatmap-cell:focus {
    outline: 3px solid white;
    outline-offset: -3px;
    z-index: 10;
}

/* Skip to main content link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    z-index: 10000;
}

.skip-link:focus {
    top: 0;
}

/* Keyboard navigation indicators */
.nav-item:focus-visible {
    background: rgba(255,255,255,0.2);
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .heatmap-cell {
        border: 2px solid currentColor;
    }

    .correlation-neutral {
        background: #fff;
        border: 2px solid var(--text-dark);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .tour-highlight {
        animation: none;
    }
}

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

.view.active {
    animation: fadeIn 0.3s ease-in-out;
}

/* Import Section */
.import-section {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-top: 20px;
}

.file-upload-area {
    border: 3px dashed var(--border-color);
    border-radius: 12px;
    padding: 60px 40px;
    text-align: center;
    background: var(--bg-light);
    transition: all 0.3s;
    cursor: pointer;
}

.file-upload-area:hover {
    border-color: var(--primary-color);
    background: rgba(102, 126, 234, 0.05);
}

.file-upload-area.drag-over {
    border-color: var(--primary-color);
    background: rgba(102, 126, 234, 0.1);
    transform: scale(1.02);
}

.upload-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.file-upload-area h4 {
    color: var(--text-dark);
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.file-upload-area p {
    color: var(--text-light);
    margin-bottom: 20px;
}

.import-format-guide {
    background: var(--bg-light);
    padding: 25px;
    border-radius: 12px;
}

.import-format-guide h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.import-format-guide ul {
    list-style: none;
    padding: 0;
}

.import-format-guide li {
    padding: 8px 0;
    color: var(--text-dark);
    border-bottom: 1px solid var(--border-color);
}

.import-format-guide li:last-child {
    border-bottom: none;
}

#import-preview {
    background: var(--bg-light);
    padding: 25px;
    border-radius: 12px;
    border: 2px solid var(--primary-color);
}

#import-preview-content {
    max-height: 300px;
    overflow-y: auto;
    background: white;
    padding: 20px;
    border-radius: 8px;
    margin: 15px 0;
}

.preview-item {
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 15px;
    align-items: start;
}

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

.preview-item-number {
    background: var(--primary-color);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.preview-item-details strong {
    color: var(--primary-color);
    display: block;
    margin-bottom: 5px;
}

.preview-item-details small {
    color: var(--text-light);
    display: block;
}

#import-status .success {
    background: rgba(76, 175, 80, 0.1);
    border-left: 4px solid var(--success-color);
    padding: 15px;
    border-radius: 8px;
    color: var(--success-color);
    font-weight: 600;
}

#import-status .error {
    background: rgba(231, 76, 60, 0.1);
    border-left: 4px solid var(--danger-color);
    padding: 15px;
    border-radius: 8px;
    color: var(--danger-color);
    font-weight: 600;
}

@media (max-width: 768px) {
    .import-section {
        grid-template-columns: 1fr;
    }
}

/* Emotional Mapping Styles */
.section-heading {
    color: var(--primary-color);
    font-size: 1.1rem;
    margin: 25px 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

.emotion-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

/* Correlation Heatmap */
#correlation-heatmap {
    overflow-x: auto;
    margin-top: 20px;
}

.correlation-disclaimer {
    background: rgba(255, 193, 7, 0.1);
    border-left: 4px solid var(--warning-color);
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 8px;
    color: var(--text-dark);
    font-size: 0.9rem;
}

.heatmap-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.heatmap-table th,
.heatmap-table td {
    padding: 12px 8px;
    text-align: center;
    border: 1px solid var(--border-color);
}

.heatmap-table th {
    background: var(--primary-color);
    color: white;
    font-weight: 600;
    position: sticky;
    top: 0;
    z-index: 10;
}

.heatmap-table th:first-child {
    left: 0;
    z-index: 11;
}

.heatmap-table td:first-child {
    background: var(--bg-light);
    font-weight: 600;
    text-align: left;
    position: sticky;
    left: 0;
}

.heatmap-cell {
    position: relative;
    font-weight: 700;
    color: white;
    border-radius: 4px;
    padding: 8px;
    min-width: 50px;
}

.correlation-strong-positive {
    background: linear-gradient(135deg, #4caf50 0%, #66bb6a 100%);
    background-image:
        repeating-linear-gradient(45deg, transparent, transparent 5px, rgba(255,255,255,0.15) 5px, rgba(255,255,255,0.15) 10px),
        linear-gradient(135deg, #4caf50 0%, #66bb6a 100%);
}

.correlation-moderate-positive {
    background: linear-gradient(135deg, #8bc34a 0%, #9ccc65 100%);
    background-image:
        repeating-linear-gradient(90deg, transparent, transparent 3px, rgba(255,255,255,0.15) 3px, rgba(255,255,255,0.15) 6px),
        linear-gradient(135deg, #8bc34a 0%, #9ccc65 100%);
}

.correlation-weak-positive {
    background: linear-gradient(135deg, #cddc39 0%, #d4e157 100%);
    background-image:
        repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0,0,0,0.1) 2px, rgba(0,0,0,0.1) 4px),
        linear-gradient(135deg, #cddc39 0%, #d4e157 100%);
    color: var(--text-dark);
}

.correlation-neutral {
    background: linear-gradient(135deg, #e0e0e0 0%, #eeeeee 100%);
    color: var(--text-dark);
}

.correlation-weak-negative {
    background: linear-gradient(135deg, #ffb74d 0%, #ffa726 100%);
    color: var(--text-dark);
}

.correlation-moderate-negative {
    background: linear-gradient(135deg, #ff9800 0%, #fb8c00 100%);
}

.correlation-strong-negative {
    background: linear-gradient(135deg, #f44336 0%, #e53935 100%);
}

.correlation-legend {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
}

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

.legend-color {
    width: 30px;
    height: 20px;
    border-radius: 4px;
}

/* Emotional Drivers */
#emotional-drivers-insights .driver-item {
    padding: 20px;
    background: var(--bg-light);
    border-left: 4px solid var(--primary-color);
    margin-bottom: 15px;
    border-radius: 8px;
}

#emotional-drivers-insights .driver-item h4 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

#emotional-drivers-insights .driver-strength {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0;
}

#emotional-drivers-insights .strength-bar {
    flex: 1;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

#emotional-drivers-insights .strength-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width 0.5s ease;
}

#emotional-drivers-insights .strength-value {
    font-weight: 700;
    color: var(--primary-color);
    min-width: 40px;
}

/* Help Tooltips */
.help-tooltip {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 10;
}

.tooltip-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: help;
    transition: all 0.3s;
}

.tooltip-icon:hover {
    background: var(--primary-dark);
    transform: scale(1.1);
}

.tooltip-text {
    visibility: hidden;
    position: absolute;
    top: 35px;
    right: 0;
    width: 280px;
    background: var(--text-dark);
    color: white;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 0.85rem;
    line-height: 1.4;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 100;
}

.tooltip-text::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 10px;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid var(--text-dark);
}

.help-tooltip:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Tour Highlight */
.tour-highlight {
    position: relative;
    outline: 3px solid var(--primary-color);
    outline-offset: 5px;
    border-radius: 12px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        outline-color: var(--primary-color);
    }
    50% {
        outline-color: var(--accent-color);
    }
}

/* Insights Panel */
.insights-panel {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    border-left: 4px solid var(--primary-color);
    padding: 20px;
    margin-top: 20px;
    border-radius: 8px;
}

.insights-panel h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.insights-panel ul {
    list-style: none;
    padding: 0;
}

.insights-panel li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
}

.insights-panel li:last-child {
    border-bottom: none;
}

.insights-panel .insight-icon {
    font-size: 1.2rem;
    margin-right: 10px;
}

.insights-panel .insight-strength {
    display: inline-block;
    padding: 2px 8px;
    background: var(--success-color);
    color: white;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-left: 8px;
}

.insights-panel .insight-strength.moderate {
    background: var(--warning-color);
}

.insights-panel .insight-strength.weak {
    background: var(--info-color);
}

/* AI Insights Styles */
.ai-query-section {
    margin-bottom: 30px;
}

.ai-query-section h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.ai-query-textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    resize: vertical;
    transition: all 0.3s;
}

.ai-query-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.ai-quick-actions {
    margin: 30px 0;
}

.ai-quick-actions h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.ai-button-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.ai-action-btn {
    padding: 15px 20px;
    background: white;
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    color: var(--primary-color);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
}

.ai-action-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.ai-response {
    background: var(--bg-light);
    border-radius: 12px;
    padding: 25px;
    margin-top: 30px;
    min-height: 200px;
}

.ai-response-placeholder {
    text-align: center;
    color: var(--text-light);
    padding: 60px 20px;
}

.ai-response-content {
    line-height: 1.8;
    color: var(--text-dark);
}

.ai-response-content h1,
.ai-response-content h2,
.ai-response-content h3,
.ai-response-content h4 {
    color: var(--primary-color);
    margin-top: 25px;
    margin-bottom: 15px;
}

.ai-response-content ul,
.ai-response-content ol {
    margin-left: 25px;
    margin-bottom: 15px;
}

.ai-response-content li {
    margin-bottom: 8px;
}

.ai-response-content strong {
    color: var(--primary-color);
}

.ai-response-content code {
    background: rgba(102, 126, 234, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
}

.ai-loading {
    text-align: center;
    padding: 40px;
}

.ai-spinner {
    border: 4px solid var(--border-color);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

/* ===== AI CHAT INTERFACE ===== */
.chat-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 140px);
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background: linear-gradient(135deg, var(--primary-color), #5a67d8);
    color: white;
    border-bottom: 3px solid rgba(255, 255, 255, 0.2);
}

.chat-header-info h3 {
    margin: 0;
    font-size: 1.3rem;
    color: white;
}

.chat-subtitle {
    margin: 5px 0 0 0;
    font-size: 0.85rem;
    opacity: 0.9;
}

.chat-header-actions {
    display: flex;
    gap: 10px;
}

.btn-sm {
    padding: 8px 15px;
    font-size: 0.85rem;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    background: var(--bg-light);
    scroll-behavior: smooth;
}

.chat-message {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    animation: slideInMessage 0.3s ease-out;
}

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

.user-message {
    flex-direction: row-reverse;
}

.message-avatar {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-center;
    font-size: 1.5rem;
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.user-message .message-avatar {
    background: var(--primary-color);
    color: white;
}

.message-content {
    max-width: 75%;
    flex: 1;
}

.message-text {
    background: white;
    padding: 15px 18px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    line-height: 1.6;
}

.user-message .message-text {
    background: var(--primary-color);
    color: white;
}

.message-text p {
    margin: 0 0 10px 0;
}

.message-text p:last-child {
    margin-bottom: 0;
}

.message-text strong {
    font-weight: 600;
}

.message-text em {
    font-style: italic;
    opacity: 0.9;
}

.message-time {
    font-size: 0.75rem;
    color: var(--text-light);
    margin-top: 5px;
}

.suggested-questions {
    padding: 15px 20px;
    background: white;
    border-top: 1px solid var(--border-color);
}

.suggestions-label {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 10px;
    font-weight: 500;
}

.suggestions-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.suggestion-chip {
    padding: 8px 14px;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.2s;
}

.suggestion-chip:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.quick-analysis-bar {
    display: flex;
    gap: 8px;
    padding: 12px 20px;
    background: white;
    border-top: 1px solid var(--border-color);
    overflow-x: auto;
}

.quick-btn {
    padding: 10px 16px;
    background: white;
    border: 2px solid var(--primary-color);
    border-radius: 20px;
    color: var(--primary-color);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    flex-shrink: 0;
}

.quick-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.chat-input-area {
    display: flex;
    gap: 12px;
    padding: 20px;
    background: white;
    border-top: 2px solid var(--border-color);
    align-items: flex-end;
}

.chat-input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 15px;
    font-family: inherit;
    resize: none;
    transition: all 0.3s;
    max-height: 120px;
}

.chat-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.btn-send-chat {
    padding: 12px 24px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.btn-send-chat:hover {
    background: #5a67d8;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-send-chat:active {
    transform: translateY(0);
}

.send-icon {
    font-size: 1.1rem;
}

.chat-typing {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 20px;
    background: white;
    border-top: 1px solid var(--border-color);
}

.typing-indicator {
    display: flex;
    gap: 4px;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary-color);
    animation: typingBounce 1.4s infinite;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingBounce {
    0%, 60%, 100% {
        transform: translateY(0);
    }
    30% {
        transform: translateY(-10px);
    }
}

.typing-text {
    font-size: 0.9rem;
    color: var(--text-light);
    font-style: italic;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .chat-container {
        height: calc(100vh - 100px);
    }

    .chat-header {
        padding: 15px;
    }

    .chat-header h3 {
        font-size: 1.1rem;
    }

    .message-content {
        max-width: 85%;
    }

    .quick-analysis-bar {
        padding: 10px;
    }

    .quick-btn {
        padding: 8px 12px;
        font-size: 0.8rem;
    }

    .chat-input-area {
        padding: 15px;
    }
}

.ai-config-warning {
    background: rgba(255, 193, 7, 0.1);
    border-left: 4px solid var(--warning-color);
    padding: 15px 20px;
    margin-bottom: 25px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.ai-config-warning .warning-icon {
    font-size: 2rem;
}

.ai-config-success {
    background: rgba(76, 175, 80, 0.1);
    border-left: 4px solid var(--success-color);
    padding: 15px 20px;
    margin-bottom: 25px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.ai-config-success .success-icon {
    font-size: 2rem;
}

.ai-error {
    background: rgba(231, 76, 60, 0.1);
    border-left: 4px solid var(--danger-color);
    padding: 20px;
    margin-top: 20px;
    border-radius: 8px;
    color: var(--danger-color);
}

@media (max-width: 1024px) {
    .grid-2col {
        grid-template-columns: 1fr;
    }

    .emotion-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }

    .ai-button-grid {
        grid-template-columns: 1fr;
    }
}

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

    /* Improved mobile heatmap */
    #correlation-heatmap {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        position: relative;
    }

    .heatmap-table {
        font-size: 0.7rem;
        min-width: 600px; /* Force horizontal scroll */
    }

    .heatmap-table th,
    .heatmap-table td {
        padding: 6px 3px;
        min-width: 45px;
    }

    .heatmap-cell {
        padding: 4px 2px;
        min-width: 40px;
        font-size: 0.65rem;
    }

    /* Mobile scroll hint */
    #correlation-heatmap::after {
        content: '← Scroll to see more →';
        display: block;
        text-align: center;
        color: var(--text-light);
        font-size: 0.75rem;
        padding: 10px;
        font-style: italic;
    }

    /* Tooltip positioning for mobile */
    .tooltip-text {
        width: 200px;
        right: auto;
        left: 50%;
        transform: translateX(-50%);
    }

    .tooltip-text::before {
        left: 50%;
        transform: translateX(-50%);
        right: auto;
    }

    .help-tooltip {
        position: static;
        display: inline-block;
        margin-left: 8px;
    }

    /* Insights panel mobile */
    .insights-panel {
        padding: 15px;
    }

    .insights-panel li {
        flex-direction: column;
        align-items: flex-start;
    }

    .insights-panel .insight-strength {
        margin-left: 0;
        margin-top: 5px;
    }

    /* Form stages for mobile */
    .stage-progress {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
    }

    .stage-indicator {
        min-width: 85px;
        font-size: 0.8rem;
    }

    /* Dashboard cards */
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .stat-value {
        font-size: 2rem;
    }

    /* Charts on mobile */
    canvas {
        max-height: 300px;
    }

    /* Navigation improvements */
    .correlation-legend {
        flex-direction: column;
        align-items: flex-start;
    }

    .legend-item {
        width: 100%;
        padding: 5px 0;
    }
}

/* ===== AUTHENTICATION STYLES ===== */

/* Auth Container */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    padding: 20px;
}

/* Auth Card */
.auth-card {
    background: white;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    max-width: 450px;
    width: 100%;
    padding: 40px;
    animation: slideUp 0.3s ease-out;
}

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

/* Auth Header */
.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-header h1 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.auth-subtitle {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* Auth Form */
.auth-form h2 {
    color: var(--text-dark);
    font-size: 1.5rem;
    margin-bottom: 24px;
    text-align: center;
}

.auth-description {
    color: var(--text-light);
    font-size: 0.9rem;
    text-align: center;
    margin-bottom: 24px;
    line-height: 1.5;
}

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

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

.auth-form input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s;
    background: white;
}

.auth-form input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.auth-form input::placeholder {
    color: var(--text-light);
}

.auth-form select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s;
    background: white;
    cursor: pointer;
}

.auth-form select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Form Section Headers */
.form-section-header {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 24px 0 16px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--border-color);
}

.form-section-header:first-child {
    margin-top: 0;
}

/* Password Requirements */
.password-requirements {
    margin-top: 12px;
    padding: 12px;
    background: var(--bg-light);
    border-radius: 6px;
    font-size: 0.85rem;
}

.password-requirement {
    padding: 4px 0;
    color: var(--text-light);
    transition: all 0.2s;
}

.password-requirement.valid {
    color: var(--success-color);
    font-weight: 500;
}

/* Auth Button */
.btn-auth {
    width: 100%;
    padding: 14px;
    font-size: 1rem;
    font-weight: 600;
    margin-top: 24px;
    border-radius: 8px;
    transition: all 0.3s;
}

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

/* Auth Links */
.auth-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.auth-links a {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.auth-links a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Auth Messages */
.auth-message {
    padding: 12px 16px;
    border-radius: 8px;
    margin: 16px 0;
    font-size: 0.9rem;
    display: none;
    line-height: 1.5;
    white-space: pre-line;
}

.auth-message.success {
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid var(--success-color);
    color: var(--success-color);
}

.auth-message.error {
    background: rgba(231, 76, 60, 0.1);
    border: 1px solid var(--danger-color);
    color: var(--danger-color);
}

/* User Profile in Sidebar */
.user-profile {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    margin-top: auto;
}

.user-info {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-right: 12px;
}

.user-details {
    flex: 1;
}

.user-name {
    font-weight: 600;
    font-size: 0.95rem;
}

.user-email {
    font-size: 0.8rem;
    opacity: 0.8;
}

.btn-logout {
    width: 100%;
    padding: 10px;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s;
}

.btn-logout:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Responsive Auth */
@media (max-width: 768px) {
    .auth-card {
        padding: 30px 20px;
    }

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

    .auth-links {
        flex-direction: column;
        gap: 12px;
    }
}

/* ===== TUTORIAL & ONBOARDING STYLES ===== */

/* Tutorial Overlay */
.tutorial-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    backdrop-filter: blur(2px);
}

/* Tutorial Tooltip */
.tutorial-tooltip {
    position: fixed;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    max-width: 450px;
    z-index: 9999;
    opacity: 0;
    transition: all 0.3s ease-out;
    animation: tutorialSlideIn 0.3s ease-out forwards;
}

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

.tutorial-tooltip-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 20px 15px 20px;
    border-bottom: 2px solid var(--border-color);
}

.tutorial-tooltip-header h3 {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.2rem;
}

.tutorial-close {
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-light);
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.tutorial-close:hover {
    background: var(--bg-light);
    color: var(--text-dark);
}

.tutorial-tooltip-content {
    padding: 20px;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-dark);
}

.tutorial-tooltip-footer {
    padding: 15px 20px 20px 20px;
    border-top: 1px solid var(--border-color);
}

.tutorial-progress {
    margin-bottom: 15px;
}

.tutorial-progress-text {
    display: block;
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 8px;
}

.tutorial-progress-bar {
    width: 100%;
    height: 6px;
    background: var(--border-color);
    border-radius: 3px;
    overflow: hidden;
}

.tutorial-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    transition: width 0.3s ease;
    border-radius: 3px;
}

.tutorial-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.btn-tutorial {
    padding: 10px 20px;
    font-size: 0.9rem;
    border-radius: 6px;
    transition: all 0.2s;
}

/* Highlight target element */
.tutorial-highlight {
    position: relative;
    z-index: 9997;
    box-shadow: 0 0 0 4px var(--primary-color), 0 0 0 8px rgba(102, 126, 234, 0.3);
    border-radius: 8px;
    animation: tutorialPulse 2s infinite;
}

@keyframes tutorialPulse {
    0%, 100% {
        box-shadow: 0 0 0 4px var(--primary-color), 0 0 0 8px rgba(102, 126, 234, 0.3);
    }
    50% {
        box-shadow: 0 0 0 4px var(--primary-color), 0 0 0 12px rgba(102, 126, 234, 0.5);
    }
}

/* Tutorial Completion Message */
.tutorial-completion-message {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10000;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: tutorialSlideIn 0.3s ease-out;
}

.tutorial-completion-content {
    padding: 40px;
    text-align: center;
    max-width: 450px;
}

.tutorial-completion-content h2 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.tutorial-completion-content p {
    margin: 10px 0;
    color: var(--text-dark);
    line-height: 1.6;
}

.tutorial-completion-content button {
    margin-top: 25px;
}

/* Help Modal */
.help-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.2s;
}

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

.help-modal {
    background: white;
    border-radius: 16px;
    max-width: 700px;
    width: 90%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: tutorialSlideIn 0.3s ease-out;
}

.help-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    border-bottom: 2px solid var(--border-color);
}

.help-modal-header h2 {
    margin: 0;
    color: var(--primary-color);
}

.help-modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-light);
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.help-modal-close:hover {
    background: var(--bg-light);
    color: var(--text-dark);
}

.help-modal-content {
    padding: 30px;
    overflow-y: auto;
    flex: 1;
    line-height: 1.7;
}

.help-modal-content h4 {
    color: var(--primary-color);
    margin: 20px 0 10px 0;
}

.help-modal-content ul, .help-modal-content ol {
    margin: 10px 0;
    padding-left: 25px;
}

.help-modal-content li {
    margin: 8px 0;
}

.help-modal-content strong {
    color: var(--text-dark);
}

.help-modal-footer {
    padding: 20px 30px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.help-modal-restart {
    margin-right: auto;
}

/* Help Button */
.btn-help {
    padding: 10px 18px;
    background: white;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s;
}

.btn-help:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Welcome Section */
.welcome-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 50px 40px;
    margin-bottom: 30px;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
}

.welcome-card h2 {
    color: white;
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-align: center;
}

.welcome-subtitle {
    text-align: center;
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.95;
}

.welcome-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.welcome-item {
    text-align: center;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    transition: all 0.3s;
}

.welcome-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
}

.welcome-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.welcome-item h4 {
    color: white;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.welcome-item p {
    font-size: 0.9rem;
    opacity: 0.9;
    line-height: 1.5;
}

.welcome-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
}

.btn-large {
    padding: 15px 30px;
    font-size: 1.05rem;
    font-weight: 600;
}

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

.welcome-actions .btn-primary:hover {
    background: var(--bg-light);
    transform: translateY(-3px);
}

.welcome-actions .btn-secondary {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid white;
    color: white;
}

.welcome-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Video Demo Section */
.video-demo-section {
    margin-top: 40px;
    padding-top: 40px;
    border-top: 2px solid rgba(255, 255, 255, 0.2);
}

.video-demo-section h3 {
    color: white;
    text-align: center;
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.video-placeholder {
    text-align: center;
    padding: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-style: italic;
    opacity: 0.8;
}

.video-container {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.video-container iframe {
    display: block;
    width: 100%;
    height: 400px;
    border: none;
}

/* Responsive Tutorial */
@media (max-width: 768px) {
    .tutorial-tooltip {
        max-width: 90%;
        left: 5% !important;
        right: 5% !important;
        top: auto !important;
        bottom: 20px !important;
    }

    .tutorial-buttons {
        flex-direction: column;
    }

    .btn-tutorial {
        width: 100%;
    }

    .welcome-card {
        padding: 30px 20px;
    }

    .welcome-card h2 {
        font-size: 2rem;
    }

    .welcome-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .welcome-actions {
        flex-direction: column;
    }

    .welcome-actions button {
        width: 100%;
    }

    .help-modal {
        max-width: 95%;
        max-height: 90vh;
    }

    .help-modal-footer {
        flex-direction: column;
    }

    .help-modal-restart {
        margin-right: 0;
    }
}

/* Need State Questionnaire */
.questionnaire-progress {
    margin-bottom: 30px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e0e4e8;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    transition: width 0.3s ease;
    width: 0%;
}

.progress-text {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-light);
    font-weight: 500;
}

.question-card {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
}

.question-card h4 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.question-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.question-option {
    display: flex;
    align-items: center;
    padding: 15px;
    background: white;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.question-option:hover {
    border-color: var(--primary-color);
    background: rgba(102, 126, 234, 0.05);
}

.question-option input[type="radio"] {
    margin-right: 12px;
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.question-option label {
    cursor: pointer;
    flex: 1;
    font-weight: 500;
}

.question-option.selected {
    border-color: var(--primary-color);
    background: rgba(102, 126, 234, 0.1);
}

.need-state-result-card {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    border: 2px solid var(--primary-color);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 15px;
}

.need-state-result-card h4 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.need-state-result-card .score {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.need-state-result-card .description {
    color: var(--text-dark);
    line-height: 1.6;
    margin-bottom: 15px;
}

.need-state-result-card .characteristics {
    background: white;
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
}

.need-state-result-card .characteristics h5 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 1rem;
}

.need-state-result-card .characteristics ul {
    list-style: none;
    padding: 0;
}

.need-state-result-card .characteristics li {
    padding: 5px 0;
    padding-left: 20px;
    position: relative;
}

.need-state-result-card .characteristics li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

/* Modal Base Styles for Need State Helper */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s;
}

.modal-content {
    background: white;
    border-radius: 16px;
    max-width: 700px;
    width: 90%;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: tutorialSlideIn 0.3s ease-out;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    border-bottom: 2px solid var(--border-color);
}

.modal-header h2 {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.5rem;
}

.modal-close {
    background: none;
    border: none;
    font-size: 32px;
    cursor: pointer;
    color: var(--text-light);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.modal-close:hover {
    background: var(--bg-light);
    color: var(--text-dark);
}

.modal-body {
    padding: 30px;
    overflow-y: auto;
    flex: 1;
}

/* Advanced Analytics Styles */
.advanced-analytics {
    margin-top: 20px;
}

.analytics-section {
    margin-bottom: 40px;
    padding: 25px;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.analytics-section h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.section-description {
    color: var(--text-light);
    margin-bottom: 20px;
    font-size: 0.95rem;
}

/* Statistical Cards */
.stat-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.stat-cards .stat-card {
    display: flex;
    gap: 15px;
    padding: 20px;
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    color: var(--text-dark);
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.15);
    border: 2px solid #bbdefb;
}

.stat-cards .stat-icon {
    font-size: 2rem;
    opacity: 0.8;
}

.stat-cards .stat-content {
    flex: 1;
}

.stat-cards .stat-label {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 5px;
}

.stat-cards .stat-value {
    font-size: 1.8rem;
    font-weight: bold;
    margin-bottom: 5px;
    color: var(--primary-color);
}

.stat-cards .stat-detail {
    font-size: 0.9rem;
    color: var(--text-dark);
}

.stat-cards .stat-detail-small {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 3px;
}

/* Trend Analysis */
.trend-analysis-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.trend-card {
    padding: 20px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s;
}

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

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

.trend-header h5 {
    margin: 0;
    color: var(--text-dark);
    font-size: 1.1rem;
}

.trend-badge {
    background: var(--bg-light);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    color: var(--text-light);
    font-weight: 600;
}

.trend-metric {
    margin-bottom: 10px;
}

.trend-label {
    font-size: 0.85rem;
    color: var(--text-light);
    display: block;
    margin-bottom: 5px;
}

.trend-change {
    font-size: 1.2rem;
    font-weight: bold;
    padding: 8px 12px;
    border-radius: 8px;
    display: inline-block;
}

.positive-change {
    background: rgba(67, 233, 123, 0.1);
    color: #27ae60;
}

.negative-change {
    background: rgba(235, 87, 87, 0.1);
    color: #e74c3c;
}

.no-change {
    background: var(--bg-light);
    color: var(--text-light);
}

.statistical-significance {
    margin: 10px 0;
    padding: 10px;
    background: rgba(67, 233, 123, 0.1);
    border-left: 3px solid #27ae60;
    border-radius: 4px;
}

.sig-badge {
    font-weight: 600;
    color: #27ae60;
    font-size: 0.9rem;
}

.statistical-insignificance {
    margin: 10px 0;
    padding: 10px;
    background: var(--bg-light);
    border-left: 3px solid var(--text-light);
    border-radius: 4px;
}

.insig-badge {
    font-weight: 600;
    color: var(--text-light);
    font-size: 0.9rem;
}

.sig-details {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 5px;
}

.trend-details {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.trend-stat {
    text-align: center;
}

.trend-stat span {
    display: block;
    font-size: 0.8rem;
    color: var(--text-light);
    margin-bottom: 5px;
}

.trend-stat strong {
    font-size: 1.1rem;
    color: var(--primary-color);
}

.trend-charts {
    margin-top: 30px;
    padding: 20px;
    background: var(--bg-light);
    border-radius: 8px;
}

/* Segmentation */
.segmentation-results {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 20px;
}

#segmentation-chart-container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.cluster-descriptions {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.cluster-card {
    padding: 15px;
    background: var(--bg-light);
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
}

.cluster-card h5 {
    margin: 0 0 10px 0;
    color: var(--primary-color);
    font-size: 1rem;
}

.cluster-products {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 10px;
}

.cluster-characteristics {
    margin-bottom: 10px;
}

.cluster-characteristics strong {
    font-size: 0.9rem;
    color: var(--text-dark);
}

.cluster-characteristics ul {
    margin: 5px 0 0 0;
    padding-left: 20px;
}

.cluster-characteristics li {
    font-size: 0.85rem;
    color: var(--text-dark);
    margin: 3px 0;
}

.cluster-examples {
    font-size: 0.85rem;
    color: var(--text-light);
}

.cluster-examples strong {
    color: var(--text-dark);
}

/* Predictive Insights */
.prediction-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.prediction-card {
    padding: 20px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
}

.prediction-card.highlight {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    border-color: var(--primary-color);
}

.prediction-card h5 {
    margin: 0 0 15px 0;
    color: var(--primary-color);
    font-size: 1.05rem;
}

.prediction-metric {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.prediction-strength {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 10px;
}

.prediction-accuracy {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.prediction-insight {
    font-size: 0.95rem;
    color: var(--text-dark);
    line-height: 1.5;
}

.recommendation-list ul {
    margin: 10px 0;
    padding-left: 20px;
}

.recommendation-list li {
    margin: 8px 0;
    color: var(--text-dark);
    line-height: 1.6;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .stat-cards {
        grid-template-columns: 1fr;
    }

    .segmentation-results {
        grid-template-columns: 1fr;
    }

    .trend-analysis-grid {
        grid-template-columns: 1fr;
    }

    .prediction-cards {
        grid-template-columns: 1fr;
    }
}

/* Consumer Panel Styles */
.consumer-panel-dashboard {
    padding: 10px 0;
}

.import-panel-form {
    display: grid;
    gap: 20px;
    padding: 20px;
    background: var(--bg-light);
    border-radius: 8px;
}

.import-panel-form .form-group {
    margin-bottom: 0;
}

.import-panel-form button {
    margin-right: 10px;
}

.panel-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.panel-card {
    padding: 20px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s;
}

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

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

.panel-header h5 {
    margin: 0;
    color: var(--text-dark);
    font-size: 1.1rem;
}

.panel-badge {
    background: var(--primary-color);
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

.panel-info {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 15px;
    padding: 15px;
    background: var(--bg-light);
    border-radius: 8px;
}

.panel-stat {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.panel-stat span {
    font-size: 0.8rem;
    color: var(--text-light);
}

.panel-stat strong {
    font-size: 1.1rem;
    color: var(--primary-color);
}

.panel-actions {
    display: flex;
    gap: 10px;
}

.btn-small {
    padding: 8px 16px;
    font-size: 0.85rem;
}

.comparison-results {
    margin-top: 20px;
}

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

.comparison-header h5 {
    margin: 0;
    color: var(--primary-color);
}

.correlation-badge {
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

.correlation-very-strong {
    background: rgba(67, 233, 123, 0.2);
    color: #27ae60;
}

.correlation-strong {
    background: rgba(52, 152, 219, 0.2);
    color: #2980b9;
}

.correlation-moderate {
    background: rgba(241, 196, 15, 0.2);
    color: #f39c12;
}

.correlation-weak, .correlation-very-weak {
    background: rgba(231, 76, 60, 0.2);
    color: #c0392b;
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

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

.comparison-table th {
    background: var(--bg-light);
    color: var(--text-dark);
    font-weight: 600;
}

.comparison-table .attribute-name {
    font-weight: 500;
}

.positive-diff {
    color: #27ae60;
}

.negative-diff {
    color: #e74c3c;
}

.agreement-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

.agreement-high {
    background: rgba(67, 233, 123, 0.2);
    color: #27ae60;
}

.agreement-moderate {
    background: rgba(241, 196, 15, 0.2);
    color: #f39c12;
}

.agreement-low {
    background: rgba(231, 76, 60, 0.2);
    color: #c0392b;
}

.comparison-notes {
    margin-top: 15px;
    padding: 15px;
    background: var(--bg-light);
    border-radius: 8px;
}

.comparison-notes p {
    margin: 5px 0;
}

.reformulation-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin-top: 20px;
}

.reformulation-card {
    padding: 25px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
}

.reformulation-card h5 {
    margin: 0 0 20px 0;
    color: var(--primary-color);
    font-size: 1.2rem;
}

.reform-timeline {
    display: flex;
    align-items: center;
    justify-content: space-around;
    margin-bottom: 25px;
    padding: 20px;
    background: var(--bg-light);
    border-radius: 8px;
}

.timeline-point {
    text-align: center;
}

.timeline-point strong {
    display: block;
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: var(--primary-color);
}

.timeline-point div {
    font-size: 0.9rem;
    color: var(--text-dark);
}

.sample-size {
    font-size: 0.8rem !important;
    color: var(--text-light) !important;
    margin-top: 5px;
}

.timeline-arrow {
    font-size: 2rem;
    color: var(--primary-color);
}

.purchase-intent-summary {
    margin-top: 15px;
    padding: 15px;
    background: var(--bg-light);
    border-radius: 8px;
    font-size: 1rem;
}

.pi-change {
    font-weight: bold;
    margin-left: 10px;
}

.pi-change.positive {
    color: #27ae60;
}

.pi-change.negative {
    color: #e74c3c;
}

#preference-map-container {
    padding: 20px;
    background: var(--bg-light);
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
}

@media (max-width: 768px) {
    .panel-list {
        grid-template-columns: 1fr;
    }

    .panel-info {
        grid-template-columns: 1fr;
    }

    .reform-timeline {
        flex-direction: column;
        gap: 20px;
    }

    .timeline-arrow {
        transform: rotate(90deg);
    }
}

/* Custom Lexicon Styles */
.lexicon-dashboard {
    padding: 10px 0;
}

.active-lexicon-card {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border: 2px solid #bbdefb;
    border-radius: 12px;
    padding: 25px;
}

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

.lexicon-header h3 {
    margin: 0 0 10px 0;
    color: var(--primary-color);
    font-size: 1.5rem;
}

.lexicon-meta {
    color: var(--text-light);
    font-size: 0.9rem;
    margin: 5px 0;
}

.lexicon-description {
    color: var(--text-dark);
    margin: 10px 0 0 0;
    line-height: 1.5;
}

.lexicon-stats {
    display: flex;
    gap: 30px;
    padding: 20px;
    background: white;
    border-radius: 8px;
}

.lexicon-stat {
    text-align: center;
}

.lexicon-stat span {
    display: block;
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.lexicon-stat label {
    font-size: 0.9rem;
    color: var(--text-light);
}

.lexicon-selector {
    max-width: 500px;
}

.lexicon-actions {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.lexicon-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.lexicon-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s;
}

.lexicon-item:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.lexicon-item-info {
    flex: 1;
}

.lexicon-item-info h5 {
    margin: 0 0 5px 0;
    color: var(--text-dark);
    font-size: 1.1rem;
}

.lexicon-item-meta {
    font-size: 0.85rem;
    color: var(--text-light);
    margin: 5px 0;
}

.lexicon-item-desc {
    font-size: 0.9rem;
    color: var(--text-dark);
    margin: 8px 0 0 0;
}

.lexicon-item-actions {
    display: flex;
    gap: 10px;
}

.template-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.template-card {
    padding: 25px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    text-align: center;
    transition: all 0.3s;
}

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

.template-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.template-card h5 {
    margin: 10px 0;
    color: var(--text-dark);
    font-size: 1.1rem;
}

.template-card p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin: 10px 0 20px 0;
}

.lexicon-editor {
    border: 2px solid var(--primary-color);
    background: linear-gradient(135deg, rgba(227, 242, 253, 0.3) 0%, rgba(243, 229, 245, 0.3) 100%);
}

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

.editor-meta {
    display: grid;
    gap: 15px;
    padding: 20px;
    background: white;
    border-radius: 8px;
    margin-bottom: 25px;
}

.stages-editor {
    padding: 20px;
    background: white;
    border-radius: 8px;
}

.stages-editor h5 {
    margin: 0 0 15px 0;
    color: var(--primary-color);
}

.stages-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 20px;
}

.stage-editor-card {
    padding: 20px;
    background: var(--bg-light);
    border: 2px solid var(--border-color);
    border-radius: 8px;
}

.stage-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.stage-editor-header h6 {
    margin: 0;
    color: var(--text-dark);
    font-size: 1.1rem;
}

.attributes-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.attribute-editor-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: white;
    border-radius: 6px;
}

.attribute-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.attribute-info strong {
    color: var(--text-dark);
}

.attribute-meta {
    font-size: 0.8rem;
    color: var(--text-light);
}

.attribute-desc {
    font-size: 0.85rem;
    color: var(--text-dark);
}

.emotions-editor {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
}

.emotions-editor strong {
    display: block;
    margin-bottom: 10px;
    color: var(--text-dark);
}

.emotions-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.emotion-tag {
    padding: 5px 12px;
    background: var(--primary-color);
    color: white;
    border-radius: 15px;
    font-size: 0.85rem;
}

@media (max-width: 768px) {
    .lexicon-header {
        flex-direction: column;
        gap: 15px;
    }

    .lexicon-stats {
        flex-direction: column;
        gap: 15px;
    }

    .lexicon-actions {
        flex-direction: column;
    }

    .lexicon-item {
        flex-direction: column;
        gap: 15px;
    }

    .lexicon-item-actions {
        width: 100%;
        justify-content: stretch;
    }

    .lexicon-item-actions button {
        flex: 1;
    }

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

/* Industry Benchmarks Styles */
.benchmarks-dashboard {
    padding: 10px 0;
}

.benchmarks-library {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin-top: 20px;
}

.benchmark-category h5 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.benchmark-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 15px;
}

.benchmark-item {
    padding: 20px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s;
}

.benchmark-item:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.benchmark-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.benchmark-item-header strong {
    color: var(--text-dark);
    font-size: 1.05rem;
}

.custom-badge {
    background: var(--primary-color);
    color: white;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

.default-badge {
    background: var(--success-color);
    color: white;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

.benchmark-meta {
    display: flex;
    gap: 15px;
    margin: 8px 0;
    font-size: 0.85rem;
    color: var(--text-light);
}

.benchmark-source {
    font-size: 0.8rem;
    color: var(--text-light);
    font-style: italic;
    margin: 8px 0;
}

.benchmark-actions {
    display: flex;
    gap: 8px;
    margin-top: 15px;
}

.comparison-selectors {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 15px;
    align-items: end;
    margin-bottom: 25px;
}

.comparison-results-card {
    margin-top: 25px;
    padding: 30px;
    background: white;
    border: 2px solid var(--primary-color);
    border-radius: 12px;
}

.results-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.results-header h5 {
    margin: 0;
    color: var(--text-dark);
}

.vs-text {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--text-light);
}

.overall-performance {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 30px;
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border-radius: 12px;
    margin-bottom: 30px;
}

.performance-badge {
    font-size: 1.2rem;
    font-weight: bold;
    padding: 12px 24px;
    border-radius: 24px;
}

.performance-badge-small {
    font-size: 0.8rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
}

.performance-exceptional {
    background: rgba(67, 233, 123, 0.2);
    color: #27ae60;
}

.performance-above-average {
    background: rgba(52, 152, 219, 0.2);
    color: #2980b9;
}

.performance-average {
    background: rgba(241, 196, 15, 0.2);
    color: #f39c12;
}

.performance-below-average {
    background: rgba(230, 126, 34, 0.2);
    color: #d68910;
}

.performance-needs-improvement {
    background: rgba(231, 76, 60, 0.2);
    color: #c0392b;
}

.percentile-display {
    text-align: center;
}

.percentile-value {
    font-size: 3rem;
    font-weight: bold;
    color: var(--primary-color);
}

.percentile-label {
    font-size: 1rem;
    color: var(--text-light);
}

.score-comparison {
    display: flex;
    gap: 30px;
    justify-content: center;
    align-items: center;
}

.score-comparison span {
    font-size: 1rem;
}

.your-score {
    color: var(--primary-color);
    font-weight: bold;
}

.benchmark-score {
    color: var(--text-light);
}

.score-comparison .diff {
    font-weight: bold;
    font-size: 1.2rem;
}

.score-comparison .diff.positive {
    color: #27ae60;
}

.score-comparison .diff.negative {
    color: #e74c3c;
}

.benchmark-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

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

.benchmark-table th {
    background: var(--bg-light);
    color: var(--text-dark);
    font-weight: 600;
}

.percentile-bar-container {
    position: relative;
    width: 100%;
    height: 24px;
    background: var(--bg-light);
    border-radius: 12px;
    overflow: hidden;
}

.percentile-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 12px;
    transition: width 0.3s ease;
}

.percentile-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.8rem;
    font-weight: bold;
    color: var(--text-dark);
}

.positioning-card {
    margin-top: 20px;
    padding: 25px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
}

.positioning-card h5 {
    margin: 0 0 20px 0;
    color: var(--primary-color);
}

.rankings-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ranking-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 15px;
    background: var(--bg-light);
    border-radius: 8px;
    transition: all 0.3s;
}

.ranking-item:hover {
    background: #e3f2fd;
}

.ranking-number {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    min-width: 50px;
    text-align: center;
}

.ranking-info {
    flex: 1;
}

.ranking-info strong {
    display: block;
    color: var(--text-dark);
    margin-bottom: 5px;
}

.ranking-meta {
    font-size: 0.85rem;
    color: var(--text-light);
}

.ranking-score {
    display: flex;
    align-items: center;
    gap: 15px;
}

.percentile-display-small {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--primary-color);
}

.custom-benchmark-form {
    display: grid;
    gap: 20px;
    padding: 25px;
    background: var(--bg-light);
    border-radius: 8px;
}

.product-checkbox-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 300px;
    overflow-y: auto;
    padding: 15px;
    background: white;
    border-radius: 8px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.checkbox-item:hover {
    background: var(--bg-light);
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

@media (max-width: 768px) {
    .benchmark-items {
        grid-template-columns: 1fr;
    }

    .comparison-selectors {
        grid-template-columns: 1fr;
    }

    .results-header {
        flex-direction: column;
    }

    .score-comparison {
        flex-direction: column;
        gap: 10px;
    }

    .ranking-item {
        flex-direction: column;
        text-align: center;
    }

    .ranking-score {
        flex-direction: column;
        gap: 10px;
    }
}

/* ===== EXPORT & REPORTS STYLING ===== */

.export-reports-dashboard {
    max-width: 1400px;
    margin: 0 auto;
}

/* Export Action Cards */
.export-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.export-action-card {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border: 2px solid #bbdefb;
    border-radius: 12px;
    padding: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    width: 100%;
}

.export-action-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
    border-color: var(--primary-color);
}

.export-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.export-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.export-description {
    font-size: 14px;
    color: var(--text-light);
    line-height: 1.5;
}

/* Product Export List */
.product-export-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.product-export-item {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
}

.product-export-item:hover {
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.1);
}

.product-export-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.product-export-info strong {
    font-size: 16px;
    color: var(--text-dark);
}

.product-meta {
    font-size: 14px;
    color: var(--text-light);
}

.product-export-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Comparison Export Form */
.comparison-export-form,
.benchmark-export-form {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 8px;
    margin-top: 20px;
}

.comparison-export-form .product-checkbox-list,
.benchmark-export-form .product-checkbox-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 10px;
    margin: 15px 0;
    max-height: 300px;
    overflow-y: auto;
    padding: 15px;
    background: white;
    border-radius: 6px;
}

/* Export Actions */
.export-actions {
    margin-top: 20px;
    text-align: center;
}

/* Button Styling */
.btn-small {
    padding: 8px 16px;
    font-size: 14px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.btn-small.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.btn-small.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.btn-small.btn-secondary {
    background: #e0e0e0;
    color: var(--text-dark);
}

.btn-small.btn-secondary:hover {
    background: #d0d0d0;
}

.btn-small.btn-danger {
    background: #f44336;
    color: white;
}

.btn-small.btn-danger:hover {
    background: #d32f2f;
}

/* Responsive Design */
@media (max-width: 768px) {
    .export-actions-grid {
        grid-template-columns: 1fr;
    }

    .product-export-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .product-export-actions {
        width: 100%;
        flex-direction: column;
    }

    .product-export-actions button {
        width: 100%;
    }

    .comparison-export-form .product-checkbox-list,
    .benchmark-export-form .product-checkbox-list {
        grid-template-columns: 1fr;
    }
}

/* Print Styles for Reports */
@media print {
    .no-print {
        display: none !important;
    }

    body {
        background: white;
    }

    .page-break {
        page-break-before: always;
    }
}

/* ===== BATCH IMPORT STYLING ===== */

.batch-import-dashboard {
    max-width: 1400px;
    margin: 0 auto;
}

/* File Upload Zone */
.file-upload-zone {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border: 3px dashed #bbdefb;
    border-radius: 12px;
    padding: 60px 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 20px 0;
}

.file-upload-zone:hover,
.file-upload-zone.drag-over {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #bbdefb 0%, #e1bee7 100%);
    transform: scale(1.02);
}

.file-upload-zone .upload-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

.file-upload-zone h5 {
    color: var(--text-dark);
    margin: 15px 0;
    font-size: 24px;
}

.file-upload-zone p {
    color: var(--text-light);
    margin-bottom: 25px;
}

.file-upload-zone .upload-formats {
    margin-top: 20px;
    font-size: 14px;
    color: var(--text-light);
}

/* File Info */
.file-info {
    background: white;
    border: 2px solid #4caf50;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.file-info-item {
    display: flex;
    gap: 8px;
    align-items: center;
    font-size: 14px;
}

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

/* Batch Import Actions */
.batch-import-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
    flex-wrap: wrap;
}

/* Column Mapping Grid */
.column-mapping-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

.mapping-category {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 25px;
    border: 2px solid #e0e0e0;
}

.mapping-category h5 {
    color: var(--primary-color);
    margin: 0 0 20px 0;
    font-size: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e3f2fd;
}

.mapping-fields {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.mapping-field {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.mapping-field label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
}

.column-select {
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    background: white;
    font-size: 14px;
    cursor: pointer;
    transition: border-color 0.2s ease;
}

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

.column-select:hover {
    border-color: #bbdefb;
}

/* Mapping Controls */
.mapping-controls {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

/* Validation Summary */
.validation-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 25px 0;
}

.validation-stat {
    background: white;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    border: 3px solid;
}

.validation-stat.valid {
    border-color: #4caf50;
}

.validation-stat.invalid {
    border-color: #f44336;
}

.validation-stat.warning {
    border-color: #ff9800;
}

.validation-icon {
    font-size: 48px;
    margin-bottom: 10px;
}

.validation-count {
    font-size: 36px;
    font-weight: 700;
    margin: 10px 0;
}

.validation-count {
    color: var(--text-dark);
}

.validation-stat.valid .validation-count {
    color: #4caf50;
}

.validation-stat.invalid .validation-count {
    color: #f44336;
}

.validation-stat.warning .validation-count {
    color: #ff9800;
}

.validation-label {
    font-size: 14px;
    color: var(--text-light);
    text-transform: uppercase;
    font-weight: 600;
}

/* Preview Table */
.preview-table-container {
    background: white;
    border-radius: 8px;
    padding: 20px;
    margin: 25px 0;
    overflow-x: auto;
}

.preview-table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
}

.preview-table thead {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.preview-table th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.preview-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #e0e0e0;
    font-size: 14px;
}

.preview-table tr.valid-row {
    background: #f1f8f4;
}

.preview-table tr.invalid-row {
    background: #ffebee;
}

.preview-table tr:hover {
    background: #e3f2fd;
}

.preview-note {
    text-align: center;
    color: var(--text-light);
    font-size: 14px;
    margin-top: 15px;
}

/* Validation Issues */
.validation-issues {
    background: #fff3e0;
    border-left: 4px solid #ff9800;
    border-radius: 8px;
    padding: 20px;
    margin: 25px 0;
}

.validation-issues h5 {
    margin: 0 0 15px 0;
    color: #ff9800;
}

.issue-item {
    padding: 10px 0;
    border-bottom: 1px solid #ffe0b2;
}

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

.issue-item strong {
    display: block;
    margin-bottom: 5px;
    color: var(--text-dark);
}

.error-text {
    display: block;
    color: #f44336;
    font-size: 14px;
    margin: 5px 0;
}

.warning-text {
    display: block;
    color: #ff9800;
    font-size: 14px;
    margin: 5px 0;
}

/* Import Actions */
.import-actions {
    display: flex;
    gap: 15px;
    margin: 30px 0;
    flex-wrap: wrap;
    justify-content: center;
}

/* Large Button */
.btn-large {
    padding: 16px 40px;
    font-size: 18px;
    font-weight: 600;
}

/* Responsive Design */
@media (max-width: 768px) {
    .column-mapping-grid {
        grid-template-columns: 1fr;
    }

    .validation-summary {
        grid-template-columns: 1fr;
    }

    .file-upload-zone {
        padding: 40px 20px;
    }

    .file-info {
        flex-direction: column;
        align-items: flex-start;
    }

    .preview-table-container {
        overflow-x: scroll;
    }

    .preview-table {
        min-width: 600px;
    }
}

/* ===== RECIPE/FORMULATION TRACKER STYLING ===== */

.recipe-tracker-dashboard {
    max-width: 1400px;
    margin: 0 auto;
}

/* Formulation List */
.formulation-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin-top: 20px;
}

.product-formulation-card {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 25px;
    transition: all 0.2s ease;
}

.product-formulation-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.1);
}

.product-formulation-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e3f2fd;
}

.product-formulation-header h5 {
    margin: 0;
    color: var(--text-dark);
    font-size: 20px;
}

.formulation-count {
    background: #e3f2fd;
    color: var(--primary-color);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

/* Formulation Item */
.formulations-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 20px;
}

.formulation-item {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    border-left: 4px solid var(--primary-color);
}

.formulation-info {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.formulation-info strong {
    font-size: 16px;
    color: var(--text-dark);
}

.formulation-version {
    background: white;
    color: var(--primary-color);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid var(--primary-color);
}

.formulation-status {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.status-development {
    background: #fff3e0;
    color: #ff9800;
}

.status-testing {
    background: #e3f2fd;
    color: #2196f3;
}

.status-production {
    background: #e8f5e9;
    color: #4caf50;
}

.status-discontinued {
    background: #ffebee;
    color: #f44336;
}

.formulation-meta {
    display: flex;
    gap: 20px;
    color: var(--text-light);
    font-size: 14px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.formulation-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    background: white;
    border-radius: 12px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.formulation-edit-modal {
    max-width: 1000px;
}

.modal-header {
    padding: 25px;
    border-bottom: 2px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    color: var(--text-dark);
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-light);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #f0f0f0;
    color: var(--text-dark);
}

.modal-body {
    padding: 25px;
}

.modal-footer {
    padding: 20px 25px;
    border-top: 2px solid #e0e0e0;
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

/* Formulation Details */
.formulation-details {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.detail-section {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
}

.detail-section h4 {
    margin: 0 0 20px 0;
    color: var(--primary-color);
    font-size: 18px;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.detail-label {
    font-size: 12px;
    color: var(--text-light);
    text-transform: uppercase;
    font-weight: 600;
}

/* Ingredients Table */
.ingredients-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
}

.ingredients-table thead {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.ingredients-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.ingredients-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #e0e0e0;
    font-size: 14px;
}

.ingredients-table tr:hover {
    background: #f8f9fa;
}

.ingredient-total {
    margin-top: 15px;
    text-align: right;
    font-size: 16px;
    color: var(--text-dark);
}

/* Processing Steps */
.processing-steps {
    list-style: none;
    counter-reset: step-counter;
    padding: 0;
}

.processing-steps li {
    counter-increment: step-counter;
    background: white;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
    position: relative;
    padding-left: 50px;
}

.processing-steps li::before {
    content: counter(step-counter);
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--primary-color);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}

.processing-steps li small {
    color: var(--text-light);
}

/* Form Sections */
.form-section {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.form-section h4 {
    margin: 0 0 15px 0;
    color: var(--primary-color);
}

/* Ingredient Editor */
#ingredients-editor {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.ingredient-editor-row {
    display: grid;
    grid-template-columns: 2fr 1.5fr 0.8fr 1fr 0.8fr auto;
    gap: 10px;
    align-items: center;
}

.ingredient-editor-row input,
.ingredient-editor-row select {
    padding: 8px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
}

.ingredient-editor-row input:focus,
.ingredient-editor-row select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.ingredient-name {
    font-weight: 500;
}

/* Comparison Results */
.comparison-results {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin-top: 25px;
    border: 2px solid #e0e0e0;
}

.comparison-results h5 {
    margin: 0 0 20px 0;
    color: var(--text-dark);
}

.comparison-summary {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 20px;
    align-items: center;
    margin-bottom: 25px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.comparison-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.comparison-item strong {
    font-size: 16px;
    color: var(--text-dark);
}

.comparison-item span {
    font-size: 14px;
    color: var(--text-light);
}

.vs-text {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-color);
    text-align: center;
}

.cost-change {
    background: #e3f2fd;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cost-increase {
    color: #f44336;
    font-weight: 600;
}

.cost-decrease {
    color: #4caf50;
    font-weight: 600;
}

.ingredient-changes {
    margin-bottom: 25px;
}

.ingredient-changes h6 {
    margin: 0 0 15px 0;
    color: var(--text-dark);
    font-size: 16px;
}

.ingredient-changes ul {
    list-style: none;
    padding: 0;
}

.ingredient-changes li {
    background: #f8f9fa;
    padding: 10px 15px;
    margin-bottom: 8px;
    border-radius: 6px;
    border-left: 3px solid var(--primary-color);
}

/* Changes Table */
.changes-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
}

.changes-table thead {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.changes-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.changes-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #e0e0e0;
    font-size: 14px;
}

.positive-change {
    color: #4caf50;
    font-weight: 600;
}

.negative-change {
    color: #f44336;
    font-weight: 600;
}

/* Responsive Design */
@media (max-width: 768px) {
    .formulation-info {
        flex-direction: column;
        align-items: flex-start;
    }

    .formulation-meta {
        flex-direction: column;
        gap: 8px;
    }

    .formulation-actions {
        flex-direction: column;
    }

    .formulation-actions button {
        width: 100%;
    }

    .ingredient-editor-row {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .comparison-summary {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .modal-content {
        max-width: 100%;
        margin: 0;
        border-radius: 0;
        max-height: 100vh;
    }

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

/* ===== TEMPORAL ANALYSIS STYLING ===== */

.temporal-analysis-dashboard {
    max-width: 1400px;
    margin: 0 auto;
}

/* Temporal Product Grid */
.temporal-product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.temporal-product-card {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border: 2px solid #bbdefb;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.temporal-product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
    border-color: var(--primary-color);
}

.temporal-product-card .product-name {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.product-temporal-stats {
    display: flex;
    gap: 15px;
    margin: 10px 0;
}

.product-temporal-stats span {
    background: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 13px;
    color: var(--primary-color);
    font-weight: 500;
}

.product-date-range {
    font-size: 13px;
    color: var(--text-light);
    margin-top: 8px;
}

/* Temporal Info Box */
.temporal-info-box {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 25px;
    margin-top: 20px;
}

.temporal-info-box h5 {
    color: var(--primary-color);
    margin: 0 0 15px 0;
}

.temporal-info-box ol, .temporal-info-box ul {
    margin: 10px 0;
    padding-left: 25px;
}

.temporal-info-box li {
    margin: 8px 0;
}

/* Analysis Results */
.temporal-analysis-results {
    margin-top: 30px;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e3f2fd;
}

.results-header h4 {
    margin: 0;
    color: var(--text-dark);
}

/* Chart Selector */
.chart-selector {
    margin: 20px 0;
}

.chart-selector label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-dark);
}

/* Charts Container */
.charts-container {
    margin-top: 25px;
}

.chart-group {
    margin-bottom: 40px;
}

.chart-group h6 {
    color: var(--primary-color);
    margin: 0 0 20px 0;
    font-size: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e3f2fd;
}

.chart-wrapper {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
}

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

.chart-title {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 16px;
}

.chart-trend {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
}

.trend-increasing {
    background: #e8f5e9;
    color: #4caf50;
}

.trend-decreasing {
    background: #ffebee;
    color: #f44336;
}

.trend-stable {
    background: #e3f2fd;
    color: #2196f3;
}

.time-series-chart {
    height: 200px;
    max-height: 200px;
}

/* Shelf Life Analysis */
.shelf-life-stable {
    display: flex;
    align-items: center;
    gap: 20px;
    background: #e8f5e9;
    border-left: 4px solid #4caf50;
    padding: 20px;
    border-radius: 8px;
}

.shelf-life-stable .status-icon {
    font-size: 48px;
}

.shelf-life-stable .status-message strong {
    display: block;
    color: #4caf50;
    font-size: 18px;
    margin-bottom: 5px;
}

.shelf-life-warning {
    background: #fff3e0;
    border-left: 4px solid #ff9800;
    padding: 20px;
    border-radius: 8px;
}

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

.warning-icon {
    font-size: 32px;
}

.warning-header strong {
    font-size: 18px;
    color: #ff9800;
}

.shelf-life-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.shelf-life-details .detail-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.shelf-life-details .detail-label {
    font-size: 12px;
    color: var(--text-light);
    text-transform: uppercase;
    font-weight: 600;
}

.shelf-life-details .detail-value {
    font-size: 16px;
    color: var(--text-dark);
    font-weight: 500;
}

.shelf-life-details .detail-value.highlight {
    color: #ff9800;
    font-size: 20px;
    font-weight: 700;
}

.other-degrading {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #ffe0b2;
}

.other-degrading ul {
    list-style: none;
    padding: 0;
    margin: 10px 0;
}

.other-degrading li {
    padding: 8px 0;
    font-size: 14px;
}

/* Batch Variation */
.variation-summary {
    margin: 20px 0;
}

.consistency-badge {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 16px;
    font-size: 14px;
    font-weight: 600;
}

.consistency-high {
    background: #e8f5e9;
    color: #4caf50;
}

.consistency-moderate {
    background: #fff3e0;
    color: #ff9800;
}

.consistency-low {
    background: #ffebee;
    color: #f44336;
}

.variation-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    margin-top: 20px;
}

.variation-table thead {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.variation-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.variation-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #e0e0e0;
    font-size: 14px;
}

.variation-table tr:hover {
    background: #f8f9fa;
}

.table-note {
    text-align: center;
    color: var(--text-light);
    font-size: 13px;
    margin-top: 10px;
}

/* Fresh vs Aged Comparison */
.comparison-timeline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.timeline-point {
    text-align: center;
}

.timeline-label {
    font-size: 16px;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.timeline-date {
    font-size: 14px;
    color: var(--text-light);
}

.timeline-arrow {
    font-size: 32px;
    color: var(--primary-color);
}

/* Significant Changes */
.significant-changes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.change-card {
    background: white;
    border-radius: 8px;
    padding: 15px;
    border: 2px solid;
    display: flex;
    align-items: center;
    gap: 12px;
}

.change-card.severity-high {
    border-color: #f44336;
    background: #ffebee;
}

.change-card.severity-moderate {
    border-color: #ff9800;
    background: #fff3e0;
}

.change-icon {
    font-size: 32px;
}

.change-info {
    flex: 1;
}

.change-info strong {
    display: block;
    font-size: 14px;
    color: var(--text-dark);
    margin-bottom: 4px;
}

.change-info div {
    font-size: 13px;
    color: var(--text-light);
}

.change-value {
    font-size: 18px;
    font-weight: 700;
}

.change-value.positive {
    color: #4caf50;
}

.change-value.negative {
    color: #f44336;
}

/* Responsive Design */
@media (max-width: 768px) {
    .temporal-product-grid {
        grid-template-columns: 1fr;
    }

    .results-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

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

    .shelf-life-details {
        grid-template-columns: 1fr;
    }

    .comparison-timeline {
        flex-direction: column;
        gap: 15px;
    }

    .significant-changes-grid {
        grid-template-columns: 1fr;
    }

    .variation-table {
        font-size: 12px;
    }

    .variation-table th, .variation-table td {
        padding: 8px;
    }
}

/* ===== PHOTO GALLERY STYLES ===== */

/* Photo Gallery Dashboard */
.photo-gallery-overview {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 30px;
}

.photo-gallery-overview h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.8rem;
}

.photo-overview-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.photo-stat-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.photo-stat-card .stat-label {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 8px;
}

.photo-stat-card .stat-value {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
}

/* Photo Filter Section */
.photo-filter-section {
    background: white;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-sm);
}

.photo-filter-section h3 {
    margin-bottom: 15px;
    color: var(--text-dark);
}

.filter-controls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

.filter-controls select {
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
}

/* Photo Grid */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.photo-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    cursor: pointer;
}

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

.photo-card-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    background: #f0f0f0;
}

.photo-card-content {
    padding: 15px;
}

.photo-card-title {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
    font-size: 1.1rem;
}

.photo-card-caption {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.photo-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-light);
}

.photo-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

.photo-tag {
    display: inline-block;
    padding: 4px 10px;
    background: var(--bg-light);
    border-radius: 12px;
    font-size: 0.75rem;
    color: var(--primary-color);
    font-weight: 500;
}

/* Upload Dialog */
.upload-dialog {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.2s ease;
}

.upload-dialog-content {
    background: white;
    border-radius: 16px;
    padding: 30px;
    max-width: 600px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    animation: slideUp 0.3s ease;
}

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

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

.upload-dialog h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.6rem;
}

/* Drag and Drop Zone */
.photo-drop-zone {
    border: 3px dashed var(--border-color);
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    margin-bottom: 20px;
    transition: all 0.3s ease;
    cursor: pointer;
    background: var(--bg-light);
}

.photo-drop-zone:hover,
.photo-drop-zone.drag-over {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
}

.photo-drop-zone p {
    color: var(--text-light);
    margin-top: 10px;
}

.photo-drop-zone input[type="file"] {
    display: none;
}

.upload-icon {
    font-size: 3rem;
    margin-bottom: 10px;
}

/* Photo Preview */
.photo-preview-section {
    margin: 20px 0;
}

.photo-preview-section h4 {
    margin-bottom: 15px;
    color: var(--text-dark);
}

.photo-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 15px;
}

.photo-preview-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.photo-preview-item img {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.photo-preview-remove {
    position: absolute;
    top: 5px;
    right: 5px;
    background: var(--danger-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    transition: transform 0.2s ease;
}

.photo-preview-remove:hover {
    transform: scale(1.1);
}

/* Tag Selector */
.tag-selector {
    margin: 20px 0;
}

.tag-selector h4 {
    margin-bottom: 12px;
    color: var(--text-dark);
}

.tag-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    max-height: 200px;
    overflow-y: auto;
    padding: 15px;
    background: var(--bg-light);
    border-radius: 8px;
}

.tag-option {
    display: flex;
    align-items: center;
    gap: 6px;
}

.tag-option input[type="checkbox"] {
    cursor: pointer;
}

.tag-option label {
    cursor: pointer;
    user-select: none;
}

/* Photo Viewer Modal */
.photo-viewer-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    animation: fadeIn 0.2s ease;
}

.photo-viewer-content {
    position: relative;
    max-width: 90%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.photo-viewer-image {
    max-width: 100%;
    max-height: 70vh;
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
}

.photo-viewer-info {
    background: white;
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
    max-width: 600px;
    width: 100%;
}

.photo-viewer-info h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.photo-viewer-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

.photo-viewer-meta-item {
    display: flex;
    flex-direction: column;
}

.photo-viewer-meta-label {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 4px;
}

.photo-viewer-meta-value {
    font-weight: 600;
    color: var(--text-dark);
}

.photo-viewer-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.photo-viewer-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: white;
    color: var(--text-dark);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.photo-viewer-close:hover {
    background: var(--danger-color);
    color: white;
    transform: rotate(90deg);
}

/* Edit Photo Dialog */
.edit-photo-dialog {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1500;
    animation: fadeIn 0.2s ease;
}

.edit-photo-content {
    background: white;
    border-radius: 16px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    animation: slideUp 0.3s ease;
}

.edit-photo-content h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
}

/* Empty State */
.photo-empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-light);
}

.photo-empty-state .empty-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.5;
}

.photo-empty-state h3 {
    color: var(--text-dark);
    margin-bottom: 10px;
}

.photo-empty-state p {
    margin-bottom: 25px;
}

/* Product Photos Section */
.product-photos-section {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin-top: 25px;
    box-shadow: var(--shadow-sm);
}

.product-photos-section h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

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

.product-photo-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: all 0.3s ease;
}

.product-photo-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.product-photo-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.product-photo-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    padding: 10px;
    color: white;
    font-size: 0.85rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .photo-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
    
    .product-photo-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
    
    .photo-overview-stats {
        grid-template-columns: 1fr;
    }
    
    .photo-viewer-image {
        max-height: 50vh;
    }
    
    .upload-dialog-content {
        width: 95%;
        padding: 20px;
    }
}

/* Loading State */
.photo-loading {
    text-align: center;
    padding: 40px;
    color: var(--text-light);
}

.photo-loading-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid var(--bg-light);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Storage Warning */
.storage-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffe4a3 100%);
    border-left: 4px solid var(--warning-color);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.storage-warning h4 {
    color: var(--warning-color);
    margin-bottom: 8px;
}

.storage-warning p {
    color: var(--text-dark);
    font-size: 0.9rem;
}

/* ===== TEAM COLLABORATION STYLES ===== */

/* Team Overview */
.team-collaboration-dashboard {
    padding: 0;
}

.team-overview-section {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 30px;
}

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

.team-header h2 {
    color: var(--primary-color);
    margin: 0;
    font-size: 1.8rem;
}

.team-subtitle {
    color: var(--text-light);
    margin-top: 5px;
}

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

.team-stat-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 15px;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.stat-content .stat-value {
    font-size: 2rem;
    font-weight: bold;
    color: var(--text-dark);
    line-height: 1;
}

.stat-content .stat-label {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-top: 5px;
}

/* Team Members */
.team-members-section {
    margin-top: 30px;
}

.team-members-list {
    display: grid;
    gap: 15px;
    margin-top: 20px;
}

.team-member-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    background: var(--bg-light);
    border-radius: 12px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.team-member-card.current-user {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
}

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

.member-avatar {
    position: relative;
    width: 60px;
    height: 60px;
}

.member-avatar img,
.avatar-placeholder {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
}

.avatar-placeholder {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
}

.member-avatar-small img,
.avatar-placeholder-small {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.avatar-placeholder-small {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: bold;
}

.current-user-badge {
    position: absolute;
    bottom: -5px;
    right: -5px;
    background: var(--primary-color);
    color: white;
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 600;
}

.member-info {
    flex: 1;
}

.member-name {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--text-dark);
}

.member-email {
    color: var(--text-light);
    font-size: 0.9rem;
}

.member-meta {
    display: flex;
    gap: 15px;
    margin-top: 5px;
    align-items: center;
}

.member-role {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.member-joined {
    font-size: 0.85rem;
    color: var(--text-light);
}

.member-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.role-selector {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
}

.btn-icon {
    padding: 8px 12px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

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

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

/* Role Permissions */
.role-permissions-section {
    margin-top: 30px;
}

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

.permission-card {
    background: var(--bg-light);
    padding: 20px;
    border-radius: 12px;
}

.permission-card h4 {
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.permission-card ul {
    list-style: none;
    padding: 0;
}

.permission-card li {
    padding: 8px 0;
    color: var(--text-dark);
}

/* Share Product Dialog */
.shared-users-section {
    margin-bottom: 25px;
    padding-bottom: 25px;
    border-bottom: 1px solid var(--border-color);
}

.shared-user-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--bg-light);
    border-radius: 8px;
    margin-bottom: 10px;
}

.shared-user-info {
    flex: 1;
}

.shared-user-name {
    font-weight: 600;
    color: var(--text-dark);
}

.shared-user-meta {
    font-size: 0.85rem;
    color: var(--text-light);
}

.btn-danger-outline {
    border: 1px solid var(--danger-color);
    color: var(--danger-color);
    background: white;
}

.btn-danger-outline:hover {
    background: var(--danger-color);
    color: white;
}

/* User Checklist */
.user-checklist {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px;
}

.user-checkbox-item {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.user-checkbox-item:hover {
    background: var(--bg-light);
}

.user-checkbox-item input[type="checkbox"] {
    margin-right: 12px;
    cursor: pointer;
}

.user-checkbox-content {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.user-checkbox-name {
    font-weight: 600;
    color: var(--text-dark);
}

.user-checkbox-role {
    font-size: 0.85rem;
    color: var(--text-light);
}

/* ===== COMMENTS STYLES ===== */

.comments-section {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin-top: 25px;
    box-shadow: var(--shadow-sm);
}

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

.comments-header h3 {
    color: var(--primary-color);
    margin: 0;
}

/* Add Comment Form */
.add-comment-form {
    margin-bottom: 25px;
    padding: 15px;
    background: var(--bg-light);
    border-radius: 12px;
}

.comment-input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    margin-bottom: 10px;
}

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

.comment-form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.comment-form-hints small {
    color: var(--text-light);
}

.comment-form-buttons {
    display: flex;
    gap: 10px;
}

/* Comment Thread */
.comments-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.comment-thread {
    padding-left: 0;
}

.comment-card {
    display: flex;
    gap: 12px;
    padding: 15px;
    background: var(--bg-light);
    border-radius: 12px;
    margin-bottom: 10px;
}

.comment-avatar {
    flex-shrink: 0;
}

.comment-content {
    flex: 1;
}

.comment-header {
    display: flex;
    gap: 10px;
    margin-bottom: 8px;
}

.comment-author {
    font-weight: 600;
    color: var(--text-dark);
}

.comment-time {
    color: var(--text-light);
    font-size: 0.85rem;
}

.comment-text {
    color: var(--text-dark);
    line-height: 1.6;
    margin-bottom: 10px;
}

.mention {
    color: var(--primary-color);
    font-weight: 600;
}

/* Comment Reactions */
.comment-reactions {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.reaction-bubble {
    padding: 4px 10px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.reaction-bubble:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-sm);
}

.reaction-bubble.user-reacted {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.reaction-btn {
    padding: 4px 10px;
    background: transparent;
    border: 1px dashed var(--border-color);
    border-radius: 12px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.reaction-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* Reaction Picker */
.reaction-picker-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.reaction-picker {
    background: white;
    padding: 15px;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    display: flex;
    gap: 10px;
}

.reaction-emoji {
    padding: 10px;
    background: transparent;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.reaction-emoji:hover {
    background: var(--bg-light);
    transform: scale(1.2);
}

/* Comment Actions */
.comment-actions {
    display: flex;
    gap: 15px;
}

.comment-action-btn {
    background: transparent;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    font-size: 0.9rem;
    padding: 4px 8px;
    transition: color 0.2s ease;
}

.comment-action-btn:hover {
    color: var(--primary-color);
}

.comment-action-btn.text-danger:hover {
    color: var(--danger-color);
}

/* Reply Container */
.reply-container {
    margin-top: 15px;
}

/* Empty Comments */
.empty-comments {
    text-align: center;
    padding: 40px;
    color: var(--text-light);
}

/* ===== ACTIVITY FEED STYLES ===== */

.activity-feed {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

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

.activity-feed-header h3 {
    color: var(--primary-color);
    margin: 0;
}

.activity-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.activity-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: var(--bg-light);
    border-radius: 8px;
    border-left: 3px solid var(--primary-color);
}

.activity-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

.activity-content {
    flex: 1;
}

.activity-text {
    color: var(--text-dark);
    font-size: 0.95rem;
}

.activity-time {
    color: var(--text-light);
    font-size: 0.85rem;
    margin-top: 4px;
}

.empty-activity {
    text-align: center;
    padding: 40px;
    color: var(--text-light);
}

/* Activity Widget */
.activity-widget {
    padding: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.activity-widget h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.activity-widget-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.activity-widget-item {
    display: flex;
    gap: 10px;
    padding: 8px;
    font-size: 0.9rem;
}

.activity-widget-icon {
    flex-shrink: 0;
}

.activity-widget-text {
    color: var(--text-dark);
}

.activity-widget-link {
    display: block;
    margin-top: 15px;
    text-align: right;
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.9rem;
}

.activity-widget-link:hover {
    text-decoration: underline;
}

/* ===== APPROVAL WORKFLOW STYLES ===== */

.approvals-dashboard {
    padding: 0;
}

.approvals-overview {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 30px;
}

.approvals-overview h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
}

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

.approval-stat-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.approval-stat-card.pending {
    border-left: 4px solid #ff9800;
}

.approval-stat-card.submitted {
    border-left: 4px solid #2196f3;
}

.approval-stat-card.approved {
    border-left: 4px solid #4caf50;
}

.approval-stat-card.rate {
    border-left: 4px solid #667eea;
}

.approvals-section {
    margin-bottom: 30px;
}

.approvals-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.approval-card {
    background: var(--bg-light);
    padding: 20px;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

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

.approval-status {
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
}

.approval-date {
    color: var(--text-light);
    font-size: 0.9rem;
}

.approval-body {
    margin-bottom: 15px;
}

.approval-product,
.approval-submitter,
.approval-notes {
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.approval-approvers {
    margin-bottom: 15px;
}

.approvers-list {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.approver-item {
    padding: 10px;
    background: white;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.approver-name {
    font-weight: 600;
    color: var(--text-dark);
}

.approver-status {
    font-size: 0.85rem;
}

.approver-comments {
    margin-top: 5px;
    font-size: 0.85rem;
    color: var(--text-light);
    font-style: italic;
}

.approval-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-success {
    background: var(--success-color);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.btn-success:hover {
    background: #45a049;
}

.btn-warning {
    background: var(--warning-color);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.btn-warning:hover {
    background: #e68900;
}

/* Approvers Checklist */
.approvers-checklist {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px;
}

.approver-checkbox {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.approver-checkbox:hover {
    background: var(--bg-light);
}

.approver-checkbox input[type="checkbox"] {
    margin-right: 12px;
    cursor: pointer;
}

.approver-checkbox-content {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.approver-name {
    font-weight: 600;
}

.approver-role {
    font-size: 0.85rem;
    color: var(--text-light);
}

/* Empty Approvals */
.empty-approvals {
    text-align: center;
    padding: 60px 20px;
}

.empty-approvals h3 {
    color: var(--text-dark);
    margin-bottom: 10px;
}

.empty-approvals p {
    color: var(--text-light);
}

/* Modal Sizes */
.modal-large {
    max-width: 900px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .team-stats-grid,
    .approval-stats-grid,
    .permissions-grid {
        grid-template-columns: 1fr;
    }

    .team-member-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .member-actions {
        width: 100%;
        flex-direction: column;
    }

    .role-selector {
        width: 100%;
    }

    .approval-actions {
        flex-direction: column;
    }

    .approval-actions button {
        width: 100%;
    }
}
