/* Recipe Styles v10.0.0 - Full White Label via CSS Variables */

:root {
    /* These are fallbacks only — the real values are injected by recipe-ai-plugin.php from RecipeConfig */
    --brand-primary: #002395;
    --brand-secondary: #ED2939;
    --brand-bg: #F7F8FC;
    --brand-text: #1A1A2E;
    --brand-text-light: #6B7280;
    --brand-success: #002395;
    --brand-warning: #ED2939;
    --brand-purple: #5B21B6;
    --badge-time: #002395;
    --badge-servings: #ED2939;
    --badge-difficulty: #002395;
    --badge-cost: #ED2939;
    --badge-calories: #002395;
    --font-head: 'Playfair Display', serif;
    --font-body: 'Nunito', sans-serif;

    --primary-white: #ffffff;
    --border-light: #e2e8f0;
    --bounce-timing: cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --smooth-timing: cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- SAFETY RESET SCOPED TO CONTAINER --- */
.recipe-container,
.recipe-container * {
    box-sizing: border-box;
}

.recipe-container {
    font-family: var(--font-body);
    font-size: 18px;
    font-weight: 600;
    line-height: 1.6;
    color: var(--brand-text);
    background: var(--primary-white);
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s var(--smooth-timing);
}

.recipe-container.loaded {
    opacity: 1;
    transform: translateY(0);
}

.recipe-container h1,
.recipe-container h2,
.recipe-container h3,
.recipe-container h4,
.recipe-container h5,
.recipe-container h6 {
    font-family: var(--font-head);
    font-weight: 700;
    margin-top: 0;
}

/* --- LOADING --- */
.page-loader {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: var(--primary-white);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.5s ease;
    font-family: var(--font-head);
}

.page-loader.hidden {
    opacity: 0;
    pointer-events: none;
}

.cooking-animation {
    font-size: 4rem;
    animation: cooking 2s infinite ease-in-out;
}

@keyframes cooking {
    0%, 100% { transform: rotate(-10deg) scale(1); }
    50% { transform: rotate(10deg) scale(1.1); }
}

/* --- SCROLL PROGRESS --- */
.scroll-progress {
    position: fixed !important;
    top: 0 !important; left: 0 !important;
    width: 6px !important; height: 100% !important;
    background: rgba(0,0,0,0.15);
    z-index: 10000 !important;
    box-shadow: 2px 0 8px rgba(0,0,0,0.1);
    pointer-events: none;
}

.scroll-progress-bar {
    width: 100%;
    background: linear-gradient(0deg, var(--brand-primary), var(--brand-secondary));
    height: 0%;
    transition: height 0.2s ease-out;
    box-shadow: 0 0 15px rgba(0,0,0,0.2);
    border-radius: 3px 3px 0 0;
    position: absolute;
    bottom: 0;
}

/* --- HEADER --- */
.recipe-header-modern {
    background: white;
    padding: 20px;
    width: 100%;
    margin: 20px auto;
    border-radius: 20px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.breadcrumb-nav {
    margin-bottom: 20px;
    font-size: 14px;
    color: #666;
    text-align: center;
    font-family: var(--font-head);
}

.breadcrumb-link {
    color: var(--brand-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-link:hover {
    color: var(--brand-secondary);
    text-decoration: underline;
}

.breadcrumb-separator {
    margin: 0 8px;
    color: #999;
}

.breadcrumb-current {
    color: var(--brand-text);
    font-weight: 500;
}

/* --- TITLE & RATING --- */
.recipe-title-section {
    margin-bottom: 25px;
}

.recipe-title-modern {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--brand-text);
    margin-bottom: 15px;
    line-height: 1.2;
    text-align: center;
}

.recipe-rating-section {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
    font-family: var(--font-head);
}

.rating-stars {
    display: flex;
    align-items: center;
    gap: 5px;
}

.star { font-size: 1.2rem; color: #ddd; transition: color 0.3s ease; }
.star.filled { color: #f39c12; }

.rating-value {
    font-weight: 600;
    color: var(--brand-text);
    margin-left: 8px;
}

.comments-link {
    color: var(--brand-primary);
    text-decoration: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: color 0.3s ease;
}

.comments-link:hover {
    color: var(--brand-secondary);
    text-decoration: underline;
}

/* --- MAIN IMAGE + GALLERY --- */
.recipe-main-media {
    margin-bottom: 30px;
}

.main-image-container {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 15px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    border: 2px solid rgba(0,0,0,0.05);
}

.recipe-main-image-modern {
    width: 100%;
    height: auto !important;
    object-fit: contain !important;
    object-position: center center;
    transition: transform 0.3s ease;
    display: block;
}

.main-image-container:hover .recipe-main-image-modern {
    transform: scale(1.05);
}

.recipe-gallery {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 5px;
    justify-content: center;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.recipe-gallery::-webkit-scrollbar { height: 4px; }
.recipe-gallery::-webkit-scrollbar-track { background: #f1f1f1; border-radius: 2px; }
.recipe-gallery::-webkit-scrollbar-thumb { background: var(--brand-primary); border-radius: 2px; }

.gallery-thumb {
    flex-shrink: 0;
    width: 80px; height: 80px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    border: 3px solid transparent;
    transition: all 0.3s ease;
}

.gallery-thumb:hover {
    border-color: var(--brand-primary);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.gallery-thumb.active {
    border-color: var(--brand-secondary);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.gallery-thumb img {
    width: 100%; height: 100%;
    object-fit: cover;
}

.gallery-thumb.placeholder {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border: 2px dashed var(--brand-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--brand-primary);
    font-size: 24px;
    font-weight: bold;
}

.gallery-more {
    flex-shrink: 0;
    width: 80px; height: 80px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.gallery-more:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

/* --- INFO BADGES --- */
.recipe-info-badges {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    overflow-x: auto;
    padding-bottom: 5px;
    justify-content: center;
    font-family: var(--font-head);
}

.badge-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--brand-bg);
    padding: 12px 16px;
    border-radius: 10px;
    border-left: 4px solid;
    min-width: 120px;
    transition: all 0.6s var(--bounce-timing);
    flex-shrink: 0;
}

.badge-item:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.time-badge { border-left-color: var(--badge-time); }
.servings-badge { border-left-color: var(--badge-servings); }
.difficulty-badge { border-left-color: var(--badge-difficulty); }
.cost-badge { border-left-color: var(--badge-cost); }
.calories-badge { border-left-color: var(--badge-calories); }

.badge-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.5rem;
    transition: transform 0.3s ease;
}

.badge-item:hover .badge-icon { transform: scale(1.1); }

.time-badge .badge-icon { color: var(--badge-time); }
.servings-badge .badge-icon { color: var(--badge-servings); }
.difficulty-badge .badge-icon { color: var(--badge-difficulty); }
.cost-badge .badge-icon { color: var(--badge-cost); }
.calories-badge .badge-icon { color: var(--badge-calories); }

.badge-content { display: flex; flex-direction: column; }
.badge-value { font-weight: 600; color: var(--brand-text); font-size: 0.95rem; }
.badge-label { font-size: 0.75rem; color: var(--brand-text-light); text-transform: uppercase; letter-spacing: 0.5px; }

/* --- DESCRIPTION --- */
.recipe-description-modern {
    background: var(--brand-bg);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 25px;
    border-left: 4px solid var(--brand-secondary);
    text-align: center;
}

.recipe-description-modern p {
    margin: 0;
    line-height: 1.6;
    color: var(--brand-text);
    font-size: 1rem;
}

/* --- ACTION BUTTONS --- */
.recipe-actions-bar {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.action-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-family: var(--font-head);
}

.primary-action {
    background: var(--brand-primary);
    color: white;
    flex: 1;
    justify-content: center;
    min-width: 200px;
    max-width: 300px;
}

.primary-action:hover {
    filter: brightness(0.85);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.secondary-action {
    background: white;
    color: var(--brand-text);
    border: 2px solid var(--brand-primary);
}

.secondary-action:hover {
    background: var(--brand-primary);
    color: white;
    transform: translateY(-2px);
}

.pinterest-action {
    background: #E60023 !important;
    color: white !important;
    border: 2px solid #E60023 !important;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pinterest-action:hover {
    background: #AD081B !important;
    border-color: #AD081B !important;
    transform: translateY(-2px);
}

.pinterest-action svg { flex-shrink: 0; }

/* --- MAIN GRID --- */
.recipe-main-grid {
    display: block;
    width: 100%;
}

.ingredients-section,
.instructions-section {
    width: 100%;
    margin-bottom: 2rem;
}

/* --- INGREDIENTS --- */
.ingredients-section {
    background: var(--primary-white);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 1px solid var(--border-light);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--brand-text);
    font-family: var(--font-head);
    margin: 0;
}

.section-title svg,
.badge-icon svg {
    vertical-align: middle;
    display: inline;
}

.portions-adjuster {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--brand-bg);
    padding: 0.5rem 1rem;
    border-radius: 15px;
}

.portion-btn {
    width: 36px; height: 36px;
    border: none;
    border-radius: 50%;
    background: var(--brand-primary);
    color: var(--primary-white);
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s var(--bounce-timing);
    display: flex;
    align-items: center;
    justify-content: center;
}

.portion-btn:hover {
    transform: scale(1.1);
    background: var(--brand-secondary);
}

.portion-display {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--brand-text);
}

.portion-display svg {
    color: var(--brand-secondary);
    flex-shrink: 0;
}

.portion-count {
    font-size: 1.2rem;
    font-weight: bold;
    min-width: 30px;
    text-align: center;
    font-family: var(--font-head);
    transition: transform 0.2s ease;
}

.ingredients-subtitle {
    color: var(--brand-primary);
    margin-bottom: 15px;
    font-weight: 600;
}

.ingredients-grid-modern {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.ingredient-card-modern {
    text-align: center;
    cursor: pointer;
    transition: all 0.4s var(--bounce-timing);
    padding: 15px;
    background: var(--primary-white);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: relative;
    overflow: hidden;
    border: 1px solid transparent;
}

.ingredient-card-modern:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    border-color: var(--brand-primary);
}

.ingredient-card-modern img {
    width: 80px; height: 80px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 8px;
    transition: all 0.4s ease;
}

.ingredient-card-modern:hover img {
    transform: scale(1.1) rotate(2deg);
}

.ingredient-name-modern {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.3;
}

.affiliate-badge {
    position: absolute;
    top: 5px; right: 5px;
    background: var(--brand-warning);
    color: white;
    border-radius: 50%;
    width: 20px; height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
    animation: pulse 2s infinite;
}

.buy-hint {
    font-size: 0.7rem;
    color: var(--brand-warning);
    margin-top: 4px;
    font-weight: 600;
}

.ingredient-card-modern.checked {
    opacity: 0.6;
    filter: grayscale(80%);
}

.ingredient-card-modern.checked::after {
    content: '✓';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3rem;
    color: var(--brand-success);
    font-weight: bold;
    text-shadow: 0 0 5px white;
    z-index: 10;
}

.ingredients-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ingredient-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    margin-bottom: 0.5rem;
    background: var(--brand-bg);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s var(--smooth-timing);
    border-left: 4px solid var(--brand-primary);
}

.ingredient-item:hover {
    transform: translateX(5px);
    background: #e0f2fe;
}

.ingredient-item.checked {
    background: #dcfce7;
    border-left-color: var(--brand-success);
    opacity: 0.7;
}

.ingredient-item.checked .ingredient-text {
    text-decoration: line-through;
    color: #6b7280;
}

.ingredient-checkbox {
    width: 22px; height: 22px;
    border: 2px solid var(--brand-primary);
    border-radius: 6px;
    position: relative;
    flex-shrink: 0;
}

.ingredient-item.checked .ingredient-checkbox {
    background: var(--brand-success);
    border-color: var(--brand-success);
}

.ingredient-item.checked .ingredient-checkbox::after {
    content: '✓';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-weight: bold;
    font-size: 14px;
}

/* --- INSTRUCTIONS --- */
.instructions-section {
    background: var(--primary-white);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 1px solid var(--border-light);
}

.instruction-step {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    background: var(--brand-bg);
    border-radius: 15px;
    transition: all 0.3s var(--smooth-timing);
}

.instruction-step:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.step-number {
    width: 40px; height: 40px;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    color: var(--primary-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: bold;
    flex-shrink: 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    font-family: var(--font-head);
}

.step-content { flex: 1; }

.step-content p {
    margin-bottom: 1rem;
    font-weight: 600;
    line-height: 1.7;
    font-size: 1rem;
    color: var(--brand-text);
}

.step-done-btn {
    background: var(--brand-primary);
    color: var(--primary-white);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    font-family: var(--font-head);
    font-size: 0.9rem;
}

.step-done-btn:hover { filter: brightness(0.85); }
.step-done-btn.completed { background: #9ca3af; }

.step-image-container {
    margin: 20px 0;
    text-align: center;
}

.step-image {
    max-width: 100%;
    width: 100%;
    height: auto !important;
    max-height: none !important;
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
    cursor: zoom-in;
    object-fit: contain !important;
    border: 2px solid rgba(0,0,0,0.05);
    display: block;
}

.step-image:hover {
    transform: scale(1.03);
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
    border-color: var(--brand-secondary);
}

.step-image-caption {
    margin-top: 8px;
    font-size: 0.9rem;
    color: var(--brand-text-light);
    font-style: italic;
}

/* --- UTENSILS --- */
.utensils-section { margin: 2rem 0; }

.utensils-grid-modern {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.utensil-card-modern {
    text-align: center;
    cursor: pointer;
    transition: all 0.4s var(--bounce-timing);
    padding: 20px;
    background: linear-gradient(135deg, var(--brand-bg) 0%, #fed7aa 100%);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.utensil-card-modern:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
    border-color: var(--brand-warning);
}

.utensil-card-modern img {
    width: 80px; height: 80px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 12px;
}

.utensil-name-modern {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--brand-text);
}

.utensils-list {
    list-style: none;
    counter-reset: utensil-counter;
    padding: 0;
}

.utensil-item {
    padding: 12px;
    margin-bottom: 8px;
    background: var(--brand-bg);
    border-radius: 8px;
    border-left: 4px solid var(--brand-warning);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 15px;
}

.utensil-item::before {
    content: counter(utensil-counter);
    counter-increment: utensil-counter;
    width: 30px; height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1rem;
    flex-shrink: 0;
}

/* --- SECTION CARDS --- */
.section-card {
    background: var(--primary-white);
    border-radius: 20px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-left: 5px solid;
    position: relative;
    overflow: hidden;
}

.section-card::before {
    content: '';
    position: absolute;
    top: 0; right: 0;
    width: 100px; height: 100px;
    opacity: 0.1;
    border-radius: 50%;
    transform: translate(30px, -30px);
}

.green-theme { border-left-color: var(--brand-primary); background: linear-gradient(135deg, #ffffff 0%, var(--brand-bg) 100%); }
.green-theme::before { background: var(--brand-primary); }
.blue-theme { border-left-color: var(--brand-primary); background: linear-gradient(135deg, #ffffff 0%, var(--brand-bg) 100%); }
.blue-theme::before { background: var(--brand-primary); }
.red-theme { border-left-color: var(--brand-secondary); background: linear-gradient(135deg, #ffffff 0%, #fef2f2 100%); }
.red-theme::before { background: var(--brand-secondary); }
.purple-theme { border-left-color: var(--brand-purple); background: linear-gradient(135deg, #ffffff 0%, #f5f3ff 100%); }
.purple-theme::before { background: var(--brand-purple); }
.orange-theme { border-left-color: var(--brand-secondary); background: linear-gradient(135deg, #ffffff 0%, var(--brand-bg) 100%); }
.orange-theme::before { background: var(--brand-secondary); }
.yellow-theme { border-left-color: var(--brand-primary); background: linear-gradient(135deg, #ffffff 0%, var(--brand-bg) 100%); }
.yellow-theme::before { background: var(--brand-primary); }

/* --- STORING GRID (numbered sections) --- */
.storing-grid {
    counter-reset: item-counter;
    display: grid;
    gap: 15px;
    margin-top: 15px;
}

.storing-item {
    display: flex;
    gap: 15px;
    padding: 18px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    border: 1px solid rgba(0,0,0,0.05);
    align-items: flex-start;
}

.storing-icon {
    width: 32px; height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    flex-shrink: 0;
    background: var(--brand-primary);
}

.storing-icon::before {
    content: counter(item-counter);
    counter-increment: item-counter;
}

.storing-content {
    font-weight: 600;
    color: var(--brand-text);
    line-height: 1.5;
}

/* Section-specific icon colors */
.tips-section .storing-icon { background: var(--brand-primary); }
.troubleshooting-section .storing-icon { background: var(--brand-secondary); }
.variations-section .storing-icon { background: var(--brand-purple); }
.alternatives-section .storing-icon { background: var(--brand-primary); }
.diet-section .storing-icon { background: var(--brand-primary); }
.garnish-section .storing-icon { background: var(--brand-secondary); }
.storage-section .storing-icon { background: var(--brand-primary); }
.leftovers-section .storing-icon { background: var(--brand-secondary); }
.mistakes-section .storing-icon { background: var(--brand-secondary); }

/* --- NUTRITION --- */
.nutrition-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1.5rem;
    margin-top: 15px;
}

.nutrition-item {
    color: var(--primary-white);
    border-radius: 15px;
    padding: 1.5rem;
    text-align: center;
}

.nutrition-value {
    font-size: 1.8rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    font-family: var(--font-head);
}

.nutrition-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* --- FAQ --- */
.faq-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 15px;
}

.faq-item {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    overflow: hidden;
}

.faq-question {
    padding: 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--brand-bg);
    border-left: 4px solid var(--brand-primary);
    transition: background 0.3s;
}

.faq-question:hover { filter: brightness(0.97); }

.faq-question-text {
    font-weight: 600;
    color: var(--brand-text);
    font-size: 1.1rem;
}

.faq-arrow {
    font-size: 1.2rem;
    color: var(--brand-primary);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-arrow { transform: rotate(90deg); }

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: white;
}

.faq-item.active .faq-answer { max-height: 500px; }

.faq-answer p {
    padding: 20px;
    margin: 0;
    color: var(--brand-text);
    line-height: 1.6;
    border-top: 1px solid var(--brand-bg);
}

/* --- REVIEWS --- */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 15px;
}

.review-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border: 1px solid rgba(0,0,0,0.05);
    position: relative;
}

.review-card::before {
    content: '"';
    position: absolute;
    top: -10px; left: 15px;
    font-size: 4rem;
    color: rgba(0,0,0,0.05);
    font-family: serif;
    line-height: 1;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.review-name {
    font-weight: 700;
    color: var(--brand-text);
    font-size: 1.1rem;
    font-family: var(--font-head);
}

.review-rating { font-size: 1.2rem; letter-spacing: 2px; }

.review-date {
    font-size: 0.9rem;
    color: var(--brand-text-light);
    font-style: italic;
    width: 100%;
}

.review-comment {
    color: var(--brand-text);
    line-height: 1.6;
    font-size: 1rem;
    position: relative;
    z-index: 2;
}

/* --- TIMER --- */
.timer-sidebar {
    position: fixed;
    top: 50%; right: 20px;
    transform: translateY(-50%);
    z-index: 990;
}

.timer-card {
    background: var(--primary-white);
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    border: 2px solid var(--brand-primary);
    min-width: 200px;
    text-align: center;
}

.timer-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--brand-text);
    margin-bottom: 1rem;
}

.timer-display {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--brand-secondary);
    margin-bottom: 1rem;
    font-family: var(--font-head), monospace;
}

.custom-timer {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
    margin-bottom: 1rem;
}

.custom-timer input {
    width: 70px;
    padding: 8px;
    border: 2px solid var(--border-light);
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
}

.timer-set-btn {
    padding: 8px 12px;
    background: var(--brand-primary);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
}

.timer-controls {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.timer-btn {
    padding: 8px 12px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.8rem;
    font-family: var(--font-head);
}

.timer-btn.start { background: var(--brand-primary); color: white; }
.timer-btn.pause { background: var(--brand-secondary); color: white; }
.timer-btn.reset { background: var(--brand-text-light); color: white; }

/* --- FLOATING ACTIONS --- */
.floating-actions {
    position: fixed;
    bottom: 2rem; right: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    z-index: 995;
}

.floating-actions .recipe-fab {
    width: 60px; height: 60px;
    border-radius: 50%;
    border: none;
    background: var(--brand-primary);
    color: var(--primary-white);
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
    transition: all 0.3s;
    position: relative;
}

.floating-actions .recipe-fab:hover {
    transform: scale(1.1);
    background: var(--brand-secondary);
}

.pin-fab { background: #E60023 !important; }
.pin-fab:hover { background: #AD081B !important; }

.recipe-fab[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    right: 70px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--brand-text);
    color: var(--primary-white);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.8rem;
    white-space: nowrap;
    z-index: 1000;
    pointer-events: none;
}

/* --- IMAGE MODAL --- */
.image-modal {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 999999;
    cursor: pointer;
}

.image-modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

#modal-image {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.modal-close {
    position: absolute;
    top: 20px; right: 30px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
}

/* --- ANIMATIONS --- */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* --- SCROLL ANIMATIONS --- */
[data-scroll] {
    opacity: 1 !important;
    transform: none !important;
    transition: opacity 0.6s, transform 0.6s;
}

body.js-active [data-scroll] {
    opacity: 0 !important;
    transform: translateY(30px) !important;
}

body.js-active [data-scroll].visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* --- MOBILE --- */
@media (max-width: 1024px) {
    .timer-sidebar {
        position: static;
        transform: none;
        margin: 2rem auto;
        max-width: 400px;
    }
    .timer-card { width: 100%; max-width: 100%; }
}

@media (max-width: 768px) {
    .recipe-container { max-width: 100%; padding: 0 10px; }
    .recipe-header-modern { padding: 15px; margin-top: 20px; }
    .recipe-title-modern { font-size: 2rem; }

    .recipe-info-badges { flex-direction: column; gap: 10px; align-items: stretch; }
    .badge-item { width: 100%; justify-content: center; }

    .recipe-actions-bar { flex-direction: column; }
    .action-btn { width: 100%; justify-content: center; }

    .section-header { flex-direction: column; gap: 1rem; align-items: center; }

    .main-image-container { max-width: 100%; border-radius: 12px; }
    .recipe-main-image-modern { width: 100%; height: auto !important; object-fit: contain !important; }
    .recipe-gallery { justify-content: center; padding-left: 5px; }

    .floating-actions { bottom: 1rem; right: 1rem; }
    .floating-actions .recipe-fab { width: 50px; height: 50px; font-size: 1.2rem; }

    .ingredients-grid-modern { grid-template-columns: repeat(3, 1fr); gap: 10px; }
    .utensils-grid-modern { grid-template-columns: repeat(2, 1fr); }
    .reviews-grid, .nutrition-grid { grid-template-columns: 1fr; }

    .instruction-step { flex-direction: column; gap: 12px; padding: 15px; }
    .step-number { align-self: flex-start; }
    .step-content p { font-size: 0.9rem; }
}

@media (max-width: 480px) {
    .recipe-title-modern { font-size: 1.5rem; }
    .gallery-thumb { width: 60px; height: 60px; }
    .ingredients-grid-modern { grid-template-columns: repeat(2, 1fr); }
    .utensils-grid-modern { grid-template-columns: 1fr; }
    .section-card { margin-bottom: 1rem; padding: 1.5rem; }
}

/* --- SMART PRINT --- */
@media print {
    .floating-actions, .timer-sidebar, .scroll-progress, .page-loader,
    .recipe-actions-bar, .image-overlay-actions, .recipe-gallery,
    .breadcrumb-nav, .recipe-rating-section, .recipe-description-modern,
    .youtube-video-section, .utensils-section, .tips-section,
    .troubleshooting-section, .variations-section, .alternatives-section,
    .serving-section, .nutrition-section, .diet-section, .garnish-section,
    .storage-section, .leftovers-section, .mistakes-section,
    .faq-section, .reviews-section, .image-modal,
    .ingredients-grid-modern, .ingredients-subtitle, .step-done-btn,
    .portions-adjuster, .ingredient-checkbox, .step-image-container,
    #wpadminbar, header:not(.recipe-header-modern), footer,
    .site-header, .site-footer, nav:not(.breadcrumb-nav) {
        display: none !important;
    }

    body, html { background: white !important; margin: 0 !important; padding: 0 !important; }

    .recipe-container {
        opacity: 1 !important; transform: none !important;
        box-shadow: none !important; max-width: 100% !important; padding: 0 !important;
    }

    .recipe-header-modern { box-shadow: none !important; padding: 10px !important; margin: 0 !important; }
    .recipe-title-modern { font-size: 1.8rem !important; text-align: left !important; }

    .main-image-container { max-width: 400px !important; margin: 10px auto !important; box-shadow: none !important; border: 1px solid #ddd !important; }
    .recipe-main-image-modern { max-height: 300px !important; object-fit: contain !important; }

    .recipe-info-badges { justify-content: flex-start !important; gap: 8px !important; }
    .badge-item { padding: 6px 10px !important; min-width: auto !important; font-size: 12px !important; }

    .ingredients-section, .instructions-section {
        box-shadow: none !important; border: none !important; padding: 10px 0 !important;
        display: block !important;
    }

    .ingredient-item { padding: 4px 8px !important; margin-bottom: 2px !important; border-left: 2px solid #333 !important; background: white !important; font-size: 13px !important; }
    .instruction-step { background: white !important; padding: 8px !important; margin-bottom: 8px !important; page-break-inside: avoid; }
    .step-number { width: 28px !important; height: 28px !important; font-size: 0.9rem !important; }
    .step-content p { font-size: 13px !important; }

    .section-card { display: none !important; }
    .recipe-main-grid > section:not(.ingredients-section):not(.instructions-section) { display: none !important; }
    [data-scroll] { opacity: 1 !important; transform: none !important; }
}