/* OpenServings Main CSS Bundle */
/* From: assets/css/main.css */
/* OpenServings Recipe Manager - Main Stylesheet
   Version: 2.4.0
   Last Updated: September 5, 2025 */

/* CSS Variables for theming */
:root {
    --bg-primary: #f5f5f5;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f8f9fa;
    --text-primary: #343a40;
    --text-secondary: #6c757d;
    --text-muted: #999999;
    --header-bg: #343a40;
    --header-text: #ffffff;
    --border-color: #ddd;
    --border-light: #e9ecef;
    --accent-primary: #007bff;
    --accent-hover: #0056b3;
    --success: #28a745;
    --success-hover: #218838;
    --danger: #dc3545;
    --danger-hover: #c82333;
    --warning: #ffc107;
    --shadow: rgba(0,0,0,0.1);
    --shadow-hover: rgba(0,0,0,0.15);
    --bg-color: var(--bg-secondary);
    --text-color: var(--text-primary);
    --primary-color: var(--accent-primary);
    --secondary-color: #6c757d;
    --accent-bg: var(--bg-tertiary);
    --input-bg: #ffffff;
    --primary-color-alpha: rgba(0, 123, 255, 0.25);
    --error-color: var(--danger);
    --success-color: var(--success);
    --success-color-alpha: rgba(40, 167, 69, 0.25);
}

/* Dark mode variables */
[data-theme="dark"] {
    --bg-primary: #1a1a1a;
    --bg-secondary: #2d2d2d;
    --bg-tertiary: #3a3a3a;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --text-muted: #888888;
    --header-bg: #1a1a1a;
    --header-text: #ffffff;
    --border-color: #444444;
    --border-light: #555555;
    --accent-primary: #4dabf7;
    --accent-hover: #339af0;
    --success: #51cf66;
    --success-hover: #40c057;
    --danger: #ff6b6b;
    --danger-hover: #ff5252;
    --warning: #ffd43b;
    --shadow: rgba(0,0,0,0.3);
    --shadow-hover: rgba(0,0,0,0.4);
    --bg-color: var(--bg-secondary);
    --text-color: var(--text-primary);
    --primary-color: var(--accent-primary);
    --secondary-color: #adb5bd;
    --accent-bg: var(--bg-tertiary);
    --input-bg: #404040;
    --primary-color-alpha: rgba(77, 171, 247, 0.25);
    --error-color: var(--danger);
    --success-color: var(--success);
    --success-color-alpha: rgba(81, 207, 102, 0.25);
}

/* Base styles */
body { 
    font-family: Arial, sans-serif; 
    margin: 0; 
    padding: 0; 
    background-color: var(--bg-primary);
    color: var(--text-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Header and navigation */
header { 
    background-color: var(--header-bg); 
    color: var(--header-text); 
    padding: 1rem; 
}

header h1 { 
    margin: 0; 
}

nav { 
    margin-top: 1rem; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    flex-wrap: wrap; 
}

.nav-left { 
    display: flex; 
    gap: 1rem; 
}

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

nav a { 
    color: var(--header-text); 
    text-decoration: none; 
    padding: 0.5rem; 
}

nav a:hover { 
    background-color: var(--border-color); 
    border-radius: 4px; 
}

.user-info { 
    color: #adb5bd; 
    font-size: 0.9rem; 
}

.logout-btn { 
    background: #dc3545; 
    color: white; 
    border: none; 
    padding: 0.5rem 1rem; 
    border-radius: 4px; 
    cursor: pointer; 
}

.logout-btn:hover { 
    background: #c82333; 
}

/* Theme toggle button */
.theme-toggle {
    background: none;
    border: 1px solid var(--header-text);
    color: var(--header-text);
    padding: 0.5rem;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    background: var(--header-text);
    color: var(--header-bg);
    transform: rotate(180deg);
}

/* Main content area */
main { 
    max-width: 1200px; 
    margin: 2rem auto; 
    padding: 0 1rem; 
    background-color: var(--bg-secondary); 
    border-radius: 8px; 
    box-shadow: 0 2px 10px var(--shadow); 
    padding: 2rem;
    border: 1px solid var(--border-light);
}

/* Form elements */
form { 
    margin: 1rem 0; 
}

input, textarea, button { 
    margin: 0.5rem 0; 
    padding: 0.5rem; 
    font-size: 1rem; 
}

input[type='text'], input[type='password'], input[type='email'], textarea { 
    width: 100%; 
    max-width: 500px; 
}

button { 
    background-color: var(--accent-primary); 
    color: white; 
    border: none; 
    padding: 0.75rem 1rem; 
    cursor: pointer; 
    border-radius: 4px; 
}

button:hover { 
    background-color: var(--accent-hover); 
}

.login-form { 
    max-width: 400px; 
    margin: 2rem auto; 
}

/* Tables */
table { 
    width: 100%; 
    border-collapse: collapse; 
    margin: 1rem 0; 
}

th, td { 
    padding: 0.75rem; 
    text-align: left; 
    border-bottom: 1px solid var(--border-color); 
}

th { 
    background-color: var(--bg-tertiary); 
    font-weight: bold; 
}

/* Footer */
footer { 
    text-align: center; 
    padding: 2rem; 
    color: #6c757d; 
}

/* Alert styles */
.auth-required { 
    background-color: #fff3cd; 
    color: #856404; 
    padding: 1rem; 
    border: 1px solid #ffeaa7; 
    border-radius: 4px; 
    margin: 1rem 0; 
}

/* Search interface styles */
.search-container { 
    background-color: #f8f9fa; 
    padding: 1.5rem; 
    border-radius: 8px; 
    border: 1px solid #dee2e6; 
    margin-bottom: 2rem; 
}

.search-form { 
    display: flex; 
    gap: 1rem; 
    align-items: center; 
    flex-wrap: wrap; 
}

.search-input-container { 
    flex: 1; 
    min-width: 250px; 
}

.search-input { 
    width: 100%; 
    padding: 0.75rem; 
    border: 1px solid #ced4da; 
    border-radius: 4px; 
    font-size: 1rem; 
    transition: border-color 0.2s, box-shadow 0.2s;
}

.search-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

.search-button { 
    background-color: #007bff; 
    color: white; 
    border: none; 
    padding: 0.75rem 1.5rem; 
    border-radius: 4px; 
    cursor: pointer; 
    font-size: 1rem; 
    transition: background-color 0.2s;
}

.search-button:hover { 
    background-color: #0056b3; 
}

.clear-button { 
    background-color: #6c757d; 
    color: white; 
    padding: 0.75rem 1rem; 
    border-radius: 4px; 
    text-decoration: none; 
    font-size: 1rem; 
    transition: background-color 0.2s;
}

.clear-button:hover { 
    background-color: #545b62; 
}

/* Advanced filters styles */
.advanced-filters-container {
    width: 100%;
    margin-top: 1rem;
    padding: 1rem;
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: 6px;
}

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

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.filter-group label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.filter-select {
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.9rem;
}

.filter-select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

.filter-presets {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    padding-top: 0.5rem;
    border-top: 1px solid var(--border-light);
}

.preset-btn {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-hover));
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px var(--shadow);
}

.preset-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px var(--shadow-hover);
}

.preset-btn.clear-btn {
    background: var(--secondary-color);
    color: white;
}

.preset-btn.clear-btn:hover {
    background: #5a6268;
    transform: translateY(-1px);
}

.search-results-info {
    margin-bottom: 1rem;
    padding: 0.5rem;
    color: #495057;
}

/* Highlight search terms in results */
.highlight {
    background-color: #ffeb3b;
    padding: 1px 2px;
    border-radius: 2px;
}

/* Category filter styles */
.category-filter-container {
    min-width: 200px;
}

.category-filter {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 1rem;
    background-color: white;
    cursor: pointer;
}

.category-filter:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

/* Category selection in add recipe form */
.category-selection {
    max-height: 200px;
    overflow-y: auto;
}

.category-selection label {
    user-select: none;
}

.category-selection input[type=checkbox] {
    width: auto;
    margin: 0 0.25rem 0 0;
}

/* Category badges in table */
.category-badge {
    display: inline-block;
    padding: 2px 8px;
    margin: 1px;
    border-radius: 12px;
    font-size: 0.8em;
    color: white;
}

/* View toggle styles */
.view-toggle {
    display: flex;
    gap: 0.5rem;
    margin: 1rem 0;
    align-items: center;
}

.view-toggle button {
    padding: 0.5rem 1rem;
    border: 2px solid #007bff;
    background: white;
    color: #007bff;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
}

.view-toggle button.active {
    background: #007bff;
    color: white;
}

.view-toggle button:hover {
    background: #007bff;
    color: white;
}

/* Recipe cards layout */
.recipes-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
    margin: 1rem 0;
}

.recipe-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px var(--shadow);
    transition: transform 0.2s, box-shadow 0.2s, background-color 0.3s ease;
}

.recipe-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--shadow-hover);
}

.recipe-card h3 {
    margin: 0 0 0.5rem 0;
    color: var(--text-primary);
    font-size: 1.3rem;
}

.recipe-card .description {
    color: var(--text-secondary);
    margin: 0.5rem 0;
    font-size: 0.95rem;
    line-height: 1.4;
}

.recipe-card .meta-info {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin: 1rem 0;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 6px;
    font-size: 0.9rem;
}

.recipe-card .meta-item {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.recipe-card .categories {
    margin: 0.5rem 0;
}

.recipe-card .ingredients {
    font-size: 0.9rem;
    color: #495057;
    margin: 0.5rem 0;
    max-height: 4em;
    overflow: hidden;
}

.recipe-card .actions {
    margin-top: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.recipe-card .view-btn {
    background: #28a745;
    color: white;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    font-size: 0.9rem;
}

.recipe-card .view-btn:hover {
    background: #218838;
}

.recipe-card .delete-btn {
    background: #dc3545;
    color: white;
    padding: 0.4rem 0.8rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
}

.recipe-card .delete-btn:hover {
    background: #c82333;
}

/* Stars for difficulty */
.stars {
    color: #ffc107;
    font-size: 1.1em;
}

.stars .empty {
    color: #e9ecef;
}

/* Hidden class for view toggle */
.hidden {
    display: none !important;
}

/* Recipe detail page styles */
.recipe-detail {
    max-width: 800px;
    margin: 0 auto;
}

.recipe-header {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e9ecef;
}

.recipe-header h1 {
    margin: 0 0 1rem 0;
    color: #343a40;
    font-size: 2.5rem;
}

.recipe-meta {
    margin: 1rem 0;
}

.categories-section {
    margin-bottom: 1rem;
}

.recipe-stats {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin: 1rem 0;
}

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

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

.stat-label {
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 0.25rem;
}

.stat-value {
    font-size: 1.1rem;
    font-weight: bold;
    color: #343a40;
}

.recipe-section {
    margin: 2rem 0;
}

.recipe-section h3 {
    margin: 0 0 1rem 0;
    color: #343a40;
    font-size: 1.5rem;
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 0.5rem;
}

.ingredients-list {
    list-style: none;
    padding: 0;
}

.ingredients-list li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f1f3f4;
    position: relative;
    padding-left: 1.5rem;
}

.ingredients-list li:before {
    content: "•";
    color: #007bff;
    font-weight: bold;
    position: absolute;
    left: 0;
}

.instructions {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #495057;
}

.recipe-actions {
    margin: 3rem 0 2rem 0;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 8px;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: center;
}

.btn-primary, .btn-secondary, .btn-danger {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    text-decoration: none;
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: #007bff;
    color: white;
}

.btn-primary:hover {
    background: #0056b3;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #545b62;
}

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

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

/* Favorite button styles */
.favorite-btn:hover {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

.favorite-star {
    color: #ffc107;
    font-size: 1.2em;
}

.favorite-star.empty {
    color: #e9ecef;
}

.favorite-star.table {
    font-size: 1.1em;
}

/* Recipe scaling calculator */
.scaling-calculator {
    background: var(--accent-bg);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    margin: 20px 0;
}

.scaling-calculator h3 {
    margin-top: 0;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.scaling-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.scaling-controls label {
    font-weight: 600;
    color: var(--text-color);
}

#servings-input {
    width: 80px;
    padding: 8px 12px;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-color);
    color: var(--text-color);
    font-size: 16px;
    text-align: center;
}

#servings-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.servings-display {
    color: var(--text-color);
    font-weight: 600;
}

.reset-btn {
    padding: 6px 12px;
    background: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.3s ease;
}

.reset-btn:hover {
    background: #5a6268;
}

.ingredient-item {
    margin-bottom: 8px;
}

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

/* Mobile responsiveness */
@media (max-width: 768px) {
    .recipes-cards {
        grid-template-columns: 1fr;
    }
    
    .recipe-card .meta-info {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .view-toggle {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .recipe-header h1 {
        font-size: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .recipe-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .btn-primary, .btn-secondary, .btn-danger {
        justify-content: center;
    }
}

/* Print styles */
@media print {
    /* Hide navigation and non-essential elements */
    header, nav, .view-toggle, .recipe-actions, 
    .search-container, .auth-required,
    button:not(.print-keep), form,
    .logout-btn, footer {
        display: none !important;
    }
    
    /* Reset page margins and background */
    @page {
        margin: 0.5in;
        size: letter;
    }
    
    body {
        background: white !important;
        font-size: 12pt;
        line-height: 1.4;
        color: black !important;
    }
    
    main {
        max-width: none;
        margin: 0;
        padding: 0;
        box-shadow: none;
        background: white;
    }
    
    /* Recipe detail print formatting */
    .recipe-detail {
        max-width: none;
    }
    
    .recipe-header {
        border-bottom: 2px solid #000;
        margin-bottom: 1rem;
        padding-bottom: 0.5rem;
    }
    
    .recipe-header h1 {
        font-size: 24pt;
        margin-bottom: 0.5rem;
    }
    
    .recipe-stats {
        background: #f5f5f5 !important;
        border: 1px solid #ccc;
        page-break-inside: avoid;
    }
    
    .stats-grid {
        display: block;
    }
    
    .stat-item {
        display: inline-block;
        margin-right: 1rem;
        margin-bottom: 0.5rem;
    }
    
    .stat-label {
        font-weight: bold;
    }
    
    .stat-label:after {
        content: ": ";
    }
    
    .stat-value {
        display: inline;
        font-weight: normal;
    }
    
    .recipe-section {
        page-break-inside: avoid;
        margin: 1rem 0;
    }
    
    .recipe-section h3 {
        font-size: 16pt;
        margin-bottom: 0.5rem;
        border-bottom: 1px solid #000;
    }
    
    .ingredients-list {
        column-count: 2;
        column-gap: 2rem;
        page-break-inside: avoid;
    }
    
    .ingredients-list li {
        break-inside: avoid;
        padding: 0.25rem 0;
        border: none;
    }
    
    .instructions {
        font-size: 11pt;
        line-height: 1.5;
    }
    
    /* Table print formatting */
    table {
        page-break-inside: auto;
        border-collapse: collapse;
        width: 100%;
    }
    
    tr {
        page-break-inside: avoid;
        page-break-after: auto;
    }
    
    th, td {
        border: 1px solid #000 !important;
        padding: 4pt;
        font-size: 10pt;
    }
    
    th {
        background: #f0f0f0 !important;
        font-weight: bold;
    }
    
    /* Hide cards view elements in print */
    .recipes-cards, #cards-view {
        display: none !important;
    }
    
    /* Ensure table view is visible */
    #table-view {
        display: block !important;
    }
    
    /* Category badges in print */
    .category-badge {
        background: #e9ecef !important;
        color: #000 !important;
        border: 1px solid #ccc !important;
    }
    
    /* Stars for difficulty in print */
    .stars {
        color: #000 !important;
    }
    
    .stars .empty {
        color: #ccc !important;
    }
    
    /* Add print-specific content */
    .recipe-header:after {
        content: "Printed from OpenServings";
        font-size: 10pt;
        color: #666;
        font-style: italic;
        display: block;
        margin-top: 0.5rem;
    }
    
    /* Hide scaling calculator when printing */
    .scaling-calculator {
        display: none !important;
    }
}

/* ========================================
   COMPREHENSIVE DARK MODE STYLES
   ======================================== */

/* Dark mode form elements */
[data-theme="dark"] input,
[data-theme="dark"] textarea,
[data-theme="dark"] select {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] input:focus,
[data-theme="dark"] textarea:focus,
[data-theme="dark"] select:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(77, 171, 247, 0.25);
}

