:root {
    --primary-color: #ff2cc3;
    --secondary-color: #6dddff;
    --dark-color: #333;
    --light-color: #f8f9fa;
    --success-color: #28a745;
    --error-color: #e63946;
    --warning-color: #ffc107;
}

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

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
    background-color: #f5f5f5;
}

/*header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 2rem 0;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}*/

h1, h2 {
    font-family: 'Playfair Display', serif;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: var(--dark-color);
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
}

main {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.add-recipe, .filter {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

input, select, textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    font-size: 1rem;
}

textarea {
    resize: vertical;
    min-height: 100px;
}

.btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn:hover {
    background: #f000ac;
    transform: translateY(-2px);
}

.filter-controls {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.filter-controls input, .filter-controls select {
    flex: 1;
}

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

.recipe-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.recipe-card:hover {
    transform: translateY(-5px);
}

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

.recipe-content {
    padding: 1.5rem;
}

.recipe-title {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.recipe-category {
    display: inline-block;
    background: var(--secondary-color);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    margin-bottom: 1rem;
}

.recipe-ingredients, .recipe-instructions {
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.recipe-ingredients {
    color: #555;
}

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

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

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

footer {
    text-align: center;
    padding: 1.5rem;
    background: var(--dark-color);
    color: white;
    margin-top: 2rem;
}

@media (max-width: 768px) {
    .filter-controls {
        flex-direction: column;
    }
    
    .recipes-grid {
        grid-template-columns: 1fr;
    }
}

/* Стили для уведомлений */
.alert {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 400px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    z-index: 1000;
    animation: alertSlideIn 0.4s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    transform: translateX(120%);
    opacity: 0;
}

.alert-success {
    background: var(--success-color);
    border-left: 5px solid darken(var(--success-color), 10%);
}

.alert-error {
    background: var(--error-color);
    border-left: 5px solid darken(var(--error-color), 10%);
}

.alert-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    margin-left: 1rem;
    line-height: 1;
    padding: 0 0.5rem;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.alert-close:hover {
    opacity: 1;
}

.alert-message {
    flex: 1;
    padding-right: 1rem;
}

/* Анимации */
@keyframes alertSlideIn {
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.fade-out {
    animation: alertFadeOut 0.4s ease-out forwards;
}

@keyframes alertFadeOut {
    to {
        transform: translateY(-30px);
        opacity: 0;
    }
}

/* Спиннер для кнопки */
.fa-spinner {
    animation: spin 1s linear infinite;
    margin-right: 8px;
}

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

/* Состояние кнопки при загрузке */
.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.8;
}

/* Основные стили для контейнера уведомлений */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    z-index: 1000;
}

/* Обновленные стили для системы уведомлений */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    z-index: 1000;
}

.notification {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 400px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    animation: 
        notificationSlideIn 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards,
        notificationFadeOut 0.5s ease 3s forwards;
    transform: translateX(120%);
    opacity: 0;
    margin-bottom: 0;
}

.notification-success {
    background: var(--success-color);
    border-left: 5px solid #1e7e34;
}

.notification-error {
    background: var(--error-color);
    border-left: 5px solid #b71c1c;
}

.notification-warning {
    background: var(--warning-color);
    border-left: 5px solid #ff8f00;
    color: var(--dark-color);
}

.notification-close {
    background: none;
    border: none;
    color: inherit;
    font-size: 1.5rem;
    cursor: pointer;
    margin-left: 1rem;
    line-height: 1;
    padding: 0 0.5rem;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.notification-close:hover {
    opacity: 1;
}

.notification-message {
    flex: 1;
    padding-right: 1rem;
}

/* Анимации для уведомлений */
@keyframes notificationSlideIn {
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes notificationFadeOut {
    to {
        transform: translateY(-30px) scale(0.95);
        opacity: 0;
    }
}

/* Адаптация для мобильных устройств */
@media (max-width: 768px) {
    .notification-container {
        top: 10px;
        right: 10px;
        left: 10px;
        align-items: center;
    }
    
    .notification {
        width: calc(100% - 20px);
        max-width: 100%;
    }
}

/* Стили для навигационной панели */
.navigation-panel {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-align: center;
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.nav-buttons {
    display: flex;
    justify-content: center;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.nav-btn.active {
    background: white;
    color: var(--primary-color);
    border-color: white;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .nav-buttons {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }
    
    .nav-btn {
        width: 200px;
        justify-content: center;
    }
}