/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px; /* Base font size for rem calculations */
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: #2c1810;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
    background: linear-gradient(-45deg, #f4a261, #e76f51, #2a9d8f, #264653);
    background-size: 400% 400%;
    animation: gradientShift 8s ease infinite;
}

/* Background Gradient Animation */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Prayer Flags Background */
.prayer-flags {
    position: fixed;
    top: 0;
    left: -100px;
    width: calc(100% + 200px);
    height: 100vh;
    pointer-events: none;
    z-index: 1;
    opacity: 0.3;
}

.prayer-flags-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    animation: driftRight 12s linear infinite;
}

@keyframes driftRight {
    0% {
        transform: translateX(-100px);
    }
    100% {
        transform: translateX(100px);
    }
}

/* Language Switcher */
.language-switcher {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    gap: 10px;
}

.lang-btn {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid #e76f51;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lang-btn:hover {
    background: #e76f51;
    transform: scale(1.1);
}

.lang-btn.active {
    background: #e76f51;
    box-shadow: 0 4px 15px rgba(231, 111, 81, 0.4);
}

.lang-btn img {
    width: 30px;
    height: 20px;
    object-fit: cover;
    border-radius: 3px;
}

/* Main Container */
.container {
    position: relative;
    z-index: 10;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Logo Section */
.logo-section {
    text-align: center;
    margin: 40px 0;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.logo {
    max-width: 200px;
    height: auto;
    animation: logoPulse 3s ease-in-out infinite;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

@keyframes logoPulse {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
    }
    50% {
        transform: scale(1.05);
        filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.3));
    }
}

/* Hero Section */
.hero-section {
    position: relative;
    margin: 60px 0;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    animation: fadeInUp 1.5s ease-out;
}

@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(50px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    animation: parallaxEffect 12s ease-in-out infinite;
}

@keyframes parallaxEffect {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(44, 24, 16, 0.8), rgba(231, 111, 81, 0.6));
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 40px;
}

.main-header {
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    animation: textShadowPulse 3s ease-in-out infinite;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
}

@keyframes textShadowPulse {
    0%, 100% {
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    }
    50% {
        text-shadow: 4px 4px 8px rgba(0, 0, 0, 0.8), 0 0 20px rgba(231, 111, 81, 0.6);
    }
}

.tagline {
    font-size: 1.3rem;
    font-weight: 400;
    color: #f4f4f4;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
}

/* Contact Section */
.contact-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 40px;
    margin: 40px 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: center;
}

.contact-item {
    font-size: 1.1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.contact-label {
    font-weight: 600;
    color: #e76f51;
}

.contact-item a {
    color: #2a9d8f;
    text-decoration: none;
    transition: color 0.3s ease;
}

.contact-item a:hover {
    color: #e76f51;
    text-decoration: underline;
}

/* Food Showcase */
.food-showcase {
    margin: 60px 0;
}

.section-title {
    font-size: 2.2rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 40px;
    color: #2c1810;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.8);
}

.food-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    padding: 20px 0;
}

.food-item {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.food-item:hover {
    transform: scale(1.1);
    box-shadow: 0 0 25px rgba(231, 111, 81, 0.6);
    border: 2px solid #e76f51;
}

.food-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 15px;
}

.food-name {
    font-size: 1.1rem;
    font-weight: 500;
    color: #2c1810;
}

/* Daily Menu Section */
.daily-menu-section {
    margin: 60px 0;
    text-align: center;
}

.daily-menu {
    display: flex;
    justify-content: center;
    margin-top: 30px;
}

.daily-menu-img {
    max-width: 400px;
    width: 100%;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    animation: shakeAnimation 5s infinite;
}

@keyframes shakeAnimation {
    0%, 90%, 100% {
        transform: translateX(0);
    }
    92%, 96% {
        transform: translateX(-2px);
    }
    94%, 98% {
        transform: translateX(2px);
    }
}

/* Cultural Section */
.cultural-section {
    margin: 60px 0;
    text-align: center;
}

