* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

/* Minimal Background Elements */
body::before {
    content: '💍';
    position: fixed;
    font-size: 100px;
    opacity: 0.08;
    top: 10%;
    left: 5%;
    animation: float-slow 35s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

body::after {
    content: '💕';
    position: fixed;
    font-size: 80px;
    opacity: 0.08;
    bottom: 15%;
    right: 8%;
    animation: float-slow 40s ease-in-out infinite reverse;
    pointer-events: none;
    z-index: 0;
}

.bg-element {
    position: fixed;
    opacity: 0.06;
    pointer-events: none;
    z-index: 0;
}

.bg-element-1 {
    font-size: 120px;
    top: 50%;
    left: -5%;
    animation: float-slow 45s ease-in-out infinite;
}

.bg-element-2 {
    font-size: 90px;
    top: 20%;
    right: 10%;
    animation: float-slow 38s ease-in-out infinite reverse;
}

.bg-element-3 {
    font-size: 70px;
    bottom: 25%;
    left: 15%;
    animation: float-slow 42s ease-in-out infinite;
}

.bg-element-4 {
    width: 200px;
    height: 200px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    top: 30%;
    right: -5%;
    animation: rotate-slow 60s linear infinite;
}

.bg-element-5 {
    width: 150px;
    height: 150px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    bottom: 10%;
    left: 20%;
    animation: rotate-slow 55s linear infinite reverse;
}

@keyframes float-slow {
    0%, 100% {
        transform: translateY(0) translateX(0);
    }
    25% {
        transform: translateY(-30px) translateX(20px);
    }
    50% {
        transform: translateY(0) translateX(40px);
    }
    75% {
        transform: translateY(30px) translateX(20px);
    }
}

@keyframes rotate-slow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.card {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: slideIn 0.5s ease-out;
}

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

h1 {
    text-align: center;
    color: #667eea;
    font-size: 2.5em;
    margin-bottom: 10px;
}

.subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 30px;
    font-size: 1.1em;
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
}

input, textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s;
    font-family: inherit;
}

input:focus, textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

textarea {
    resize: vertical;
    min-height: 80px;
}

button {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

button:active {
    transform: translateY(0);
}

.hidden {
    display: none !important;
}

/* Template Selection */
.selection-title {
    text-align: center;
    color: white;
    font-size: 2.5em;
    margin-bottom: 10px;
}

.selection-subtitle {
    text-align: center;
    color: rgba(255,255,255,0.9);
    margin-bottom: 40px;
    font-size: 1.1em;
}

.templates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 20px;
}

.template-card {
    background: white;
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.template-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

.template-card.romantic {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
}

.template-card.playful {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
}

.template-card.adventurous {
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);
}

.template-icon {
    font-size: 4em;
    margin-bottom: 15px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.template-card h3 {
    font-size: 1.8em;
    margin-bottom: 10px;
    color: #333;
}

.template-card p {
    color: #666;
    font-size: 1.1em;
}

.preview-badge {
    margin-top: 15px;
    padding: 8px 20px;
    background: rgba(255,255,255,0.8);
    border-radius: 20px;
    display: inline-block;
    font-size: 0.9em;
    font-weight: 600;
    color: #667eea;
}

/* Proposal Views */
.proposal-view {
    background: white;
    border-radius: 20px;
    padding: 60px 40px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    position: relative;
    overflow: hidden;
    animation: fadeIn 0.5s;
    min-height: 600px;
}

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

.romantic-theme {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
}

.playful-theme {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
}

.adventure-theme {
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);
}

.proposal-content {
    text-align: center;
    position: relative;
    z-index: 10;
}

.emoji-large {
    font-size: 5em;
    margin-bottom: 20px;
}

.bouncing {
    animation: bounce 1s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

.pulse {
    animation: pulse 2s ease-in-out infinite;
}

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

.proposal-view h2 {
    font-size: 2.5em;
    color: #c0392b;
    margin-bottom: 20px;
}

.divider {
    width: 100px;
    height: 3px;
    background: #c0392b;
    margin: 20px auto;
}

.proposal-view p {
    font-size: 1.3em;
    line-height: 1.8;
    color: #2c3e50;
    margin-bottom: 25px;
}

.proposal-view .intro {
    font-style: italic;
    font-weight: 500;
}

.closing {
    font-size: 2em;
    font-weight: bold;
    color: #c0392b;
    margin-top: 40px;
    animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    10%, 30% { transform: scale(1.1); }
    20%, 40% { transform: scale(1); }
}

/* Floating Elements */
.floating-hearts span,
.confetti span,
.stars span {
    position: absolute;
    font-size: 2em;
    opacity: 0.6;
    animation: float-around 10s linear infinite;
}

.floating-hearts span:nth-child(1) { top: 10%; left: 10%; animation-delay: 0s; }
.floating-hearts span:nth-child(2) { top: 20%; right: 15%; animation-delay: 2s; }
.floating-hearts span:nth-child(3) { bottom: 30%; left: 20%; animation-delay: 4s; }
.floating-hearts span:nth-child(4) { bottom: 15%; right: 10%; animation-delay: 6s; }

.confetti span:nth-child(1) { top: 5%; left: 15%; animation-delay: 0s; }
.confetti span:nth-child(2) { top: 15%; right: 10%; animation-delay: 1s; }
.confetti span:nth-child(3) { bottom: 25%; left: 10%; animation-delay: 2s; }
.confetti span:nth-child(4) { bottom: 10%; right: 20%; animation-delay: 3s; }
.confetti span:nth-child(5) { top: 40%; left: 5%; animation-delay: 4s; }

.stars span:nth-child(1) { top: 10%; left: 12%; animation-delay: 0s; }
.stars span:nth-child(2) { top: 25%; right: 18%; animation-delay: 1.5s; }
.stars span:nth-child(3) { bottom: 20%; left: 15%; animation-delay: 3s; }
.stars span:nth-child(4) { bottom: 35%; right: 12%; animation-delay: 4.5s; }

@keyframes float-around {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-20px) rotate(90deg); }
    50% { transform: translateY(0) rotate(180deg); }
    75% { transform: translateY(-20px) rotate(270deg); }
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 20px;
    margin-top: 30px;
}

.back-btn, .download-btn {
    flex: 1;
    padding: 15px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
}

.back-btn {
    background: #95a5a6;
}

.download-btn {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
}

.back-btn:hover, .download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

/* Responsive */
@media (max-width: 768px) {
    .templates-grid {
        grid-template-columns: 1fr;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    h1 {
        font-size: 2em;
    }
    
    .proposal-view {
        padding: 40px 20px;
    }
}