*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
img { max-width: 100%; height: auto; }

:root {
    --primary: #2d6a4f;
    --primary-dark: #1b4332;
    --primary-light: #40916c;
    --accent: #f4845f;
    --accent-dark: #e17055;
    --text: #2d3436;
    --text-light: #4a5558;
    --text-muted: #666666;
    --bg: #f8f9fa;
    --bg-white: #ffffff;
    --border: #dfe6e9;
    --success: #00b894;
    --warning: #fdcb6e;
    --danger: #d63031;
    --info: #74b9ff;
    --shadow: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-lg: 0 4px 16px rgba(0,0,0,0.12);
    --radius: 8px;
    --radius-lg: 12px;
    --font: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

.section {
    padding: 40px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 24px;
}

.section-header h1, .section-header h2 {
    font-size: 1.75rem;
    color: var(--primary-dark);
}

.section-highlight {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    color: white;
    text-align: center;
    padding: 60px 20px;
    border-radius: var(--radius-lg);
    margin: 40px 0;
}

.section-highlight h2 {
    font-size: 2rem;
    margin-bottom: 12px;
}

.section-highlight p {
    font-size: 1.1rem;
    margin-bottom: 24px;
    opacity: 0.9;
}

.btn {
    display: inline-block;
    font-family: var(--font);
    font-size: 0.95rem;
    font-weight: 600;
    padding: 12px 24px;
    border: 2px solid transparent;
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
    line-height: 1.4;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: white;
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

.btn-link {
    background: none;
    border: none;
    color: var(--primary);
    padding: 8px 16px;
}

.btn-link:hover {
    text-decoration: underline;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.85rem;
}

.btn-lg {
    padding: 16px 32px;
    font-size: 1.05rem;
}

.btn-block {
    display: block;
    width: 100%;
}


.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.badge-success {
    background: var(--success);
    color: white;
}

.badge-warning {
    background: var(--warning);
    color: #2d3436;
}

.badge-danger {
    background: var(--danger);
    color: white;
}

.badge-secondary {
    background: var(--border);
    color: var(--text-light);
}

.badge-premium {
    background: var(--accent);
    color: white;
}

/* Flash messages */
.flash {
    padding: 16px 24px;
    margin: 0 auto;
    max-width: 1200px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 500;
    animation: slideDown 0.3s ease;
}

.flash-success {
    background: var(--success);
    color: white;
}

.flash-error {
    background: var(--danger);
    color: white;
}

.flash-info {
    background: var(--info);
    color: white;
}

.flash-close {
    background: none;
    border: none;
    color: inherit;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0.8;
}

.flash-close:hover {
    opacity: 1;
}

@keyframes slideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Navbar */
.site-header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}

.navbar-brand a {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--primary-dark);
    letter-spacing: -0.5px;
}

.navbar-menu {
    display: flex;
    align-items: center;
    gap: 24px;
}

.navbar-links {
    display: flex;
    list-style: none;
    gap: 8px;
}

.navbar-links a {
    padding: 8px 16px;
    border-radius: var(--radius);
    font-weight: 500;
    color: var(--text);
}

.navbar-links a:hover,
.navbar-links a.active {
    color: var(--primary);
    background: var(--bg);
}

.navbar-actions {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 8px;
}

.navbar-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.navbar-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    transition: 0.3s;
}

/* Hero */
.hero {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    color: white;
    padding: 80px 20px;
    text-align: center;
    border-radius: var(--radius-lg);
    margin: 40px 0;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 16px;
    line-height: 1.2;
}

.hero p {
    font-size: 1.15rem;
    max-width: 600px;
    margin: 0 auto 32px;
    opacity: 0.9;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-actions .btn-outline {
    border-color: white;
    color: white;
}

.hero-actions .btn-outline:hover {
    background: white;
    color: var(--primary-dark);
}

/* Recipe grid */
.recipe-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.recipe-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.2s, box-shadow 0.2s;
}

.recipe-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

/* Dashboard recipes grid */
.dashboard-section .recipes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
}

.dashboard-section .recipes-grid .recipe-card {
    border-radius: var(--radius);
}

.dashboard-section .recipes-grid .recipe-card-body {
    padding: 10px 12px;
}

.dashboard-section .recipes-grid .recipe-card-body h3 {
    font-size: 0.85rem;
    margin-bottom: 4px;
}

.dashboard-section .recipes-grid .recipe-card:hover {
    transform: translateY(-2px);
}

.recipe-card-link {
    color: inherit;
    display: block;
}

.recipe-card-link:hover {
    color: inherit;
}

.recipe-card-image {
    position: relative;
    height: 200px;
    background: var(--border);
    overflow: hidden;
}

.dashboard-section .recipe-card-image {
    height: 100px;
    max-height: 100px;
    width: 100%;
    max-width: 100%;
}

.recipe-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recipe-card-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    font-size: 3rem;
    background: linear-gradient(135deg, var(--border), var(--bg));
}

.recipe-card-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    background: var(--accent);
    color: white;
}

.recipe-card-body {
    padding: 16px;
}

.recipe-card-title {
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: var(--text);
}

.recipe-card-desc {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 12px;
    line-height: 1.4;
}

.recipe-card-meta {
    display: flex;
    gap: 12px;
    font-size: 0.8rem;
    color: var(--text-light);
}

/* Forms */
.form {
    max-width: 600px;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--text);
}

