/* ========================================
   FEATURES SECTION mit VOTING - Mobile First
   ======================================== */

.features-interactive {
    padding: 3rem 0.5rem;
    position: relative;
}

.features-interactive .container {
    position: relative;
    z-index: 1;
    padding: 0 0.5rem;
    max-width: 100%;
    padding-top: 50px;
}


/* ========================================
   VOTE BUTTON (für beide Layouts)
   ======================================== */

.feature-vote-btn {
    position: relative;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(255, 107, 53, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
    z-index: 10;
}

.feature-vote-btn i {
    width: 22px;
    height: 22px;
    color: var(--primary);
    transition: all 0.3s ease;
}

.feature-vote-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: scale(1.1);
}

.feature-vote-btn:hover i {
    color: white;
}

/* ⭐ VOTED STATE - Ausgefülltes Herz */
.feature-vote-btn.voted {
    background: var(--primary);
    border-color: var(--primary);
}

.feature-vote-btn.voted i {
    color: white !important;
}

/* SVG explizit füllen für ausgefülltes Herz */
.feature-vote-btn.voted svg {
    fill: white !important; /* ⭐ Füllt das Herz aus */
    stroke: white !important;
}

.feature-vote-btn.voted svg path {
    fill: white !important;
    stroke: white !important;
}

/* Animation beim Voten - Herz pulsiert */
@keyframes heartPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.3);
    }
}

.feature-vote-btn.voting {
    animation: heartPulse 0.4s ease;
}

/* WICHTIG: Herz-Icon wird weiß wenn Button aktiv ist */
.desktop-btn.active .feature-vote-btn i {
    color: white;
}

/* Desktop: Voted State im aktiven Button */
.desktop-btn.active .feature-vote-btn.voted svg {
    fill: white !important;
}

/* Vote Count Badge */
.vote-count-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    background: var(--secondary);
    color: white;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s ease;
}

.feature-vote-btn.has-votes .vote-count-badge {
    opacity: 1;
    transform: scale(1);
}

/* Vote Message */
.vote-message {
    margin-top: 0.75rem;
    padding: 0.5rem;
    border-radius: 8px;
    font-size: 0.85rem;
    text-align: center;
    display: none;
    animation: slideIn 0.3s ease;
}

.vote-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.vote-message.info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* ========================================
   MOBILE CAROUSEL (Standard, < 768px)
   ======================================== */

/* Desktop Layout verstecken auf Mobile */
.features-desktop {
    display: none;
}

/* Mobile Carousel anzeigen */
.mobile-carousel {
    display: block;
    position: relative;
    padding: 0;
}

/* Carousel Container */
.carousel-container {
    background: url('../assets/Background/Background.png') center/cover;
    border-radius: 20px;
    padding: 2rem 1rem;
    min-height: 500px;   position: relative;
    overflow: hidden;
    margin: 0;
}

/* Einzelne Slides */
.carousel-slide {
    display: none;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
    text-align: center;
    animation: slideInCarousel 0.4s ease;
}

.carousel-slide.active {
    display: flex;
}

/* Text-Bereich im Slide */
.slide-text {
    width: 100%;
    padding: 0 0.5rem;
}

/* Header mit Icon und Vote Button */
.slide-header {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    position: relative;
}

.slide-icon {
    width: 48px;
    height: 48px;
    color: var(--primary);
}

/* Vote Button Mobile - rechts vom Icon */
.feature-vote-btn.mobile {
    position: absolute;
    right: 1rem;
}

.slide-text h3 {
    font-size: 1.4rem;
    color: #1a1a2e;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.slide-text p {
    font-size: 1rem;
    color: #4a5568;
    line-height: 1.6;
}

