/* Al-Israa Tekeya - Custom Styles */

/* Prevent horizontal overflow globally */
* {
    box-sizing: border-box;
}

html, body {
    overflow-x: hidden;
    max-width: 100vw;
}

/* Base Styles */
body { 
    font-family: 'Poppins', sans-serif; 
    background: linear-gradient(135deg, #2c1810 0%, #3d2817 50%, #4a321f 100%);
    min-height: 100vh;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

/* Container constraints */
.container {
    max-width: 100%;
    width: 100%;
    margin: 0 auto;
    padding-left: 1rem;
    padding-right: 1rem;
}

/* Brand Colors */
:root {
    --brand-primary: #E67E22;
    --brand-light: #F39C12;
    --brand-dark: #D35400;
    --brand-accent: #F1C40F;
    --warm-gold: #F39C12;
    --warm-amber: #E67E22;
    --earth-brown: #8B4513;
    --soft-cream: #F5F1E8;
}

/* Brand Color Classes */
.text-brand { color: var(--brand-primary); }
.text-brand-light { color: var(--brand-light); }
.text-brand-dark { color: var(--brand-dark); }
.bg-brand { 
    background: var(--brand-primary);
    box-shadow: 0 4px 15px rgba(230, 126, 34, 0.3);
}
.bg-brand-light { 
    background: var(--brand-light);
    box-shadow: 0 4px 15px rgba(243, 156, 18, 0.3);
}
.bg-brand-dark { 
    background: var(--brand-dark);
    box-shadow: 0 4px 15px rgba(211, 84, 0, 0.3);
}
.border-brand { border-color: var(--brand-primary); }

.text-warm-gold { color: var(--warm-gold); }
.text-warm-amber { color: var(--warm-amber); }
.text-earth-brown { color: var(--earth-brown); }
.bg-warm-gold { background-color: var(--warm-gold); }
.bg-warm-amber { background-color: var(--warm-amber); }
.bg-earth-brown { background-color: var(--earth-brown); }

/* Glass Effects */
.glass {
    background: rgba(245, 241, 232, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(243, 156, 18, 0.3);
}

.glass-dark {
    background: rgba(60, 40, 24, 0.4);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(230, 126, 34, 0.25);
}

/* Hero Background */
.hero-bg {
    background: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.6)), url('../images/001_hero_starvation.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

/* Floating Animation */
.floating {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { 
        transform: translateY(0px); 
    }
    50% { 
        transform: translateY(-20px); 
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-bg {
        background-attachment: scroll;
        padding-bottom: 2rem;
    }
    
    /* Better mobile spacing for hero content */
    .hero-content {
        padding: 0 0.5rem;
    }
    
    /* Improved mobile text spacing */
    .hero-text {
        line-height: 1.4;
        margin-bottom: 1.5rem;
    }
    
    /* Mobile-optimized buttons */
    .hero-buttons {
        gap: 1rem;
        max-width: 280px;
        margin: 0 auto;
    }
    
    /* Fixed header spacing for mobile */
    header {
        height: 72px;
        overflow: hidden;
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
    
    /* Better container padding on mobile */
    .container {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
        max-width: calc(100vw - 1.5rem);
    }
    
    /* Ensure hero content is not hidden behind header */
    .hero-mobile-offset {
        padding-top: 5rem;
    }
}

@media (max-width: 640px) {
    /* Extra small mobile adjustments */
    .hero-bg {
        min-height: 100vh;
        padding-top: 7rem;
        padding-bottom: 4rem;
    }
    
    /* Tighter spacing for very small screens */
    .hero-content-mobile {
        padding: 0 0.25rem;
    }
    
    /* Better header responsiveness */
    header {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
    
    /* Smaller container padding */
    .container {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
        max-width: calc(100vw - 1rem);
    }
    
    /* Header title responsiveness */
    header h1 {
        font-size: 1.125rem;
        line-height: 1.2;
    }
    

    
    /* Ensure scroll indicator doesn't overlap buttons */
    .hero-bg .animate-bounce {
        bottom: 1.5rem !important;
    }
    
    /* Extra spacing for hero buttons on mobile */
    .hero-buttons-mobile {
        margin-bottom: 4rem;
        padding-bottom: 1rem;
    }
}

@media (max-width: 480px) {
    /* Very small mobile screens */
    .hero-bg {
        padding-top: 8rem;
        padding-bottom: 5rem;
    }
    
    /* Ultra-tight spacing for tiny screens */
    .container {
        padding-left: 0.25rem;
        padding-right: 0.25rem;
        max-width: calc(100vw - 0.5rem);
    }
    
    /* Header ultra-responsive */
    header {
        padding-left: 0.25rem;
        padding-right: 0.25rem;
    }
    
    header h1 {
        font-size: 1rem;
        line-height: 1.1;
    }
    

    
    /* Calculator adjustments */
    .modern-calc-btn {
        min-width: 60px;
        padding: 0.375rem 0.5rem;
        font-size: 0.75rem;
    }
    
    /* Gallery responsiveness */
    .gallery-container {
        max-width: 100vw;
        padding: 0;
    }
    

    
    /* Move scroll indicator even higher on very small screens */
    .hero-bg .animate-bounce {
        bottom: 2rem !important;
    }
}

@media (max-width: 400px) {
    /* Extra small screens - aggressive space optimization */
    .hero-bg {
        padding-bottom: 3rem;
    }
    
    /* Minimum spacing for ultra-small screens */
    .container {
        padding-left: 0.125rem;
        padding-right: 0.125rem;
        max-width: calc(100vw - 0.25rem);
    }
    
    /* Header minimal spacing */
    header {
        padding-left: 0.125rem;
        padding-right: 0.125rem;
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
    }
    
    /* Extra small header title */
    header h1 {
        font-size: 0.875rem;
        line-height: 1;
    }
    
    /* Hide subtitle on ultra-small screens */
    header p {
        display: none;
    }
    

    
    /* Calculator ultra-compact */
    .modern-calc-btn {
        min-width: 50px;
        padding: 0.25rem 0.375rem;
        font-size: 0.625rem;
    }
    
    /* Gallery ultra-responsive */
    .gallery-slider-track {
        gap: 0.5rem;
    }
    
    .gallery-item {
        width: 200px;
        height: 150px;
    }
    
    /* Optionally hide scroll indicator on very small screens */
    .scroll-indicator-mobile-hide {
        display: none;
    }
}

/* Additional responsive fixes for specific components */
@media (max-width: 640px) {
    /* Zelle donation card responsiveness */
    .glass-dark .text-2xl {
        font-size: 1.5rem !important;
        line-height: 1.3;
    }
    
    /* Impact section grid responsiveness */
    .grid.lg\\:grid-cols-2 {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    /* Ensure proper stacking on small screens */
    .grid > div:first-child {
        order: 1;
    }
    
    .grid > div:last-child {
        order: 2;
        margin-top: 1rem;
    }
}

@media (max-width: 480px) {
    /* Smaller Zelle card on tiny screens */
    .glass-dark .text-2xl {
        font-size: 1.25rem !important;
        line-height: 1.2;
        word-break: break-all;
        overflow-wrap: break-word;
    }
    
    /* Compact glass cards */
    .glass-dark {
        padding: 1rem !important;
        margin: 0.25rem;
    }
    
    /* Impact section text responsiveness */
    .text-3xl.md\\:text-4xl {
        font-size: 1.75rem !important;
        line-height: 1.2;
    }
    
    .text-xl {
        font-size: 1.125rem !important;
        line-height: 1.4;
    }
}

@media (max-width: 400px) {
    /* Ultra-small Zelle card */
    .glass-dark .text-2xl {
        font-size: 1rem !important;
        line-height: 1.1;
    }
    
    /* Minimal glass card padding */
    .glass-dark {
        padding: 0.75rem !important;
        margin: 0.125rem;
    }
    
    /* Ultra-compact headings */
    .text-3xl.md\\:text-4xl {
        font-size: 1.5rem !important;
        line-height: 1.1;
    }
}

/* Hover Effects */
.hover-scale {
    transition: transform 0.3s ease-in-out;
}

.hover-scale:hover {
    transform: scale(1.02);
}

/* Custom Shadows */
.shadow-warm {
    box-shadow: 0 20px 25px -5px rgba(139, 69, 19, 0.1), 0 10px 10px -5px rgba(139, 69, 19, 0.04);
}

/* Gradient Text */
.text-gradient {
    background: linear-gradient(135deg, #D4A574 0%, #E6B85C 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(60, 40, 24, 0.3);
}

::-webkit-scrollbar-thumb {
    background: rgba(212, 165, 116, 0.6);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(212, 165, 116, 0.8);
}

/* Smooth Transitions */
.transition-smooth {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Custom Focus Styles */
.focus-visible {
    outline: 2px solid #D4A574;
    outline-offset: 2px;
}

/* Loading Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Touch-friendly buttons */
.btn-touch {
    min-height: 48px;
    min-width: 48px;
}

/* Hero Section Mobile Optimizations */
.hero-mobile-spacing {
    padding: 1rem 0.5rem;
}

.hero-mobile-text {
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.hero-mobile-container {
    padding: 0 1rem;
}

@media (min-width: 640px) {
    .hero-mobile-container {
        padding: 0 2rem;
    }
}

/* Better mobile image sizing */
.hero-mobile-image {
    height: 200px;
    object-fit: cover;
    border-radius: 1rem;
}

@media (min-width: 640px) {
    .hero-mobile-image {
        height: 240px;
        border-radius: 1.5rem;
    }
}

@media (min-width: 768px) {
    .hero-mobile-image {
        height: 256px;
    }
}

/* Enhanced mobile card spacing */
.hero-mobile-cards {
    gap: 0.75rem;
    padding: 0.75rem;
}

@media (min-width: 640px) {
    .hero-mobile-cards {
        gap: 1rem;
        padding: 1rem;
    }
}

/* Calculator Enhancements */
.calculator-compact {
    max-width: 800px;
    margin: 0 auto;
}

.progress-bar-animated {
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}



/* Enhanced glass effects for calculator */
.glass-calculator {
    background: rgba(245, 241, 232, 0.1);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(230, 126, 34, 0.25);
    box-shadow: 0 8px 32px rgba(230, 126, 34, 0.1);
}

/* Progress bar improvements */
.progress-container {
    position: relative;
    overflow: hidden;
}

.progress-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Enhanced hover effects for brand elements */
.hover\:bg-brand:hover {
    background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-light) 100%);
    box-shadow: 0 8px 25px rgba(230, 126, 34, 0.4);
    transform: translateY(-2px);
}

.bg-brand:hover {
    background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-light) 100%);
}

/* Warm glow effects */
.brand-glow {
    background: var(--brand-primary);
    box-shadow: 
        0 0 20px rgba(230, 126, 34, 0.3),
        0 0 40px rgba(230, 126, 34, 0.2),
        0 0 60px rgba(230, 126, 34, 0.1);
}

/* Email responsiveness */
.email-responsive {
    word-break: break-all;
    overflow-wrap: break-word;
    hyphens: auto;
}

@media (min-width: 640px) {
    .email-responsive {
        word-break: normal;
        overflow-wrap: normal;
    }
}

/* Mobile calculator optimizations */
@media (max-width: 768px) {
    .calculator-compact {
        padding: 1rem 0.5rem;
    }
    
    .suggestion-card {
        padding: 0.75rem;
    }
    
    .progress-bar-animated {
        height: 6px;
    }
    
    /* Ensure donation card fits well on mobile */
    .donation-card {
        min-height: auto;
        padding: 1rem;
    }
}

/* Enhanced CTA Section Styles */
.bg-clip-text {
    -webkit-background-clip: text;
    background-clip: text;
}

.text-transparent {
    color: transparent;
}

/* Enhanced Card Hover Effects */
.glass-dark:hover {
    background: rgba(60, 40, 24, 0.6);
    border-color: rgba(230, 126, 34, 0.4);
    box-shadow: 0 20px 40px rgba(230, 126, 34, 0.15);
}

/* Animated Gradient Dividers */
.gradient-divider {
    background: linear-gradient(90deg, transparent, rgba(230, 126, 34, 0.8), transparent);
    animation: pulse-divider 3s ease-in-out infinite;
}

@keyframes pulse-divider {
    0%, 100% { opacity: 0.5; transform: scaleX(0.8); }
    50% { opacity: 1; transform: scaleX(1.2); }
}

/* Enhanced Button Hover Effects */
.group:hover .group-hover\:rotate-12 {
    transform: rotate(12deg);
}

/* Lightning animation for the main icon */
.lightning-glow {
    animation: lightning-pulse 4s ease-in-out infinite;
}

@keyframes lightning-pulse {
    0%, 100% { 
        box-shadow: 
            0 0 20px rgba(230, 126, 34, 0.3),
            0 0 40px rgba(230, 126, 34, 0.2),
            0 0 60px rgba(230, 126, 34, 0.1);
    }
    50% { 
        box-shadow: 
            0 0 30px rgba(230, 126, 34, 0.6),
            0 0 60px rgba(230, 126, 34, 0.4),
            0 0 90px rgba(230, 126, 34, 0.2);
    }
}

/* Floating light dots animation */
@keyframes float-random {
    0%, 100% { transform: translateY(0px) translateX(0px); }
    25% { transform: translateY(-10px) translateX(5px); }
    50% { transform: translateY(-20px) translateX(-5px); }
    75% { transform: translateY(-10px) translateX(10px); }
}

.floating-light {
    animation: float-random 8s ease-in-out infinite;
}

/* Mobile CTA Optimizations */
@media (max-width: 768px) {
    .cta-section {
        padding: 3rem 1rem;
    }
    
    .cta-title {
        font-size: 2.5rem;
        line-height: 1.2;
    }
    
    .impact-card {
        padding: 1.5rem;
    }
}

/* Donation Modal Styles */
#donationModal {
    animation: fadeIn 0.3s ease-out;
}

#donationModal .relative {
    animation: slideUp 0.3s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { 
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to { 
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Modal backdrop blur enhancement */
.modal-backdrop {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* Enhanced step cards */
.step-card {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.step-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(230, 126, 34, 0.1), transparent);
    transition: left 0.5s ease;
}

.step-card:hover::before {
    left: 100%;
}

.step-card:hover {
    transform: translateY(-2px);
    border-color: rgba(230, 126, 34, 0.4);
}

/* Copy button hover effect */
.copy-button:hover {
    background-color: rgba(230, 126, 34, 0.1);
}

/* Mobile modal optimization */
@media (max-width: 640px) {
    #donationModal .relative {
        margin: 1rem;
        max-height: calc(100vh - 2rem);
    }
    
    .step-card {
        padding: 1rem;
    }
}

/* Modern Calculator Styles */
.modern-calc-btn {
    position: relative;
    padding: 0.75rem 1rem;
    background: rgba(245, 241, 232, 0.1);
    border: 1px solid rgba(230, 126, 34, 0.2);
    border-radius: 1rem;
    color: white;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    overflow: hidden;
    min-width: 100px;
}

.modern-calc-btn:hover {
    background: rgba(230, 126, 34, 0.2);
    border-color: rgba(230, 126, 34, 0.4);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(230, 126, 34, 0.3);
}

.modern-calc-btn:active {
    transform: translateY(0) scale(0.98);
}

.modern-calc-btn .amount {
    display: block;
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--brand-primary);
}

.modern-calc-btn .impact {
    display: block;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Modern Impact Cards */
.modern-impact-card {
    background: rgba(245, 241, 232, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(230, 126, 34, 0.2);
    border-radius: 1.5rem;
    padding: 2rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.modern-impact-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(230, 126, 34, 0.1), transparent);
    transition: left 0.6s ease;
}

.modern-impact-card:hover::before {
    left: 100%;
}

.modern-impact-card:hover {
    transform: translateY(-4px);
    border-color: rgba(230, 126, 34, 0.4);
    box-shadow: 0 12px 40px rgba(230, 126, 34, 0.2);
}

/* Modern Results Animation */
.modern-results {
    animation: slideUpFade 0.6s ease-out;
}

@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Modern Donate Button */
.modern-donate-btn {
    position: relative;
    background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-light) 100%);
    color: white;
    font-weight: 700;
    font-size: 1.125rem;
    padding: 1rem 2.5rem;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(230, 126, 34, 0.3);
}

.modern-donate-btn:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 16px 48px rgba(230, 126, 34, 0.4);
}

.modern-donate-btn:active {
    transform: translateY(-1px) scale(1.02);
}

.modern-donate-btn .btn-content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    z-index: 2;
}

.modern-donate-btn .btn-shine {
    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 ease;
}

.modern-donate-btn:hover .btn-shine {
    left: 100%;
}

/* Modern Preview Cards */
.modern-preview-card {
    background: rgba(245, 241, 232, 0.08);
    border: 1px solid rgba(230, 126, 34, 0.15);
    border-radius: 1.25rem;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.modern-preview-card:hover {
    transform: translateY(-4px);
    border-color: rgba(230, 126, 34, 0.3);
    background: rgba(245, 241, 232, 0.12);
}

.modern-preview-card.highlight {
    border-color: rgba(230, 126, 34, 0.4);
    background: rgba(230, 126, 34, 0.1);
}

.modern-preview-card .icon-wrapper {
    margin-bottom: 1rem;
}

.modern-preview-card .description {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
    font-weight: 500;
}

/* Progress Ring Styles */
.progress-ring {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--warm-amber);
}

.progress-ring.complete {
    color: var(--brand-primary);
}

.progress-ring.family {
    color: var(--brand-primary);
}

.progress-ring .amount {
    position: absolute;
    font-weight: 700;
    font-size: 0.875rem;
    color: white;
}

.progress-svg {
    transform: rotate(-90deg);
    color: inherit;
}

.progress-bar {
    transition: stroke-dashoffset 1s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Enhanced Progress Bars */
.progress-container {
    position: relative;
}

.progress-container .w-full {
    position: relative;
    overflow: hidden;
}

.progress-container .w-full::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: shimmer-progress 2s infinite;
}

@keyframes shimmer-progress {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Calculator Input Enhancements */
#donationAmount {
    color: #1f2937 !important; /* Dark gray text */
}

#donationAmount:focus {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.85) 100%) !important;
    color: #1f2937 !important; /* Ensure dark text on focus */
}

#donationAmount::placeholder {
    color: #9ca3af !important; /* Gray placeholder */
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .modern-calc-btn {
        min-width: 80px;
        padding: 0.5rem 0.75rem;
    }
    
    .modern-calc-btn .amount {
        font-size: 1rem;
    }
    
    .modern-calc-btn .impact {
        font-size: 0.6875rem;
    }
    
    .modern-impact-card {
        padding: 1.25rem;
    }
    
    .modern-donate-btn {
        padding: 0.875rem 2rem;
        font-size: 1rem;
    }
    
    .modern-preview-card {
        padding: 1rem;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    .floating,
    .pulse,
    .lightning-glow,
    .floating-light,
    .gradient-divider,
    #donationModal,
    #donationModal .relative,
    .modern-results,
    .progress-bar,
    .btn-shine,
    .progress-container .w-full::after {
        animation: none !important;
        transition: none !important;
    }
    
    .transition-smooth {
        transition: none;
    }
}



/* Enhanced animations for calculator */
.modern-calc-btn:hover {
    animation: buttonPulse 0.6s ease-in-out;
}

@keyframes buttonPulse {
    0%, 100% { transform: translateY(-2px) scale(1.05); }
    50% { transform: translateY(-3px) scale(1.08); }
}

/* Loop Slider Gallery Styles */
.gallery-container {
    max-width: 100%;
    width: 100%;
    margin: 0 auto;
    overflow: hidden;
    padding: 0 0.5rem;
}

.gallery-slider-wrapper {
    width: 100%;
    overflow: hidden;
    mask: linear-gradient(
        to right,
        transparent 0%,
        black 10%,
        black 90%,
        transparent 100%
    );
    -webkit-mask: linear-gradient(
        to right,
        transparent 0%,
        black 10%,
        black 90%,
        transparent 100%
    );
}

.gallery-slider-track {
    display: flex;
    gap: 2rem;
    animation: slideLoop 20s linear infinite;
    width: max-content;
}

.gallery-slider-track:hover {
    animation-play-state: paused;
}

@keyframes slideLoop {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.gallery-item {
    flex: 0 0 auto;
    width: 320px;
    height: 240px;
    position: relative;
    overflow: hidden;
    border-radius: 1.5rem;
    background: rgba(245, 241, 232, 0.1);
    border: 1px solid rgba(230, 126, 34, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery-item:hover {
    transform: translateY(-8px) scale(1.05);
    border-color: rgba(230, 126, 34, 0.4);
    box-shadow: 0 16px 40px rgba(230, 126, 34, 0.3);
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    border-radius: 1.5rem;
    transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.1);
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .gallery-container {
        padding: 0 0.25rem;
    }
    
    .gallery-slider-track {
        gap: 1.5rem;
        animation-duration: 15s;
    }
    
    .gallery-item {
        width: 280px;
        height: 200px;
        border-radius: 1rem;
    }
    
    .gallery-image {
        border-radius: 1rem;
    }
}

@media (max-width: 640px) {
    .gallery-container {
        padding: 0 0.125rem;
        max-width: calc(100vw - 0.25rem);
    }
    
    .gallery-slider-track {
        gap: 1rem;
        animation-duration: 12s;
    }
    
    .gallery-item {
        width: 240px;
        height: 180px;
    }
    
    .gallery-slider-wrapper {
        mask: linear-gradient(
            to right,
            transparent 0%,
            black 5%,
            black 95%,
            transparent 100%
        );
        -webkit-mask: linear-gradient(
            to right,
            transparent 0%,
            black 5%,
            black 95%,
            transparent 100%
        );
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .glass,
    .glass-dark {
        border-width: 2px;
        background: rgba(0, 0, 0, 0.8);
    }
    
    .gallery-item {
        border-width: 2px;
        border-color: rgba(230, 126, 34, 0.8);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .gallery-slider-track {
        animation: none !important;
    }
    
    .gallery-item,
    .gallery-image {
        transition: none !important;
        animation: none !important;
    }
}

/* Ensure header remains positioned */
header {
    position: relative;
}