:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --secondary: #8b5cf6;
    --success: #10b981;
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-card: #334155;
    --text-primary: #f8fafc;
    --text-secondary: #cbd5e1;
    --border: #475569;
    --shadow: rgba(0, 0, 0, 0.5);
    --accent-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --transition: all 0.3s ease;
}

[data-theme="light"] {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --secondary: #8b5cf6;
    --success: #10b981;
    --bg-primary: #f8fafc;
    --bg-secondary: #f1f5f9;
    --bg-card: #ffffff;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --border: #e2e8f0;
    --shadow: rgba(0, 0, 0, 0.1);
    --accent-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
    transition: var(--transition);
}

.language-selector {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1000;
}

#languageSelect {
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 10px 16px;
    color: var(--text-primary);
    font-size: 0.95em;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 6px var(--shadow);
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236366f1' d='M1.41 0L6 4.59L10.59 0L12 1.41l-6 6l-6-6z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

#languageSelect:hover {
    border-color: var(--primary);
    box-shadow: 0 6px 12px rgba(99, 102, 241, 0.3);
}

#languageSelect option {
    background: var(--bg-card);
    color: var(--text-primary);
}

.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

#themeToggle {
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    box-shadow: 0 4px 6px var(--shadow);
}

#themeToggle svg {
    pointer-events: none;
}

#themeToggle:hover {
    transform: scale(1.1);
    border-color: var(--primary);
}

.sun-icon {
    display: none;
}

.moon-icon {
    display: block;
}

[data-theme="light"] .sun-icon {
    display: block;
}

[data-theme="light"] .moon-icon {
    display: none;
}

.container {
    max-width: 900px;
    margin: 80px auto 20px;
    background: var(--bg-card);
    border-radius: 24px;
    box-shadow: 0 20px 60px var(--shadow);
    overflow: hidden;
    border: 2px solid var(--border);
}

.header {
    background: var(--accent-gradient);
    color: white;
    padding: 60px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: pulse 15s ease-in-out infinite;
}

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

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

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

.header-content {
    position: relative;
    z-index: 1;
}

.header h1 {
    font-size: 3.5em;
    margin-bottom: 10px;
    font-weight: 800;
    letter-spacing: -0.02em;
    animation: fadeInDown 0.8s ease;
}

.header p {
    font-size: 1.3em;
    opacity: 0.95;
    font-weight: 500;
    animation: fadeInUp 0.8s ease;
}

.content {
    padding: 50px 40px;
}

.start-screen {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.start-screen h2 {
    color: var(--text-primary);
    margin-bottom: 20px;
    font-size: 2.2em;
    font-weight: 700;
}

.start-screen p {
    color: var(--text-secondary);
    margin-bottom: 35px;
    font-size: 1.15em;
    line-height: 1.8;
}

.btn {
    background: var(--accent-gradient);
    color: white;
    border: none;
    padding: 16px 48px;
    font-size: 1.1em;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
    letter-spacing: 0.5px;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.5);
}

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

.question-container {
    display: none;
}

.progress-bar {
    height: 6px;
    background: var(--bg-secondary);
    border-radius: 10px;
    margin-bottom: 30px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 10px;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0%;
}

.progress-text {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 25px;
    font-weight: 700;
    font-size: 0.95em;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.question {
    margin-bottom: 35px;
}

.question h3 {
    color: var(--text-primary);
    font-size: 1.6em;
    margin-bottom: 30px;
    text-align: center;
    font-weight: 700;
    line-height: 1.4;
}

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

.answer-btn {
    background: var(--bg-secondary);
    border: 2px solid var(--border);
    padding: 22px 25px;
    border-radius: 16px;
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
    font-size: 1.05em;
    color: var(--text-primary);
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

.answer-btn::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background: var(--accent-gradient);
    transform: scaleY(0);
    transition: var(--transition);
}

.answer-btn:hover {
    border-color: var(--primary);
    transform: translateX(8px);
    background: var(--bg-card);
    box-shadow: 0 4px 12px var(--shadow);
}

.answer-btn:hover::before {
    transform: scaleY(1);
}

.answer-btn.selected {
    border: 3px solid var(--primary);
    background: var(--bg-card);
    color: var(--text-primary);
    transform: translateX(8px);
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.4);
    font-weight: 600;
}

.answer-btn.selected::before {
    transform: scaleY(1);
}

.navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 40px;
    gap: 15px;
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 2px solid var(--border);
    box-shadow: none;
}

.btn-secondary:hover {
    background: var(--bg-card);
    border-color: var(--primary);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.2);
}

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

