:root {
    --primary-color: #ff6b6b;
    --secondary-color: #4ecdc4;
    --accent-color: #45b7d1;
    --success-color: #96ceb4;
    --warning-color: #ffeaa7;
    --danger-color: #fd79a8;
    --dark-color: #2d3436;
    --light-color: #f8f9fa;
    --gradient-primary: linear-gradient(135deg, #ff6b6b, #fd79a8);
    --gradient-secondary: linear-gradient(135deg, #4ecdc4, #45b7d1);
    --gradient-success: linear-gradient(135deg, #96ceb4, #81ecec);
    --shadow-light: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 4px 20px rgba(0, 0, 0, 0.15);
    --shadow-heavy: 0 8px 30px rgba(0, 0, 0, 0.2);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: var(--dark-color);
}

/* Typography */
.brand-text {
    font-family: 'Dancing Script', cursive;
    font-weight: 600;
    font-size: 1.8rem;
}

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    text-align: center;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: #6c757d;
    margin-bottom: 2rem;
    line-height: 1.6;
    text-align: center;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 2rem;
    text-align: center;
}

/* Navigation */
.navbar {
    backdrop-filter: blur(10px);
    background: rgba(33, 37, 41, 0.95) !important;
    box-shadow: var(--shadow-light);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 600;
}

.nav-link {
    font-weight: 500;
    transition: var(--transition);
}

.nav-link:hover {
    transform: translateY(-2px);
    color: var(--primary-color) !important;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    backdrop-filter: blur(10px);
    color: white;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

/* User Stats */
.user-stats .stat-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: var(--border-radius);
    padding: 1.5rem 1rem;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.user-stats .stat-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.15);
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: white;
}

.stat-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 0.5rem;
}

/* Spin Button */
.spin-button {
    background: var(--gradient-primary);
    border: none;
    padding: 1.2rem 3rem;
    font-size: 1.3rem;
    font-weight: 600;
    border-radius: 50px;
    box-shadow: var(--shadow-medium);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.spin-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.spin-button:hover::before {
    left: 100%;
}

.spin-button:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-heavy);
}

.spin-button:active {
    transform: translateY(-1px);
}

/* Roulette Wheel */
.roulette-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.roulette-wheel {
    position: relative;
    width: 300px;
    height: 300px;
    margin-bottom: 2rem;
    transition: transform 3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.wheel-image {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    box-shadow: var(--shadow-heavy);
    filter: drop-shadow(0 0 20px rgba(255, 107, 107, 0.3));
}

.wheel-pointer {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2rem;
    color: var(--primary-color);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    z-index: 10;
}

.wheel-status {
    font-size: 1.2rem;
    font-weight: 600;
    color: white;
    text-align: center;
    opacity: 0.9;
    transition: var(--transition);
}

.wheel-status.spinning {
    animation: pulse 1.5s infinite;
}

/* Recipe Cards */
.recipe-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    border: none;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.recipe-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-heavy);
}

.recipe-header {
    margin-bottom: 1rem;
}

.recipe-name {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.recipe-cuisine {
    background: var(--gradient-secondary);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.recipe-description {
    color: #6c757d;
    line-height: 1.6;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.recipe-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 1rem;
}

.recipe-actions {
    margin-top: auto;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Recipe Detail Page */
.recipe-detail-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: var(--shadow-light);
    margin-bottom: 2rem;
}

/* Recipe image styling */
.recipe-image-container {
    max-height: 400px;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    margin-bottom: 2rem;
}

.recipe-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 12px;
    transition: transform 0.3s ease;
}

.recipe-image:hover {
    transform: scale(1.02);
}

.recipe-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 1rem;
}

.recipe-badges {
    margin-bottom: 1.5rem;
}

.recipe-badges .badge {
    margin-right: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.recipe-quick-info {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: var(--border-radius);
}

.info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-label {
    font-weight: 600;
    color: var(--dark-color);
}

.info-value {
    font-weight: 500;
    color: #6c757d;
}

.recipe-section {
    margin-bottom: 2.5rem;
}

.recipe-section .section-title {
    font-size: 1.5rem;
    text-align: left;
    margin-bottom: 1.5rem;
    color: var(--dark-color);
}

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

.ingredient-item {
    padding: 0.8rem 0;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    font-size: 1.1rem;
}

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

.instructions-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--dark-color);
}

/* Sidebar */
.recipe-sidebar {
    position: sticky;
    top: 2rem;
}

.sidebar-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-light);
    margin-bottom: 2rem;
}

.sidebar-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 1rem;
}

.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #eee;
}

.info-row:last-child {
    border-bottom: none;
}

