/* Valentine Proposal Plugin Styles */
/* Additional styles that complement the inline styles */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Quicksand:wght@400;500;600;700&family=Nunito:wght@400;600;700&display=swap');

/* CSS Variables */
:root {
    --valentine-primary: #ff6b9d;
    --valentine-secondary: #ffc2d1;
    --valentine-accent: #ff1744;
    --valentine-white: #ffffff;
    --valentine-light: #fff5f7;
    --valentine-dark: #5d4037;
}

/* Ensure full width */
.valentine-container {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

/* Enhanced Card Hover Effects */
.valentine-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.valentine-card:hover {
    transform: translateY(-3px);
    box-shadow: 
        0 20px 60px rgba(255, 107, 157, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.5) inset;
}

/* Button Ripple Effect */
.valentine-btn {
    position: relative;
    overflow: hidden;
}

.valentine-btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.valentine-btn:active::after {
    width: 300px;
    height: 300px;
}

/* Enhanced Yes Button */
.btn-yes {
    animation: yesPulse 2s ease infinite;
}

@keyframes yesPulse {
    0%, 100% { 
        box-shadow: 0 8px 25px rgba(76, 175, 80, 0.4);
    }
    50% { 
        box-shadow: 0 12px 35px rgba(76, 175, 80, 0.6), 0 0 20px rgba(76, 175, 80, 0.3);
    }
}

/* No Button States */
.btn-no {
    opacity: 0.8;
    cursor: not-allowed;
}

.btn-no:hover {
    opacity: 1;
}

/* Input Focus Animation */
.form-group input {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.form-group input:focus {
    transform: scale(1.01);
}

/* Enhanced Floating Hearts */
.heart {
    filter: drop-shadow(0 2px 4px rgba(255, 107, 157, 0.3));
}

/* Celebration State */
.valentine-container.celebrating {
    animation: celebrationBg 2s ease infinite;
}

@keyframes celebrationBg {
    0%, 100% { 
        filter: brightness(1);
    }
    50% { 
        filter: brightness(1.05);
    }
}

/* Response Message Enhancements */
.response-message {
    position: relative;
}

.response-message::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    background: linear-gradient(45deg, #ffd54f, #ff6b9d, #ffd54f, #ff6b9d);
    background-size: 400% 400%;
    border-radius: 18px;
    z-index: -1;
    animation: borderGlow 3s ease infinite;
}

@keyframes borderGlow {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Enhanced Sparkles */
.sparkle {
    filter: drop-shadow(0 0 5px rgba(255, 215, 0, 0.8));
}

/* Dodge Counter Animation */
.dodge-counter.updated {
    animation: counterPulse 0.2s ease;
}

@keyframes counterPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Share Section */
.share-section {
    animation: slideDown 0.3s ease;
}

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

/* Card Footer */
.card-footer {
    border-top: 1px solid rgba(255, 194, 209, 0.3);
    margin-top: auto;
}

.btn-reset-link {
    opacity: 0.6;
    transition: opacity 0.2s ease;
}

.btn-reset-link:hover {
    opacity: 1;
}

/* Mobile Touch Improvements */
@media (hover: none) {
    .valentine-btn:hover {
        transform: none;
    }
    
    .valentine-btn:active {
        transform: scale(0.98);
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .heart,
    .sparkle,
    .valentine-btn,
    .valentine-card,
    .form-group input {
        animation: none !important;
        transition: none !important;
    }
}

/* Loading State */
.valentine-btn.loading {
    pointer-events: none;
    opacity: 0.7;
}

.valentine-btn.loading::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Error State */
.form-group input.error {
    border-color: #f44336;
    background: #ffebee;
}

/* Success State */
.form-group input.success {
    border-color: #4caf50;
    background: #e8f5e9;
}

/* Custom Scrollbar */
.valentine-container ::-webkit-scrollbar {
    width: 6px;
}

.valentine-container ::-webkit-scrollbar-track {
    background: var(--valentine-light);
    border-radius: 10px;
}

.valentine-container ::-webkit-scrollbar-thumb {
    background: var(--valentine-primary);
    border-radius: 10px;
}

.valentine-container ::-webkit-scrollbar-thumb:hover {
    background: var(--valentine-accent);
}

/* Print Styles */
@media print {
    .floating-hearts,
    .sparkles,
    .hearts-container,
    .confetti-container,
    .btn-no {
        display: none !important;
    }
    
    .valentine-container {
        background: white !important;
    }
    
    .valentine-card {
        box-shadow: none !important;
        border: 2px solid #ddd;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .valentine-card {
        border: 3px solid var(--valentine-accent);
    }
    
    .valentine-btn {
        border: 2px solid currentColor;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .valentine-container {
        background: linear-gradient(135deg, #2d1f24 0%, #1a1215 50%, #2d1f24 100%);
    }
    
    .valentine-card {
        background: rgba(40, 30, 35, 0.95);
        color: #fff;
    }
    
    .form-group input {
        background: #3a2a30;
        border-color: #5a4a50;
        color: #fff;
    }
    
    .form-group label {
        color: #ccc;
    }
    
    .valentine-subtitle,
    .question-prefix,
    .question-suffix {
        color: #aaa;
    }
}

/* Ensure single screen on mobile */
@media (max-width: 480px) {
    html, body {
        overflow-x: hidden;
    }
    
    .valentine-container {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        padding: 8px;
    }
    
    .question-card {
        max-height: calc(100vh - 16px);
        max-height: calc(100dvh - 16px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
}

/* Landscape mobile */
@media (max-height: 500px) and (orientation: landscape) {
    .valentine-card {
        padding: 15px;
    }
    
    .question-img, .celebration-img {
        max-height: 80px;
    }
    
    .the-question {
        font-size: 16px;
    }
    
    .buttons-container {
        min-height: 45px;
    }
    
    .btn-yes {
        padding: 12px 28px;
        font-size: 16px;
    }
    
    .btn-no {
        padding: 8px 20px;
        font-size: 12px;
    }
}
