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

:root {
    --dark-bg: #0A0E27;
    --coral: #FF3366;
    --coral-light: #FF6B9D;
    --gold: #FFD700;
    --light-card: #FFFBF5;
    --text-dark: #1A1A1A;
    --text-gray: #6B7280;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--dark-bg);
    color: white;
    overflow-x: hidden;
    line-height: 1.6;
}

/* Page Management */
.page {
    display: none;
    min-height: 100vh;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.page.active {
    display: block;
    opacity: 1;
}

/* Landing Page */
.hero-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 2rem;
}

.radial-glow {
    position: absolute;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(255, 51, 102, 0.15) 0%, rgba(255, 51, 102, 0) 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    animation: pulse 4s ease-in-out infinite;
}

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

.content-wrapper {
    text-align: center;
    position: relative;
    z-index: 1;
    max-width: 700px;
}

.hero-title {
    font-family: 'DM Serif Display', serif;
    font-size: clamp(3rem, 10vw, 5.5rem);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #FFFFFF 0%, #FFD700 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 3rem;
    font-weight: 400;
}

/* CTA Button */
.cta-button {
    background: linear-gradient(90deg, var(--coral) 0%, var(--coral-light) 100%);
    color: white;
    font-size: 1.125rem;
    font-weight: 600;
    padding: 1rem 2.5rem;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    font-family: 'Inter', sans-serif;
    box-shadow: 0 10px 30px rgba(255, 51, 102, 0.3);
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(255, 51, 102, 0.4);
}

.cta-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.button-shine {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.cta-button:hover .button-shine {
    left: 100%;
}

/* Container */
.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 2rem 1rem;
    min-height: 100vh;
}

/* Back Button */
.back-button {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: none;
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    font-size: 1rem;
    cursor: pointer;
    margin-bottom: 2rem;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.back-button:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* Upload Card */
.upload-card {
    background: var(--light-card);
    border-radius: 24px;
    padding: 32px;
    box-shadow: 0 20px 60px rgba(10, 14, 39, 0.15);
}

.card-title {
    font-family: 'DM Serif Display', serif;
    font-size: 2rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.card-subtitle {
    color: var(--text-gray);
    font-size: 1rem;
    margin-bottom: 2rem;
}

/* Upload Zone */
.upload-zone {
    border: 2px dashed #D1D5DB;
    border-radius: 16px;
    padding: 3rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 2rem;
    position: relative;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.upload-zone:hover {
    border-color: var(--coral);
    background: rgba(255, 51, 102, 0.02);
}

.upload-zone.drag-over {
    border-color: var(--coral);
    background: rgba(255, 51, 102, 0.05);
}

.upload-prompt {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.upload-prompt svg {
    color: var(--coral);
}

.upload-text {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-dark);
}

.upload-hint {
    color: var(--text-gray);
    font-size: 0.875rem;
}

.image-preview {
    max-width: 100%;
    max-height: 400px;
    border-radius: 12px;
    object-fit: contain;
}

/* Tips Box */
.tips-box {
    background: rgba(255, 215, 0, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.tips-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.75rem;
}

.tips-list {
    list-style: none;
    color: var(--text-dark);
    font-size: 0.875rem;
}

.tips-list li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.5rem;
}

.tips-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--gold);
    font-weight: bold;
}

/* Processing Page */
.processing-card {
    text-align: center;
    padding: 2rem 1rem;
}

.processing-image-container {
    position: relative;
    display: inline-block;
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 2rem;
    max-width: 400px;
    width: 100%;
}

.processing-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 16px;
}

.shimmer-overlay {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.3) 50%,
        transparent 100%
    );
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

.processing-title {
    font-family: 'DM Serif Display', serif;
    font-size: 2rem;
    margin-bottom: 1rem;
}

.processing-subtitle {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    margin-bottom: 2rem;
}

.processing-dots {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}

.processing-dots span {
    width: 12px;
    height: 12px;
    background: var(--coral);
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out;
}

.processing-dots span:nth-child(1) { animation-delay: -0.32s; }
.processing-dots span:nth-child(2) { animation-delay: -0.16s; }

@keyframes bounce {
    0%, 80%, 100% { transform: scale(0); opacity: 0.5; }
    40% { transform: scale(1); opacity: 1; }
}

/* Results Page */
.results-card {
    background: var(--light-card);
    border-radius: 24px;
    padding: 32px;
    box-shadow: 0 20px 60px rgba(10, 14, 39, 0.15);
}

.score-section {
    text-align: center;
    padding: 2rem 0;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.score-label {
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-gray);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

.score-display {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 5rem;
    font-weight: 700;
    color: var(--gold);
    line-height: 1;
    margin-bottom: 0.5rem;
    text-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
}

.score-subtitle {
    font-size: 1.125rem;
    color: var(--text-dark);
    font-weight: 500;
}

/* Recommendations */
.recommendations-section {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.recommendation-item {
    opacity: 0;
    animation: fadeInUp 0.5s ease forwards;
}

.recommendation-item:nth-child(1) { animation-delay: 0.1s; }
.recommendation-item:nth-child(2) { animation-delay: 0.2s; }
.recommendation-item:nth-child(3) { animation-delay: 0.3s; }
.recommendation-item:nth-child(4) { animation-delay: 0.4s; }

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

.recommendation-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.recommendation-emoji {
    font-size: 1.5rem;
}

.recommendation-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-dark);
}

.recommendation-text {
    color: var(--text-dark);
    font-size: 1rem;
    line-height: 1.7;
    margin-left: 2.25rem;
}

/* Share Button */
.share-button {
    width: 100%;
    background: var(--text-dark);
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 16px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.share-button:hover {
    background: #000;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* Branding */
.branding {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 2px solid rgba(0, 0, 0, 0.1);
}

.brand-logo {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-gray);
}

/* Mobile Responsiveness */
@media (max-width: 640px) {
    .hero-title {
        font-size: 3rem;
    }

    .hero-subtitle {
        font-size: 1.125rem;
    }

    .upload-card,
    .results-card {
        padding: 24px;
        border-radius: 20px;
    }

    .score-display {
        font-size: 4rem;
    }

    .card-title {
        font-size: 1.75rem;
    }

    .upload-zone {
        padding: 2rem 1rem;
    }
}
