:root {
    --bg-dark: #0f172a;
    --bg-card: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent-primary: #38bdf8;
    /* Sky Blue */
    --accent-secondary: #a855f7;
    /* Purple */
    --accent-success: #22c55e;
    /* Green */
    --accent-warning: #eab308;
    /* Yellow */
    --accent-danger: #ef4444;
    /* Red */
    --glow-primary: 0 0 20px rgba(56, 189, 248, 0.3);
    --glow-secondary: 0 0 20px rgba(168, 85, 247, 0.3);
    --font-main: 'Inter', sans-serif;
}

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

body {
    font-family: var(--font-main);
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    padding: 20px;
}

.app-container {
    width: 100%;
    max-width: 1200px;
    background-color: var(--bg-card);
    border-radius: 24px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Header */
.main-header {
    padding: 25px 40px;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo-area h1 {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -1px;
    margin: 0;
}

.highlight {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin: 0;
}

.nav-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    padding: 10px 20px;
    border-radius: 12px;
    cursor: pointer;
    font-family: var(--font-main);
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.nav-btn.hidden {
    display: none;
}

/* Content Area */
.content-area {
    padding: 40px;
    flex: 1;
    min-height: 60vh;
}

.hidden {
    display: none !important;
}

/* Landing Page */
.landing-content {
    text-align: center;
    padding: 40px 0;
}

.landing-content h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.landing-content p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 50px;
}

.selection-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 900px;
    margin: 0 auto;
}

.selection-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 24px;
    padding: 40px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.selection-card:hover {
    transform: translateY(-10px);
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.selection-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at top right, rgba(56, 189, 248, 0.1), transparent 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.selection-card:hover::before {
    opacity: 1;
}

.card-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    width: 80px;
    height: 80px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    background: rgba(0, 0, 0, 0.2);
}

.rula-glow {
    color: var(--accent-primary);
    box-shadow: var(--glow-primary);
}

.reba-glow {
    color: var(--accent-secondary);
    box-shadow: var(--glow-secondary);
}

.selection-card h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.selection-card p {
    font-size: 1rem;
    margin-bottom: 30px;
}

.card-action {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--accent-primary);
    font-weight: 600;
    font-size: 0.95rem;
}

/* User Details Form */
.user-details-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 40px;
    background: rgba(0, 0, 0, 0.2);
    padding: 25px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

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

.input-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.input-group input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 12px 15px;
    border-radius: 10px;
    color: white;
    font-family: var(--font-main);
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
}

.input-group input:focus {
    border-color: var(--accent-primary);
    background: rgba(255, 255, 255, 0.08);
}

/* Assessment Section */
.section-header {
    margin-bottom: 40px;
    text-align: center;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.header-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 10px;
}

.section-header h2 {
    font-size: 2rem;
    margin: 0;
}

.badge {
    font-size: 0.75rem;
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.rula-badge {
    background: rgba(56, 189, 248, 0.15);
    color: var(--accent-primary);
}

.reba-badge {
    background: rgba(168, 85, 247, 0.15);
    color: var(--accent-secondary);
}

.ref-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 15px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    padding: 8px 16px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.03);
    transition: all 0.2s ease;
}

.ref-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: white;
}

/* Steps */
.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
}

.step-card {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 25px;
    transition: all 0.3s ease;
}

.step-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.step-title {
    font-weight: 600;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.05rem;
}

.step-number {
    background: rgba(255, 255, 255, 0.1);
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
}

.step-control select {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    padding: 12px;
    border-radius: 10px;
    font-family: var(--font-main);
    font-size: 0.95rem;
    outline: none;
    cursor: pointer;
}

.step-control select:focus {
    border-color: var(--accent-primary);
}

.adjustments-area {
    margin-top: 15px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.adj-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.calc-display {
    display: block;
    background: rgba(255, 255, 255, 0.05);
    padding: 10px;
    border-radius: 8px;
    text-align: center;
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--accent-success);
}

/* Action Area */
.action-area {
    margin-top: 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.action-btn {
    border: none;
    padding: 16px 40px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.rula-btn {
    background: linear-gradient(135deg, var(--accent-primary), #0ea5e9);
    color: white;
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.4);
}

.reba-btn {
    background: linear-gradient(135deg, var(--accent-secondary), #9333ea);
    color: white;
    box-shadow: 0 0 20px rgba(168, 85, 247, 0.4);
}

.action-btn:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

.action-btn.secondary {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-secondary);
    font-size: 0.9rem;
    padding: 12px 30px;
}

.action-btn.secondary:hover {
    border-color: var(--text-primary);
    color: var(--text-primary);
}

/* Result Display */
.result-display {
    margin-top: 30px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 30px 50px;
    display: flex;
    align-items: center;
    gap: 40px;
    animation: slideUp 0.5s ease;
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.score-circle {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.2);
}

.score-value {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
}

.score-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    opacity: 0.7;
}

.result-details h3 {
    margin-bottom: 10px;
    font-size: 1.4rem;
}

/* Footer */
.main-footer {
    padding: 30px;
    background: rgba(15, 23, 42, 0.9);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.developer-info {
    margin-bottom: 20px;
}

.dev-name {
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
    margin: 5px 0;
}

.dev-credentials {
    font-size: 0.8rem;
    opacity: 0.7;
    max-width: 700px;
    margin: 0 auto;
}

.references {
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.8rem;
    opacity: 0.6;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }

    .app-container {
        border-radius: 16px;
    }

    .main-header {
        padding: 20px;
        flex-direction: column;
        gap: 15px;
    }

    .content-area {
        padding: 20px;
    }

    .user-details-form {
        grid-template-columns: 1fr;
    }

    .steps-container {
        grid-template-columns: 1fr;
    }

    .result-display {
        flex-direction: column;
        text-align: center;
        padding: 25px;
        gap: 20px;
    }

    .action-btn {
        width: 100%;
        justify-content: center;
    }
}