.form-control {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-family: var(--font);
    font-size: 0.95rem;
    transition: border-color 0.2s;
    background: var(--bg-white);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

.search-form {
    display: flex;
    gap: 8px;
}

.search-form .form-control {
    max-width: 300px;
}

/* Auth pages */
.auth-page {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-container {
    width: 100%;
    max-width: 440px;
    padding: 20px;
}

.auth-logo {
    display: block;
    text-align: center;
    margin-bottom: 32px;
}

.auth-logo h1 {
    color: white;
    font-size: 1.8rem;
}

.auth-form {
    background: var(--bg-white);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.auth-form h2 {
    text-align: center;
    margin-bottom: 24px;
    color: var(--primary-dark);
}

.auth-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
    font-size: 0.9rem;
}

/* Recipe detail */
.ad-in-article {
    min-height: 250px;
    contain: layout;
}
.recipe-detail {
    max-width: 800px;
    margin: 0 auto;
}

.recipe-header {
    margin-bottom: 24px;
}

.recipe-header h1 {
    font-size: 2rem;
    color: var(--primary-dark);
    margin-bottom: 8px;
}

.recipe-meta-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

.recipe-meta {
    display: flex;
    gap: 16px;
    font-size: 0.9rem;
    color: var(--text-light);
    flex-wrap: wrap;
    align-items: center;
}

.servings-adjuster {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.servings-label {
    margin-right: 2px;
}

.servings-btn {
    width: 28px;
    height: 28px;
    border: 1px solid var(--border);
    border-radius: 50%;
    background: var(--bg-card);
    color: var(--primary);
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, border-color 0.2s;
    line-height: 1;
}

.servings-btn:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.servings-value {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary-dark);
    min-width: 24px;
    text-align: center;
}

.recipe-image {
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin: 0 auto 24px;
    max-width: 800px;
    aspect-ratio: 16 / 9;
}

.recipe-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.recipe-description {
    font-size: 1.1rem;
    margin-bottom: 32px;
    color: var(--text);
}

.recipe-content {
    display: grid;
    grid-template-columns: 1fr auto 2fr;
    gap: 32px;
    align-items: start;
}

.recipe-ingredients h2,
.recipe-instructions h2 {
    font-size: 1.3rem;
    margin-bottom: 16px;
    color: var(--primary-dark);
}

.ingredient-list {
    list-style: none;
}

.ingredient-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.95rem;
    transition: opacity 0.2s;
}

.ingredient-item.checked {
    opacity: 0.45;
}

.ingredient-item.checked .ingredient-name {
    text-decoration: line-through;
}

.ingredient-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    flex: 1;
}

.ingredient-checkbox {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary);
    flex-shrink: 0;
}

.ingredient-qty {
    color: var(--text-light);
    font-size: 0.85rem;
    min-width: 60px;
    flex-shrink: 0;
}

.ingredient-name {
    color: var(--text);
}

.btn-add-to-list {
    background: none;
    border: 2px solid var(--primary);
    color: var(--primary);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.2s;
    margin-left: 8px;
}

.btn-add-to-list:hover {
    background: var(--primary);
    color: white;
}

.btn-add-to-list.added {
    background: var(--success);
    border-color: var(--success);
    color: white;
}

.qty-editor {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    margin-left: 8px;
}

.qty-input {
    width: 60px;
    padding: 4px 6px;
    border: 2px solid var(--primary);
    border-radius: 4px;
    font-size: 0.85rem;
    font-family: inherit;
    text-align: center;
    outline: none;
}

.qty-input:focus {
    border-color: var(--primary-dark);
}

.qty-unit {
    font-size: 0.85rem;
    color: var(--text-light);
    min-width: 30px;
}

.qty-confirm {
    background: var(--success);
    color: white;
    border: none;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.qty-confirm:hover {
    background: #00a381;
}

.qty-cancel {
    background: none;
    color: var(--text-light);
    border: none;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
}

.qty-cancel:hover {
    background: #fee;
    color: var(--danger);
}

.step-list {
    padding-left: 0;
    list-style: none;
}

.step-item {
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.95rem;
    line-height: 1.6;
    transition: opacity 0.2s;
}

.step-item.checked {
    opacity: 0.5;
}

.step-item.checked .step-text {
    text-decoration: line-through;
}

.step-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
}

.step-checkbox {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary);
    flex-shrink: 0;
    margin-top: 4px;
}

.step-text {
    color: var(--text);
}

/* Menu cards */
.menus-list {
    display: grid;
    gap: 16px;
}

.menu-card {
    display: block;
    background: var(--bg-white);
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.menu-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.menu-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.menu-card-header h2 {
    font-size: 1.2rem;
    color: var(--primary-dark);
}

.menu-card p {
    color: var(--text-light);
    margin-bottom: 12px;
}

.menu-card-link {
    color: var(--primary);
    font-weight: 600;
}

/* Menu week view */
.menu-week {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 16px;
    margin: 24px 0;
}

.menu-day {
    background: var(--bg-white);
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
}

.day-header {
    font-size: 1.1rem;
    color: var(--primary-dark);
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--primary-light);
}

.day-meal {
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
}

.meal-type {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-light);
    margin-bottom: 4px;
}

.meal-recipe {
    display: block;
    font-weight: 500;
}

.day-empty {
    color: var(--text-light);
    font-style: italic;
    font-size: 0.9rem;
}

.menu-actions {
    margin-top: 24px;
}

/* Shopping list */
.shopping-list-items {
    max-width: 600px;
}

.list-category {
    font-size: 1rem;
    color: var(--primary-dark);
    margin: 20px 0 8px;
    padding-bottom: 4px;
    border-bottom: 2px solid var(--primary-light);
}

.list-item {
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    transition: opacity 0.2s;
}

.list-item.checked {
    opacity: 0.5;
}

.list-item-label {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
}

.list-item-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--primary);
}

.list-item-name {
    font-size: 0.95rem;
}

.list-item.checked .list-item-name {
    text-decoration: line-through;
}

.list-item-qty {
    color: var(--text-light);
    font-size: 0.85rem;
    margin-left: 8px;
}

.shopping-list-tools {
    margin-bottom: 16px;
}

.previous-lists {
    margin-top: 32px;
}

.week-selector {
    display: flex;
    align-items: center;
    gap: 12px;
}

.week-current {
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--primary-dark);
    min-width: 130px;
    text-align: center;
}