.btn:disabled:hover {
    transform: none;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.result-screen {
    display: none;
    animation: fadeIn 0.6s ease;
}

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

.result-type {
    font-size: 2.8em;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 25px;
    font-weight: 800;
    text-align: center;
}

.result-description {
    color: var(--text-secondary);
    font-size: 1.25em;
    margin-bottom: 35px;
    line-height: 1.8;
    text-align: center;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.result-section {
    background: var(--bg-secondary);
    padding: 30px;
    border-radius: 16px;
    margin-bottom: 20px;
    border: 2px solid var(--border);
    transition: var(--transition);
}

.result-section:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px var(--shadow);
    border-color: var(--primary);
}

.result-section h4 {
    color: var(--primary);
    margin-bottom: 18px;
    font-size: 1.4em;
    font-weight: 700;
}

.result-section ul {
    list-style: none;
    padding-left: 0;
}

.result-section li {
    padding: 10px 0;
    color: var(--text-primary);
    position: relative;
    padding-left: 30px;
    font-size: 1.05em;
}

.result-section li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--success);
    font-weight: bold;
    font-size: 1.2em;
}

.result-focus {
    background: var(--accent-gradient);
    color: white;
    padding: 30px;
    border-radius: 16px;
    margin-top: 35px;
    font-size: 1.2em;
    font-weight: 600;
    text-align: center;
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
}

.footer {
    background: var(--bg-secondary);
    padding: 30px 40px;
    text-align: center;
    border-top: 2px solid var(--border);
}

.footer-links {
    margin-bottom: 15px;
}

.footer-links a {
    margin: 0px 15px;
    color: var(--primary);
}

.footer a {
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.footer a:hover {
    color: var(--primary-hover);
}

.footer-copyright {
    color: var(--text-secondary);
    font-size: 0.95em;
    margin-top: 15px;
     text-decoration: none;
}

.footer-copyright a:hover {
    color: var(--primary)
}

.footer-link {
    color: var(--text-secondary);
    font-weight: 600;
}

.footer-link:hover {
    color: var(--primary)
}

@media (max-width: 768px) {
    body {
        padding: 0;
    }

    .language-selector {
        top: 15px;
        left: 15px;
        z-index: 2000;
    }

    #languageSelect {
        font-size: 0.85em;
        padding: 8px 12px;
        padding-right: 32px;
    }

    .theme-toggle {
        top: 15px;
        right: 15px;
        z-index: 2000;
    }

    #themeToggle {
        width: 48px;
        height: 48px;
        box-shadow: 0 2px 8px var(--shadow);
    }

    .container {
        margin: 70px 10px 10px;
        border-radius: 20px;
    }

    .header {
        padding: 40px 20px;
    }

    .header h1 {
        font-size: 2.2em;
        margin-bottom: 8px;
    }

    .header p {
        font-size: 1.1em;
    }

    .content {
        padding: 30px 20px;
    }

    .start-screen h2 {
        font-size: 1.8em;
        margin-bottom: 15px;
    }

    .start-screen p {
        font-size: 1.05em;
        margin-bottom: 30px;
    }

    .progress-text {
        font-size: 0.85em;
        margin-bottom: 20px;
    }

    .progress-bar {
        height: 5px;
        margin-bottom: 25px;
    }

    .question h3 {
        font-size: 1.25em;
        margin-bottom: 25px;
        line-height: 1.5;
    }

    .answers {
        gap: 12px;
    }

    .answer-btn {
        padding: 18px 18px;
        font-size: 0.95em;
        border-radius: 14px;
    }

    .answer-btn:hover {
        transform: translateX(4px);
    }

    .answer-btn.selected {
        transform: translateX(4px);
    }

    .navigation {
        flex-direction: column;
        gap: 12px;
        margin-top: 30px;
    }

    .btn {
        width: 100%;
        padding: 14px 32px;
        font-size: 1em;
    }

    .result-type {
        font-size: 2em;
        margin-bottom: 20px;
    }

    .result-description {
        font-size: 1.1em;
        margin-bottom: 30px;
    }

    .result-section {
        padding: 25px 20px;
        margin-bottom: 15px;
        border-radius: 14px;
    }

    .result-section h4 {
        font-size: 1.2em;
        margin-bottom: 15px;
    }

    .result-section li {
        font-size: 1em;
        padding: 8px 0;
        padding-left: 28px;
    }

    .result-focus {
        padding: 25px 20px;
        font-size: 1.1em;
        margin-top: 25px;
        border-radius: 14px;
    }

    .footer {
        padding: 25px 20px;
    }

    .footer-links {
        margin-bottom: 12px;
    }

    .footer a {
        margin: 0 10px;
        font-size: 0.95em;
    }

    .footer-copyright {
        font-size: 0.85em;
    }
}

@media (max-width: 480px) {
    .container {
        margin: 70px 5px 5px;
        border-radius: 16px;
    }

    .header {
        padding: 30px 15px;
    }

    .header h1 {
        font-size: 1.8em;
    }

    .header p {
        font-size: 1em;
    }

    .content {
        padding: 25px 15px;
    }

    .answer-btn {
        padding: 16px 15px;
        font-size: 0.9em;
    }

    .result-section {
        padding: 20px 15px;
    }
}