/* Bild-Bereich im Slide */
.slide-image {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slide-image img {
    max-width: 95%;
    height: auto;
    width: 80%;
    object-fit: contain;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}

/* Dot Indicators */
.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.dot {
    width: 10px;
    height: 10px;
    background: rgba(0, 0, 0, 0.2);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.dot.active {
    background: var(--primary);
    width: 12px;
    height: 12px;
}

/* Slide Animation */
@keyframes slideInCarousel {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}


/* ========================================
   TABLET & DESKTOP (ab 768px)
   ======================================== */

@media (min-width: 768px) {
    .features-interactive {
        padding: 4rem 2rem;
    }

    /* Mobile Carousel verstecken */
    .mobile-carousel {
        display: none;
    }

    /* Desktop Layout anzeigen */
    .features-desktop {
        display: grid;
        grid-template-columns: 350px 1fr;
        gap: 2rem;
        align-items: flex-start;
    }

    /* Button Sidebar */
    .desktop-buttons {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }

    .desktop-btn {
        display: flex;
        align-items: center;
        gap: 1rem;
        padding: 1.5rem;
        background: white;
        border: 2px solid transparent;
        border-radius: 16px;
        cursor: pointer;
        transition: all 0.3s ease;
        text-align: left;
        position: relative;
        overflow: hidden;
        z-index: 1;
    }

    /* Orange Hintergrund-Animation */
    .desktop-btn::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: var(--gradient-warm);
        transition: left 0.3s ease;
        z-index: 0;
    }

    .desktop-btn.active::before {
        left: 0;
    }

    /* Feature Icon im Button (NICHT das Herz) */
    .desktop-btn > .feature-icon {
        width: 28px;
        height: 28px;
        color: #404040;
        transition: color 0.3s ease;
        z-index: 10;
        position: relative;
        flex-shrink: 0;
    }

    .desktop-btn.active > .feature-icon {
        color: white !important;
        z-index: 10 !important;
    }

    .desktop-btn.active > .feature-icon,
    .desktop-btn.active > .feature-icon svg,
    .desktop-btn.active > .feature-icon path {
        stroke: white !important;
        color: white !important;
    }

    /* Text im Button */
    .desktop-btn-text {
        position: relative;
        z-index: 1;
        flex: 1;
    }

    .desktop-btn-text h3 {
        font-size: 1.3rem;
        color: #404040;
        margin-bottom: 0.4rem;
        font-weight: 700;
        transition: color 0.3s ease;
    }

    .desktop-btn-text p {
        font-size: 0.95rem;
        color: #666;
        transition: color 0.3s ease;
    }

    .desktop-btn.active .desktop-btn-text h3,
    .desktop-btn.active .desktop-btn-text p {
        color: white;
    }

    /* ⭐ Vote Button Desktop - Obere rechte Ecke */
    .desktop-btn > .feature-vote-btn {
        position: absolute;
        top: 12px;
        right: 12px;
        z-index: 20;
        
        width: 40px;
        height: 40px;
        
        border: none;
        background: transparent;
        border-radius: 50%;
       
    }

    /* Herz immer weiß im Desktop-Button */
    .desktop-btn .feature-vote-btn i {
        color: white !important;
        width: 22px;
        height: 22px;
        
    }

    
    .desktop-btn .feature-vote-btn svg {
        fill: white !important;
        stroke:var(--primary)!important;
    }

     .desktop-btn .feature-vote-btn svg path {
        fill: white !important;
    }
    
    .desktop-btn .feature-vote-btn.voted svg path {
        fill: var(--primary) !important;
        stroke:white!important;
    }

    .desktop-btn.active .feature-vote-btn.voted svg path {
        fill: var(--primary) !important;
    }

    /* Hover auf Vote-Button */
    .desktop-btn .feature-vote-btn:hover {
        background: rgba(255, 255, 255, 0.2);
        transform: scale(1.15);
    }

    .desktop-btn:hover:not(.active) {
        border-color: var(--primary-light);
        transform: translateX(5px);
    }

    /* Bild-Display */
    .desktop-display {
        background: url('../assets/Background/Background.png') center/cover;
        border-radius: 24px;
        padding: 2rem;
        min-height: 400px;
        max-height: 500px;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
        overflow: hidden;
    }

    .desktop-image {
        display: none;
        animation: fadeIn 0.4s ease;
    }

    .desktop-image.active {
        display: flex;
        justify-content: center;
        align-items: center;
        padding: 1rem;
        margin: 1rem;
    }

    .desktop-image img {
        max-width: 40%;
        min-width: 200px;
        height: auto;
        border-radius: 16px;
        max-height: 60%;
        object-fit: contain;  
         box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);  
        margin: 1rem;   
    }
}

/* Large Desktop */
@media (min-width: 1200px) {
    .features-interactive {
        padding: 6rem 2rem;
    }

    .desktop-image img {
        max-width: 48%;
        max-height: 450px;
    }
}

/* Fade Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}