:root {
    --bg-color: #030308;
    --card-bg: rgba(13, 13, 25, 0.6);
    --text-primary: #ffffff;
    --text-secondary: #94a3b8;
    --accent-pink: #ff007f;
    --accent-pink-glow: rgba(255, 0, 127, 0.4);
    --accent-blue: #00f0ff;
    --accent-blue-glow: rgba(0, 240, 255, 0.4);
    --accent-purple: #8b5cf6;
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-border-hover: rgba(255, 255, 255, 0.2);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
}

/* Cosmic background gradients */
body::before, body::after {
    content: '';
    position: absolute;
    width: 350px;
    height: 350px;
    border-radius: 50%;
    filter: blur(100px);
    z-index: -1;
    opacity: 0.5;
    animation: floatGlow 10s ease-in-out infinite alternate;
}

body::before {
    background: var(--accent-pink);
    top: 15%;
    left: 10%;
}

body::after {
    background: var(--accent-blue);
    bottom: 15%;
    right: 10%;
    animation-delay: -5s;
}

@keyframes floatGlow {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(30px, 30px) scale(1.2); }
}

.app-container {
    width: 100%;
    max-width: 480px;
    min-height: 100vh;
    padding: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    z-index: 1;
}

.screen {
    display: none;
    width: 100%;
    animation: slideUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.screen.active {
    display: block;
}

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

/* Premium Glassmorphism Card */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 48px 32px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4),
                inset 0 1px 1px rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -50%;
    width: 200%;
    height: 100%;
    background: linear-gradient(
        to right,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.03) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(25deg);
    transition: 0.7s;
    pointer-events: none;
}

.glass-card:hover::before {
    left: 120%;
}

/* Badges & Accents */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 16px;
    border-radius: 100px;
    background: rgba(255, 0, 127, 0.12);
    border: 1px solid rgba(255, 0, 127, 0.25);
    color: var(--accent-pink);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 24px;
    letter-spacing: 0.5px;
    box-shadow: 0 0 15px rgba(255, 0, 127, 0.1);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.9; }
    50% { opacity: 1; transform: scale(1.02); box-shadow: 0 0 20px rgba(255, 0, 127, 0.2); }
}

.main-title {
    font-size: 2.6rem;
    line-height: 1.25;
    font-weight: 900;
    margin-bottom: 20px;
    letter-spacing: -0.5px;
}

.neon-text {
    background: linear-gradient(135deg, var(--accent-pink), #ff00ea, var(--accent-blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 950;
    filter: drop-shadow(0 2px 10px rgba(255, 0, 127, 0.3));
}

.subtitle {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.6;
    margin-bottom: 48px;
}

/* Interactive Buttons */
button {
    cursor: pointer;
    border: none;
    outline: none;
    font-family: inherit;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.glow-btn {
    width: 100%;
    padding: 18px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--accent-pink), #c000ff);
    color: white;
    font-size: 1.15rem;
    font-weight: 800;
    box-shadow: 0 8px 24px rgba(255, 0, 127, 0.35);
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.glow-btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #c000ff, var(--accent-blue));
    opacity: 0;
    z-index: -1;
    transition: opacity 0.5s ease;
}

.glow-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(255, 0, 127, 0.5);
}

.glow-btn:hover::after {
    opacity: 1;
}

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

.outline-btn {
    width: 100%;
    padding: 18px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-primary);
    border: 1px solid var(--glass-border);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 14px;
}

.outline-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--glass-border-hover);
    transform: translateY(-2px);
}

/* Quiz Screen Style */
.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    margin-bottom: 36px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-pink));
    width: 0%;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 0 12px var(--accent-pink-glow);
}

.q-image-container {
    width: 100%;
    margin-bottom: 24px;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(0, 0, 0, 0.2);
}

.q-image {
    width: 100%;
    max-height: 220px;
    object-fit: cover;
    display: block;
}

.question-container {
    margin-bottom: 40px;
    text-align: left;
}

.q-num {
    color: var(--accent-blue);
    font-weight: 800;
    font-size: 1.3rem;
    margin-bottom: 12px;
    display: inline-block;
    letter-spacing: 1px;
    text-shadow: 0 0 10px var(--accent-blue-glow);
}

.q-text {
    font-size: 1.5rem;
    line-height: 1.45;
    font-weight: 800;
    word-break: keep-all;
}

.options-container {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.option-btn {
    width: 100%;
    padding: 20px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    font-size: 1.05rem;
    line-height: 1.4;
    text-align: left;
    position: relative;
    overflow: hidden;
}

.option-btn::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background: var(--accent-pink);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.option-btn:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateX(6px);
}

.option-btn:hover::before {
    opacity: 1;
}

.option-main {
    font-weight: 700;
    display: inline-block;
}

.option-sub {
    font-size: 0.88rem;
    color: var(--text-secondary);
    display: inline-block;
    margin-top: 6px;
    font-weight: 500;
}

.loading-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 320px;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.03);
    border-radius: 50%;
    border-top-color: var(--accent-pink);
    border-right-color: var(--accent-blue);
    animation: spin 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
    margin-bottom: 32px;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.1);
}

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

.loading-card h2 {
    font-size: 1.7rem;
    font-weight: 800;
    margin-bottom: 12px;
}

.loading-card p {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* Result Screen Design */
.result-card {
    padding-top: 48px;
    padding-bottom: 48px;
}

.result-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
    font-weight: 600;
}

.result-title {
    font-size: 2.2rem;
    margin-bottom: 32px;
    line-height: 1.35;
    font-weight: 900;
    white-space: pre-line;
}

.result-desc-box {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 20px;
    padding: 28px 24px;
    margin-bottom: 36px;
    text-align: left;
    box-shadow: inset 0 2px 8px rgba(0,0,0,0.5);
}

.result-desc {
    line-height: 1.75;
    font-size: 1.02rem;
    color: #e2e8f0;
    white-space: pre-line;
}

.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