.shopping-list-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.progress-bar-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.progress-bar {
    flex: 1;
    max-width: 400px;
    height: 8px;
    background: var(--border);
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 0.85rem;
    color: var(--text-light);
    white-space: nowrap;
}

.add-item-form {
    margin-bottom: 20px;
    padding: 16px;
    background: var(--bg);
    border-radius: var(--radius);
}

.add-item-row {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.add-item-row .form-input {
    padding: 8px 12px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.9rem;
    font-family: inherit;
}

.add-item-row .form-input:focus {
    outline: none;
    border-color: var(--primary);
}

.add-item-row .form-input-sm {
    width: 80px;
}

.list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.list-item-remove {
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    opacity: 0;
    transition: opacity 0.2s, background 0.2s, color 0.2s;
}

.list-item:hover .list-item-remove {
    opacity: 1;
}

.list-item-remove:hover {
    background: #fee;
    color: var(--danger);
}

.previous-lists li {
    padding: 4px 0;
}

.previous-lists a {
    color: var(--text);
}

.previous-lists a.active {
    color: var(--primary);
    font-weight: 600;
}

.previous-lists a:hover {
    color: var(--primary-dark);
}

@media print {
    .navbar, .site-footer, .shopping-list-tools, .add-item-form, .week-selector,
    .previous-lists, .list-item-remove, #btn-add-item, .flash-messages {
        display: none !important;
    }
    .shopping-list-items {
        max-width: 100%;
    }
    .list-item {
        break-inside: avoid;
    }
    .list-item.checked {
        opacity: 0.4;
    }
    .list-item-checkbox {
        display: none;
    }
    .section {
        padding: 0;
        margin: 0;
    }
    .section-header {
        margin-bottom: 16px;
    }
}

/* Profile */
.profile-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow);
}

.profile-info p {
    margin-bottom: 12px;
    font-size: 1rem;
}

/* Plans */
.plans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin: 32px 0;
}

.plan-card {
    background: var(--bg-white);
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    text-align: center;
    transition: border-color 0.2s, transform 0.2s;
}

.plan-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
}

.plan-header h2 {
    font-size: 1.3rem;
    color: var(--primary-dark);
    margin-bottom: 16px;
}

.plan-price {
    margin-bottom: 24px;
}

.plan-price .price {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary);
}

.plan-price .period {
    font-size: 1rem;
    color: var(--text-light);
}

.plan-features ul {
    list-style: none;
    margin-bottom: 24px;
}

.plan-features li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
}

.plans-info {
    margin-top: 32px;
}

.plans-info ul {
    list-style: disc;
    padding-left: 20px;
}

.plans-info li {
    padding: 4px 0;
}

/* Admin */
.admin-page {
    display: flex;
}

.admin-layout {
    display: flex;
    min-height: 100vh;
    width: 100%;
}

.admin-sidebar {
    width: 250px;
    background: var(--primary-dark);
    color: white;
    padding: 24px 0;
    flex-shrink: 0;
}

.admin-sidebar-header {
    padding: 0 24px;
    margin-bottom: 24px;
}

.admin-sidebar-header h2 {
    font-size: 1.3rem;
}

.admin-nav {
    display: flex;
    flex-direction: column;
}

.admin-nav a {
    padding: 12px 24px;
    color: rgba(255,255,255,0.8);
    transition: background 0.2s, color 0.2s;
}

.admin-nav a:hover,
.admin-nav a.active {
    background: rgba(255,255,255,0.1);
    color: white;
}

.admin-content {
    flex: 1;
    padding: 32px;
    background: var(--bg);
}

/* Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow);
    text-align: center;
}

.stat-card h3 {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 8px;
}

.stat-number {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
}

/* Tables */
.table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.table th,
.table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.table th {
    background: var(--bg);
    font-weight: 700;
    color: var(--text-light);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.table tr:hover td {
    background: var(--bg);
}

/* Pagination */

.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 32px;
}

.pagination a {
    padding: 8px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-weight: 500;
    transition: all 0.2s;
}

.pagination a:hover,
.pagination a.active {
    border-color: var(--primary);
    background: var(--primary);
    color: white;
}

/* Content with sidebar */
.content-with-sidebar {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 32px;
}

.sidebar {
    position: sticky;
    top: 80px;
    align-self: start;
}

.sidebar-section {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
}

.sidebar-section h3 {
    font-size: 1rem;
    color: var(--primary-dark);
    margin-bottom: 12px;
}

.sidebar-premium-info .premium-status {
    color: var(--success);
    font-weight: 600;
    margin-bottom: 4px;
}

.sidebar-premium-info .premium-expiry {
    font-size: 0.85rem;
    color: var(--text-light);
}

.sidebar-premium-btn {
    margin-top: 8px;
}

.sidebar-list {
    list-style: none;
}

.sidebar-list li {
    padding: 6px 0;
}

.sidebar-list a {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
}

.sidebar-list .count {
    color: var(--text-light);
    font-size: 0.85rem;
}

/* Error pages */
.error-page {
    text-align: center;
    padding: 100px 20px;
}

.error-page h1 {
    font-size: 6rem;
    color: var(--primary);
    margin-bottom: 16px;
}

.error-page p {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 8px;
}

/* CTA section */
.cta-content {
    max-width: 600px;
    margin: 0 auto;
}

.current-menu {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow);
}

/* Success page */
.success-page {
    text-align: center;
    padding: 60px 20px;
}

.success-page h1 {
    font-size: 2rem;
    color: var(--success);
    margin-bottom: 16px;
}

.success-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-top: 24px;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-light);
}

/* Footer */
.site-footer {
    background: var(--primary-dark);
    color: rgba(255,255,255,0.9);
    padding: 40px 20px 20px;
    margin-top: auto;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    margin-bottom: 32px;
}

.footer-section h3,
.footer-section h4 {
    color: white;
    margin-bottom: 12px;
}

.footer-section p {
    font-size: 0.9rem;
    line-height: 1.6;
    opacity: 0.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 8px;
}

.footer-section a {
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    font-size: 0.85rem;
    opacity: 0.7;
}