/* Dark mode buttons */
[data-theme="dark"] .btn-outline {
    background-color: transparent;
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .btn-outline:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

/* Dark mode search elements */
[data-theme="dark"] .search-container {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .search-input {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .search-input:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px var(--primary-color-alpha);
}

/* Dark mode advanced filters */
[data-theme="dark"] .advanced-filters-container {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .filter-select {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .filter-select:focus {
    border-color: var(--accent-primary);
}

/* Dark mode recipe cards */
[data-theme="dark"] .recipe-card {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .recipe-card h3 {
    color: var(--text-primary);
}

[data-theme="dark"] .recipe-card .description {
    color: var(--text-secondary);
}

[data-theme="dark"] .recipe-card .meta-info {
    background-color: var(--bg-tertiary);
    color: var(--text-secondary);
}

[data-theme="dark"] .recipe-card .ingredients {
    color: var(--text-secondary);
}

/* Dark mode recipe stats */
[data-theme="dark"] .recipe-stats {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
}

[data-theme="dark"] .stat-label {
    color: var(--text-secondary);
}

[data-theme="dark"] .stat-value {
    color: var(--text-primary);
}

/* Dark mode recipe actions */
[data-theme="dark"] .recipe-actions {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
}

/* Dark mode scaling calculator */
[data-theme="dark"] .scaling-calculator {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] #servings-input {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .servings-display {
    color: var(--text-primary);
}

/* Dark mode tables */
[data-theme="dark"] table {
    color: var(--text-primary);
}

[data-theme="dark"] th {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] td {
    border-color: var(--border-color);
}

[data-theme="dark"] tr:hover {
    background-color: var(--bg-tertiary);
}

/* Dark mode alerts and messages */
[data-theme="dark"] .auth-required {
    background-color: #3d3d00;
    color: #ffeb3b;
    border-color: #666600;
}

[data-theme="dark"] .alert {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .alert-success {
    background-color: #1a4d1a;
    color: #4caf50;
    border-color: #2e7d32;
}

[data-theme="dark"] .alert-error {
    background-color: #4d1a1a;
    color: #f44336;
    border-color: #d32f2f;
}

[data-theme="dark"] .alert-warning {
    background-color: #4d4d1a;
    color: #ff9800;
    border-color: #f57c00;
}

/* Dark mode breadcrumbs */
[data-theme="dark"] .breadcrumb {
    color: var(--text-secondary);
}

[data-theme="dark"] .breadcrumb a {
    color: var(--accent-primary);
}

[data-theme="dark"] .breadcrumb a:hover {
    color: var(--accent-hover);
}

/* Dark mode category badges */
[data-theme="dark"] .category-badge {
    background-color: var(--accent-primary);
    color: white;
}

/* Dark mode login/auth forms */
[data-theme="dark"] .login-form {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 2rem;
}

/* Dark mode footer */
[data-theme="dark"] footer {
    background-color: var(--bg-secondary);
    color: var(--text-secondary);
    border-top: 1px solid var(--border-color);
}

/* Dark mode search results highlighting */
[data-theme="dark"] .highlight {
    background-color: #ffa000;
    color: #000;
}

/* Dark mode category filter */
[data-theme="dark"] .category-filter {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

/* Dark mode view toggle */
[data-theme="dark"] .view-toggle button {
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--accent-primary);
}

[data-theme="dark"] .view-toggle button.active {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .view-toggle button:hover {
    background-color: var(--accent-primary);
    color: white;
}

/* Dark mode pagination */
[data-theme="dark"] .pagination {
    background-color: var(--bg-secondary);
}

[data-theme="dark"] .pagination a {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .pagination a:hover {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .pagination .current {
    background-color: var(--accent-primary);
    color: white;
}

/* Dark mode form labels */
[data-theme="dark"] label {
    color: var(--text-primary);
}

[data-theme="dark"] .form-group label {
    color: var(--text-secondary);
}

/* Dark mode recipe section headers */
[data-theme="dark"] .recipe-section h3 {
    color: var(--text-primary);
    border-color: var(--border-color);
}

/* Dark mode ingredients list */
[data-theme="dark"] .ingredients-list li {
    border-color: var(--border-light);
    color: var(--text-primary);
}

[data-theme="dark"] .ingredients-list li:before {
    color: var(--accent-primary);
}

/* Dark mode instructions */
[data-theme="dark"] .instructions {
    color: var(--text-secondary);
}

/* Dark mode modal dialogs */
[data-theme="dark"] .modal {
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

[data-theme="dark"] .modal-header {
    border-color: var(--border-color);
}

[data-theme="dark"] .modal-footer {
    border-color: var(--border-color);
}

/* Dark mode dropdown menus */
[data-theme="dark"] .dropdown-menu {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .dropdown-item {
    color: var(--text-primary);
}

[data-theme="dark"] .dropdown-item:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

/* Dark mode tooltips */
[data-theme="dark"] .tooltip {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

/* Smooth transitions for theme switching */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Dark mode scrollbars (webkit browsers) */
[data-theme="dark"] ::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

[data-theme="dark"] ::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

[data-theme="dark"] ::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* From: assets/css/navigation.css */
/* Navigation Component Styles */

/* Main Navigation */
.main-navigation {
    background: var(--bg-secondary, #f8f9fa);
    border-bottom: 1px solid var(--border-color, #dee2e6);
    position: relative;
    z-index: 999;
}

.navigation-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 56px;
}

/* Navigation Links */
.nav-links {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.25rem;
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    color: var(--text-primary, #212529);
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.2s;
    border: none;
    background: none;
    cursor: pointer;
}

.nav-link:hover {
    background: var(--bg-primary, #ffffff);
    color: #007bff;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.nav-link.active {
    background: #007bff;
    color: white;
    box-shadow: 0 2px 4px rgba(0, 123, 255, 0.3);
}

.nav-link.active:hover {
    background: #0056b3;
    color: white;
}

/* Navigation Icons */
.nav-icon {
    flex-shrink: 0;
    transition: transform 0.2s;
}

.nav-link:hover .nav-icon {
    transform: scale(1.1);
}

/* Navigation Text */
.nav-text {
    white-space: nowrap;
}

/* Navigation Badges */
.nav-badge {
    background: #dc3545;
    color: white;
    font-size: 0.7rem;
    padding: 0.125rem 0.375rem;
    border-radius: 10px;
    min-width: 1.25rem;
    text-align: center;
    font-weight: bold;
}

.nav-link.active .nav-badge {
    background: rgba(255, 255, 255, 0.2);
}

/* Dropdown Navigation */
.nav-item-dropdown {
    position: relative;
}

.nav-dropdown-trigger {
    position: relative;
}

.dropdown-arrow {
    transition: transform 0.2s;
    margin-left: 0.25rem;
}

.nav-dropdown-trigger[aria-expanded="true"] .dropdown-arrow {
    transform: rotate(180deg);
}

.nav-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 280px;
    background: var(--bg-primary, #ffffff);
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    margin-top: 0.5rem;
    overflow: hidden;
}

.nav-dropdown-content {
    padding: 0.5rem 0;
}

.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: var(--text-primary, #212529);
    text-decoration: none;
    transition: background 0.2s;
}

.nav-dropdown-item:hover {
    background: var(--bg-secondary, #f8f9fa);
}

.nav-dropdown-section {
    border-bottom: 1px solid var(--border-color, #dee2e6);
    padding-bottom: 0.5rem;
    margin-bottom: 0.5rem;
}

.nav-dropdown-header {
    padding: 0.5rem 1rem 0.25rem;
    font-size: 0.8rem;
    font-weight: bold;
    color: var(--text-muted, #6c757d);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-dropdown-footer {
    border-top: 1px solid var(--border-color, #dee2e6);
    padding-top: 0.5rem;
}

.nav-dropdown-action {
    display: block;
    padding: 0.5rem 1rem;
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
    text-align: center;
    transition: background 0.2s;
}

.nav-dropdown-action:hover {
    background: var(--bg-secondary, #f8f9fa);
}

/* Category and Tag Specific Styles */
.category-icon {
    font-size: 1.1rem;
}

.category-name {
    flex: 1;
}

.category-count {
    background: var(--bg-secondary, #f8f9fa);
    color: var(--text-muted, #6c757d);
    font-size: 0.75rem;
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-weight: 500;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0 1rem;
}

.tag-link {
    background: var(--bg-secondary, #f8f9fa);
    color: var(--text-primary, #212529);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.tag-link:hover {
    background: #007bff;
    color: white;
    transform: translateY(-1px);
}

/* Secondary Navigation */
.nav-secondary {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.quick-actions {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.quick-action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.75rem;
    background: none;
    border: 2px solid transparent;
    border-radius: 6px;
    color: var(--text-muted, #6c757d);
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    white-space: nowrap;
}

.quick-action-btn:hover {
    background: var(--bg-primary, #ffffff);
    border-color: var(--border-color, #dee2e6);
    color: #007bff;
    transform: translateY(-1px);
}

.quick-action-text {
    display: none;
}

/* Show text on larger screens */
@media (min-width: 1024px) {
    .quick-action-text {
        display: inline;
    }
}

/* Mobile Navigation */
.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1050;
    backdrop-filter: blur(4px);
}

.mobile-nav-content {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 320px;
    max-width: 90vw;
    background: var(--bg-primary, #ffffff);
    border-left: 1px solid var(--border-color, #dee2e6);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.mobile-nav-overlay.active .mobile-nav-content {
    transform: translateX(0);
}

.mobile-nav-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border-bottom: 1px solid var(--border-color, #dee2e6);
    background: var(--bg-secondary, #f8f9fa);
}

.mobile-nav-title {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
}

.mobile-nav-close {
    background: none;
    border: none;
    color: var(--text-muted, #6c757d);
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: background 0.2s;
}

.mobile-nav-close:hover {
    background: var(--bg-primary, #ffffff);
}

.mobile-nav-links {
    padding: 1rem 0;
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: var(--text-primary, #212529);
    text-decoration: none;
    transition: background 0.2s;
    font-weight: 500;
}

.mobile-nav-link:hover {
    background: var(--bg-secondary, #f8f9fa);
}

.mobile-nav-link.active {
    background: #007bff;
    color: white;
}

.mobile-nav-link.mobile-nav-primary {
    background: #007bff;
    color: white;
    margin: 0 1rem;
    border-radius: 6px;
}

.mobile-nav-link.mobile-nav-primary:hover {
    background: #0056b3;
}

.mobile-nav-link.mobile-nav-logout {
    color: #dc3545;
}

.mobile-nav-link.mobile-nav-logout:hover {
    background: rgba(220, 53, 69, 0.1);
}

.mobile-nav-divider {
    height: 1px;
    background: var(--border-color, #dee2e6);
    margin: 0.5rem 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .navigation-container {
        padding: 0 0.5rem;
    }
    
    .nav-links {
        display: none;
    }
    
    .nav-secondary {
        flex: 1;
        justify-content: flex-end;
    }
    
    .nav-text {
        display: none;
    }
    
    .quick-actions {
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .navigation-container {
        min-height: 48px;
    }
    
    .quick-action-btn {
        width: 2rem;
        height: 2rem;
    }
    
    .mobile-nav-content {
        width: 280px;
    }
}

/* Animation for dropdown */
.nav-dropdown {
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    pointer-events: none;
}

.nav-item-dropdown:hover .nav-dropdown,
.nav-dropdown-trigger[aria-expanded="true"] + .nav-dropdown,
.nav-dropdown.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* Focus states for accessibility */
.nav-link:focus,
.quick-action-btn:focus,
.mobile-nav-link:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .nav-link {
        border: 1px solid transparent;
    }
    
    .nav-link:hover,
    .nav-link:focus {
        border-color: currentColor;
    }
}

/* ========================================
   DARK MODE NAVIGATION STYLES
   ======================================== */

[data-theme="dark"] .main-navigation {
    background: var(--bg-secondary);
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .nav-link {
    color: var(--text-primary);
}

[data-theme="dark"] .nav-link:hover,
[data-theme="dark"] .nav-link:focus {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .nav-link.active {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .nav-link.active:hover {
    background-color: var(--accent-hover);
}

[data-theme="dark"] .dropdown-menu {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .dropdown-link {
    color: var(--text-primary);
}

[data-theme="dark"] .dropdown-link:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .mobile-nav-toggle {
    background-color: transparent;
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .mobile-nav-toggle:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .mobile-nav {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .mobile-nav .nav-link {
    color: var(--text-primary);
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .mobile-nav .nav-link:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .mobile-nav .nav-link.active {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .breadcrumb-navigation {
    background-color: var(--bg-secondary);
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .breadcrumb-link {
    color: var(--accent-primary);
}

[data-theme="dark"] .breadcrumb-link:hover {
    color: var(--accent-hover);
}

[data-theme="dark"] .breadcrumb-separator {
    color: var(--text-muted);
}

[data-theme="dark"] .breadcrumb-current {
    color: var(--text-primary);
}

/* From: assets/css/header.css */
/* Header Component Styles */
.main-header {
    background: var(--header-bg, #343a40);
    color: var(--header-text, #ffffff);
    border-bottom: 1px solid var(--border-color, #dee2e6);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 64px;
}

/* Brand/Logo Section */
.header-brand {
    flex-shrink: 0;
}

.brand-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s;
}

.brand-link:hover {
    opacity: 0.8;
}

.brand-logo {
    color: #007bff;
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand-name {
    font-size: 1.25rem;
    font-weight: bold;
    color: var(--header-text, #ffffff);
}

.brand-version {
    font-size: 0.75rem;
    color: var(--text-muted, #6c757d);
}

/* Search Section */
.header-search {
    flex: 1;
    max-width: 500px;
    position: relative;
}

.search-form {
    width: 100%;
    position: relative;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input {
    width: 100%;
    padding: 0.5rem 2.5rem 0.5rem 1rem;
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 6px;
    font-size: 0.9rem;
    background: var(--bg-primary, #ffffff);
    color: var(--text-primary, #212529);
    transition: border-color 0.2s;
}

.search-input:focus {
    outline: none;
    border-color: #007bff;
}

.search-button {
    position: absolute;
    right: 0.5rem;
    background: none;
    border: none;
    color: var(--text-muted, #6c757d);
    padding: 0.25rem;
    cursor: pointer;
    border-radius: 4px;
    transition: color 0.2s;
}

.search-button:hover {
    color: #007bff;
}

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-primary, #ffffff);
    border: 2px solid var(--border-color, #dee2e6);
    border-top: none;
    border-radius: 0 0 6px 6px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 1001;
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.header-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border: 2px solid transparent;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
    background: none;
    color: inherit;
}

.header-action-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.header-action-btn.btn-primary {
    background: #007bff;
    color: white;
    border-color: #007bff;
}

.header-action-btn.btn-primary:hover {
    background: #0056b3;
    border-color: #0056b3;
}

.header-action-btn.btn-outline {
    border-color: var(--header-text, #ffffff);
    color: var(--header-text, #ffffff);
}

.header-action-btn.btn-outline:hover {
    background: var(--header-text, #ffffff);
    color: var(--header-bg, #343a40);
}

/* Notification Button */
.notification-btn {
    position: relative;
}

.notification-badge {
    position: absolute;
    top: -0.25rem;
    right: -0.25rem;
    background: #dc3545;
    color: white;
    font-size: 0.7rem;
    padding: 0.125rem 0.375rem;
    border-radius: 10px;
    min-width: 1.25rem;
    text-align: center;
}

/* Theme Toggle */
.theme-toggle {
    position: relative;
    width: 2.5rem;
    height: 2.5rem;
    justify-content: center;
}

.theme-icon {
    position: absolute;
    transition: opacity 0.3s;
}

[data-theme="light"] .theme-icon-dark,
[data-theme="dark"] .theme-icon-light {
    opacity: 0;
}

[data-theme="light"] .theme-icon-light,
[data-theme="dark"] .theme-icon-dark {
    opacity: 1;
}

/* User Menu */
.user-menu {
    position: relative;
}

.user-menu-trigger {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.2s;
}

.user-menu-trigger:hover {
    background: rgba(255, 255, 255, 0.1);
}

.user-avatar {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-placeholder {
    width: 100%;
    height: 100%;
    background: #007bff;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
}

.user-name {
    font-size: 0.9rem;
    font-weight: 500;
}

.dropdown-arrow {
    transition: transform 0.2s;
}

.user-menu-trigger[aria-expanded="true"] .dropdown-arrow {
    transform: rotate(180deg);
}

/* User Menu Dropdown */
.user-menu-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 240px;
    background: var(--bg-primary, #ffffff);
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 6px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    margin-top: 0.5rem;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    pointer-events: none;
}

.user-menu-dropdown.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.user-menu-header {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color, #dee2e6);
}

.user-menu-header .user-name {
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin-bottom: 0.25rem;
}

.user-email {
    font-size: 0.8rem;
    color: var(--text-muted, #6c757d);
}

.user-menu-section {
    padding: 0.5rem 0;
}

.user-menu-section + .user-menu-section {
    border-top: 1px solid var(--border-color, #dee2e6);
}

.user-menu-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: var(--text-primary, #212529);
    text-decoration: none;
    transition: background 0.2s;
}

.user-menu-item:hover {
    background: var(--bg-secondary, #f8f9fa);
}

.user-menu-logout {
    color: #dc3545;
}

.user-menu-logout:hover {
    background: rgba(220, 53, 69, 0.1);
}

/* Guest Actions */
.guest-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 0.25rem;
    background: none;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
    border-radius: 4px;
}

.hamburger-line {
    width: 1.5rem;
    height: 2px;
    background: var(--header-text, #ffffff);
    transition: all 0.3s;
}

/* Mobile Search */
.mobile-search {
    background: var(--bg-primary, #ffffff);
    border-top: 1px solid var(--border-color, #dee2e6);
    padding: 1rem;
}

.mobile-search-form {
    display: flex;
    gap: 0.5rem;
}

.mobile-search-input {
    flex: 1;
    padding: 0.5rem;
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 6px;
    font-size: 0.9rem;
}

.mobile-search-button {
    padding: 0.5rem 1rem;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-container {
        padding: 0 0.5rem;
        min-height: 56px;
    }
    
    .header-search {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .btn-text {
        display: none;
    }
    
    .user-name {
        display: none;
    }
    
    .brand-text {
        display: none;
    }
    
    .guest-actions .header-action-btn {
        padding: 0.5rem;
    }
}

@media (max-width: 480px) {
    .header-actions {
        gap: 0.25rem;
    }
    
    .header-action-btn {
        padding: 0.375rem;
        font-size: 0.8rem;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--bg-primary, #ffffff);
    color: var(--text-primary, #212529);
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1002;
}

.skip-link:focus {
    top: 6px;
}

/* ========================================
   DARK MODE HEADER STYLES
   ======================================== */

[data-theme="dark"] .main-header {
    background: var(--header-bg);
    color: var(--header-text);
    border-bottom-color: var(--border-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .brand-logo {
    color: var(--accent-primary);
}

[data-theme="dark"] .brand-name {
    color: var(--text-primary);
}

[data-theme="dark"] .brand-version {
    color: var(--text-secondary);
}

[data-theme="dark"] .search-input {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .search-input:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px var(--primary-color-alpha);
}

[data-theme="dark"] .search-button {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .search-button:hover {
    background-color: var(--accent-hover);
}

[data-theme="dark"] .user-menu-toggle {
    background-color: transparent;
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .user-menu-toggle:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .user-menu {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .user-menu-item {
    color: var(--text-primary);
}

[data-theme="dark"] .user-menu-item:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .user-menu-separator {
    border-color: var(--border-color);
}

[data-theme="dark"] .theme-toggle {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .theme-toggle:hover {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .login-btn {
    background-color: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

[data-theme="dark"] .login-btn:hover {
    background-color: var(--accent-hover);
    border-color: var(--accent-hover);
}

[data-theme="dark"] .register-btn {
    background-color: transparent;
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

[data-theme="dark"] .register-btn:hover {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .mobile-menu {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .mobile-menu-item {
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .mobile-menu-item:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .skip-link {
    background: var(--bg-primary);
    color: var(--text-primary);
}

/* From: assets/css/footer.css */
/* Footer Component Styles */

/* Main Footer */
.site-footer {
    background: var(--bg-secondary, #f8f9fa);
    border-top: 1px solid var(--border-color, #dee2e6);
    margin-top: auto;
    position: relative;
}

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

/* Footer Main Content */
.footer-main {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 2rem;
    padding: 3rem 0 2rem;
}

/* Footer Brand Section */
.footer-brand {
    max-width: 300px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.footer-logo-svg {
    color: #007bff;
    flex-shrink: 0;
}

.footer-brand-text {
    line-height: 1.2;
}

.footer-brand-name {
    font-size: 1.25rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin: 0 0 0.25rem 0;
}

.footer-brand-tagline {
    font-size: 0.9rem;
    color: var(--text-muted, #6c757d);
    margin: 0;
    font-style: italic;
}

.footer-description {
    color: var(--text-secondary, #495057);
    line-height: 1.6;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

/* Social Links */
.footer-social {
    margin-bottom: 1rem;
}

.footer-social-label {
    font-size: 0.9rem;
    color: var(--text-muted, #6c757d);
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.footer-social-links {
    display: flex;
    gap: 0.5rem;
}

.footer-social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background: var(--bg-primary, #ffffff);
    color: var(--text-muted, #6c757d);
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.2s;
    border: 1px solid var(--border-color, #dee2e6);
}

.footer-social-link:hover {
    background: #007bff;
    color: white;
    border-color: #007bff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

/* Footer Sections */
.footer-section {
    min-width: 0; /* Prevent flex item overflow */
}

.footer-section-title {
    font-size: 1rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin: 0 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #007bff;
    position: relative;
}

.footer-section-title::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 30px;
    height: 2px;
    background: #007bff;
}

/* Footer Links */
.footer-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-link {
    color: var(--text-secondary, #495057);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s;
    display: inline-block;
    position: relative;
}

.footer-link:hover {
    color: #007bff;
    padding-left: 0.5rem;
}

.footer-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 2px;
    background: #007bff;
    transition: width 0.2s;
}

.footer-link:hover::before {
    width: 0.25rem;
}

/* Footer Bottom */
.footer-bottom {
    border-top: 1px solid var(--border-color, #dee2e6);
    padding: 1.5rem 0;
    background: var(--bg-primary, #ffffff);
}

.footer-bottom-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

/* Copyright */
.footer-copyright {
    color: var(--text-muted, #6c757d);
    font-size: 0.85rem;
}

.footer-copyright p {
    margin: 0;
}

/* Footer Meta Information */
.footer-meta {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.footer-version {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-muted, #6c757d);
}

.version-label {
    font-weight: 500;
}

.version-number {
    background: var(--bg-secondary, #f8f9fa);
    color: var(--text-primary, #212529);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-weight: 600;
}

.build-info {
    color: var(--text-muted, #6c757d);
    cursor: help;
}

/* System Status */
.footer-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.status-indicator.status-operational {
    background: #28a745;
    box-shadow: 0 0 4px rgba(40, 167, 69, 0.5);
}

.status-indicator.status-degraded {
    background: #ffc107;
    box-shadow: 0 0 4px rgba(255, 193, 7, 0.5);
}

.status-indicator.status-down {
    background: #dc3545;
    box-shadow: 0 0 4px rgba(220, 53, 69, 0.5);
}

.status-text {
    color: var(--text-muted, #6c757d);
}

/* Quick Links */
.footer-quick-links {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.footer-quick-link {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--text-muted, #6c757d);
    text-decoration: none;
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: all 0.2s;
}

.footer-quick-link:hover {
    background: var(--bg-secondary, #f8f9fa);
    color: #007bff;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 3rem;
    height: 3rem;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
    transition: all 0.3s;
    z-index: 1000;
    opacity: 0;
    transform: translateY(20px);
}

.back-to-top.visible {
    opacity: 1;
    transform: translateY(0);
}

.back-to-top:hover {
    background: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 123, 255, 0.4);
}

.back-to-top:active {
    transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 992px) {
    .footer-main {
        grid-template-columns: 2fr 1fr 1fr;
        gap: 1.5rem;
    }
    
    .footer-section:nth-child(4),
    .footer-section:nth-child(5) {
        grid-column: 2 / 4;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .footer-main {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 2rem 0 1.5rem;
    }
    
    .footer-section:nth-child(4),
    .footer-section:nth-child(5) {
        grid-column: 1;
        display: block;
    }
    
    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .footer-meta {
        justify-content: center;
    }
    
    .footer-quick-links {
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .back-to-top {
        bottom: 1rem;
        right: 1rem;
        width: 2.5rem;
        height: 2.5rem;
    }
}

@media (max-width: 480px) {
    .footer-container {
        padding: 0 0.5rem;
    }
    
    .footer-main {
        padding: 1.5rem 0 1rem;
        gap: 1.5rem;
    }
    
    .footer-social-links {
        justify-content: center;
    }
    
    .footer-meta {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .footer-quick-links {
        gap: 0.5rem;
    }
    
    .footer-quick-link {
        font-size: 0.75rem;
        padding: 0.25rem;
    }
}

/* Dark Theme Support */
[data-theme="dark"] .site-footer {
    background: var(--bg-secondary, #2d3748);
    border-top-color: var(--border-color, #4a5568);
}

[data-theme="dark"] .footer-bottom {
    background: var(--bg-primary, #1a202c);
    border-top-color: var(--border-color, #4a5568);
}

[data-theme="dark"] .footer-social-link {
    background: var(--bg-primary, #1a202c);
    border-color: var(--border-color, #4a5568);
}

[data-theme="dark"] .version-number {
    background: var(--bg-primary, #1a202c);
    color: var(--text-primary, #f7fafc);
}

/* Print Styles */
@media print {
    .site-footer {
        background: white !important;
        border-top: 1px solid #000;
    }
    
    .footer-social,
    .footer-quick-links,
    .back-to-top {
        display: none !important;
    }
    
    .footer-main {
        display: block;
    }
    
    .footer-section {
        margin-bottom: 1rem;
        page-break-inside: avoid;
    }
}

/* Accessibility Enhancements */
@media (prefers-reduced-motion: reduce) {
    .footer-link,
    .footer-social-link,
    .footer-quick-link,
    .back-to-top {
        transition: none;
    }
    
    .back-to-top {
        transform: none;
    }
    
    .back-to-top.visible {
        transform: none;
    }
}

/* Focus styles for accessibility */
.footer-link:focus,
.footer-social-link:focus,
.footer-quick-link:focus,
.back-to-top:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

/* ========================================
   DARK MODE FOOTER STYLES
   ======================================== */

[data-theme="dark"] .site-footer {
    background: var(--bg-secondary);
    border-top-color: var(--border-color);
}

[data-theme="dark"] .footer-brand-name {
    color: var(--text-primary);
}

[data-theme="dark"] .footer-brand-version {
    color: var(--text-muted);
}

[data-theme="dark"] .footer-brand-description {
    color: var(--text-secondary);
}

[data-theme="dark"] .footer-section-title {
    color: var(--text-primary);
}

[data-theme="dark"] .footer-link {
    color: var(--text-secondary);
}

[data-theme="dark"] .footer-link:hover {
    color: var(--accent-primary);
}

[data-theme="dark"] .footer-social-link {
    background-color: var(--bg-tertiary);
    color: var(--text-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .footer-social-link:hover {
    background-color: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

[data-theme="dark"] .footer-quick-link {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .footer-quick-link:hover {
    background-color: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

[data-theme="dark"] .footer-bottom {
    background-color: var(--bg-primary);
    border-top-color: var(--border-color);
}

[data-theme="dark"] .footer-copyright {
    color: var(--text-muted);
}

[data-theme="dark"] .footer-legal-links {
    color: var(--text-secondary);
}

[data-theme="dark"] .footer-legal-link {
    color: var(--text-secondary);
}

[data-theme="dark"] .footer-legal-link:hover {
    color: var(--accent-primary);
}

[data-theme="dark"] .back-to-top {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .back-to-top:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
}

[data-theme="dark"] .footer-link:focus,
[data-theme="dark"] .footer-social-link:focus,
[data-theme="dark"] .footer-quick-link:focus,
[data-theme="dark"] .back-to-top:focus {
    outline-color: var(--accent-primary);
}

/* From: assets/css/auth.css */
/* Auth Pages Styling */

/* Auth Container */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 2rem 1rem;
}

.auth-card {
    background: var(--bg-primary, #ffffff);
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    padding: 2.5rem;
    width: 100%;
    max-width: 420px;
    position: relative;
    overflow: hidden;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #007bff, #6610f2, #e83e8c, #fd7e14);
}

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

.auth-title {
    font-size: 1.75rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin: 0 0 0.5rem 0;
}

.auth-subtitle {
    color: var(--text-muted, #6c757d);
    margin: 0;
    line-height: 1.5;
}

/* Form Groups */
.form-group {
    margin-bottom: 1.5rem;
}

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

.form-label-required {
    color: #dc3545;
    margin-left: 0.25rem;
}

/* Input Groups */
.form-input-group {
    position: relative;
    display: flex;
    align-items: center;
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    padding-left: 2.75rem;
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 8px;
    font-size: 1rem;
    background: var(--bg-primary, #ffffff);
    color: var(--text-primary, #212529);
    transition: all 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.form-input::placeholder {
    color: var(--text-muted, #6c757d);
}

.form-input-icon {
    position: absolute;
    left: 0.75rem;
    color: var(--text-muted, #6c757d);
    pointer-events: none;
    z-index: 1;
}

.form-input:focus + .form-input-icon,
.form-input-group:focus-within .form-input-icon {
    color: #007bff;
}

/* Password Toggle */
.form-input-toggle {
    position: absolute;
    right: 0.75rem;
    background: none;
    border: none;
    color: var(--text-muted, #6c757d);
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: color 0.2s;
}

.form-input-toggle:hover {
    color: #007bff;
}

/* Form Help Text */
.form-help {
    font-size: 0.8rem;
    color: var(--text-muted, #6c757d);
    margin-top: 0.25rem;
}

/* Checkbox Groups */
.form-checkbox-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.form-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-checkbox-input {
    width: 1.1rem;
    height: 1.1rem;
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 4px;
    background: var(--bg-primary, #ffffff);
    cursor: pointer;
    position: relative;
    appearance: none;
    transition: all 0.2s;
}

.form-checkbox-input:checked {
    background: #007bff;
    border-color: #007bff;
}

.form-checkbox-input:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 0.8rem;
    font-weight: bold;
}

.form-checkbox-label {
    font-size: 0.9rem;
    color: var(--text-secondary, #495057);
    cursor: pointer;
}

/* Form Links */
.form-link {
    color: #007bff;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
}

.form-link:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    border: 2px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: #007bff;
    color: white;
    border-color: #007bff;
}

.btn-primary:hover {
    background: #0056b3;
    border-color: #0056b3;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

.btn-full {
    width: 100%;
}

.btn-loading {
    animation: spin 1s linear infinite;
}

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

/* Auth Footer */
.auth-footer {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color, #dee2e6);
}

.auth-footer-text {
    color: var(--text-muted, #6c757d);
    margin: 0;
}

.auth-footer-link {
    color: #007bff;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.auth-footer-link:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* Auth Divider */
.auth-divider {
    position: relative;
    text-align: center;
    margin: 1.5rem 0;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--border-color, #dee2e6);
}

.auth-divider-text {
    background: var(--bg-primary, #ffffff);
    color: var(--text-muted, #6c757d);
    padding: 0 1rem;
    font-size: 0.85rem;
    position: relative;
}

/* Social Login */
.social-login {
    display: grid;
    gap: 0.75rem;
    margin-top: 1rem;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 8px;
    background: var(--bg-primary, #ffffff);
    color: var(--text-primary, #212529);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

.social-btn:hover {
    border-color: var(--text-muted, #6c757d);
    background: var(--bg-secondary, #f8f9fa);
}

/* Alert Styles */
.alert {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    line-height: 1.4;
}

.alert-error {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.alert-success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.alert-warning {
    background: #fffbeb;
    color: #92400e;
    border: 1px solid #fed7aa;
}

.alert-info {
    background: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

/* Responsive Design */
@media (max-width: 480px) {
    .auth-container {
        padding: 1rem 0.5rem;
    }
    
    .auth-card {
        padding: 2rem 1.5rem;
        margin: 0;
        border-radius: 8px;
    }
    
    .auth-title {
        font-size: 1.5rem;
    }
    
    .form-checkbox-group {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
}

/* Dark Theme Support */
[data-theme="dark"] .auth-container {
    background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
}

[data-theme="dark"] .auth-card {
    background: var(--bg-primary, #1a202c);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .form-input {
    background: var(--bg-secondary, #2d3748);
    border-color: var(--border-color, #4a5568);
}

[data-theme="dark"] .form-checkbox-input {
    background: var(--bg-secondary, #2d3748);
    border-color: var(--border-color, #4a5568);
}

[data-theme="dark"] .social-btn {
    background: var(--bg-secondary, #2d3748);
    border-color: var(--border-color, #4a5568);
}

/* Focus and Accessibility */
.form-input:focus,
.form-checkbox-input:focus,
.btn:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .form-input,
    .form-checkbox-input,
    .btn {
        border-width: 3px;
    }
    
    .alert {
        border-width: 2px;
    }
}

/* ========================================
   DARK MODE AUTH STYLES
   ======================================== */

[data-theme="dark"] .auth-container {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
}

[data-theme="dark"] .auth-card {
    background: var(--bg-primary);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .auth-title {
    color: var(--text-primary);
}

[data-theme="dark"] .auth-subtitle {
    color: var(--text-muted);
}

[data-theme="dark"] .form-group label {
    color: var(--text-primary);
}

[data-theme="dark"] .form-input {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .form-input:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px var(--primary-color-alpha);
}

[data-theme="dark"] .form-input::placeholder {
    color: var(--text-muted);
}

[data-theme="dark"] .form-checkbox-label {
    color: var(--text-secondary);
}

[data-theme="dark"] .form-checkbox-input {
    background-color: var(--input-bg);
    border-color: var(--border-color);
}

[data-theme="dark"] .form-checkbox-input:checked {
    background-color: var(--accent-primary);
    border-color: var(--accent-primary);
}

[data-theme="dark"] .btn-primary {
    background-color: var(--accent-primary);
    border-color: var(--accent-primary);
}

[data-theme="dark"] .btn-primary:hover {
    background-color: var(--accent-hover);
    border-color: var(--accent-hover);
}

[data-theme="dark"] .btn-secondary {
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .btn-secondary:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .auth-links a {
    color: var(--accent-primary);
}

[data-theme="dark"] .auth-links a:hover {
    color: var(--accent-hover);
}

[data-theme="dark"] .alert-success {
    background-color: #1a4d1a;
    color: #4caf50;
    border-color: #2e7d32;
}

[data-theme="dark"] .alert-error {
    background-color: #4d1a1a;
    color: #f44336;
    border-color: #d32f2f;
}

[data-theme="dark"] .alert-info {
    background-color: #1a1a4d;
    color: #2196f3;
    border-color: #1976d2;
}

[data-theme="dark"] .social-btn {
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .social-btn:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .divider-text {
    background-color: var(--bg-primary);
    color: var(--text-muted);
}

[data-theme="dark"] .divider-line {
    border-color: var(--border-color);
}

/* From: assets/css/homepage.css */
/* Minimal CSS for homepage hero section */
.hero-section {
    padding: 4rem 2rem;
    text-align: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.hero-content {
    flex: 1;
    min-width: 300px;
}

.hero-title {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

.brand-highlight {
    color: #ffd700;
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-primary {
    background: #007bff;
    color: white;
    border: 2px solid #007bff;
}

.btn-primary:hover {
    background: #0056b3;
    border-color: #0056b3;
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background: white;
    color: #667eea;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.hero-image {
    flex: 1;
    min-width: 300px;
    text-align: center;
}

.hero-img-placeholder {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 2rem;
}

.placeholder-text {
    margin-top: 1rem;
    opacity: 0.8;
}

.features-preview {
    padding: 4rem 2rem;
    background: #f8f9fa;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #333;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
}

.feature-card:hover {
    transform: translateY(-4px);
}

.feature-icon {
    color: #007bff;
    margin-bottom: 1rem;
}

.feature-title {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #333;
}

.feature-description {
    color: #666;
    line-height: 1.6;
}

/* Featured Recipes Section */
.featured-recipes {
    padding: 4rem 2rem;
    background: white;
}

.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 3rem;
}

.recipes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.recipe-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

.recipe-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.recipe-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.recipe-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recipe-image-placeholder {
    width: 100%;
    height: 100%;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
}

.recipe-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s;
}

.recipe-card:hover .recipe-overlay {
    opacity: 1;
}

.recipe-link {
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    padding: 0.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: transform 0.2s;
}

.recipe-link:hover {
    transform: scale(1.1);
}

.recipe-content {
    padding: 1.5rem;
}

.recipe-title {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.recipe-title a {
    color: #333;
    text-decoration: none;
}

.recipe-title a:hover {
    color: #007bff;
}

.recipe-description {
    color: #666;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.recipe-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: #888;
}

.recipe-author {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.recipe-stats {
    display: flex;
    gap: 1rem;
}

.recipe-rating,
.recipe-time {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.section-actions {
    text-align: center;
}

/* Statistics Section */
.stats-section {
    padding: 4rem 2rem;
    background: #f8f9fa;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.stat-card {
    text-align: center;
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: #007bff;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: #666;
    font-size: 1rem;
}

/* Call to Action Section */
.cta-section {
    padding: 4rem 2rem;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    text-align: center;
}

.cta-content {
    max-width: 600px;
    margin: 0 auto;
}

.cta-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-subtitle {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.cta-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-outline {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-outline:hover {
    background: white;
    color: #28a745;
}

/* Responsive design */
@media (max-width: 768px) {
    .hero-container {
        flex-direction: column;
        text-align: center;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-actions {
        flex-direction: column;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .cta-title {
        font-size: 2rem;
    }
    
    .cta-actions {
        flex-direction: column;
    }
    
    .recipe-meta {
        flex-direction: column;
        gap: 0.5rem;
        align-items: flex-start;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ========================================
   DARK MODE HOMEPAGE STYLES
   ======================================== */

[data-theme="dark"] .hero-section {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    color: var(--text-primary);
}

[data-theme="dark"] .brand-highlight {
    color: var(--accent-primary);
}

[data-theme="dark"] .hero-subtitle {
    color: var(--text-secondary);
}

[data-theme="dark"] .btn-primary {
    background-color: var(--accent-primary);
    border-color: var(--accent-primary);
}

[data-theme="dark"] .btn-primary:hover {
    background-color: var(--accent-hover);
    border-color: var(--accent-hover);
}

[data-theme="dark"] .btn-outline {
    background-color: transparent;
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .btn-outline:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .features-section {
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

[data-theme="dark"] .section-title {
    color: var(--text-primary);
}

[data-theme="dark"] .section-subtitle {
    color: var(--text-secondary);
}

[data-theme="dark"] .feature-card {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .feature-card:hover {
    background-color: var(--bg-tertiary);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .feature-icon {
    color: var(--accent-primary);
}

[data-theme="dark"] .feature-title {
    color: var(--text-primary);
}

[data-theme="dark"] .feature-description {
    color: var(--text-secondary);
}

[data-theme="dark"] .stats-section {
    background-color: var(--bg-secondary);
    border-top-color: var(--border-color);
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .stat-card {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .stat-number {
    color: var(--accent-primary);
}

[data-theme="dark"] .stat-label {
    color: var(--text-secondary);
}

[data-theme="dark"] .cta-section {
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-hover) 100%);
    color: white;
}

[data-theme="dark"] .cta-title {
    color: white;
}

[data-theme="dark"] .cta-description {
    color: rgba(255, 255, 255, 0.9);
}

[data-theme="dark"] .cta-btn {
    background-color: white;
    color: var(--accent-primary);
    border-color: white;
}

[data-theme="dark"] .cta-btn:hover {
    background-color: rgba(255, 255, 255, 0.9);
    color: var(--accent-hover);
}

/* From: assets/css/dashboard.css */
/* Dashboard Styles */

/* Dashboard Container */
.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* Dashboard Header */
.dashboard-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid var(--border-color, #dee2e6);
}

.dashboard-welcome {
    flex: 1;
}

.dashboard-title {
    font-size: 2rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin: 0 0 0.5rem 0;
}

.dashboard-subtitle {
    color: var(--text-muted, #6c757d);
    margin: 0;
    font-size: 1.1rem;
}

.dashboard-actions {
    display: flex;
    gap: 1rem;
}

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

.stat-card {
    background: var(--bg-primary, #ffffff);
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.2s;
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, #007bff, #6610f2);
}

/* Stat Icons */
.stat-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-icon-primary {
    background: rgba(0, 123, 255, 0.1);
    color: #007bff;
}

.stat-icon-success {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
}

.stat-icon-warning {
    background: rgba(255, 193, 7, 0.1);
    color: #ffc107;
}

.stat-icon-info {
    background: rgba(23, 162, 184, 0.1);
    color: #17a2b8;
}

/* Stat Content */
.stat-content {
    flex: 1;
    min-width: 0;
}

.stat-number {
    font-size: 1.75rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin-bottom: 0.25rem;
}

.stat-label {
    color: var(--text-muted, #6c757d);
    font-size: 0.9rem;
    font-weight: 500;
}

/* Stat Actions */
.stat-action {
    flex-shrink: 0;
}

.stat-link {
    color: #007bff;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: all 0.2s;
}

.stat-link:hover {
    background: rgba(0, 123, 255, 0.1);
    color: #0056b3;
}

/* Dashboard Sections */
.dashboard-section {
    margin-bottom: 2.5rem;
}

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

.dashboard-section-title {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin: 0;
}

.dashboard-section-action {
    color: #007bff;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.dashboard-section-action:hover {
    color: #0056b3;
}

/* Recipe Cards */
.recipe-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.recipe-card {
    background: var(--bg-primary, #ffffff);
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.2s;
}

.recipe-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.recipe-image {
    width: 100%;
    height: 160px;
    background: var(--bg-secondary, #f8f9fa);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.recipe-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recipe-placeholder {
    color: var(--text-muted, #6c757d);
    text-align: center;
}

.recipe-content {
    padding: 1.25rem;
}

.recipe-title {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin: 0 0 0.5rem 0;
}

.recipe-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s;
}

.recipe-title a:hover {
    color: #007bff;
}

.recipe-description {
    color: var(--text-secondary, #495057);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.recipe-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.8rem;
    color: var(--text-muted, #6c757d);
    margin-bottom: 1rem;
}

.recipe-meta-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.recipe-status {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-published {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
}

.status-draft {
    background: rgba(108, 117, 125, 0.1);
    color: #6c757d;
}

.status-private {
    background: rgba(255, 193, 7, 0.1);
    color: #856404;
}

/* Recipe Actions */
.recipe-actions {
    display: flex;
    gap: 0.5rem;
    border-top: 1px solid var(--border-color, #dee2e6);
    padding-top: 1rem;
}

.recipe-action {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem;
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 6px;
    background: var(--bg-primary, #ffffff);
    color: var(--text-muted, #6c757d);
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.2s;
}

.recipe-action:hover {
    background: var(--bg-secondary, #f8f9fa);
    color: var(--text-primary, #212529);
}

.recipe-action-danger {
    color: #dc3545;
}

.recipe-action-danger:hover {
    background: rgba(220, 53, 69, 0.1);
    border-color: #dc3545;
}

/* Activity Feed */
.activity-feed {
    background: var(--bg-primary, #ffffff);
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 12px;
    padding: 1.5rem;
}

.activity-item {
    display: flex;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color, #dee2e6);
}

.activity-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.activity-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background: var(--bg-secondary, #f8f9fa);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted, #6c757d);
    flex-shrink: 0;
}

.activity-content {
    flex: 1;
    min-width: 0;
}

.activity-text {
    color: var(--text-primary, #212529);
    margin-bottom: 0.25rem;
    font-size: 0.9rem;
}

.activity-time {
    color: var(--text-muted, #6c757d);
    font-size: 0.8rem;
}

/* Empty States */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-muted, #6c757d);
}

.empty-state-icon {
    width: 4rem;
    height: 4rem;
    margin: 0 auto 1rem;
    opacity: 0.5;
}

.empty-state-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-secondary, #495057);
}

.empty-state-text {
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

/* Responsive Design */
@media (max-width: 768px) {
    .dashboard-container {
        padding: 1rem 0.5rem;
    }
    
    .dashboard-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .dashboard-title {
        font-size: 1.5rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .stat-card {
        padding: 1rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .recipe-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .dashboard-container {
        padding: 0.5rem;
    }
    
    .stat-card {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }
    
    .recipe-actions {
        flex-direction: column;
    }
    
    .activity-item {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }
}

/* Dashboard Layout */
.dashboard-main {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    align-items: start;
}

/* Dashboard Sidebar */
.dashboard-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.sidebar-section {
    background: var(--bg-secondary, #ffffff);
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 12px;
    padding: 1.5rem;
}

.sidebar-title {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin: 0 0 1rem 0;
}

/* Quick Actions */
.quick-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.quick-action {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: var(--bg-primary, #f8f9fa);
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-primary, #212529);
    transition: all 0.2s ease;
}

.quick-action:hover {
    background: var(--bg-tertiary, #e9ecef);
    border-color: var(--accent-primary, #007bff);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.quick-action-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background: var(--accent-primary, #007bff);
    color: white;
    border-radius: 8px;
    flex-shrink: 0;
}

.quick-action-content {
    flex: 1;
    min-width: 0;
}

.quick-action-title {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary, #212529);
    margin-bottom: 0.25rem;
}

.quick-action-description {
    font-size: 0.8rem;
    color: var(--text-secondary, #6c757d);
    line-height: 1.3;
}

/* Activity List */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem;
    background: var(--bg-primary, #f8f9fa);
    border: 1px solid var(--border-light, #e9ecef);
    border-radius: 6px;
}

.activity-icon {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: var(--accent-primary, #007bff);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.activity-content {
    flex: 1;
    min-width: 0;
}

.activity-text {
    font-size: 0.85rem;
    color: var(--text-primary, #212529);
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.activity-time {
    font-size: 0.75rem;
    color: var(--text-muted, #999999);
}

/* Dashboard section headers */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.section-title {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin: 0;
}

.section-action {
    color: var(--accent-primary, #007bff);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.section-action:hover {
    color: var(--accent-secondary, #0056b3);
}

/* Recipe List Styles */
.recipe-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.recipe-item {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--bg-secondary, #ffffff);
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 12px;
    transition: all 0.2s ease;
}

.recipe-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.08);
}

.recipe-image {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.recipe-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recipe-image-placeholder {
    width: 100%;
    height: 100%;
    background: var(--bg-tertiary, #f8f9fa);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted, #999999);
}

.recipe-content {
    flex: 1;
    min-width: 0;
}

.recipe-title {
    margin: 0 0 0.5rem 0;
}

.recipe-title a {
    color: var(--text-primary, #212529);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    line-height: 1.3;
}

.recipe-title a:hover {
    color: var(--accent-primary, #007bff);
}

.recipe-description {
    color: var(--text-secondary, #6c757d);
    font-size: 0.9rem;
    line-height: 1.4;
    margin-bottom: 0.75rem;
}

.recipe-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.8rem;
    color: var(--text-muted, #999999);
}

.recipe-time,
.recipe-servings {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.recipe-actions {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    flex-shrink: 0;
}

/* Responsive adjustments for dashboard layout */
@media (max-width: 1024px) {
    .dashboard-main {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .dashboard-sidebar {
        order: -1;
    }
    
    .quick-actions {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .recipe-item {
        flex-direction: column;
    }
    
    .recipe-image {
        width: 100%;
        height: 160px;
        align-self: stretch;
    }
    
    .quick-actions {
        grid-template-columns: 1fr;
    }
}

/* Dark Theme Support */
[data-theme="dark"] .stat-card,
[data-theme="dark"] .recipe-card,
[data-theme="dark"] .activity-feed {
    background: var(--bg-secondary);
    border-color: var(--border-color);
}

/* ========================================
   COMPREHENSIVE DARK MODE DASHBOARD STYLES
   ======================================== */

[data-theme="dark"] .dashboard-container {
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

[data-theme="dark"] .dashboard-header {
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .dashboard-title {
    color: var(--text-primary);
}

[data-theme="dark"] .dashboard-subtitle {
    color: var(--text-secondary);
}

/* Dashboard Main Layout */
[data-theme="dark"] .dashboard-main {
    color: var(--text-primary);
}

/* Sidebar Styles */
[data-theme="dark"] .dashboard-sidebar {
    color: var(--text-primary);
}

[data-theme="dark"] .sidebar-section {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] .sidebar-title {
    color: var(--text-primary);
}

/* Quick Actions Enhanced */
[data-theme="dark"] .quick-actions {
    color: var(--text-primary);
}

[data-theme="dark"] .quick-action {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
    color: var(--text-primary);
}

[data-theme="dark"] .quick-action:hover {
    background-color: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

[data-theme="dark"] .quick-action-icon {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .quick-action:hover .quick-action-icon {
    background-color: white;
    color: var(--accent-primary);
}

[data-theme="dark"] .quick-action-title {
    color: var(--text-primary);
}

[data-theme="dark"] .quick-action:hover .quick-action-title {
    color: white;
}

[data-theme="dark"] .quick-action-description {
    color: var(--text-secondary);
}

[data-theme="dark"] .quick-action:hover .quick-action-description {
    color: rgba(255, 255, 255, 0.9);
}

/* Activity List Enhanced */
[data-theme="dark"] .activity-list {
    color: var(--text-primary);
}

[data-theme="dark"] .activity-item {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .activity-icon {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .activity-text {
    color: var(--text-primary);
}

[data-theme="dark"] .activity-time {
    color: var(--text-muted);
}

/* Section Headers */
[data-theme="dark"] .section-header {
    color: var(--text-primary);
}

[data-theme="dark"] .section-title {
    color: var(--text-primary);
}

[data-theme="dark"] .section-action {
    color: var(--accent-primary);
}

[data-theme="dark"] .section-action:hover {
    color: #66b3ff;
}

/* Recipe List Enhanced */
[data-theme="dark"] .recipe-list {
    color: var(--text-primary);
}

[data-theme="dark"] .recipe-item {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .recipe-item:hover {
    background-color: var(--bg-tertiary);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .recipe-image-placeholder {
    background-color: var(--bg-tertiary);
    color: var(--text-muted);
}

[data-theme="dark"] .recipe-title a {
    color: var(--text-primary);
}

[data-theme="dark"] .recipe-title a:hover {
    color: var(--accent-primary);
}

[data-theme="dark"] .recipe-description {
    color: var(--text-secondary);
}

[data-theme="dark"] .recipe-meta {
    color: var(--text-muted);
}

/* Stat Cards Enhanced */
[data-theme="dark"] .stat-card {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .stat-icon {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .stat-number {
    color: var(--text-primary);
}

[data-theme="dark"] .stat-label {
    color: var(--text-secondary);
}

[data-theme="dark"] .stat-link {
    color: var(--accent-primary);
}

[data-theme="dark"] .stat-link:hover {
    color: #66b3ff;
    background-color: rgba(102, 179, 255, 0.1);
}

[data-theme="dark"] .stat-text {
    color: var(--text-secondary);
}

[data-theme="dark"] .stat-change {
    color: var(--text-muted);
}

[data-theme="dark"] .stat-change.positive {
    color: var(--success);
}

[data-theme="dark"] .stat-change.negative {
    color: var(--danger);
}

[data-theme="dark"] .recent-recipes {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .recipe-grid .recipe-card {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .recipe-grid .recipe-card:hover {
    background-color: var(--bg-secondary);
}

[data-theme="dark"] .recipe-grid .recipe-title {
    color: var(--text-primary);
}

[data-theme="dark"] .recipe-grid .recipe-meta {
    color: var(--text-secondary);
}

[data-theme="dark"] .empty-state {
    color: var(--text-secondary);
}

[data-theme="dark"] .empty-state-icon {
    color: var(--text-muted);
}

[data-theme="dark"] .empty-state-title {
    color: var(--text-primary);
}

[data-theme="dark"] .empty-state-description {
    color: var(--text-secondary);
}

[data-theme="dark"] .dashboard-widget {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .widget-header {
    color: var(--text-primary);
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .widget-content {
    color: var(--text-secondary);
}

/* Print Styles */
@media print {
    .dashboard-actions,
    .recipe-actions {
        display: none !important;
    }
    
    .stat-card {
        break-inside: avoid;
    }
}

/* From: assets/css/recipes.css */
/* Recipe Form Styles */
.recipe-create-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.page-title-section {
    flex: 1;
}

.page-title {
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    color: var(--text-primary);
}

.page-subtitle {
    color: var(--text-secondary);
    margin: 0;
    font-size: 1rem;
}

.page-actions {
    display: flex;
    gap: 1rem;
}

/* Form Sections */
.recipe-form-container {
    background: var(--card-bg);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.form-section {
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.form-section:last-child {
    border-bottom: none;
}

.section-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0 0 1.5rem 0;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

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

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group-full {
    grid-column: 1 / -1;
}

.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-size: 0.875rem;
}

.form-label.required::after {
    content: " *";
    color: var(--error-color);
}

.form-control {
    padding: 0.375rem 0.75rem;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.5;
    color: var(--text-primary);
    background-color: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus {
    color: var(--text-primary);
    background-color: var(--input-bg);
    border-color: var(--accent-primary);
    outline: 0;
    box-shadow: 0 0 0 0.25rem var(--primary-color-alpha);
}

.form-control::placeholder {
    color: var(--text-muted);
    opacity: 1;
}

/* Specific styling for select elements in dark mode */
[data-theme="dark"] .form-control {
    color: #ffffff;
    background-color: #404040;
    border-color: #555555;
}

[data-theme="dark"] .form-control:focus {
    color: #ffffff;
    background-color: #404040;
    border-color: #4dabf7;
    box-shadow: 0 0 0 0.25rem rgba(77, 171, 247, 0.25);
}

[data-theme="dark"] .form-control option {
    background-color: #404040;
    color: #ffffff;
}

[data-theme="dark"] .form-control select {
    color: #ffffff !important;
}

.form-help {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* File Upload */
.file-upload-area {
    border: 2px dashed var(--border-color);
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s ease, background-color 0.2s ease;
    position: relative;
}

.file-upload-area:hover {
    border-color: var(--primary-color);
    background-color: var(--primary-color-alpha);
}

.file-upload-area.has-file {
    border-color: var(--success-color);
    background-color: var(--success-color-alpha);
}

.file-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.upload-icon {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.upload-text {
    font-size: 0.875rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.upload-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.file-preview {
    position: relative;
    max-width: 200px;
    margin: 0 auto;
}

.file-preview img {
    width: 100%;
    height: auto;
    border-radius: 6px;
    border: 1px solid var(--border-color);
}

.remove-file {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--error-color);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    line-height: 1;
}

.remove-file:hover {
    background: var(--error-color-dark);
}

/* Dynamic Lists */
.ingredients-container,
.instructions-container {
    margin-bottom: 1rem;
}

.ingredient-item,
.instruction-item {
    margin-bottom: 0.75rem;
}

.ingredient-item:last-child,
.instruction-item:last-child {
    margin-bottom: 0;
}

.ingredient-fields {
    display: grid;
    grid-template-columns: 120px 1fr auto;
    gap: 0.5rem;
    align-items: center;
}

.instruction-fields {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 0.75rem;
    align-items: flex-start;
}

.instruction-number {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    flex-shrink: 0;
    margin-top: 0.75rem;
}

.ingredient-amount {
    min-width: 0;
}

.ingredient-item-name,
.instruction-text {
    min-width: 0;
}

.remove-ingredient,
.remove-instruction {
    padding: 0.5rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    margin-top: 0.5rem;
}

/* Tags */
.popular-tags {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.popular-tags-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.popular-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag-suggestion {
    padding: 0.25rem 0.75rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    font-size: 0.75rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.tag-suggestion:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Form Actions */
.form-actions {
    padding: 2rem;
    background: var(--bg-secondary);
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    border-top: 1px solid var(--border-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .recipe-create-container {
        padding: 1rem;
    }
    
    .page-header {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .form-section {
        padding: 1.5rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .ingredient-fields {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .instruction-fields {
        grid-template-columns: auto 1fr;
        gap: 0.75rem;
    }
    
    .remove-ingredient,
    .remove-instruction {
        grid-column: 2;
        justify-self: end;
        margin-top: 0.5rem;
    }
    
    .form-actions {
        flex-direction: column;
        padding: 1.5rem;
    }
    
    .popular-tags-list {
        gap: 0.25rem;
    }
}

/* ========================================
   COMPREHENSIVE DARK MODE RECIPES STYLES
   ======================================== */

[data-theme="dark"] .recipe-form-container {
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

[data-theme="dark"] .recipe-form {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .form-section {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .form-section-title {
    color: var(--text-primary);
}

[data-theme="dark"] .form-section-description {
    color: var(--text-secondary);
}

[data-theme="dark"] .form-group label {
    color: var(--text-primary);
}

[data-theme="dark"] .form-help {
    color: var(--text-muted);
}

[data-theme="dark"] .form-control {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .form-control:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 0.25rem var(--primary-color-alpha);
}

[data-theme="dark"] .form-control::placeholder {
    color: var(--text-muted);
}

[data-theme="dark"] .form-control option {
    background-color: var(--input-bg);
    color: var(--text-primary);
}

[data-theme="dark"] .form-control textarea {
    background-color: var(--input-bg);
    color: var(--text-primary);
}

[data-theme="dark"] .ingredients-container {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .ingredient-item {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .ingredient-item input {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .instructions-container {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .instruction-item {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .instruction-item textarea {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .add-item-btn {
    background-color: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

[data-theme="dark"] .add-item-btn:hover {
    background-color: var(--accent-hover);
    border-color: var(--accent-hover);
}

[data-theme="dark"] .remove-item-btn {
    background-color: var(--danger);
    color: white;
    border-color: var(--danger);
}

[data-theme="dark"] .remove-item-btn:hover {
    background-color: var(--danger-hover);
    border-color: var(--danger-hover);
}

[data-theme="dark"] .categories-selection {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .category-checkbox-item {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .category-checkbox-item:hover {
    background-color: var(--bg-tertiary);
}

[data-theme="dark"] .category-checkbox-item input[type="checkbox"] {
    background-color: var(--input-bg);
    border-color: var(--border-color);
}

[data-theme="dark"] .category-checkbox-item label {
    color: var(--text-primary);
}

[data-theme="dark"] .tags-selection {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .tag-input-container {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .tag-input {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .add-tag-btn {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .add-tag-btn:hover {
    background-color: var(--accent-hover);
}

[data-theme="dark"] .selected-tags {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .tag-item {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .tag-remove {
    color: rgba(255, 255, 255, 0.8);
}

[data-theme="dark"] .tag-remove:hover {
    color: white;
    background-color: rgba(255, 255, 255, 0.2);
}

[data-theme="dark"] .popular-tags {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .popular-tags-title {
    color: var(--text-primary);
}

[data-theme="dark"] .popular-tag {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .popular-tag:hover {
    background-color: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

[data-theme="dark"] .form-actions {
    background-color: var(--bg-secondary);
    border-top-color: var(--border-color);
}

[data-theme="dark"] .save-draft-btn {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .save-draft-btn:hover {
    background-color: var(--text-muted);
    color: white;
}

[data-theme="dark"] .recipe-table {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .recipe-table th {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .recipe-table td {
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .recipe-table tr:hover {
    background-color: var(--bg-tertiary);
}

[data-theme="dark"] .recipe-table .recipe-title {
    color: var(--accent-primary);
}

[data-theme="dark"] .recipe-table .recipe-title:hover {
    color: var(--accent-hover);
}

[data-theme="dark"] .recipe-meta-badge {
    background-color: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

[data-theme="dark"] .status-published {
    background-color: #1a4d1a;
    color: #4caf50;
    border-color: #2e7d32;
}

[data-theme="dark"] .status-draft {
    background-color: #4d4d1a;
    color: #ff9800;
    border-color: #f57c00;
}

[data-theme="dark"] .status-private {
    background-color: #4d1a1a;
    color: #f44336;
    border-color: #d32f2f;
}

[data-theme="dark"] .recipe-filters {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .filter-title {
    color: var(--text-primary);
}

[data-theme="dark"] .image-upload-area {
    background-color: var(--bg-tertiary);
    border-color: var(--border-color);
    color: var(--text-secondary);
}

[data-theme="dark"] .image-upload-area:hover {
    background-color: var(--bg-secondary);
    border-color: var(--accent-primary);
}

[data-theme="dark"] .image-preview {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .remove-image-btn {
    background-color: var(--danger);
    color: white;
}

[data-theme="dark"] .remove-image-btn:hover {
    background-color: var(--danger-hover);
}

/* From: assets/css/recipe-cards-enhanced.css */
/* Enhanced Recipe Cards - Modern UI/UX Improvements
   OpenServings Recipe Manager v3.1.0 - UI Enhancement Update */

/* Recipe Grid Container */
.recipes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
    padding: 0 0.5rem;
}

/* Enhanced Recipe Card */
.recipe-card {
    background: var(--bg-secondary);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-light);
    position: relative;
}

.recipe-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    border-color: var(--accent-primary);
}

/* Recipe Image Container */
.recipe-image {
    position: relative;
    height: 220px;
    overflow: hidden;
    background: var(--bg-tertiary);
}

.recipe-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.recipe-card:hover .recipe-image img {
    transform: scale(1.05);
}

/* Recipe Placeholder */
.recipe-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--accent-bg) 100%);
    color: var(--text-muted);
    position: relative;
}

.recipe-placeholder::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23f0f0f0' fill-opacity='0.3'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
    opacity: 0.1;
}

/* Recipe Overlay with Gradient */
.recipe-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.4) 50%, transparent 100%);
    padding: 1.25rem;
    color: white;
}

/* Recipe Meta Information */
.recipe-meta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    color: rgba(255, 255, 255, 0.95);
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.meta-item svg {
    opacity: 0.9;
}

/* Recipe Content */
.recipe-content {
    padding: 1.5rem;
    background: var(--bg-secondary);
}

.recipe-title {
    margin: 0 0 0.75rem 0;
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.4;
}

.recipe-title a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

.recipe-title a:hover {
    color: var(--accent-primary);
}

/* Recipe Description */
.recipe-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0 0 1.25rem 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Recipe Actions */
.recipe-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: auto;
}

.recipe-actions .btn {
    flex: 1;
    justify-content: center;
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
    text-align: center;
}

.recipe-actions .btn-primary {
    background: var(--accent-primary);
    color: white;
    border: 1px solid var(--accent-primary);
}

.recipe-actions .btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.3);
}

.recipe-actions .btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.recipe-actions .btn-secondary:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--text-secondary);
    transform: translateY(-1px);
}

/* Recipe Card Categories/Tags */
.recipe-card-tags {
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 2;
}

.recipe-tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(255, 255, 255, 0.9);
    color: var(--text-primary);
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 12px;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Empty State Improvements */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    grid-column: 1 / -1;
}

.empty-illustration {
    margin-bottom: 2rem;
    color: var(--text-muted);
    opacity: 0.6;
}

.empty-state h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.empty-state p {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 2rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.empty-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.empty-actions .btn {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
}

/* Responsive Design */
@media (max-width: 768px) {
    .recipes-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 0;
    }
    
    .recipe-card {
        margin: 0 1rem;
    }
    
    .recipe-image {
        height: 200px;
    }
    
    .recipe-content {
        padding: 1.25rem;
    }
    
    .recipe-actions {
        flex-direction: column;
    }
    
    .recipe-actions .btn {
        flex: none;
    }
    
    .empty-state {
        padding: 3rem 1rem;
    }
    
    .empty-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .empty-actions .btn {
        width: 100%;
        max-width: 280px;
    }
}

@media (max-width: 480px) {
    .recipe-meta {
        gap: 0.5rem;
    }
    
    .meta-item {
        font-size: 0.8rem;
        padding: 0.125rem 0.375rem;
    }
    
    .recipe-title {
        font-size: 1.125rem;
    }
    
    .recipe-overlay {
        padding: 1rem;
    }
}

/* Dark Mode Adjustments */
[data-theme="dark"] .recipe-placeholder {
    background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-primary) 100%);
}

[data-theme="dark"] .recipe-tag {
    background: rgba(0, 0, 0, 0.8);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .meta-item {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Animation for card loading */
@keyframes cardFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.recipe-card {
    animation: cardFadeIn 0.5s ease-out;
}

.recipe-card:nth-child(1) { animation-delay: 0.1s; }
.recipe-card:nth-child(2) { animation-delay: 0.2s; }
.recipe-card:nth-child(3) { animation-delay: 0.3s; }
.recipe-card:nth-child(4) { animation-delay: 0.4s; }
.recipe-card:nth-child(5) { animation-delay: 0.5s; }
.recipe-card:nth-child(6) { animation-delay: 0.6s; }

/* From: assets/css/recipe-display-enhanced.css */
/* Enhanced Recipe Display - Improved Layout and Typography
   OpenServings Recipe Manager v3.1.0 - Recipe View Enhancement */

/* Recipe Header Enhancement */
.recipe-header {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    padding: 2rem 0;
    margin-bottom: 2rem;
    border-radius: 0 0 2rem 2rem;
    position: relative;
    overflow: hidden;
}

.recipe-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23f8f9fa' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
    opacity: 0.3;
    pointer-events: none;
}

.recipe-header-content {
    position: relative;
    z-index: 1;
}

/* Recipe Meta Information */
.recipe-meta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: 1rem;
    border: 1px solid var(--border-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.meta-item {
    text-align: center;
    padding: 1rem;
    background: var(--bg-tertiary);
    border-radius: 12px;
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.meta-item:hover {
    transform: translateY(-2px);
    background: var(--accent-bg);
}

.meta-icon {
    font-size: 1.5rem;
    color: var(--accent-primary);
    margin-bottom: 0.5rem;
    display: block;
}

.meta-value {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    display: block;
    margin-bottom: 0.25rem;
}

.meta-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

/* Enhanced Ingredients Section */
.ingredients-section {
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: 1rem;
    border: 1px solid var(--border-light);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-light);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 3rem;
    height: 2px;
    background: var(--accent-primary);
    border-radius: 1px;
}

.section-title i {
    color: var(--accent-primary);
    font-size: 1.25rem;
}

/* Enhanced Ingredients List */
.ingredients-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 0.75rem;
}

.ingredient-item {
    display: grid;
    grid-template-columns: auto auto 1fr auto;
    gap: 0.5rem;
    align-items: baseline;
    padding: 1rem;
    background: var(--bg-tertiary);
    border-radius: 12px;
    border: 1px solid var(--border-light);
    transition: all 0.2s ease;
    position: relative;
}

.ingredient-item:hover {
    background: var(--accent-bg);
    border-color: var(--accent-primary);
    transform: translateX(4px);
}

.ingredient-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--accent-primary);
    border-radius: 0 2px 2px 0;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.ingredient-item:hover::before {
    opacity: 1;
}

.ingredient-amount {
    font-weight: 600;
    color: var(--accent-primary);
    font-size: 0.95rem;
    min-width: 3rem;
    text-align: right;
}

.ingredient-unit {
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 0.9rem;
    min-width: 4rem;
}

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

.ingredient-notes,
.ingredient-preparation {
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.85rem;
    grid-column: 1 / -1;
    margin-top: 0.25rem;
    padding-left: 7.5rem;
}

/* Instructions Section */
.instructions-section {
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: 1rem;
    border: 1px solid var(--border-light);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.instructions-list {
    list-style: none;
    padding: 0;
    margin: 0;
    counter-reset: step-counter;
}

.instruction-item {
    counter-increment: step-counter;
    display: flex;
    gap: 1.5rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    background: var(--bg-tertiary);
    border-radius: 12px;
    border: 1px solid var(--border-light);
    position: relative;
    transition: all 0.3s ease;
}

.instruction-item:hover {
    background: var(--accent-bg);
    border-color: var(--accent-primary);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.1);
}

.instruction-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background: var(--accent-primary);
    color: white;
    border-radius: 50%;
    font-weight: 700;
    font-size: 1rem;
    flex-shrink: 0;
    position: relative;
}

.instruction-number::before {
    content: counter(step-counter);
}

.instruction-content {
    flex: 1;
    line-height: 1.6;
    color: var(--text-primary);
    font-size: 1rem;
    align-self: center;
}

/* Recipe Actions */
.recipe-actions {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.recipe-actions .btn {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s ease;
}

.recipe-actions .btn:hover {
    transform: translateY(-2px);
}

.recipe-actions .btn i {
    font-size: 0.9rem;
}

/* Shopping List Button Enhancement */
.shopping-list-btn {
    width: 100%;
    margin-top: 1rem;
    padding: 1rem;
    font-size: 1rem;
    background: var(--success);
    color: white;
    border: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.shopping-list-btn:hover {
    background: var(--success-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(40, 167, 69, 0.3);
}

.shopping-list-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.shopping-list-btn:hover::before {
    left: 100%;
}

/* Recipe Details Grid */
.recipe-details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

/* Featured Image Enhancement */
.recipe-image-container {
    margin: 2rem 0;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    position: relative;
}

.recipe-featured-image {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.recipe-image-container:hover .recipe-featured-image {
    transform: scale(1.02);
}

/* No content states */
.no-ingredients,
.no-instructions {
    text-align: center;
    color: var(--text-muted);
    font-style: italic;
    padding: 2rem;
    background: var(--bg-tertiary);
    border-radius: 8px;
    border: 2px dashed var(--border-color);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .recipe-details-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .recipe-meta-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .recipe-header {
        padding: 1.5rem 0;
        margin-bottom: 1.5rem;
        border-radius: 0 0 1rem 1rem;
    }
    
    .ingredients-section,
    .instructions-section {
        padding: 1.5rem;
    }
    
    .section-title {
        font-size: 1.25rem;
        margin-bottom: 1rem;
    }
    
    .ingredient-item {
        grid-template-columns: auto 1fr;
        gap: 0.5rem;
    }
    
    .ingredient-unit {
        grid-column: 1;
    }
    
    .ingredient-name {
        grid-column: 2;
    }
    
    .ingredient-amount {
        grid-column: 1 / -1;
        text-align: left;
        margin-bottom: 0.5rem;
        font-size: 1rem;
    }
    
    .ingredient-notes,
    .ingredient-preparation {
        padding-left: 0;
        grid-column: 1 / -1;
    }
    
    .instruction-item {
        flex-direction: column;
        gap: 1rem;
        padding: 1.25rem;
    }
    
    .instruction-number {
        align-self: flex-start;
    }
    
    .recipe-actions {
        flex-direction: column;
    }
    
    .recipe-meta-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .ingredients-section,
    .instructions-section {
        padding: 1rem;
        margin-bottom: 1rem;
    }
    
    .ingredient-item {
        padding: 0.75rem;
    }
    
    .instruction-item {
        padding: 1rem;
    }
    
    .instruction-number {
        width: 2rem;
        height: 2rem;
        font-size: 0.875rem;
    }
    
    .recipe-meta-grid {
        grid-template-columns: 1fr;
    }
    
    .meta-item {
        padding: 0.75rem;
    }
}

/* Print Styles */
@media print {
    .recipe-actions,
    .shopping-list-btn {
        display: none !important;
    }
    
    .recipe-details-grid {
        display: block;
    }
    
    .ingredients-section,
    .instructions-section {
        break-inside: avoid;
        margin-bottom: 1rem;
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .ingredient-item,
    .instruction-item {
        break-inside: avoid;
        background: white !important;
        box-shadow: none;
    }
}

/* Dark mode enhancements */
[data-theme="dark"] .recipe-header {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
}

[data-theme="dark"] .instruction-number {
    background: var(--accent-primary);
    color: var(--bg-primary);
}

/* From: assets/css/meal-planner.css */
/**
 * OpenServings v3.2.0 - Meal Planning Interface Styles
 * Smart meal planner with drag-and-drop, calendar view, and shopping lists
 * Created: September 7, 2025
 */

/* ====================================
   MEAL PLANNER LAYOUT
   ==================================== */

.meal-planner-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 30px;
    min-height: calc(100vh - 120px);
}

.meal-planner-sidebar {
    background: var(--color-surface);
    border-radius: 12px;
    padding: 24px;
    border: 1px solid var(--color-border);
    height: fit-content;
    position: sticky;
    top: 20px;
}

.meal-planner-main {
    background: var(--color-surface);
    border-radius: 12px;
    padding: 24px;
    border: 1px solid var(--color-border);
    min-height: 600px;
}

/* ====================================
   MEAL PLAN CONTROLS
   ==================================== */

.meal-plan-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.meal-plan-header {
    display: flex;
    align-items: center;
    gap: 16px;
}

.meal-plan-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--color-text);
    margin: 0;
}

.meal-plan-dates {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    background: var(--color-background-subtle);
    padding: 4px 12px;
    border-radius: 20px;
}

.meal-plan-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.week-navigation {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 16px;
    background: var(--color-background-subtle);
    border-radius: 8px;
}

.week-nav-btn {
    background: none;
    border: none;
    padding: 8px;
    border-radius: 6px;
    cursor: pointer;
    color: var(--color-text-secondary);
    transition: all 0.2s ease;
}

.week-nav-btn:hover {
    background: var(--color-primary-light);
    color: var(--color-primary);
}

.week-nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.current-week {
    font-weight: 500;
    color: var(--color-text);
    min-width: 120px;
    text-align: center;
}

/* ====================================
   WEEKLY CALENDAR GRID
   ==================================== */

.weekly-calendar {
    display: grid;
    grid-template-columns: 120px repeat(7, 1fr);
    gap: 1px;
    background: var(--color-border);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 24px;
}

.calendar-header {
    background: var(--color-primary);
    color: white;
    padding: 16px 12px;
    font-weight: 600;
    text-align: center;
    font-size: 0.9rem;
}

.calendar-header.meal-type-header {
    background: var(--color-background-subtle);
    color: var(--color-text);
    font-size: 0.8rem;
    padding: 12px 8px;
}

.calendar-day-header {
    background: var(--color-primary-light);
    color: var(--color-primary-dark);
    padding: 12px 8px;
    text-align: center;
    font-weight: 500;
    font-size: 0.85rem;
}

.calendar-day-header.today {
    background: var(--color-accent);
    color: white;
}

.meal-slot {
    background: var(--color-surface);
    min-height: 80px;
    padding: 8px;
    position: relative;
    border: 2px dashed transparent;
    transition: all 0.2s ease;
    cursor: pointer;
}

.meal-slot:hover {
    background: var(--color-background-subtle);
}

.meal-slot.drag-over {
    border-color: var(--color-primary);
    background: var(--color-primary-light);
}

.meal-slot.occupied {
    background: var(--color-surface);
    border: 2px solid var(--color-border);
    cursor: default;
}

.meal-slot.occupied:hover {
    border-color: var(--color-primary-light);
}

/* ====================================
   PLANNED MEAL CARDS
   ==================================== */

.planned-meal {
    background: var(--bg-secondary);
    border-radius: 8px;
    padding: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    cursor: grab;
    position: relative;
    transition: all 0.2s ease;
    border: 1px solid var(--border-color);
}

.planned-meal:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.planned-meal.dragging {
    opacity: 0.5;
    cursor: grabbing;
    transform: rotate(5deg);
}

.planned-meal-title {
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--color-text);
    line-height: 1.3;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.planned-meal-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    color: var(--color-text-secondary);
    margin-bottom: 8px;
}

.meal-time {
    display: flex;
    align-items: center;
    gap: 4px;
}

.meal-servings {
    background: var(--color-accent-light);
    color: var(--color-accent-dark);
    padding: 2px 6px;
    border-radius: 10px;
    font-weight: 500;
}

.planned-meal-actions {
    position: absolute;
    top: 8px;
    right: 8px;
    opacity: 0;
    transition: opacity 0.2s ease;
    z-index: 10;
}

.planned-meal:hover .planned-meal-actions {
    opacity: 1;
}

.meal-action-btn {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(220, 53, 69, 0.3);
    border-radius: 50%;
    padding: 6px;
    cursor: pointer;
    color: #dc3545;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: bold;
    line-height: 1;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.meal-action-btn:hover {
    background: #dc3545;
    color: white;
    border-color: #dc3545;
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3);
}

.meal-action-btn:hover {
    background: var(--color-danger);
    color: white;
    border-color: var(--color-danger);
}

.meal-action-btn:hover {
    background: #dc3545;
    color: white;
    border-color: #dc3545;
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3);
}

/* ====================================
   SETTINGS MODAL
   ==================================== */

.modal {
    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;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(2px);
}

.modal.show {
    opacity: 1;
    visibility: visible;
}

.modal-large {
    max-width: 800px;
}

.modal-content {
    background: var(--color-surface);
    border-radius: 12px;
    max-width: 90%;
    max-height: 90vh;
    width: 100%;
    border: 1px solid var(--color-border);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transform: translateY(-20px);
    transition: transform 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal.show .modal-content {
    transform: translateY(0);
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--color-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--color-surface);
}

.modal-header h2 {
    margin: 0;
    color: var(--color-text-primary);
    font-size: 1.25rem;
    font-weight: 600;
}

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

.modal-footer {
    padding: 20px 24px;
    border-top: 1px solid var(--color-border);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    background: var(--color-surface);
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--color-text-secondary);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: var(--color-danger);
    color: white;
}

.settings-section {
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--color-border);
}

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

.settings-section h3 {
    color: var(--color-text-primary);
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
}

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

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    color: var(--color-text-primary);
    font-weight: 500;
    margin-bottom: 6px;
    font-size: 14px;
}

.form-group input,
.form-group textarea {
    padding: 10px 12px;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    font-size: 14px;
    background: var(--color-surface);
    color: var(--color-text-primary);
    transition: all 0.2s ease;
}

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

.form-group textarea {
    min-height: 80px;
    resize: vertical;
    font-family: inherit;
}

.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--color-surface);
}

.checkbox-item:hover {
    background: var(--color-primary-light);
    border-color: var(--color-primary);
}

.checkbox-item input[type="checkbox"] {
    margin-right: 8px;
    margin-bottom: 0;
}

.checkbox-item input[type="checkbox"]:checked + .checkbox-label {
    color: var(--color-primary);
    font-weight: 500;
}

.checkbox-label {
    color: var(--color-text-primary);
    font-size: 14px;
    user-select: none;
}

/* Dark mode support for settings */
:root[data-theme="dark"] .modal {
    background: rgba(0, 0, 0, 0.7);
}

:root[data-theme="dark"] .modal-content {
    background: var(--color-background-secondary);
    border-color: var(--color-border);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

:root[data-theme="dark"] .modal-header,
:root[data-theme="dark"] .modal-footer {
    background: var(--color-background-secondary);
    border-color: var(--color-border);
}

:root[data-theme="dark"] .settings-section h3 {
    color: var(--color-text-primary);
}

:root[data-theme="dark"] .form-group input,
:root[data-theme="dark"] .form-group textarea {
    background: var(--color-background-secondary);
    border-color: var(--color-border);
    color: var(--color-text-primary);
}

:root[data-theme="dark"] .checkbox-item {
    background: var(--color-background-secondary);
    border-color: var(--color-border);
}

:root[data-theme="dark"] .checkbox-item:hover {
    background: rgba(var(--color-primary-rgb), 0.1);
}

/* ====================================
   EMPTY MEAL SLOT
   ==================================== */

.empty-meal-slot {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 80px;
    color: var(--color-text-secondary);
    font-size: 0.8rem;
    text-align: center;
    transition: all 0.2s ease;
}

.empty-meal-slot .add-meal-icon {
    font-size: 24px;
    margin-bottom: 4px;
    opacity: 0.5;
}

.empty-meal-slot .add-meal-text {
    opacity: 0;
    transition: opacity 0.2s ease;
}

.meal-slot:hover .empty-meal-slot .add-meal-icon {
    opacity: 0.8;
    color: var(--color-primary);
}

.meal-slot:hover .empty-meal-slot .add-meal-text {
    opacity: 1;
}

/* ====================================
   RECIPE SIDEBAR
   ==================================== */

.recipe-sidebar-section {
    margin-bottom: 24px;
}

.sidebar-section-title {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--color-text);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.recipe-search {
    margin-bottom: 16px;
}

.recipe-search-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-size: 0.9rem;
    transition: border-color 0.2s ease;
}

.recipe-search-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-light);
}

.recipe-filters {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.filter-select {
    padding: 8px 12px;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    font-size: 0.85rem;
    background: white;
}

.quick-add-recipes {
    max-height: 400px;
    overflow-y: auto;
}

.recipe-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: grab;
    transition: all 0.2s ease;
    background: white;
}

.recipe-item:hover {
    border-color: var(--color-primary);
    background: var(--color-primary-light);
}

.recipe-item.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

.recipe-item-image {
    width: 40px;
    height: 40px;
    border-radius: 6px;
    object-fit: cover;
    background: var(--color-background-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-secondary);
    font-size: 18px;
}

.recipe-item-info {
    flex: 1;
    min-width: 0;
}

.recipe-item-title {
    font-weight: 500;
    font-size: 0.85rem;
    color: var(--color-text);
    line-height: 1.3;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.recipe-item-meta{font-size:.75rem;color:var(--color-text-secondary);display:flex;gap:8px}[data-theme="dark"] .recipe-item{background:var(--bg-secondary)!important;border-color:var(--border-color);color:var(--text-primary)}[data-theme="dark"] .recipe-item:hover{background:var(--bg-tertiary)!important;border-color:var(--color-primary)}[data-theme="dark"] .recipe-item-title{color:var(--text-primary)}[data-theme="dark"] .recipe-item-meta{color:var(--text-secondary)}[data-theme="dark"] .recipe-search-input{background:var(--bg-secondary);border-color:var(--border-color);color:var(--text-primary)}[data-theme="dark"] .filter-select{background:var(--bg-secondary);border-color:var(--border-color);color:var(--text-primary)}

/* ====================================
   MEAL PLAN STATS
   ==================================== */

.meal-plan-stats {
    background: var(--color-background-subtle);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 24px;
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

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

.stat-value {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--color-primary);
    display: block;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--color-text-secondary);
    margin-top: 4px;
}

/* ====================================
   NUTRITION SUMMARY
   ==================================== */

.nutrition-summary {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 16px;
    margin-top: 24px;
}

.nutrition-title {
    font-weight: 600;
    font-size: 1rem;
    color: var(--color-text);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.nutrition-bars {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nutrition-bar {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nutrition-bar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
}

.nutrition-label {
    font-weight: 500;
    color: var(--color-text);
}

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

.nutrition-progress {
    height: 8px;
    background: var(--color-background-subtle);
    border-radius: 4px;
    overflow: hidden;
}

.nutrition-progress-fill {
    height: 100%;
    background: var(--color-primary);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.nutrition-progress-fill.over-target {
    background: var(--color-warning);
}

.nutrition-progress-fill.way-over {
    background: var(--color-danger);
}

/* ====================================
   MOBILE RESPONSIVENESS
   ==================================== */

@media (max-width: 1024px) {
    .meal-planner-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .meal-planner-sidebar {
        position: static;
        order: 2;
    }
    
    .weekly-calendar {
        grid-template-columns: 100px repeat(7, 1fr);
    }
    
    .meal-slot {
        min-height: 60px;
        padding: 6px;
    }
    
    .planned-meal {
        padding: 8px;
    }
    
    .planned-meal-title {
        font-size: 0.8rem;
    }
}

@media (max-width: 768px) {
    .meal-planner-container {
        padding: 16px;
    }
    
    .meal-planner-main,
    .meal-planner-sidebar {
        padding: 16px;
    }
    
    .meal-plan-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .meal-plan-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .weekly-calendar {
        grid-template-columns: 80px repeat(7, 1fr);
        font-size: 0.8rem;
    }
    
    .calendar-header {
        padding: 12px 8px;
        font-size: 0.8rem;
    }
    
    .meal-slot {
        min-height: 50px;
        padding: 4px;
    }
    
    .recipe-item {
        padding: 8px;
        gap: 8px;
    }
    
    .recipe-item-image {
        width: 32px;
        height: 32px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

/* ====================================
   DRAG AND DROP STATES
   ==================================== */

.drag-source {
    opacity: 0.5;
}

.drag-target-valid {
    border-color: var(--color-success) !important;
    background: var(--color-success-light) !important;
}

.drag-target-invalid {
    border-color: var(--color-danger) !important;
    background: var(--color-danger-light) !important;
}

/* ====================================
   LOADING STATES
   ==================================== */

.meal-planner-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    color: var(--color-text-secondary);
}

.skeleton-meal-slot {
    background: linear-gradient(90deg, var(--color-background-subtle) 25%, var(--color-border) 50%, var(--color-background-subtle) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: 8px;
    height: 80px;
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ====================================
   ACCESSIBILITY ENHANCEMENTS
   ==================================== */

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.meal-slot:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

.recipe-item:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .meal-slot {
        border: 2px solid var(--color-text);
    }
    
    .planned-meal {
        border: 2px solid var(--color-text);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .planned-meal,
    .meal-slot,
    .recipe-item,
    .nutrition-progress-fill {
        transition: none;
    }
    
    .skeleton-meal-slot {
        animation: none;
    }
}

/* ====================================
   RECIPE SELECTION MODAL
   ==================================== */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--bg-secondary, #ffffff);
    border-radius: 12px;
    max-width: 800px;
    max-height: 80vh;
    width: 90%;
    border: 1px solid var(--border-color, #e5e7eb);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transform: translateY(-20px);
    transition: transform 0.3s ease;
    opacity: 1;
    position: relative;
}

/* Dark mode modal content */
[data-theme="dark"] .modal-content {
    background: var(--bg-secondary);
    border-color: var(--border-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color, #e5e7eb);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-secondary, #ffffff);
    border-radius: 12px 12px 0 0;
}

.modal-header h3 {
    margin: 0;
    color: var(--text-primary, #1f2937);
    font-size: 1.25rem;
    font-weight: 600;
}

/* Dark mode modal header */
[data-theme="dark"] .modal-header {
    background: var(--bg-secondary);
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .modal-header h3 {
    color: var(--text-primary);
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-secondary, #6b7280);
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.modal-close:hover {
    background: var(--bg-tertiary, #f3f4f6);
    color: var(--text-primary, #1f2937);
}

/* Dark mode modal close button */
[data-theme="dark"] .modal-close {
    color: var(--text-secondary);
}

[data-theme="dark"] .modal-close:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.modal-body {
    padding: 24px;
    max-height: 60vh;
    overflow-y: auto;
    background: var(--bg-secondary, #ffffff);
}

/* Dark mode modal body */
[data-theme="dark"] .modal-body {
    background: var(--bg-secondary);
}

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

.recipe-selection-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 8px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background: var(--bg-secondary, #ffffff);
}

.recipe-selection-item:hover {
    border-color: var(--primary-color, #2563eb);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Dark mode recipe selection item */
[data-theme="dark"] .recipe-selection-item {
    background: var(--bg-tertiary);
    border-color: var(--border-color);
}

[data-theme="dark"] .recipe-selection-item:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.recipe-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

.recipe-info {
    flex: 1;
    min-width: 0;
}

.recipe-info .recipe-title {
    margin: 0 0 8px 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary, #1f2937);
}

.recipe-meta {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
}

.recipe-meta span {
    font-size: 0.875rem;
    color: var(--text-secondary, #6b7280);
    background: var(--bg-tertiary, #f3f4f6);
    padding: 2px 8px;
    border-radius: 4px;
}

/* Dark mode recipe info */
[data-theme="dark"] .recipe-info .recipe-title {
    color: var(--text-primary);
}

[data-theme="dark"] .recipe-meta span {
    color: var(--text-secondary);
    background: var(--bg-primary);
}

.recipe-description {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-secondary, #6b7280);
    line-height: 1.4;
}

.select-recipe-btn {
    flex-shrink: 0;
    padding: 8px 16px;
    font-size: 0.875rem;
}

/* Dark mode recipe description */
[data-theme="dark"] .recipe-description {
    color: var(--text-secondary);
}

/* Responsive modal */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        max-height: 90vh;
    }
    
    .recipe-selection-item {
        flex-direction: column;
        text-align: center;
    }
    
    .recipe-thumb {
        width: 80px;
        height: 80px;
    }
    
    .recipe-meta {
        justify-content: center;
    }
}

/* From: assets/css/advanced-search.css */
/* Advanced Search & Filtering Interface
   OpenServings Recipe Manager v3.1.0 - Advanced Search Enhancement */

/* Advanced Search Container */
.advanced-search-container {
    background: var(--bg-secondary);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

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

.search-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.advanced-toggle {
    background: none;
    border: none;
    color: var(--accent-primary);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.advanced-toggle:hover {
    background: var(--accent-bg);
}

.advanced-toggle svg {
    transition: transform 0.2s ease;
}

.advanced-toggle.expanded svg {
    transform: rotate(180deg);
}

/* Main Search Input */
.main-search-group {
    position: relative;
    margin-bottom: 1rem;
}

.main-search-input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    font-size: 1rem;
    border: 2px solid var(--border-light);
    border-radius: 12px;
    background: var(--bg-tertiary);
    transition: all 0.3s ease;
}

.main-search-input:focus {
    border-color: var(--accent-primary);
    background: var(--bg-secondary);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.main-search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    transition: color 0.2s ease;
}

.main-search-input:focus ~ .main-search-icon {
    color: var(--accent-primary);
}

/* Quick Filters */
.quick-filters {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.quick-filter {
    padding: 0.5rem 1rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-light);
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.quick-filter:hover {
    background: var(--accent-bg);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
    transform: translateY(-1px);
}

.quick-filter.active {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

.quick-filter svg {
    font-size: 0.75rem;
}

/* Advanced Filters Panel */
.advanced-filters {
    display: none;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-light);
    margin-top: 1rem;
}

.advanced-filters.show {
    display: grid;
}

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

.filter-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.filter-input,
.filter-select {
    padding: 0.75rem;
    border: 1px solid var(--border-light);
    border-radius: 8px;
    background: var(--bg-tertiary);
    font-size: 0.875rem;
    transition: all 0.2s ease;
}

.filter-input:focus,
.filter-select:focus {
    border-color: var(--accent-primary);
    background: var(--bg-secondary);
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.1);
}

/* Range Inputs */
.range-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.range-input {
    flex: 1;
    padding: 0.5rem;
    text-align: center;
}

.range-separator {
    color: var(--text-muted);
    font-weight: 500;
}

/* Dietary Restrictions */
.dietary-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.dietary-filter {
    padding: 0.375rem 0.75rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.dietary-filter:hover {
    background: var(--accent-bg);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.dietary-filter.active {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

.dietary-filter input[type="checkbox"] {
    display: none;
}

/* Ingredient Search */
.ingredient-search-group {
    grid-column: 1 / -1;
}

.ingredient-input-container {
    position: relative;
}

.ingredient-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-top: none;
    border-radius: 0 0 8px 8px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.ingredient-suggestion {
    padding: 0.75rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 1px solid var(--border-light);
}

.ingredient-suggestion:hover {
    background: var(--accent-bg);
}

.ingredient-suggestion:last-child {
    border-bottom: none;
}

.ingredient-suggestion-icon {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Selected Ingredients */
.selected-ingredients {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.75rem;
    min-height: 2rem;
}

.selected-ingredient {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    background: var(--accent-primary);
    color: white;
    border-radius: 16px;
    font-size: 0.875rem;
    font-weight: 500;
}

.remove-ingredient {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    padding: 0;
    margin-left: 0.25rem;
    font-size: 1rem;
    line-height: 1;
    transition: color 0.2s ease;
}

.remove-ingredient:hover {
    color: white;
}

/* Search Actions */
.search-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-light);
}

.search-btn {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-btn-primary {
    background: var(--accent-primary);
    color: white;
    border: 1px solid var(--accent-primary);
}

.search-btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.3);
}

.search-btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

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

/* Active Filters Display */
.active-filters {
    margin-bottom: 1rem;
}

.active-filters-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.active-filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.active-filter-tag {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    background: var(--success);
    color: white;
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 500;
}

.remove-filter {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    padding: 0;
    font-size: 0.875rem;
    line-height: 1;
    transition: color 0.2s ease;
}

.remove-filter:hover {
    color: white;
}

/* Search Results Info */
.search-results-info {
    display: flex;
    justify-content: between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 1rem;
    background: var(--bg-tertiary);
    border-radius: 8px;
    border: 1px solid var(--border-light);
}

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

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

/* Responsive Design */
@media (max-width: 768px) {
    .advanced-search-container {
        padding: 1rem;
    }
    
    .advanced-filters {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .search-actions {
        flex-direction: column;
    }
    
    .search-btn {
        justify-content: center;
    }
    
    .quick-filters {
        gap: 0.5rem;
    }
    
    .quick-filter {
        font-size: 0.8rem;
        padding: 0.375rem 0.75rem;
    }
    
    .range-group {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .range-input {
        text-align: left;
    }
}

@media (max-width: 480px) {
    .main-search-input {
        padding: 0.875rem 0.875rem 0.875rem 2.5rem;
    }
    
    .main-search-icon {
        left: 0.875rem;
    }
    
    .dietary-filters {
        gap: 0.375rem;
    }
    
    .dietary-filter {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
    }
}

/* Dark mode adjustments */
[data-theme="dark"] .ingredient-suggestions {
    background: var(--bg-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .ingredient-suggestion:hover {
    background: var(--bg-secondary);
}

/* From: assets/css/animations.css */
/* Loading States and Animations - Enhanced UI/UX
   OpenServings Recipe Manager v3.1.0 - Animation Enhancement Update */

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 2rem;
    height: 2rem;
    border: 3px solid var(--border-light);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s ease-in-out infinite;
}

.loading-spinner.sm {
    width: 1rem;
    height: 1rem;
    border-width: 2px;
}

.loading-spinner.lg {
    width: 3rem;
    height: 3rem;
    border-width: 4px;
}

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

/* Loading State Container */
.loading-state {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    color: var(--text-secondary);
    flex-direction: column;
    gap: 1rem;
}

.loading-state p {
    margin: 0;
    font-size: 0.9rem;
}

/* Skeleton Loading for Recipe Cards */
.recipe-card.skeleton {
    animation: none;
    pointer-events: none;
}

.recipe-card.skeleton * {
    background: var(--skeleton-bg) !important;
    color: transparent !important;
    border-color: var(--skeleton-bg) !important;
}

.skeleton-pulse {
    background: linear-gradient(90deg, var(--skeleton-bg) 25%, var(--skeleton-highlight) 50%, var(--skeleton-bg) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Skeleton Colors */
:root {
    --skeleton-bg: #f0f0f0;
    --skeleton-highlight: #e0e0e0;
}

[data-theme="dark"] {
    --skeleton-bg: #2a2a2a;
    --skeleton-highlight: #3a3a3a;
}

/* Button Loading States */
.btn.loading {
    position: relative;
    color: transparent !important;
    pointer-events: none;
}

.btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1rem;
    height: 1rem;
    margin: -0.5rem 0 0 -0.5rem;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: button-spin 0.6s linear infinite;
}

.btn.loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--accent-primary);
    border-radius: inherit;
    opacity: 0.1;
}

.btn-secondary.loading::before {
    background: var(--text-secondary);
}

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

/* Page Transitions */
.page-transition {
    animation: fadeInUp 0.5s ease-out;
}

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

/* Micro-interactions for Forms */
.form-control {
    transition: all 0.2s ease;
}

.form-control:focus {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.15);
}

/* Enhanced Button Interactions */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transition: width 0.6s, height 0.6s;
    transform: translate(-50%, -50%);
}

.btn:active::before {
    width: 300px;
    height: 300px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--shadow-hover);
}

.btn:active {
    transform: translateY(0);
    transition: transform 0.1s;
}

/* Card Hover Effects */
.recipe-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.recipe-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent 0%, rgba(0, 123, 255, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    border-radius: inherit;
}

.recipe-card:hover::before {
    opacity: 1;
}

/* Search Input Animation */
.search-input-group {
    position: relative;
}

.search-input {
    transition: all 0.3s ease;
}

.search-input:focus {
    padding-left: 3rem;
}

.search-input:focus + .search-icon,
.search-input:not(:placeholder-shown) + .search-icon {
    transform: translateX(0.5rem) scale(0.9);
    color: var(--accent-primary);
}

.search-icon {
    transition: all 0.3s ease;
}

/* Notification Animations */
.notification {
    animation: slideInRight 0.3s ease-out;
}

.notification.removing {
    animation: slideOutRight 0.3s ease-in forwards;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Modal Animations */
.modal {
    animation: modalFadeIn 0.3s ease-out;
}

.modal.closing {
    animation: modalFadeOut 0.3s ease-in forwards;
}

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

@keyframes modalFadeOut {
    to {
        opacity: 0;
    }
}

.modal-content {
    animation: modalSlideIn 0.3s ease-out;
}

.modal.closing .modal-content {
    animation: modalSlideOut 0.3s ease-in forwards;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px) scale(0.95);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

@keyframes modalSlideOut {
    to {
        transform: translateY(-50px) scale(0.95);
        opacity: 0;
    }
}

/* Progress Indicators */
.progress-bar {
    width: 100%;
    height: 4px;
    background: var(--border-light);
    border-radius: 2px;
    overflow: hidden;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: var(--accent-primary);
    border-radius: 2px;
    transition: width 0.3s ease;
    position: relative;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: progress-shine 2s infinite;
}

@keyframes progress-shine {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Staggered Animations */
.stagger-animation > * {
    animation: fadeInUp 0.6s ease-out backwards;
}

.stagger-animation > *:nth-child(1) { animation-delay: 0.1s; }
.stagger-animation > *:nth-child(2) { animation-delay: 0.2s; }
.stagger-animation > *:nth-child(3) { animation-delay: 0.3s; }
.stagger-animation > *:nth-child(4) { animation-delay: 0.4s; }
.stagger-animation > *:nth-child(5) { animation-delay: 0.5s; }
.stagger-animation > *:nth-child(6) { animation-delay: 0.6s; }

/* Accessibility - Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .recipe-card {
        transform: none !important;
    }
    
    .btn:hover {
        transform: none !important;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Focus styles for accessibility */
.btn:focus,
.form-control:focus,
.recipe-card:focus-within {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

/* Loading overlay for full page */
.page-loading {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    flex-direction: column;
    gap: 1rem;
}

[data-theme="dark"] .page-loading {
    background: rgba(26, 26, 26, 0.9);
}

.page-loading .loading-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 1rem;
}

/* From: assets/css/errors.css */
/* Error Pages Styling */

/* Error Container */
.error-container {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.error-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

/* Error Illustration */
.error-illustration {
    margin-bottom: 2rem;
    opacity: 0.8;
}

.error-illustration svg {
    max-width: 100%;
    height: auto;
}

/* Error Text */
.error-text {
    margin-bottom: 2rem;
}

.error-title {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--text-primary, #212529);
    margin-bottom: 1rem;
    line-height: 1.2;
}

.error-code {
    display: block;
    font-size: 4rem;
    font-weight: 900;
    color: #007bff;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0, 123, 255, 0.1);
}

.error-description {
    font-size: 1.1rem;
    color: var(--text-secondary, #495057);
    line-height: 1.6;
    margin-bottom: 2rem;
}

/* Error Suggestions */
.error-suggestions {
    background: var(--bg-secondary, #f8f9fa);
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    text-align: left;
}

.suggestions-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary, #212529);
    margin-bottom: 1rem;
}

.suggestions-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.suggestions-list li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-secondary, #495057);
}

.suggestions-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: #007bff;
    font-weight: bold;
}

.suggestions-list li:last-child {
    margin-bottom: 0;
}

/* Error Actions */
.error-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.error-action {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: 2px solid transparent;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
}

.error-action-primary {
    background: #007bff;
    color: white;
    border-color: #007bff;
}

.error-action-primary:hover {
    background: #0056b3;
    border-color: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

.error-action-secondary {
    background: var(--bg-primary, #ffffff);
    color: var(--text-primary, #212529);
    border-color: var(--border-color, #dee2e6);
}

.error-action-secondary:hover {
    background: var(--bg-secondary, #f8f9fa);
    border-color: var(--text-muted, #6c757d);
}

.error-action-outline {
    background: transparent;
    color: #007bff;
    border-color: #007bff;
}

.error-action-outline:hover {
    background: #007bff;
    color: white;
}

/* Search Box in Error Page */
.error-search {
    background: var(--bg-primary, #ffffff);
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.error-search-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary, #212529);
    margin-bottom: 1rem;
    text-align: center;
}

.error-search-form {
    display: flex;
    gap: 0.75rem;
    max-width: 400px;
    margin: 0 auto;
}

.error-search-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border-color, #dee2e6);
    border-radius: 8px;
    font-size: 1rem;
    background: var(--bg-primary, #ffffff);
    color: var(--text-primary, #212529);
    transition: border-color 0.2s;
}

.error-search-input:focus {
    outline: none;
    border-color: #007bff;
}

.error-search-button {
    padding: 0.75rem 1.5rem;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.error-search-button:hover {
    background: #0056b3;
}

/* Quick Links */
.error-quick-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.quick-link-card {
    background: var(--bg-primary, #ffffff);
    border: 1px solid var(--border-color, #dee2e6);
    border-radius: 8px;
    padding: 1rem;
    text-decoration: none;
    transition: all 0.2s;
    text-align: center;
}

.quick-link-card:hover {
    border-color: #007bff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.quick-link-icon {
    width: 2.5rem;
    height: 2.5rem;
    margin: 0 auto 0.75rem;
    color: #007bff;
}

.quick-link-title {
    font-weight: 600;
    color: var(--text-primary, #212529);
    margin-bottom: 0.5rem;
}

.quick-link-description {
    font-size: 0.9rem;
    color: var(--text-muted, #6c757d);
    line-height: 1.4;
}

/* Error Help */
.error-help {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 2rem;
}

.error-help-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary, #212529);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.error-help-text {
    color: var(--text-secondary, #495057);
    line-height: 1.5;
    margin-bottom: 1rem;
}

.error-help-contact {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #007bff;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.error-help-contact:hover {
    color: #0056b3;
}

/* Responsive Design */
@media (max-width: 768px) {
    .error-container {
        padding: 1rem 0.5rem;
        min-height: 60vh;
    }
    
    .error-title {
        font-size: 2rem;
    }
    
    .error-code {
        font-size: 3rem;
    }
    
    .error-description {
        font-size: 1rem;
    }
    
    .error-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .error-action {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
    
    .error-search-form {
        flex-direction: column;
    }
    
    .error-quick-links {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .error-container {
        padding: 0.5rem;
    }
    
    .error-content {
        padding: 0;
    }
    
    .error-suggestions,
    .error-search,
    .error-help {
        padding: 1rem;
    }
    
    .suggestions-list li {
        font-size: 0.9rem;
    }
}

/* Animation for Error Illustration */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.error-illustration svg {
    animation: float 3s ease-in-out infinite;
}

/* Dark Theme Support */
[data-theme="dark"] .error-suggestions,
[data-theme="dark"] .error-search,
[data-theme="dark"] .quick-link-card {
    background: var(--bg-secondary, #2d3748);
    border-color: var(--border-color, #4a5568);
}

[data-theme="dark"] .error-help {
    background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
}

/* Print Styles */
@media print {
    .error-container {
        min-height: auto;
    }
    
    .error-illustration,
    .error-actions,
    .error-search {
        display: none !important;
    }
    
    .error-title {
        font-size: 2rem;
    }
    
    .error-code {
        font-size: 2.5rem;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    .error-illustration svg {
        animation: none;
    }
    
    .error-action,
    .quick-link-card {
        transition: none;
    }
}

/* Focus States */
.error-action:focus,
.error-search-input:focus,
.error-search-button:focus,
.quick-link-card:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

/* ========================================
   DARK MODE ERROR PAGES STYLES
   ======================================== */

[data-theme="dark"] .error-container {
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

[data-theme="dark"] .error-title {
    color: var(--text-primary);
}

[data-theme="dark"] .error-code {
    color: var(--accent-primary);
    text-shadow: 2px 2px 4px rgba(77, 171, 247, 0.3);
}

[data-theme="dark"] .error-subtitle {
    color: var(--text-secondary);
}

[data-theme="dark"] .error-description {
    color: var(--text-secondary);
}

[data-theme="dark"] .error-action {
    background-color: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

[data-theme="dark"] .error-action:hover {
    background-color: var(--accent-hover);
    border-color: var(--accent-hover);
}

[data-theme="dark"] .error-action.secondary {
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .error-action.secondary:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

[data-theme="dark"] .error-search {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .error-search-input {
    background-color: var(--input-bg);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .error-search-input:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px var(--primary-color-alpha);
}

[data-theme="dark"] .error-search-input::placeholder {
    color: var(--text-muted);
}

[data-theme="dark"] .error-search-button {
    background-color: var(--accent-primary);
    color: white;
}

[data-theme="dark"] .error-search-button:hover {
    background-color: var(--accent-hover);
}

[data-theme="dark"] .quick-links {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .quick-links-title {
    color: var(--text-primary);
}

[data-theme="dark"] .quick-link-card {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] .quick-link-card:hover {
    background-color: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

[data-theme="dark"] .quick-link-icon {
    color: var(--accent-primary);
}

[data-theme="dark"] .quick-link-card:hover .quick-link-icon {
    color: white;
}

[data-theme="dark"] .quick-link-title {
    color: var(--text-primary);
}

[data-theme="dark"] .quick-link-card:hover .quick-link-title {
    color: white;
}

[data-theme="dark"] .quick-link-description {
    color: var(--text-secondary);
}

[data-theme="dark"] .quick-link-card:hover .quick-link-description {
    color: rgba(255, 255, 255, 0.8);
}

[data-theme="dark"] .error-info {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .error-info-title {
    color: var(--text-primary);
}

[data-theme="dark"] .error-info-text {
    color: var(--text-secondary);
}

[data-theme="dark"] .error-action:focus,
[data-theme="dark"] .error-search-input:focus,
[data-theme="dark"] .error-search-button:focus,
[data-theme="dark"] .quick-link-card:focus {
    outline-color: var(--accent-primary);
}

/* Dark mode for planned-meal items (meal planner cards) */
html[data-theme="dark"] body .planned-meal,
html[data-theme="dark"] .planned-meal {
    background-color: #2d2d2d !important;
    background: #2d2d2d !important;
    color: #ffffff !important;
    border-color: #444444 !important;
}

html[data-theme="dark"] body .planned-meal:hover,
html[data-theme="dark"] .planned-meal:hover {
    background-color: #3a3a3a !important;
    background: #3a3a3a !important;
    border-color: #4dabf7 !important;
}