.progress-item {
    display: flex;
    align-items: center;
    padding: 0.5rem 0;
    font-size: 1.1rem;
}

.tips-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tips-list li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.tips-list li::before {
    content: '💡';
    position: absolute;
    left: 0;
}

/* Badge Styles */
.badge-difficulty-easy {
    background: var(--success-color) !important;
    color: white;
}

.badge-difficulty-medium {
    background: var(--warning-color) !important;
    color: var(--dark-color);
}

.badge-difficulty-hard {
    background: var(--danger-color) !important;
    color: white;
}

/* Profile Page */
.profile-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: var(--shadow-light);
    text-align: center;
    margin-bottom: 2rem;
}

.profile-avatar {
    font-size: 5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.profile-name {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.profile-email {
    color: #6c757d;
    margin-bottom: 2rem;
}

.profile-stats .stats-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--dark-color);
}

.stat-item {
    display: flex;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid #eee;
}

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

.stat-icon {
    font-size: 1.5rem;
    margin-right: 1rem;
    width: 2rem;
    text-align: center;
}

.stat-content {
    flex-grow: 1;
    text-align: left;
}

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

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

/* Achievements */
.achievements-section {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: var(--shadow-light);
}

.subsection-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--dark-color);
}

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

.achievement-card {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    border: 2px solid transparent;
}

.achievement-card.earned {
    background: linear-gradient(135deg, #fff3cd, #fff8e1);
    border-color: #ffc107;
}

.achievement-card.locked {
    background: #f8f9fa;
    border-color: #dee2e6;
    opacity: 0.7;
}

.achievement-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.achievement-icon {
    font-size: 2.5rem;
    margin-right: 1rem;
    flex-shrink: 0;
}

.achievement-content {
    flex-grow: 1;
}

.achievement-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.achievement-description {
    color: #6c757d;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.achievement-requirements {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.requirement {
    font-size: 0.85rem;
    color: #6c757d;
}

.achievement-date {
    font-size: 0.85rem;
    color: #28a745;
    font-weight: 500;
}

.achievement-status {
    font-size: 1.5rem;
    margin-left: 1rem;
    flex-shrink: 0;
}

/* Features Section */
.features-section {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
}

.feature-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    height: 100%;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}

.feature-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.feature-card h4 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.feature-card p {
    color: #6c757d;
    line-height: 1.6;
}

/* Empty States */
.empty-state {
    padding: 4rem 2rem;
}

.empty-icon {
    font-size: 4rem;
    color: #dee2e6;
    margin-bottom: 1.5rem;
}

.empty-title {
    font-size: 2rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 1rem;
}

.empty-description {
    font-size: 1.1rem;
    color: #6c757d;
    margin-bottom: 2rem;
    line-height: 1.6;
}

/* Animations */
@keyframes pulse {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

@keyframes confetti-fall {
    0% {
        transform: translateY(-100vh) rotateZ(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotateZ(720deg);
        opacity: 0;
    }
}

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

/* Recipe Reveal Animation */
.recipe-reveal {
    text-align: center;
    margin-bottom: 2rem;
}

.reveal-animation {
    font-size: 3rem;
    animation: pulse 2s infinite;
    margin-bottom: 1rem;
}

/* Celebration Elements */
.celebration-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    overflow: hidden;
}

.confetti-piece {
    position: absolute;
    width: 10px;
    height: 10px;
    background: var(--primary-color);
}

.achievement-alert {
    border-left: 4px solid #ffc107;
    background: linear-gradient(135deg, #fff3cd, #fff8e1);
    font-weight: 600;
}

/* Form Styles */
.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(255, 107, 107, 0.25);
}

.btn-primary {
    background: var(--gradient-primary);
    border: none;
    transition: var(--transition);
}

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

.btn-outline-primary {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transition: var(--transition);
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .roulette-wheel {
        width: 250px;
        height: 250px;
    }
    
    .recipe-quick-info {
        flex-direction: column;
        gap: 1rem;
    }
    
    .achievements-grid {
        grid-template-columns: 1fr;
    }
    
    .recipe-actions {
        flex-direction: column;
    }
    
    .stat-item {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem 0;
    }
    
    .stat-icon {
        margin-right: 0;
        margin-bottom: 0.5rem;
    }
}

@media (max-width: 576px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .recipe-detail-card,
    .sidebar-card,
    .profile-card,
    .achievements-section {
        padding: 1.5rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .spin-button {
        padding: 1rem 2rem;
        font-size: 1.1rem;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .recipe-actions,
    .profile-actions,
    .achievement-status,
    .btn {
        display: none !important;
    }
    
    .recipe-detail-card,
    .sidebar-card {
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    body {
        background: white;
    }
}