/* Alert */
.alert {
    padding: 12px 16px;
    border-radius: var(--radius);
    margin-bottom: 16px;
    font-weight: 500;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
    padding: 8px 12px;
    border-radius: var(--radius);
    margin-top: 8px;
    font-size: 0.875rem;
}

.alert-warning a {
    color: #533f03;
    font-weight: 600;
}

/* Subscription alert banner */
.subscription-alert {
    background: #fff3cd;
    color: #856404;
    border-bottom: 1px solid #ffeeba;
    padding: 8px 0;
    font-size: 0.875rem;
    text-align: center;
}

.subscription-alert a {
    color: #533f03;
    font-weight: 600;
    text-decoration: underline;
}

.subscription-alert .container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.table th, .table td {
    border: 1px solid var(--border);
}

.premium-gate {
    position: relative;
    text-align: center;
    padding: 60px 20px;
    border: 2px dashed #2d6a4f;
    border-radius: 12px;
    background: rgba(45, 106, 79, 0.03);
    margin: 30px 0;
}

.premium-gate-content {
    max-width: 420px;
    margin: 0 auto;
}

.premium-gate-icon {
    margin-bottom: 20px;
}

.premium-gate h2 {
    color: #2d6a4f;
    margin-bottom: 12px;
    font-size: 1.5rem;
}

.premium-gate p {
    color: #666;
    margin-bottom: 24px;
    line-height: 1.6;
}

.premium-gate .btn-lg {
    padding: 14px 36px;
    font-size: 1.1rem;
}

.premium-gate-login {
    margin-top: 16px;
    font-size: 0.9rem;
}

.premium-gate-login a {
    color: #2d6a4f;
    text-decoration: underline;
}

/* Hero enhanced */
.hero {
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="80" r="40" fill="rgba(255,255,255,0.03)"/><circle cx="80" cy="20" r="60" fill="rgba(255,255,255,0.03)"/><circle cx="50" cy="50" r="30" fill="rgba(255,255,255,0.02)"/></svg>');
    background-size: cover;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-highlight {
    color: var(--accent);
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid rgba(255,255,255,0.15);
}

.hero-stat {
    text-align: center;
}

.hero-stat-number {
    display: block;
    font-size: 1.8rem;
    font-weight: 700;
}

.hero-stat-label {
    display: block;
    font-size: 0.85rem;
    opacity: 0.8;
    margin-top: 4px;
}

/* Pricing */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

.pricing-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 32px 28px;
    text-align: center;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s;
}

.pricing-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.pricing-card-popular {
    border: 2px solid var(--primary);
    transform: scale(1.05);
}

.pricing-card-popular:hover {
    transform: scale(1.05) translateY(-4px);
}

.pricing-badge {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: white;
    padding: 6px 20px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
}

.pricing-header {
    margin-bottom: 24px;
}

.pricing-header h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
}

.pricing-price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
}

.price-amount {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
}

.price-period {
    font-size: 0.9rem;
    color: var(--text-light);
}

.pricing-features {
    list-style: none;
    margin: 0 0 28px;
    flex: 1;
    text-align: left;
}

.pricing-features li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.95rem;
}

.pricing-features li::before {
    content: "✓";
    color: var(--success);
    font-weight: 700;
    margin-right: 10px;
}

/* Testimonials */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.testimonial-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 28px;
    transition: transform 0.2s;
}

.testimonial-card:hover {
    transform: translateY(-2px);
}

.testimonial-stars {
    margin-bottom: 16px;
}

.star {
    font-size: 1.2rem;
    color: var(--border);
}

.star-filled {
    color: #f1c40f;
}

.testimonial-text {
    font-style: italic;
    color: var(--text);
    line-height: 1.7;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.testimonial-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.testimonial-author strong {
    display: block;
    font-size: 0.95rem;
}

.testimonial-author span {
    display: block;
    font-size: 0.82rem;
    color: var(--text-light);
}

/* Menu highlights */
.menus-highlight {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.menu-highlight-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 24px;
    color: var(--text);
    transition: transform 0.2s, box-shadow 0.2s;
}

.menu-highlight-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    color: var(--text);
}

.menu-highlight-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.menu-highlight-week {
    font-weight: 600;
    color: var(--primary);
}

.menu-highlight-card p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 12px;
}

.menu-highlight-link {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--accent);
}

/* CTA */
.section-cta {
    text-align: center;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    border-radius: var(--radius-lg);
    padding: 60px 40px;
    margin: 40px 0;
}

.section-cta .cta-content {
    max-width: 600px;
    margin: 0 auto;
}

.section-cta h2 {
    color: white;
    font-size: 2rem;
    margin-bottom: 16px;
}

.section-cta p {
    color: rgba(255,255,255,0.9);
    font-size: 1.1rem;
    margin-bottom: 32px;
}

.section-cta .btn {
    font-size: 1.15rem;
    padding: 16px 40px;
}

.section-cta .btn-primary {
    background: var(--accent);
    border-color: var(--accent);
}

.section-cta .btn-primary:hover {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
}

/* Highlight menu section */
.section-highlight-menu {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 40px;
}

.highlight-content {
    display: flex;
    align-items: center;
    gap: 32px;
}

.highlight-text h3 {
    font-size: 1.3rem;
    color: var(--primary);
    margin-bottom: 12px;
}

.highlight-text p {
    color: var(--text-light);
    margin-bottom: 20px;
}

/* Newsletter */
.section-newsletter {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    text-align: center;
    padding: 48px 32px;
    margin: 40px 0;
}

