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

/* Root Variables */
:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --success-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --card-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    --card-hover-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Container */
.blessings-generator-container {
    width: 100%;
    min-height: 500px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    padding: 60px 20px;
    font-family: 'Poppins', sans-serif;
    position: relative;
    overflow: hidden;
}

.blessings-generator-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
    pointer-events: none;
}

.blessings-generator-wrapper {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

/* Steps */
.blessings-step {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

.blessings-step.active {
    display: block;
}

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

/* Titles */
.blessings-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: #ffffff;
    text-align: center;
    margin-bottom: 10px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

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

/* Category Cards */
.blessings-category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 40px;
}

.blessings-category-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--card-shadow);
    position: relative;
    overflow: hidden;
}

.blessings-category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: var(--primary-gradient);
    transform: scaleX(0);
    transition: var(--transition);
}

.blessings-category-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--card-hover-shadow);
}

.blessings-category-card:hover::before {
    transform: scaleX(1);
}

.blessings-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    display: inline-block;
    transition: var(--transition);
}

.blessings-category-card:hover .blessings-icon {
    transform: scale(1.2) rotate(5deg);
}

.blessings-category-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

.blessings-category-card p {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.5;
}

/* Subcategory Buttons */
.blessings-subcategory-grid {
    display: grid;
    gap: 15px;
    margin-top: 30px;
}

.blessings-subcategories {
    display: none;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.blessings-subcategories.active {
    display: grid;
}

.blessings-subcategory-btn {
    background: #ffffff;
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 18px 25px;
    font-size: 1rem;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    font-family: 'Poppins', sans-serif;
}

.blessings-subcategory-btn:hover {
    background: var(--primary-gradient);
    color: #ffffff;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

/* Back Button */
.blessings-back-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    padding: 12px 24px;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    margin-bottom: 30px;
    backdrop-filter: blur(10px);
    font-family: 'Poppins', sans-serif;
}

.blessings-back-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateX(-5px);
}

/* Options Container */
.blessings-options-container {
    background: #ffffff;
    border-radius: 20px;
    padding: 40px;
    box-shadow: var(--card-shadow);
    margin-top: 30px;
}

.blessings-option-group {
    margin-bottom: 30px;
}

.blessings-option-label {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 15px;
}

.blessings-option-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.blessings-option-btn {
    background: #f5f5f5;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 12px 24px;
    font-size: 0.95rem;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Poppins', sans-serif;
}

.blessings-option-btn:hover {
    border-color: #667eea;
    color: #667eea;
}

.blessings-option-btn.active {
    background: var(--primary-gradient);
    border-color: transparent;
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

/* Name Input */
.blessings-name-input {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    font-family: 'Poppins', sans-serif;
    transition: var(--transition);
    margin-top: 10px;
}

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

.blessings-help-text {
    display: block;
    margin-top: 8px;
    font-size: 0.85rem;
    color: #999;
}

/* Generate Button */
.blessings-generate-btn {
    width: 100%;
    background: var(--primary-gradient);
    border: none;
    border-radius: 12px;
    padding: 18px 40px;
    font-size: 1.2rem;
    font-weight: 600;
    color: #ffffff;
    cursor: pointer;
    transition: var(--transition);
    margin-top: 20px;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    font-family: 'Poppins', sans-serif;
}

.blessings-generate-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(102, 126, 234, 0.5);
}

.blessings-generate-btn:active {
    transform: translateY(-1px);
}

/* Result Card */
.blessings-result-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 50px;
    box-shadow: var(--card-shadow);
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Loader */
.blessings-loader {
    text-align: center;
}

.blessings-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.blessings-loader p {
    color: #666;
    font-size: 1.1rem;
}

/* Result Content */
.blessings-result-content {
    width: 100%;
    animation: fadeIn 0.5s ease-in-out;
}

.blessings-result-header {
    text-align: center;
    margin-bottom: 30px;
}

.blessings-result-type {
    display: inline-block;
    background: var(--primary-gradient);
    color: #ffffff;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

.blessings-result-text {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    line-height: 1.8;
    color: #333;
    text-align: center;
    margin-bottom: 40px;
    padding: 30px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 15px;
    border-left: 5px solid #667eea;
}

/* Result Actions */
.blessings-result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
}

.blessings-copy-btn,
.blessings-regenerate-btn,
.blessings-start-over-btn {
    background: #ffffff;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 14px 28px;
    font-size: 1rem;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Poppins', sans-serif;
}

.blessings-copy-btn:hover {
    background: var(--success-gradient);
    border-color: transparent;
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(79, 172, 254, 0.4);
}

.blessings-regenerate-btn:hover {
    background: var(--primary-gradient);
    border-color: transparent;
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.blessings-start-over-btn:hover {
    background: var(--secondary-gradient);
    border-color: transparent;
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(240, 147, 251, 0.4);
}

/* Copy Notification */
.blessings-copy-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #4caf50;
    color: #ffffff;
    padding: 15px 25px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.4);
    font-weight: 500;
    opacity: 0;
    transform: translateY(-20px);
    transition: var(--transition);
    pointer-events: none;
    z-index: 1000;
}

.blessings-copy-notification.show {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 768px) {
    .blessings-generator-container {
        padding: 40px 15px;
    }
    
    .blessings-title {
        font-size: 2rem;
    }
    
    .blessings-subtitle {
        font-size: 1rem;
    }
    
    .blessings-category-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .blessings-category-card {
        padding: 30px 20px;
    }
    
    .blessings-icon {
        font-size: 3rem;
    }
    
    .blessings-subcategories {
        grid-template-columns: 1fr;
    }
    
    .blessings-options-container {
        padding: 25px;
    }
    
    .blessings-option-buttons {
        flex-direction: column;
    }
    
    .blessings-option-btn {
        width: 100%;
        text-align: center;
    }
    
    .blessings-result-card {
        padding: 30px 20px;
    }
    
    .blessings-result-text {
        font-size: 1.1rem;
        padding: 20px;
    }
    
    .blessings-result-actions {
        flex-direction: column;
    }
    
    .blessings-copy-btn,
    .blessings-regenerate-btn,
    .blessings-start-over-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .blessings-title {
        font-size: 1.7rem;
    }
    
    .blessings-category-card h3 {
        font-size: 1.3rem;
    }
    
    .blessings-result-text {
        font-size: 1rem;
    }
}
