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

:root {
    --primary-color: #8e44ad;
    --secondary-color: #3498db;
    --background-color: #f9f4ff;
    --text-color: #333;
    --light-text: #777;
    --white: #fff;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

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

.logo{
    position: absolute;
    top: 10px;
    left: 10px;
    height: 80px;
    width: 80px;
}

body {
    position: relative;
    font-family: 'Poppins', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(-45deg, #ee7752, #e73c7e, #23a6d5, #23d5ab);
	background-size: 400% 400%;
	animation: gradient 15s ease infinite;
}

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

.container {
    width: 100%;
    max-width: 480px;
    padding: 20px;
}

.app-wrapper {
    background-color: var(--white);
    border-radius: 20px;
    box-shadow: var(--shadow);
    overflow: hidden;
    position: relative;
}

/* Header Styles */
header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    padding: 20px;
    text-align: center;
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    font-size: 24px;
    font-weight: 600;
    flex-grow: 1;
}

.stars {
    display: flex;
    gap: 8px;
}

.stars i {
    font-size: 16px;
    opacity: 0.8;
    animation: twinkle 1.5s infinite alternate;
}

.stars i:nth-child(2) {
    animation-delay: 0.5s;
}

@keyframes twinkle {
    0% { opacity: 0.4; transform: scale(0.8); }
    100% { opacity: 1; transform: scale(1); }
}

/* Screen Styles */
.screen {
    display: none;
    padding: 30px 20px;
    min-height: 400px;
}

.screen.active {
    display: block;
}

/* Welcome Screen */
.welcome-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 25px;
    padding: 20px 0;
}

.welcome-content p {
    font-size: 16px;
    color: var(--light-text);
    line-height: 1.6;
}

.gender-selection {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.gender-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.gender-btn {
    background-color: #f0f0f0;
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 10px;
}

.gender-btn i {
    font-size: 18px;
}

.gender-btn:hover {
    background-color: #e0e0e0;
}

.gender-btn.selected {
    border-color: var(--primary-color);
    background-color: rgba(142, 68, 173, 0.1);
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: left;
}

.input-group label {
    font-size: 14px;
    font-weight: 500;
    margin-left: 4px;
}

input {
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-size: 16px;
    transition: var(--transition);
}

input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(142, 68, 173, 0.2);
}

.primary-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    border: none;
    border-radius: 12px;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

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

/* Questions Screen */
.progress-container {
    width: 100%;
    height: 6px;
    background-color: #e0e0e0;
    border-radius: 3px;
    margin-bottom: 25px;
    overflow: hidden;
}

#progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    width: 10%;
    transition: width 0.4s ease;
}

.question-number {
    font-size: 14px;
    color: var(--light-text);
    margin-bottom: 15px;
}

#question-text {
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 30px;
    line-height: 1.5;
}

.btn-group {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.answer-btn {
    flex: 1;
    padding: 15px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.yes-btn {
    background-color: #e8f5e9;
    color: #2e7d32;
}

.yes-btn:hover {
    background-color: #c8e6c9;
}

.no-btn {
    background-color: #ffebee;
    color: #c62828;
}

.no-btn:hover {
    background-color: #ffcdd2;
}

/* Processing Screen */
.processing-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 100%;
    gap: 25px;
}

.crystal-ball {
    position: relative;
    width: 120px;
    height: 160px;
    margin-bottom: 20px;
}

.crystal {
    width: 120px;
    height: 120px;
    background: radial-gradient(ellipse at center, rgba(255,255,255,0.5) 0%, rgba(142,68,173,0.3) 100%);
    border-radius: 50%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(142, 68, 173, 0.3), 
                inset 0 -10px 15px rgba(255, 255, 255, 0.4);
    animation: glow 3s infinite alternate;
}

.inner-glow {
    position: absolute;
    width: 60px;
    height: 60px;
    top: 30px;
    left: 30px;
    background: radial-gradient(ellipse at center, rgba(255,255,255,0.9) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
    animation: float 4s infinite ease-in-out;
}

.base {
    position: absolute;
    bottom: 0;
    left: 25px;
    width: 70px;
    height: 20px;
    background: linear-gradient(135deg, #9b59b6, #8e44ad);
    border-radius: 50%;
    z-index: -1;
}

@keyframes glow {
    0% { box-shadow: 0 10px 25px rgba(142, 68, 173, 0.3), 
                    inset 0 -10px 15px rgba(255, 255, 255, 0.4); }
    100% { box-shadow: 0 15px 35px rgba(142, 68, 173, 0.5), 
                    inset 0 -15px 20px rgba(255, 255, 255, 0.6); }
}

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

.processing-content p {
    color: var(--light-text);
    font-size: 16px;
    animation: fadeInOut 2s infinite;
}

@keyframes fadeInOut {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Result Screen */
.result-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.result-content h2 {
    font-size: 22px;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.result-content p {
    font-size: 16px;
    color: var(--light-text);
    line-height: 1.6;
}

.soulmate-name {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin: 15px 0;
    padding: 10px 30px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(142, 68, 173, 0.1), rgba(52, 152, 219, 0.1));
    display: inline-block;
}

.disclaimer {
    font-size: 14px;
    font-style: italic;
    opacity: 0.7;
    max-width: 280px;
    margin: 0 auto;
}

#retry-btn {
    margin-top: 15px;
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 20px;
    }
    
    .btn-group {
        flex-direction: column;
    }
    
    .answer-btn {
        padding: 12px;
    }
    
    .soulmate-name {
        font-size: 28px;
        padding: 8px 20px;
    }
}