.newsletter-content {
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-content h2 {
    font-size: 1.6rem;
    margin-bottom: 12px;
}

.newsletter-content p {
    color: var(--text-light);
    margin-bottom: 24px;
}

.newsletter-form {
    display: flex;
    justify-content: center;
}

.newsletter-input-group {
    display: flex;
    width: 100%;
    max-width: 440px;
    gap: 0;
}

.newsletter-input {
    flex: 1;
    padding: 14px 18px;
    border: 2px solid var(--border);
    border-right: none;
    border-radius: var(--radius) 0 0 var(--radius);
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}

.newsletter-input:focus {
    border-color: var(--primary);
}

.newsletter-input-group .btn {
    border-radius: 0 var(--radius) var(--radius) 0;
    padding: 14px 24px;
    font-size: 1rem;
    flex-shrink: 0;
}

/* Admin */
.admin-sidebar-header h2 {
    font-size: 1.1rem;
}

.admin-sidebar-sub {
    font-size: 0.8rem;
    opacity: 0.7;
    display: block;
    margin-top: 2px;
}

.admin-nav hr {
    border: none;
    border-top: 1px solid rgba(255,255,255,0.15);
    margin: 12px 0;
}

.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table td, .table th {
    padding: 10px 12px;
    text-align: left;
}

.actions-cell {
    display: flex;
    gap: 6px;
    align-items: center;
    white-space: nowrap;
}

.btn-sm {
    padding: 6px 14px;
    font-size: 0.85rem;
}

.btn-danger {
    background: var(--danger);
    color: white;
    border: 1px solid var(--danger);
}

.btn-danger:hover {
    background: #c0392b;
    border-color: #c0392b;
    color: white;
}

.btn-success {
    background: var(--success);
    color: white;
    border: 1px solid var(--success);
}

.btn-success:hover {
    background: #00a381;
    border-color: #00a381;
    color: white;
}

.btn-link-danger {
    background: none;
    border: none;
    color: var(--danger);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0 4px;
    line-height: 1;
}

.btn-link-danger:hover {
    color: #c0392b;
}


.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
}

.section-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.admin-page .section-header h1 {
    font-size: 1.4rem;
}

.menu-description {
    color: var(--text);
    font-size: 1rem;
    margin-bottom: 24px;
    line-height: 1.6;
}

.menu-week-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

@media (min-width: 600px) {
    .menu-week-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 900px) {
    .menu-week-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1200px) {
    .menu-week-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.menu-day-card {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: var(--shadow-sm);
}

.menu-day-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-dark);
    border-bottom: 2px solid var(--primary-light);
    padding-bottom: 8px;
    margin-bottom: 12px;
}

.menu-day-meal {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
}

.menu-day-meal:last-child {
    border-bottom: none;
}

.meal-type-badge {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--primary-dark);
    background: var(--bg);
    padding: 1px 8px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    width: fit-content;
}

.menu-recipe-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text);
    text-decoration: none;
    font-size: 0.9rem;
    padding: 2px 0;
}

.menu-recipe-link:hover {
    color: var(--primary);
    text-decoration: underline;
}

.menu-recipe-link small {
    color: var(--text-light);
    font-size: 0.8rem;
    white-space: nowrap;
}

.empty-day {
    font-size: 0.85rem;
    font-style: italic;
    text-align: center;
    padding: 12px 0;
}

.admin-page .section {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 24px;
    margin: 0;
}

.admin-page .section + .section {
    margin-top: 20px;
}

.admin-page .form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.admin-page .form-group {
    margin-bottom: 16px;
}

.admin-page .form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text);
}

.admin-page .form-control {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.2s;
    background: var(--bg-white);
}

.admin-page .form-control:focus {
    outline: none;
    border-color: var(--primary);
}

.section-divider {
    border: none;
    border-top: 2px solid var(--border);
    margin: 2rem 0;
}

.menu-recipes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.menu-day-card {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem;
}

.menu-day-card .day-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-dark);
    border-bottom: 2px solid var(--primary-light);
    padding-bottom: 0.5rem;
    margin-bottom: 0.75rem;
}

.meal-slot {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border);
}

.meal-slot:last-child {
    border-bottom: none;
}

.meal-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.3rem;
}

.assigned-recipe {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    background: #e8f5e9;
    padding: 0.4rem 0.6rem;
    border-radius: 4px;
    font-size: 0.9rem;
}

.assigned-recipe a {
    color: var(--primary-dark);
    text-decoration: none;
}

.assigned-recipe a:hover {
    text-decoration: underline;
}

.assign-form select.form-control-sm {
    font-size: 0.85rem;
    padding: 0.3rem 0.5rem;
}

.text-muted {
    color: var(--text-light);
    font-size: 0.9rem;
}

.text-danger {
    color: var(--danger);
}

.form-narrow {
    max-width: 480px;
}

.alert-danger {
    background: #fce4ec;
    color: #c62828;
    border: 1px solid #f8bbd0;
    padding: 16px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.alert-danger strong {
    font-weight: 700;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.dashboard-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: flex-start;
    gap: 16px;
    transition: transform 0.2s;
}

.dashboard-card:hover {
    transform: translateY(-2px);
}

.dashboard-card-icon {
    width: 48px;
    height: 48px;
    background: var(--bg);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    flex-shrink: 0;
}

.dashboard-card-content h3 {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 4px;
}

.dashboard-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 4px;
}

.dashboard-card-content a {
    font-size: 0.85rem;
    color: var(--accent);
}

.dashboard-card-content a:hover {
    text-decoration: underline;
}

.dashboard-status {
    font-weight: 600;
    font-size: 0.95rem;
}

.dashboard-status.active {
    color: var(--success);
}

.dashboard-status.inactive {
    color: var(--text-light);
}

.dashboard-card-content small {
    display: block;
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 2px;
}

.dashboard-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 32px;
}

.dashboard-section {
    margin-top: 24px;
}

.dashboard-section h2 {
    font-size: 1.2rem;
    color: var(--primary-dark);
    margin-bottom: 16px;
}

.favorites-grid {
    display: grid;
    gap: 12px;
}