.cultural-image {
    max-width: 600px;
    width: 100%;
    height: auto;
    border-radius: 15px;
    opacity: 0.8;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Footer */
.footer {
    background: rgba(44, 24, 16, 0.9);
    color: #fff;
    text-align: center;
    padding: 40px 20px;
    margin-top: 60px;
    backdrop-filter: blur(10px);
}

.social-media {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.social-link {
    color: #fff;
    font-size: 1.5rem;
    transition: all 0.3s ease;
    padding: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
}

.social-link:hover {
    color: #e76f51;
    transform: rotate(360deg) scale(1.2);
    background: rgba(231, 111, 81, 0.2);
}

.footer-text {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Responsive Design - CONSOLIDATED MOBILE FIXES */
@media (max-width: 768px) {
    /* Improved German text handling */
    .main-header, .tagline {
        font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
    }

    /* Prevent text from being too compressed */
    .main-header {
        font-size: 1.6rem !important;
        max-width: none !important; /* Remove width restriction */
        white-space: normal;
        line-height: 1.4;
        padding: 0 8px;
        margin-bottom: 12px;
        text-align: center;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }

    .tagline {
        font-size: 1.2rem !important;
        max-width: none !important;
        line-height: 1.4;
        padding: 0 8px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }

    .hero-overlay {
        padding: 20px 15px;
        min-height: 320px;
    }

    .hero-image {
        height: 300px;
        object-fit: cover;
    }

    .contact-info {
        text-align: center;
    }

    .contact-item {
        flex-direction: column;
        align-items: center;
        gap: 5px;
        font-size: 1rem;
    }

    .food-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: 15px;
        padding: 10px 0;
    }

    .food-item {
        padding: 15px;
    }

    .food-item img {
        height: auto;
        aspect-ratio: 1/1;
        object-fit: cover;
    }

    .language-switcher {
        top: 10px;
        right: 10px;
    }

    .lang-btn {
        width: 40px;
        height: 40px;
    }

    .lang-btn img {
        width: 24px;
        height: 16px;
    }

    .section-title {
        font-size: 1.8rem;
        padding: 0 10px;
    }

    .daily-menu-img {
        max-width: 100%;
        height: auto;
    }
}

/* MOBILE OPTIMIZATIONS - CONSOLIDATED */
@media (max-width: 480px) {
    /* Force white background for logo */
    .logo-section {
        margin: 20px 0;
        padding: 20px;
        background: rgba(255, 255, 255, 0.98) !important;
        border-radius: 20px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
        backdrop-filter: blur(10px);
        border: 2px solid rgba(255, 255, 255, 0.3);
    }

    /* Improved text readability - INCREASED font sizes */
    .main-header {
        font-size: 1.4rem !important; /* Increased from 1.1rem */
        line-height: 1.4;
        padding: 0 8px;
        margin-bottom: 12px;
        text-align: center;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }

    .tagline {
        font-size: 1.1rem !important; /* Increased from 0.95rem */
        line-height: 1.4;
        padding: 0 8px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }

    /* Optimized mobile layout */
    .hero-overlay {
        padding: 20px 15px;
        min-height: 320px;
    }

    .container {
        padding: 8px; /* Increased from 4px */
    }

    /* Touch-friendly button sizes */
    .lang-btn, .social-link {
        min-width: 48px; /* Increased from 44px for better touch */
        min-height: 48px;
    }

    /* Mobile-specific animation controls */
    .logo {
        animation: logoPulse 4s ease-in-out infinite; /* Slower for mobile */
    }

    /* Disable resource-intensive animations on mobile */
    .prayer-flags-img {
        animation: none; /* Disable for performance */
    }

    .hero-image {
        animation: none; /* Disable parallax on mobile */
    }

    /* Optimize food grid for mobile */
    .food-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px; /* Increased from 8px */
    }

    .food-item {
        padding: 12px; /* Increased from 8px */
    }

    .food-item img {
        width: 100%;
        height: auto;
        aspect-ratio: 1/1;
    }

    .daily-menu-img,
    .cultural-image {
        max-width: 100%;
        height: auto;
    }
}