/* Warenkorb Geschenke - Frontend Styles */

.wkg-gifts-container {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    position: relative;
    overflow: hidden;
}

.wkg-gifts-container::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: wkg-shine 3s infinite;
}

@keyframes wkg-shine {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-20px, -20px); }
}

/* LOCKED/INACTIVE GIFT STYLES */
.wkg-gift-locked {
    opacity: 0.6;
    filter: grayscale(80%);
    pointer-events: none;
    cursor: not-allowed !important;
}

.wkg-gift-locked .wkg-gift-image {
    filter: grayscale(100%) brightness(0.8);
}

.wkg-gift-lock-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.wkg-gift-lock-overlay i {
    font-size: 48px;
    color: #ffffff;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.wkg-badge-locked {
    background: #95a5a6 !important;
}

.wkg-price-not-reached {
    color: #e74c3c;
    font-weight: 600;
    font-size: 14px;
}

.wkg-price-reached {
    color: #2ecc71;
    font-weight: 700;
    font-size: 16px;
}

.wkg-header {
    text-align: center;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.wkg-header-title {
    color: #ffffff;
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 10px 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.wkg-header-subtitle {
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    margin: 0;
    line-height: 1.6;
}

.wkg-gifts-grid {
    display: grid;
    gap: 20px;
    margin: 25px 0;
    position: relative;
    z-index: 1;
}

.wkg-gifts-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.wkg-gifts-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.wkg-gifts-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.wkg-gifts-grid.cols-6 { grid-template-columns: repeat(6, 1fr); }

@media (max-width: 992px) {
    .wkg-gifts-grid.cols-4,
    .wkg-gifts-grid.cols-6 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .wkg-gifts-grid.cols-3,
    .wkg-gifts-grid.cols-4,
    .wkg-gifts-grid.cols-6 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
    .wkg-gifts-grid { grid-template-columns: 1fr; }
}

/* HAUPTKLASSE: .wkg-custom-gift-box (wird im TPL verwendet) */
.wkg-custom-gift-box {
    background: #ffffff;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    min-height: 350px;
    display: flex;
    flex-direction: column;
}

.wkg-custom-gift-box:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

/* Pseudo-Elemente blockieren (Theme-Interferenz verhindern) */
.wkg-custom-gift-box::before,
.wkg-custom-gift-box::after {
    content: '' !important;
    display: none !important;
}

.wkg-custom-gift-box:hover::before,
.wkg-custom-gift-box:hover::after {
    display: none !important;
}

.wkg-gift-image-wrapper {
    width: 100%;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    background: #f8f9fa;
    position: relative;
    flex-shrink: 0;
}

.wkg-gift-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.wkg-custom-gift-box:hover .wkg-gift-image {
    transform: scale(1.1);
}

.wkg-gift-name {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 10px 0 5px 0;
    line-height: 1.4;
    min-height: 40px;
    flex-shrink: 0;
}

.wkg-gift-price {
    color: #667eea;
    font-size: 14px;
    font-weight: 700;
    margin: 5px 0;
    flex-shrink: 0;
}

.wkg-gift-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: inline-block;
    margin-top: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.wkg-footer {
    text-align: center;
    margin-top: 20px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    position: relative;
    z-index: 1;
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}

.wkg-footer p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: #ffffff;
}

/* NEU: Limit-Warnung */
.wkg-limit-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border: 2px solid #ffc107;
    border-radius: 8px;
    padding: 15px 20px;
    margin: 0 0 20px 0;
    text-align: center;
    box-shadow: 0 2px 8px rgba(255, 193, 7, 0.3);
}

/* NEU: Gift Buttons */
.wkg-add-gift-btn {
    background: #4CAF50;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s;
    width: 100%;
    margin-top: auto;
}

.wkg-add-gift-btn:hover:not(:disabled) {
    background: #45a049;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.wkg-add-gift-btn:disabled {
    background: #cccccc;
    cursor: not-allowed;
    opacity: 0.6;
}

.wkg-gift-btn-added {
    background: #2ecc71;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 700;
    width: 100%;
    margin-top: auto;
    cursor: default;
}

.wkg-gift-btn-limit {
    background: #f39c12;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    width: 100%;
    margin-top: auto;
    cursor: not-allowed;
}

/* Animationseffekte */

/* Fade Effect */
.wkg-effect-fade .wkg-custom-gift-box {
    opacity: 0;
    animation: wkg-fade-in 0.6s ease forwards;
}

@keyframes wkg-fade-in {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Slide Effect */
.wkg-effect-slide .wkg-custom-gift-box {
    opacity: 0;
    transform: translateX(-50px);
    animation: wkg-slide-in 0.6s ease forwards;
}

@keyframes wkg-slide-in {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Bounce Effect */
.wkg-effect-bounce .wkg-custom-gift-box {
    opacity: 0;
    animation: wkg-bounce-in 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

@keyframes wkg-bounce-in {
    0% {
        opacity: 0;
        transform: scale(0.3) translateY(-50px);
    }
    50% {
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Zoom Effect */
.wkg-effect-zoom .wkg-custom-gift-box {
    opacity: 0;
    transform: scale(0);
    animation: wkg-zoom-in 0.5s ease forwards;
}

@keyframes wkg-zoom-in {
    from {
        opacity: 0;
        transform: scale(0);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Animation Delays für gestaffelte Effekte */
.wkg-custom-gift-box:nth-child(1) { animation-delay: 0.1s; }
.wkg-custom-gift-box:nth-child(2) { animation-delay: 0.2s; }
.wkg-custom-gift-box:nth-child(3) { animation-delay: 0.3s; }
.wkg-custom-gift-box:nth-child(4) { animation-delay: 0.4s; }
.wkg-custom-gift-box:nth-child(5) { animation-delay: 0.5s; }
.wkg-custom-gift-box:nth-child(6) { animation-delay: 0.6s; }

/* Responsive Anpassungen */
@media (max-width: 768px) {
    .wkg-gifts-container {
        padding: 20px;
        margin: 20px 0;
    }
    
    .wkg-header-title {
        font-size: 22px;
    }
    
    .wkg-header-subtitle {
        font-size: 14px;
    }
    
    .wkg-gift-image-wrapper {
        height: 150px;
    }
}

@media (max-width: 480px) {
    .wkg-gifts-container {
        padding: 15px;
    }
    
    .wkg-header-title {
        font-size: 20px;
    }
    
    .wkg-custom-gift-box {
        padding: 15px;
    }
    
    .wkg-gift-image-wrapper {
        height: 120px;
    }
}

/* Loading Animation */
.wkg-loading {
    text-align: center;
    padding: 40px;
}

.wkg-loading::after {
    content: '';
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: wkg-spin 1s linear infinite;
}

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

/* Smooth Transitions */
.wkg-gifts-container,
.wkg-custom-gift-box,
.wkg-gift-image {
    transition: all 0.3s ease;
}