.favorite-item {
    display: flex;
    align-items: center;
    background: var(--bg-white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: opacity 0.3s, transform 0.3s;
}

.favorite-link {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
    padding: 12px 16px;
    color: var(--text);
    text-decoration: none;
}

.favorite-link:hover {
    color: var(--text);
}

.favorite-image {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.favorite-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.favorite-info h3 {
    font-size: 1rem;
    margin-bottom: 4px;
}

.favorite-meta {
    display: flex;
    gap: 8px;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-light);
}

.favorite-remove {
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.3rem;
    cursor: pointer;
    padding: 12px 16px;
    transition: color 0.2s, background 0.2s;
}

.favorite-remove:hover {
    color: var(--danger);
    background: #fee;
}

.btn-favorite {
    background: none;
    border: 2px solid var(--border);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-light);
    transition: all 0.2s;
    margin-top: 12px;
}

.btn-favorite:hover,
.btn-favorite.active {
    color: var(--danger);
    border-color: var(--danger);
    background: #fff0f0;
}

.history-section {
    margin-bottom: 32px;
}

.history-section h2 {
    font-size: 1.1rem;
    color: var(--primary-dark);
    margin-bottom: 12px;
}

.history-list {
    list-style: none;
}

.history-list li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
}

.history-list a {
    display: flex;
    justify-content: space-between;
    color: var(--text);
}

.history-list a:hover {
    color: var(--primary);
}

.history-list small {
    color: var(--text-light);
    font-size: 0.85rem;
}

.nav-dropdown {
    position: relative;
}

.nav-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--bg-white);
    border-radius: var(--radius);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
    min-width: 200px;
    z-index: 100;
    list-style: none;
    padding: 8px 0;
}

.nav-dropdown:hover .nav-dropdown-menu {
    display: block;
}

.nav-dropdown-menu li {
    padding: 0;
}

.nav-dropdown-menu a {
    display: block;
    padding: 8px 16px;
    font-size: 0.9rem;
    color: var(--text);
    white-space: nowrap;
}

.nav-dropdown-menu a:hover {
    background: var(--bg);
    color: var(--primary-dark);
}

.nav-divider {
    border-top: 1px solid var(--border);
    margin: 4px 0;
}

.nav-logout-btn {
    width: 100%;
    text-align: left;
    padding: 8px 16px;
    font-size: 0.9rem;
    border: none;
    background: none;
    cursor: pointer;
    color: var(--text);
    font-family: inherit;
}

.nav-logout-btn:hover {
    background: var(--bg);
    color: var(--primary-dark);
}

.my-menus-grid {
    display: grid;
    gap: 16px;
}

.my-menu-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 20px;
    transition: opacity 0.3s;
}

.my-menu-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 4px;
}

.my-menu-header h3 {
    font-size: 1.1rem;
}

.my-menu-header h3 a {
    color: var(--primary-dark);
    text-decoration: none;
}

.my-menu-header h3 a:hover {
    text-decoration: underline;
}

.my-menu-week {
    font-size: 0.85rem;
    color: var(--text-light);
    white-space: nowrap;
}

.my-menu-dates {
    margin-bottom: 8px;
}

.my-menu-dates small {
    color: var(--text-light);
    font-size: 0.85rem;
}

.my-menu-desc {
    color: var(--text);
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.my-menu-actions {
    display: flex;
    gap: 8px;
}

.section-form {
    margin-bottom: 20px;
}

.section-recipes h2 {
    font-size: 1.2rem;
    color: var(--primary-dark);
    margin-bottom: 8px;
}

.section-recipes .text-muted {
    margin-bottom: 16px;
}

.my-menu-recipes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}

.my-menu-day-card {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem;
}

.my-menu-day-card .day-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-dark);
    border-bottom: 2px solid var(--primary-light);
    padding-bottom: 0.5rem;
    margin-bottom: 0.75rem;
}

.my-menu-day-card .meal-slot {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border);
}

.my-menu-day-card .meal-slot:last-child {
    border-bottom: none;
}

.my-menu-day-card .meal-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.3rem;
}

.my-menu-day-card .assigned-recipe {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    background: #e8f5e9;
    padding: 0.4rem 0.6rem;
    border-radius: 4px;
    font-size: 0.9rem;
}

.my-menu-day-card .assigned-recipe a {
    color: var(--primary-dark);
    text-decoration: none;
}

.my-menu-day-card .assigned-recipe a:hover {
    text-decoration: underline;
}

.btn-remove-recipe {
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
}

.btn-remove-recipe:hover {
    color: var(--danger);
}

.my-menu-day-card .recipe-select {
    width: 100%;
    font-size: 0.85rem;
    padding: 0.3rem 0.5rem;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-family: inherit;
    background: var(--bg-white);
}

.my-menu-day-card .recipe-select:focus {
    outline: none;
    border-color: var(--primary);
}

.my-menu-card .empty-state {
    text-align: center;
    padding: 40px 20px;
}

.my-menu-card .empty-state p {
    color: var(--text-light);
    margin-bottom: 16px;
    font-size: 1rem;
}

