*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background: #f5f7fb;
    color: #1e293b;
    line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; height: auto; display: block; }

.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.muted { color: #94a3b8; font-size: 14px; }

/* ===================== BUTTONS ===================== */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 10px 24px; border-radius: 10px;
    font-size: 14px; font-weight: 600;
    border: none; cursor: pointer;
    transition: background .2s, transform .1s;
}
.btn:active { transform: scale(.97); }
.btn-green { background: #16a34a; color: #fff; }
.btn-green:hover { background: #15803d; }
.btn-white { background: #fff; color: #2563eb; border: 2px solid #e2e8f0; }
.btn-white:hover { border-color: #2563eb; }
.btn-blue, .btn-primary { background: #2563eb; color: #fff; }
.btn-blue:hover, .btn-primary:hover { background: #1d4ed8; }
.btn-lg { padding: 14px 36px; font-size: 16px; border-radius: 12px; }
.btn-block { width: 100%; }
.btn-outline-sm {
    background: transparent; color: #64748b;
    border: 1px solid #cbd5e1; border-radius: 8px;
    padding: 6px 14px; font-size: 13px;
}

/* ===================== HEADER ===================== */
.header {
    background: #2563eb;
    color: #fff;
    position: sticky; top: 0; z-index: 50;
}
.header-inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 60px; gap: 16px;
}
.header-brand { display: flex; align-items: center; gap: 10px; }
.header-logo { width: 36px; height: 36px; border-radius: 8px; }
.header-name { font-weight: 800; font-size: 20px; color: #fff; }

.header-nav { display: flex; gap: 24px; }
.nav-link { font-size: 14px; font-weight: 500; color: rgba(255,255,255,.8); transition: color .2s; }
.nav-link:hover { color: #fff; }

.header-actions { display: flex; gap: 8px; }
.header-actions .btn-white { padding: 8px 18px; font-size: 13px; border-color: rgba(255,255,255,.3); color: #fff; background: transparent; }
.header-actions .btn-white:hover { background: rgba(255,255,255,.15); }
.header-actions .btn-green { padding: 8px 18px; font-size: 13px; }

/* ===================== SCROLL PROGRESS BAR ===================== */
.scroll-progress {
    position: fixed; top: 0; left: 0;
    height: 3px; width: 0;
    background: linear-gradient(90deg, #16a34a, #2563eb, #8b5cf6);
    z-index: 999;
    transition: width .1s linear;
    border-radius: 0 2px 2px 0;
}

/* ===================== HERO ===================== */
.hero {
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 50%, #60a5fa 100%);
    color: #fff;
    padding: 60px 0 80px;
    overflow: hidden;
    position: relative;
}

/* Decorative hero circles */
.hero::before,
.hero::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}
.hero::before {
    width: 400px; height: 400px;
    background: rgba(255,255,255,.06);
    top: -120px; right: -80px;
}
.hero::after {
    width: 250px; height: 250px;
    background: rgba(255,255,255,.05);
    bottom: -60px; left: -50px;
}

.hero-inner {
    display: flex; align-items: center; justify-content: space-between; gap: 40px;
    position: relative; z-index: 1;
}
.hero-text { flex: 1; max-width: 560px; }
.hero-text h1 {
    font-size: 42px; font-weight: 800; line-height: 1.15;
    margin-bottom: 16px;
}
.hero-sub {
    font-size: 18px; opacity: .85; margin-bottom: 32px;
}
.hero-visual { flex: 0 0 300px; text-align: center; }
.hero-img {
    width: 260px;
    filter: drop-shadow(0 12px 32px rgba(0,0,0,.3));
    animation: float 4s ease-in-out infinite;
}
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

/* ===================== WAVE DIVIDERS ===================== */
.wave-divider { line-height: 0; margin-top: -1px; }
.wave-divider svg { display: block; width: 100%; height: 60px; }
.wave-hero { background: linear-gradient(135deg, #2563eb 0%, #3b82f6 50%, #60a5fa 100%); }
.wave-features { background: #fff; }
.wave-stats { background: #f0f7ff; }

/* ===================== FEATURES ===================== */
.section-features { padding: 64px 0; background: #fff; }
.section-title {
    text-align: center; font-size: 28px; font-weight: 700;
    margin-bottom: 40px; color: #1e293b;
}
.features-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
}
.fcard {
    background: #fff; border: 1px solid #e2e8f0;
    border-radius: 16px; padding: 28px 20px;
    text-align: center;
    transition: transform .2s, box-shadow .2s, opacity .6s ease;
}
.fcard.visible:hover { transform: translateY(-6px); box-shadow: 0 12px 32px rgba(37,99,235,.12); }
.fcard-icon {
    width: 64px; height: 64px; border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px;
}
.fcard h3 { font-size: 16px; font-weight: 700; margin-bottom: 8px; color: #1e293b; }
.fcard p { font-size: 13px; color: #64748b; line-height: 1.5; }

/* ===================== STATS ===================== */
.section-stats {
    padding: 56px 0;
    background: #f0f7ff;
}
.stats-grid {
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
}
.stat-item {
    text-align: center;
}
.stat-number {
    display: inline-block;
    font-size: 48px;
    font-weight: 800;
    color: #2563eb;
    line-height: 1;
}
.stat-plus {
    font-size: 36px;
    font-weight: 800;
    color: #2563eb;
}
.stat-label {
    display: block;
    margin-top: 8px;
    font-size: 15px;
    color: #64748b;
    font-weight: 500;
}

/* ===================== LEVELS ===================== */
.section-levels { padding: 64px 0; background: #f5f7fb; }
.levels-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.lcard {
    border-radius: 14px; padding: 28px 16px;
    text-align: center; color: #fff;
    transition: transform .3s, box-shadow .3s, opacity .6s ease;
    cursor: default;
}
.lcard.visible:hover { transform: translateY(-6px) scale(1.04); }
.lcard-lvl { display: block; font-size: 32px; font-weight: 800; }
.lcard-txt { display: block; font-size: 12px; font-weight: 500; margin-top: 4px; opacity: .9; }

.lcard-a1 { background: linear-gradient(135deg, #ef4444, #f97316); }
.lcard-a2 { background: linear-gradient(135deg, #f97316, #eab308); }
.lcard-b1 { background: linear-gradient(135deg, #eab308, #84cc16); }
.lcard-b2 { background: linear-gradient(135deg, #22c55e, #14b8a6); }
.lcard-c1 { background: linear-gradient(135deg, #06b6d4, #3b82f6); }
.lcard-c2 { background: linear-gradient(135deg, #6366f1, #8b5cf6); }

.lcard-a1:hover { box-shadow: 0 8px 30px rgba(239,68,68,.45); }
.lcard-a2:hover { box-shadow: 0 8px 30px rgba(249,115,22,.45); }
.lcard-b1:hover { box-shadow: 0 8px 30px rgba(234,179,8,.4); }
.lcard-b2:hover { box-shadow: 0 8px 30px rgba(34,197,94,.4); }
.lcard-c1:hover { box-shadow: 0 8px 30px rgba(6,182,212,.4); }
.lcard-c2:hover { box-shadow: 0 8px 30px rgba(99,102,241,.45); }

/* ===================== FOOTER ===================== */
.footer {
    padding: 48px 0 0;
    font-size: 14px; color: #64748b;
    border-top: 1px solid #e2e8f0; background: #fff;
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 32px;
}
.footer-brand {
    display: flex; align-items: center; gap: 10px;
    margin-bottom: 12px;
}
.footer-logo { width: 32px; height: 32px; border-radius: 8px; }
.footer-name { font-size: 18px; font-weight: 800; color: #1e293b; }
.footer-desc { font-size: 13px; color: #94a3b8; line-height: 1.6; max-width: 300px; }
.footer-heading { font-size: 14px; font-weight: 700; color: #1e293b; margin-bottom: 12px; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: #64748b; font-size: 13px; transition: color .2s; }
.footer-links a:hover { color: #2563eb; }
.footer-socials { display: flex; gap: 12px; margin-top: 16px; }
.social-link {
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 10px; background: #f1f5f9;
    color: #64748b; transition: all .2s;
}
.social-link:hover { background: #2563eb; color: #fff; }
.footer-bottom {
    text-align: center;
    padding: 20px 0;
    font-size: 13px;
    color: #94a3b8;
    border-top: 1px solid #e2e8f0;
}

/* ===================== REVEAL ANIMATIONS ===================== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity .6s ease, transform .6s ease;
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===================== MODALS ===================== */
.modal-overlay {
    position: fixed; inset: 0;
    background: rgba(15,23,42,.5);
    backdrop-filter: blur(4px);
    z-index: 200;
    display: flex; align-items: center; justify-content: center;
    padding: 16px;
}
.modal-box {
    background: #fff; border-radius: 20px;
    padding: 36px 32px; width: 100%; max-width: 420px;
    box-shadow: 0 24px 64px rgba(0,0,0,.18);
    position: relative;
}
.modal-close {
    position: absolute; top: 14px; right: 18px;
    background: none; border: none;
    font-size: 24px; color: #94a3b8; cursor: pointer;
}
.modal-close:hover { color: #475569; }
.modal-title { font-size: 24px; font-weight: 700; margin-bottom: 8px; color: #1e293b; }
.modal-subtitle { font-size: 14px; color: #64748b; margin-bottom: 24px; }

.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 13px; font-weight: 600; color: #475569; margin-bottom: 6px; }
.form-input {
    width: 100%; padding: 12px 14px;
    border: 2px solid #e2e8f0; border-radius: 10px;
    font-size: 15px; background: #f8fafc; color: #1e293b;
    outline: none; transition: border-color .2s;
}
.form-input:focus { border-color: #2563eb; background: #fff; }
.form-input[readonly] { background: #f1f5f9; color: #94a3b8; cursor: default; }
.form-error { font-size: 12px; color: #ef4444; margin-top: 4px; }
.form-link {
    display: inline-block; margin-top: 16px;
    font-size: 14px; color: #2563eb; cursor: pointer;
}
.form-link:hover { text-decoration: underline; }

/* ===================== APP HEADER ===================== */
.app-header { background: #2563eb; color: #fff; }
.app-header-inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 56px; padding: 0 20px;
}
.app-header-left { display: flex; align-items: center; gap: 12px; }
.app-header-left .header-name { font-size: 18px; }
.app-header-right { display: flex; align-items: center; gap: 12px; }

/* Level dropdown in header */
.level-dropdown {
    appearance: none; -webkit-appearance: none;
    background: rgba(255,255,255,.15);
    color: #fff; border: 1px solid rgba(255,255,255,.3);
    border-radius: 8px; padding: 6px 32px 6px 12px;
    font-size: 13px; font-weight: 700; font-family: inherit;
    cursor: pointer; outline: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    transition: background .2s;
}
.level-dropdown:hover { background: rgba(255,255,255,.25); }
.level-dropdown:focus { border-color: rgba(255,255,255,.6); }
.level-dropdown option { color: #1e293b; background: #fff; }

/* Profile icon */
.profile-icon {
    width: 36px; height: 36px;
    border-radius: 50%; border: 2px solid rgba(255,255,255,.4);
    background: rgba(255,255,255,.15);
    color: #fff; font-size: 15px; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; transition: all .2s;
}
.profile-icon:hover { background: rgba(255,255,255,.3); border-color: #fff; }

/* Burger */
.burger {
    width: 36px; height: 36px;
    background: rgba(255,255,255,.15); border: none; border-radius: 8px;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 4px; padding: 8px; cursor: pointer;
    transition: background .2s;
}
.burger:hover { background: rgba(255,255,255,.25); }
.burger span {
    display: block; width: 18px; height: 2px;
    background: #fff; border-radius: 2px;
    transition: transform .25s, opacity .25s;
}
.burger.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Sidebar */
.sidebar-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,.3);
    z-index: 39; display: none;
}
.sidebar-overlay.show { display: block; }

.sidebar {
    position: fixed; top: 56px; left: 0; bottom: 0;
    width: 260px; background: #fff;
    border-right: 1px solid #e2e8f0;
    z-index: 40;
    transform: translateX(-100%);
    transition: transform .25s ease;
    box-shadow: 4px 0 16px rgba(0,0,0,.06);
}
.sidebar.open { transform: translateX(0); }
.sidebar-nav { padding: 12px 0; }

.sidebar-link {
    display: flex; align-items: center; gap: 12px;
    width: 100%; padding: 14px 24px;
    background: none; border: none;
    font-size: 15px; color: #475569;
    cursor: pointer; text-align: left;
    transition: background .15s, color .15s;
    border-left: 3px solid transparent;
}
.sidebar-link:hover { background: #eff6ff; color: #2563eb; }
.sidebar-link.active {
    background: #eff6ff; color: #2563eb;
    font-weight: 700; border-left-color: #2563eb;
}
.sl-icon { display: flex; align-items: center; width: 20px; }
.sidebar-divider { height: 1px; background: #e2e8f0; margin: 8px 24px; }

/* App content */
.app-content { padding: 28px 24px; max-width: 960px; margin: 0 auto; }
.page h2 { font-size: 24px; font-weight: 700; color: #1e293b; margin-bottom: 8px; }
.page-hint { font-size: 14px; color: #64748b; margin-bottom: 20px; }

/* ===================== STUDY INTRO ===================== */
.study-intro {
    text-align: center;
    padding: 48px 24px;
    max-width: 520px;
    margin: 0 auto;
}
.study-intro-icon { margin-bottom: 20px; }
.study-intro h2 { font-size: 28px; margin-bottom: 12px; }
.study-level-badge {
    display: inline-block;
    background: #eff6ff; color: #2563eb;
    font-size: 14px; font-weight: 700;
    padding: 6px 18px; border-radius: 20px;
    margin-bottom: 20px;
}
.study-intro-desc {
    font-size: 15px; color: #64748b; line-height: 1.7;
    margin-bottom: 28px;
}
.study-stats {
    font-size: 13px; color: #94a3b8;
    margin-bottom: 24px;
}
.study-stats span { font-weight: 700; color: #2563eb; }

.study-intro-actions {
    display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; align-items: center;
}
.study-reset-btn { margin-top: 0; }

.study-empty .study-reset-btn { margin-top: 16px; }

/* ===================== STUDY CARDS ===================== */
.study-cards-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 20px;
}
.study-cards-header h2 { margin-bottom: 0; }
.study-cards-level {
    font-size: 14px; font-weight: 700;
    background: #eff6ff; color: #2563eb;
    padding: 2px 10px; border-radius: 6px;
    margin-left: 8px;
}
.study-cards-list { display: flex; flex-direction: column; gap: 16px; }
.study-cards-footer { margin-top: 28px; text-align: center; }

/* Word card */
.word-card {
    display: flex; align-items: center; gap: 16px;
    background: #fff; border: 1px solid #e2e8f0;
    border-radius: 14px; padding: 20px;
    transition: box-shadow .2s;
}
.word-card:hover { box-shadow: 0 4px 16px rgba(37,99,235,.08); }

.word-card-left {
    flex: 1; min-width: 0;
}
.word-kz {
    font-size: 20px; font-weight: 700; color: #1e293b;
    margin-bottom: 4px;
}
.word-play-btn {
    background: none; border: none; cursor: pointer;
    color: #2563eb; padding: 4px;
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 12px; font-weight: 600;
    transition: color .2s;
}
.word-play-btn:hover { color: #1d4ed8; }

.word-card-img {
    width: 90px; height: 90px;
    border-radius: 12px; object-fit: cover;
    background: #f1f5f9; flex-shrink: 0;
    order: 3;
}
.word-card-img-placeholder {
    width: 90px; height: 90px;
    border-radius: 12px; background: #f1f5f9;
    display: flex; align-items: center; justify-content: center;
    color: #cbd5e1; flex-shrink: 0;
    order: 3;
}

.word-card-right {
    flex: 0 0 auto; min-width: 0;
    order: 2;
}
.word-ru {
    font-size: 17px; font-weight: 600; color: #2563eb;
}
.word-ru {
    font-size: 18px; font-weight: 600; color: #16a34a;
}

.study-empty {
    text-align: center; padding: 40px 20px;
    color: #64748b;
}
.study-empty svg { margin-bottom: 12px; }
.study-empty p { font-size: 15px; }

/* ===================== TEST ===================== */
.test-counter {
    font-size: 14px; font-weight: 700; color: #64748b;
    background: #f1f5f9; padding: 4px 14px; border-radius: 8px;
}
.test-area { max-width: 600px; margin: 0 auto; }
.test-question {
    background: #fff; border: 1px solid #e2e8f0;
    border-radius: 16px; padding: 32px; text-align: center;
}
.test-word-kz {
    font-size: 32px; font-weight: 800; color: #1e293b;
    margin-bottom: 8px;
}
.test-hint {
    font-size: 13px; color: #94a3b8; margin-bottom: 24px;
}
.test-options {
    display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
}
.test-option {
    padding: 14px 16px; border-radius: 12px;
    border: 2px solid #e2e8f0; background: #fff;
    font-size: 16px; font-weight: 600; color: #1e293b;
    cursor: pointer; transition: all .2s;
    text-align: center;
}
.test-option:hover { border-color: #2563eb; background: #eff6ff; }
.test-option.correct {
    border-color: #16a34a; background: #dcfce7; color: #15803d;
}
.test-option.wrong {
    border-color: #ef4444; background: #fef2f2; color: #dc2626;
}
.test-option.disabled { pointer-events: none; opacity: .7; }

.test-result {
    text-align: center; padding: 48px 24px;
    max-width: 480px; margin: 0 auto;
}
.test-result-score {
    width: 120px; height: 120px;
    border-radius: 50%;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    margin: 0 auto 24px;
    font-size: 36px; font-weight: 800;
}
.test-result-score.good { background: #dcfce7; color: #16a34a; }
.test-result-score.ok { background: #fef3c7; color: #d97706; }
.test-result-score.bad { background: #fef2f2; color: #ef4444; }
.test-result-score small { font-size: 14px; font-weight: 600; }
.test-result h3 { font-size: 22px; font-weight: 700; margin-bottom: 8px; }
.test-result p { font-size: 15px; color: #64748b; margin-bottom: 24px; }
.test-result-actions { display: flex; gap: 12px; justify-content: center; }

/* ===================== PROGRESS ===================== */
.progress-overall {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
    margin-bottom: 32px;
}
.progress-stat-card {
    display: flex; align-items: center; gap: 16px;
    background: #fff; border: 1px solid #e2e8f0;
    border-radius: 14px; padding: 20px;
}
.psc-icon {
    width: 48px; height: 48px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.psc-blue { background: #eff6ff; color: #2563eb; }
.psc-green { background: #dcfce7; color: #16a34a; }
.psc-purple { background: #ede9fe; color: #7c3aed; }
.psc-data { display: flex; flex-direction: column; }
.psc-value { font-size: 24px; font-weight: 800; color: #1e293b; line-height: 1.1; }
.psc-label { font-size: 12px; color: #94a3b8; font-weight: 500; margin-top: 2px; }

.progress-section-title {
    font-size: 18px; font-weight: 700; color: #1e293b;
    margin-bottom: 16px;
}
.progress-levels {
    display: flex; flex-direction: column; gap: 12px;
}

/* Level progress card */
.plevel-card {
    background: #fff; border: 1px solid #e2e8f0;
    border-radius: 14px; padding: 20px 24px;
    transition: box-shadow .2s;
}
.plevel-card:hover { box-shadow: 0 4px 16px rgba(37,99,235,.06); }
.plevel-top {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 12px;
}
.plevel-badge {
    font-size: 15px; font-weight: 800; color: #fff;
    padding: 4px 14px; border-radius: 8px;
}
.plevel-badge.A1 { background: linear-gradient(135deg, #ef4444, #f97316); }
.plevel-badge.A2 { background: linear-gradient(135deg, #f97316, #eab308); }
.plevel-badge.B1 { background: linear-gradient(135deg, #eab308, #84cc16); }
.plevel-badge.B2 { background: linear-gradient(135deg, #22c55e, #14b8a6); }
.plevel-badge.C1 { background: linear-gradient(135deg, #06b6d4, #3b82f6); }
.plevel-badge.C2 { background: linear-gradient(135deg, #6366f1, #8b5cf6); }
.plevel-nums {
    font-size: 13px; color: #64748b;
}
.plevel-nums span { font-weight: 700; color: #1e293b; }

.plevel-bars { display: flex; flex-direction: column; gap: 8px; }
.plevel-bar-row {
    display: flex; align-items: center; gap: 10px;
}
.plevel-bar-label {
    font-size: 12px; font-weight: 600; color: #64748b;
    width: 70px; flex-shrink: 0;
}
.plevel-bar-track {
    flex: 1; height: 10px;
    background: #f1f5f9; border-radius: 5px;
    overflow: hidden;
}
.plevel-bar-fill {
    height: 100%; border-radius: 5px;
    transition: width .6s ease;
}
.plevel-bar-fill.bar-blue { background: linear-gradient(90deg, #3b82f6, #2563eb); }
.plevel-bar-fill.bar-green { background: linear-gradient(90deg, #22c55e, #16a34a); }
.plevel-bar-pct {
    font-size: 12px; font-weight: 700; color: #1e293b;
    width: 36px; text-align: right; flex-shrink: 0;
}

.plevel-toggle {
    margin-left: 8px;
    border: none;
    background: transparent;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: #64748b;
    cursor: pointer;
    padding: 2px 4px;
}
.plevel-toggle:hover { color: #2563eb; }
.plevel-toggle-icon {
    font-size: 10px;
    transition: transform .2s;
}

.plevel-words {
    display: none;
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px dashed #e2e8f0;
}
.plevel-words ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 4px 12px;
}
.plevel-words li {
    font-size: 13px;
    color: #475569;
}
.pw-kz { font-weight: 600; color: #1e293b; }
.pw-sep { margin: 0 4px; color: #94a3b8; }
.pw-ru { color: #2563eb; }

.progress-empty {
    text-align: center; padding: 40px; color: #64748b;
}

/* ===================== PROFILE ===================== */
.profile-card {
    display: flex; gap: 32px; align-items: flex-start;
    background: #fff; border: 1px solid #e2e8f0;
    border-radius: 16px; padding: 32px;
    margin-bottom: 32px;
}
.profile-avatar {
    width: 72px; height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    color: #fff; font-size: 28px; font-weight: 800;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.profile-form { flex: 1; }
.form-row { display: flex; gap: 16px; }
.form-row .form-group { flex: 1; }
.profile-msg {
    margin-top: 12px; font-size: 13px; font-weight: 600;
}
.profile-msg.success { color: #16a34a; }
.profile-msg.error { color: #ef4444; }

.profile-levels-section h3 {
    font-size: 18px; font-weight: 700; color: #1e293b;
    margin-bottom: 16px;
}
.profile-levels {
    display: flex; flex-wrap: wrap; gap: 10px;
}
.profile-level-tag {
    padding: 8px 20px; border-radius: 10px;
    font-size: 14px; font-weight: 700;
    color: #fff; text-align: center;
}
.profile-level-tag.A1 { background: linear-gradient(135deg, #ef4444, #f97316); }
.profile-level-tag.A2 { background: linear-gradient(135deg, #f97316, #eab308); }
.profile-level-tag.B1 { background: linear-gradient(135deg, #eab308, #84cc16); }
.profile-level-tag.B2 { background: linear-gradient(135deg, #22c55e, #14b8a6); }
.profile-level-tag.C1 { background: linear-gradient(135deg, #06b6d4, #3b82f6); }
.profile-level-tag.C2 { background: linear-gradient(135deg, #6366f1, #8b5cf6); }

/* ===================== RESPONSIVE — TABLET ===================== */
@media (max-width: 1024px) {
    .hero-text h1 { font-size: 32px; }
    .hero-visual { flex: 0 0 220px; }
    .hero-img { width: 200px; }
    .features-grid { grid-template-columns: repeat(2, 1fr); }
    .levels-grid { grid-template-columns: repeat(3, 1fr); }
    .stats-grid { gap: 40px; }
    .stat-number { font-size: 40px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

/* ===================== RESPONSIVE — MOBILE ===================== */
@media (max-width: 640px) {
    .container { padding: 0 16px; }

    .header-inner { height: 52px; }
    .header-nav { display: none; }
    .header-name { font-size: 16px; }
    .header-actions .btn-white { padding: 7px 14px; font-size: 12px; border-color: rgba(255,255,255,.4); }
    .header-actions .btn-green { padding: 7px 14px; font-size: 12px; }

    .hero { padding: 40px 0 50px; }
    .hero-inner { flex-direction: column; text-align: center; }
    .hero-text h1 { font-size: 26px; }
    .hero-sub { font-size: 15px; }
    .hero-visual { flex: none; }
    .hero-img { width: 160px; margin: 0 auto; }

    .features-grid { grid-template-columns: 1fr; gap: 16px; }
    .fcard { padding: 20px 16px; }

    .levels-grid { grid-template-columns: repeat(3, 1fr); gap: 10px; }
    .lcard { padding: 20px 8px; }
    .lcard-lvl { font-size: 24px; }

    .stats-grid { gap: 24px; }
    .stat-number { font-size: 36px; }
    .stat-plus { font-size: 28px; }
    .stat-label { font-size: 13px; }

    .modal-box { padding: 28px 20px; border-radius: 16px; }

    .app-content { padding: 20px 16px; }

    /* Progress mobile */
    .progress-overall { grid-template-columns: 1fr; gap: 10px; }
    .progress-stat-card { padding: 16px; }
    .psc-value { font-size: 20px; }
    .plevel-card { padding: 16px; }
    .plevel-bar-label { width: 56px; font-size: 11px; }

    /* Test mobile */
    .test-options { grid-template-columns: 1fr; }
    .test-word-kz { font-size: 24px; }
    .test-result-actions { flex-direction: column; }

    /* Word cards mobile — image right, bigger */
    .word-card {
        display: grid;
        grid-template-columns: 1fr auto;
        grid-template-rows: auto auto;
        gap: 6px 14px;
        padding: 16px;
    }
    .word-card-left { grid-column: 1; grid-row: 1; }
    .word-card-right { grid-column: 1; grid-row: 2; text-align: left; }
    .word-card-img, .word-card-img-placeholder {
        grid-column: 2; grid-row: 1 / 3;
        width: 86px; height: 86px;
        align-self: center;
    }
    .word-kz { font-size: 18px; }
    .word-ru { font-size: 15px; }

    /* Profile mobile */
    .profile-card { flex-direction: column; align-items: center; text-align: center; gap: 20px; padding: 24px 20px; }
    .form-row { flex-direction: column; gap: 0; }

    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
    .footer { padding: 32px 0 0; }

    .wave-divider svg { height: 40px; }

    .hide-mobile { display: none; }
}