@media (min-width: 768px) {
    .my-menu-recipes-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .my-menu-recipes-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1400px) {
    .my-menu-recipes-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.form-fieldset {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    margin: 1.5rem 0;
}

.form-fieldset legend {
    font-weight: 600;
    font-size: 1rem;
    color: var(--primary-dark);
    padding: 0 0.5rem;
}

.repeater {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.repeater-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.repeater-item .form-control {
    margin-bottom: 0;
}

.repeater-step-num {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--primary);
    min-width: 24px;
    text-align: center;
}

.repeater-remove {
    flex-shrink: 0;
}

/* ---- Breadcrumb ---- */
.breadcrumb {
    padding: 0.75rem 0;
    font-size: 0.85rem;
    color: var(--text-light);
    max-width: var(--max-width);
    margin: 0 auto;
    width: 100%;
}

.breadcrumb ol {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0;
    padding: 0;
    margin: 0;
}

.breadcrumb li {
    display: inline-flex;
    align-items: center;
}

.breadcrumb a {
    color: var(--primary);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb-sep {
    margin: 0 0.5rem;
    color: var(--text-light);
}

.breadcrumb [aria-current="page"] {
    color: var(--text);
    font-weight: 500;
}

.notif-badge { background: var(--primary); color: #fff; font-size: 0.7rem; padding: 1px 6px; border-radius: 10px; margin-left: 4px; }
.notif-badge-bell { position: absolute; top: -4px; right: -6px; font-size: 0.6rem; padding: 1px 5px; margin: 0; line-height: 1.2; }
.nav-notif-btn { position: relative; padding: 6px 10px; cursor: pointer; vertical-align: middle; display: inline-flex; align-items: center; border: 1px solid var(--border); background: none; border-radius: 8px; color: var(--text); }
.nav-notif-btn:hover { border-color: var(--primary); color: var(--primary); }
.nav-notif-dropdown { position: relative; }
.nav-notif-menu { width: 320px; max-height: 400px; overflow-y: auto; right: 0; left: auto; padding: 0; }
.nav-notif-header { padding: 10px 14px; font-weight: 600; font-size: 0.85rem; border-bottom: 1px solid var(--border); color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.nav-notif-item { padding: 12px 14px; border-bottom: 1px solid var(--border); cursor: default; list-style: none; }
.nav-notif-item:last-child { border-bottom: none; }
.nav-notif-item.notif-new { background: #f0f7ff; border-left: 3px solid var(--primary); }
.nav-notif-item strong { display: block; font-size: 0.85rem; margin-bottom: 2px; }
.nav-notif-item p { font-size: 0.8rem; color: var(--text-muted); margin: 2px 0; word-break: break-word; }
.nav-notif-item a { font-size: 0.78rem; display: inline-block; margin-top: 4px; }
.nav-notif-item small { display: block; font-size: 0.7rem; color: var(--text-muted); margin-top: 4px; }

@media (min-width: 769px) { .pwa-banner { display: none !important; } }
.pwa-banner {
    position: fixed;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%) translateY(120%);
    width: calc(100% - 24px);
    max-width: 520px;
    background: #fff;
    border-radius: 16px;
    border: 1px solid rgba(0,0,0,0.08);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    z-index: 9999;
    box-shadow: 0 8px 32px rgba(0,0,0,0.18);
    transition: transform 0.35s ease;
}
.pwa-banner-show {
    transform: translateX(-50%) translateY(0);
}
.pwa-banner-close {
    position: absolute;
    top: 6px;
    right: 10px;
    background: none;
    border: none;
    font-size: 1.3rem;
    line-height: 1;
    color: #b0b0b0;
    cursor: pointer;
    z-index: 2;
}
.pwa-banner-close:hover {
    color: #666;
}
.pwa-banner-content {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}
.pwa-banner-icon-box {
    position: relative;
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, #2d6a4f, #1b4332);
    display: flex;
    align-items: center;
    justify-content: center;
}
.pwa-banner-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #f1c40f;
    color: #333;
    font-size: 0.58rem;
    font-weight: 700;
    padding: 1px 5px;
    border-radius: 8px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}
.pwa-banner-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.pwa-banner-info strong {
    font-size: 0.95rem;
    color: var(--text);
    line-height: 1.2;
}
.pwa-banner-stars {
    font-size: 0.82rem;
    color: #f1c40f;
    letter-spacing: 1px;
}
.pwa-banner-stars em {
    font-style: normal;
    color: #666;
    margin-left: 4px;
    font-weight: 600;
}
.pwa-banner-info span:last-child {
    font-size: 0.78rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pwa-banner-actions {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-shrink: 0;
}
.pwa-banner-actions .btn-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.8rem;
    white-space: nowrap;
}
.btn-pwa-install {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    font-size: 0.88rem;
    padding: 8px 14px;
}
@media (max-width: 420px) {
    .pwa-banner-actions .btn-link { display: none; }
    .pwa-banner { padding: 12px 14px; }
}
.dashboard-section .section-header { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.dashboard-section .section-header h2 { margin: 0; }
.badge-notif { background: var(--primary); color: #fff; padding: 4px 10px; border-radius: 12px; font-size: 0.8rem; }
.notifications-list { margin-top: 1rem; }
.notification-item { padding: 1rem; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 0.75rem; }
.notification-item.unread { background: #f0f7ff; border-left: 3px solid var(--primary); }
.notification-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.notification-header strong { margin: 0; font-size: 1rem; }
.notification-header small { color: var(--text-muted); }

/* View counter */
.recipe-meta-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}
.recipe-views {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.85rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.recipe-share {
    background: linear-gradient(135deg, #f0f9f4, #e6f2ea);
    border: 1px solid #cde6d6;
    border-radius: 16px;
    padding: 28px 24px;
    text-align: center;
    margin: 32px 0;
}

.recipe-share h3 {
    margin: 0 0 6px;
    color: #1b4332;
    font-size: 1.3rem;
}

.recipe-share p {
    margin: 0 0 18px;
    color: #52796f;
    font-size: 0.95rem;
}

.btn-share {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    color: #fff;
    font-weight: 600;
    font-size: 0.9rem;
    padding: 10px 18px;
    border-radius: 50px;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.2s, opacity 0.2s, box-shadow 0.2s;
    font-family: inherit;
}

.btn-share:hover {
    transform: translateY(-2px);
    color: #fff;
    box-shadow: 0 4px 14px rgba(0,0,0,0.18);
}

.btn-share-facebook { background: #1877f2; }
.btn-share-whatsapp { background: #25d366; }
.btn-share-twitter { background: #111; }
.btn-share-email { background: #6c757d; }
.btn-share-copy { background: #2d6a4f; }

/* Pricing cards (landing page) */

.section-compare {
    padding: 60px 0 80px;
    background: linear-gradient(180deg, transparent 0%, rgba(45, 106, 79, 0.03) 100%);
}

.section-compare .section-header p {
    color: var(--text-light);
    margin-top: 8px;
    font-size: 1.05rem;
}

.section-compare .pricing-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    max-width: 800px;
    margin: 0 auto;
    align-items: start;
}

.section-compare .pricing-card {
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.06);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    border: 2px solid #f0f0f0;
}

.section-compare .pricing-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.12);
}

.section-compare .pricing-free {
    border-color: #e9ecef;
}

.section-compare .pricing-premium {
    border-color: var(--primary);
    box-shadow: 0 4px 24px rgba(45, 106, 79, 0.15);
}

.section-compare .pricing-popular-badge {
    position: absolute;
    top: -1px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 6px 20px;
    border-radius: 0 0 12px 12px;
}

.section-compare .pricing-card-header {
    text-align: center;
    padding: 40px 28px 28px;
}

.section-compare .pricing-plan-icon {
    width: 44px; height: 44px;
    border-radius: 16px;
    background: #f0f4f1;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.section-compare .pricing-plan-icon-premium {
    background: var(--primary);
}

.section-compare .pricing-plan-name {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text);
    margin-bottom: 4px;
}

.section-compare .pricing-plan-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.section-compare .pricing-plan-price {
    font-size: 2.4rem;
    font-weight: 900;
    color: var(--text);
    line-height: 1;
}

.section-compare .pricing-plan-price span {
    font-size: 0.95rem;
    font-weight: 400;
    color: var(--text-muted);
}

.section-compare .pricing-price-premium {
    color: var(--primary) !important;
}

.section-compare .pricing-plan-save {
    font-size: 0.82rem;
    color: var(--primary);
    font-weight: 500;
    margin-top: 8px;
}

.section-compare .pricing-features {
    list-style: none;
    padding: 0 28px;
    margin: 0 0 28px;
}

.section-compare .pricing-feature {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    font-size: 0.92rem;
    color: var(--text);
    border-bottom: 1px solid #f5f5f5;
}

.section-compare .pricing-feature:last-child {
    border-bottom: none;
}

.section-compare .pricing-feature-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: var(--success);
}

.section-compare .pricing-feature-icon-premium {
    color: var(--primary);
}

.section-compare .pricing-feature-limited {
    color: var(--text-light);
}

.section-compare .pricing-feature-limited .pricing-feature-icon {
    color: var(--warning);
}

.section-compare .pricing-feature-disabled {
    color: var(--text-muted);
    opacity: 0.6;
}

.section-compare .pricing-feature-disabled .pricing-feature-icon {
    color: #ccc;
}

.section-compare .pricing-feature-highlight {
    background: rgba(45, 106, 79, 0.04);
    margin: 0 -12px;
    padding: 10px 12px;
    border-radius: 8px;
}

.section-compare .pricing-card-footer {
    padding: 0 28px 32px;
}

/* Limited premium preview overlay */
.recipe-content-limited {
    position: relative;
    overflow: hidden;
    max-height: none;
}
.recipe-content-limited .ingredient-list.limited-access,
.recipe-content-limited .step-list {
    filter: blur(2px);
    user-select: none;
    pointer-events: none;
    opacity: 0.6;
}
.recipe-content-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.85);
    z-index: 10;
    padding: 20px;
}
.content-lock {
    text-align: center;
    max-width: 400px;
}
.content-lock h3 {
    font-size: 1.4rem;
    color: var(--primary-dark);
    margin: 16px 0 8px;
}
.content-lock > p {
    color: var(--text-muted);
    margin-bottom: 20px;
    line-height: 1.5;
}
.content-lock-benefits {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
    text-align: left;
    display: inline-block;
}
.content-lock-benefits li {
    padding: 6px 0;
    font-size: 0.9rem;
    color: var(--text);
}
.content-lock-benefits li::before {
    content: "✓ ";
    color: var(--success);
    font-weight: 700;
}
.ingredient-limited-more {
    list-style: none;
}
.ingredient-limited-more .ingredient-name {

    font-style: italic;

}

/* Landing page sections */

.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    max-width: 900px;
    margin: 0 auto;
}

.step-card {
    text-align: center;
    padding: 32px 24px;
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    position: relative;
    transition: transform 0.2s;
}

.step-card:hover {
    transform: translateY(-4px);
}

.step-number {
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    width: 32px;
    height: 32px;
    background: var(--primary);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.step-icon {
    margin: 0 auto 16px;
}

.step-card h3 {
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: var(--primary-dark);
}

.step-card p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.5;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 960px;
    margin: 0 auto;
}

.feature-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 28px 24px;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    margin-bottom: 16px;
}

.feature-card h3 {
    font-size: 1.05rem;
    margin-bottom: 8px;
    color: var(--primary-dark);
}

.feature-card p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.5;
}

.section-testimonials {
    background: var(--bg-light, #f8f9fa);
    border-radius: var(--radius-lg);
    margin: 40px 0;
}

.hero-pill {
    display: inline-block;
    margin-bottom: 16px;
    font-size: 0.85rem;
    padding: 6px 16px;
    border-radius: 20px;
}

.hero-trust-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 28px;
}

.hero-avatars {
    display: flex;
}

.hero-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.8rem;
    border: 2px solid rgba(255,255,255,0.8);
    margin-left: -8px;
    flex-shrink: 0;
}

.hero-avatar:first-child {
    margin-left: 0;
}

.hero-trust-text {
    font-size: 0.85rem;
    opacity: 0.9;
}

.step-connector {
    display: flex;
    align-items: center;
    justify-content: center;
}

.step-connector svg {
    opacity: 0.4;
}

.generator-wrapper {
    max-width: 600px;
    margin: 0 auto;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.08);
    padding: 2rem;
}

.generator-trust {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 1rem;
    font-size: 0.82rem;
    color: var(--text-muted);
}

@media (max-width: 768px) {
    .steps-grid { grid-template-columns: 1fr; gap: 24px; }
    .features-grid { grid-template-columns: 1fr; gap: 20px; }
    .hero-actions { flex-direction: column; align-items: center; }
    .step-connector { display: none; }
}