:root {
    --primary: #4f46e5;
    --primary-dark: #312e81;
    --primary-light: #eef2ff;
    --accent: #22d3ee;
    --dark: #0f172a;
    --muted: #64748b;
    --border: #e2e8f0;
    --radius: 14px;
}

/* Data-analysis question components */
.ait-data-card {
    margin: 0.9rem 0;
    padding: 1rem;
    border: 1px solid rgba(71, 85, 105, 0.18);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06);
    overflow-x: auto;
}

.ait-data-caption {
    margin: 0 0 0.7rem;
    color: #334155;
    font-weight: 800;
    line-height: 1.4;
}

.ait-data-table {
    width: 100%;
    min-width: 420px;
    border-collapse: collapse;
    color: #1e293b;
    font-variant-numeric: tabular-nums;
}

.ait-data-table th,
.ait-data-table td {
    padding: 0.58rem 0.7rem;
    border: 1px solid rgba(100, 116, 139, 0.25);
    text-align: center;
    vertical-align: middle;
}

.ait-data-table th {
    background: rgba(99, 102, 241, 0.1);
    font-weight: 800;
}

.ait-mini-bars {
    display: grid;
    gap: 0.7rem;
    min-width: 360px;
}

.ait-bar-row {
    display: grid;
    grid-template-columns: minmax(82px, 0.9fr) minmax(180px, 3fr) 58px;
    gap: 0.7rem;
    align-items: center;
}

.ait-bar-label,
.ait-bar-value {
    color: #334155;
    font-weight: 750;
    font-variant-numeric: tabular-nums;
}

.ait-bar-value {
    text-align: right;
}

.ait-bar-track {
    height: 18px;
    overflow: hidden;
    border-radius: 999px;
    background: #e2e8f0;
}

.ait-bar-fill {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #6366f1, #22c55e);
}

.ait-line-chart {
    display: block;
    width: 100%;
    min-width: 420px;
    height: auto;
}

.ait-line-chart .grid {
    stroke: #dbe3ef;
    stroke-width: 1;
}

.ait-line-chart .axis {
    stroke: #64748b;
    stroke-width: 1.4;
}

.ait-line-chart .series-a {
    fill: none;
    stroke: #4f46e5;
    stroke-width: 3;
}

.ait-line-chart .series-b {
    fill: none;
    stroke: #e11d48;
    stroke-width: 3;
}

.ait-line-chart circle {
    stroke: #fff;
    stroke-width: 2;
}

.ait-line-chart text {
    fill: #475569;
    font: 12px system-ui, sans-serif;
}

.ait-pie-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
}

.ait-pie-chart {
    flex: 0 0 auto;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    border: 5px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.12);
}

.ait-data-legend {
    display: grid;
    gap: 0.45rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.ait-data-legend li {
    display: flex;
    gap: 0.55rem;
    align-items: center;
    color: #334155;
    font-weight: 700;
}

.ait-legend-swatch {
    width: 14px;
    height: 14px;
    border-radius: 4px;
    flex: 0 0 auto;
}

@media (max-width: 575.98px) {
    .ait-data-card {
        margin-inline: -0.2rem;
        padding: 0.8rem;
    }

    .ait-bar-row {
        grid-template-columns: 78px minmax(150px, 1fr) 50px;
        gap: 0.5rem;
    }

    .ait-pie-chart {
        width: 128px;
        height: 128px;
    }
}

/* Digital-literacy question components */
.ait-digital-card {
    margin: 0.9rem 0;
    padding: 1rem;
    border: 1px solid rgba(71, 85, 105, 0.18);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06);
    color: #1e293b;
}

.ait-digital-label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0 0 0.65rem;
    padding: 0.28rem 0.62rem;
    border-radius: 999px;
    background: rgba(79, 70, 229, 0.1);
    color: #4338ca;
    font-size: 0.78rem;
    font-weight: 850;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.ait-digital-card p:last-child,
.ait-digital-card ul:last-child {
    margin-bottom: 0;
}

.ait-browser-box {
    overflow: hidden;
    padding: 0;
}

.ait-browser-top {
    display: flex;
    gap: 0.38rem;
    align-items: center;
    padding: 0.62rem 0.8rem;
    border-bottom: 1px solid #dbe3ef;
    background: #eef2f7;
}

.ait-browser-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #94a3b8;
}

.ait-address-bar {
    flex: 1;
    min-width: 0;
    margin-left: 0.35rem;
    padding: 0.38rem 0.65rem;
    overflow-wrap: anywhere;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #fff;
    color: #334155;
    font: 0.86rem ui-monospace, SFMono-Regular, Consolas, monospace;
}

.ait-browser-body {
    padding: 0.9rem 1rem 1rem;
}

.ait-search-result + .ait-search-result {
    margin-top: 0.9rem;
    padding-top: 0.9rem;
    border-top: 1px dashed #cbd5e1;
}

.ait-result-title {
    margin: 0 0 0.18rem;
    color: #3730a3;
    font-weight: 850;
}

.ait-result-url {
    margin: 0 0 0.28rem;
    color: #047857;
    font: 0.8rem ui-monospace, SFMono-Regular, Consolas, monospace;
    overflow-wrap: anywhere;
}

.ait-result-snippet {
    margin: 0;
    color: #475569;
    line-height: 1.5;
}

.ait-message-card {
    border-left: 5px solid #f59e0b;
}

.ait-message-meta {
    display: grid;
    gap: 0.35rem;
    margin-bottom: 0.7rem;
    padding-bottom: 0.7rem;
    border-bottom: 1px solid #e2e8f0;
    color: #475569;
    font-size: 0.9rem;
}

.ait-message-body {
    line-height: 1.58;
}

.ait-file-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(135px, 1fr));
    gap: 0.65rem;
}

.ait-file-item {
    min-width: 0;
    padding: 0.72rem;
    border: 1px solid #dbe3ef;
    border-radius: 12px;
    background: #f8fafc;
}

.ait-file-name {
    display: block;
    overflow-wrap: anywhere;
    color: #1e293b;
    font-weight: 800;
}

.ait-file-meta {
    display: block;
    margin-top: 0.2rem;
    color: #64748b;
    font-size: 0.82rem;
}

.ait-permission-list,
.ait-step-list {
    display: grid;
    gap: 0.55rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.ait-permission-list li,
.ait-step-list li {
    display: flex;
    gap: 0.62rem;
    align-items: flex-start;
    padding: 0.62rem 0.7rem;
    border-radius: 10px;
    background: #f1f5f9;
}

.ait-permission-state {
    flex: 0 0 auto;
    padding: 0.1rem 0.42rem;
    border-radius: 999px;
    background: #dcfce7;
    color: #166534;
    font-size: 0.76rem;
    font-weight: 850;
}

.ait-step-number {
    display: inline-grid;
    width: 25px;
    height: 25px;
    flex: 0 0 25px;
    place-items: center;
    border-radius: 8px;
    background: #4f46e5;
    color: #fff;
    font-size: 0.78rem;
    font-weight: 900;
}

.ait-code-line {
    display: block;
    padding: 0.75rem 0.85rem;
    overflow-x: auto;
    border-radius: 10px;
    background: #0f172a;
    color: #e2e8f0;
    font: 0.9rem/1.55 ui-monospace, SFMono-Regular, Consolas, monospace;
    white-space: nowrap;
}

.ait-sheet-wrap {
    overflow-x: auto;
}

.ait-sheet {
    width: 100%;
    min-width: 420px;
    border-collapse: collapse;
    font-variant-numeric: tabular-nums;
}

.ait-sheet th,
.ait-sheet td {
    padding: 0.52rem 0.65rem;
    border: 1px solid #cbd5e1;
    text-align: center;
}

.ait-sheet thead th,
.ait-sheet tbody th {
    background: #e2e8f0;
    color: #334155;
    font-weight: 850;
}

.ait-sheet .ait-cell-active {
    outline: 3px solid #4f46e5;
    outline-offset: -3px;
    background: #eef2ff;
}

.ait-status-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.ait-status-chip {
    padding: 0.35rem 0.62rem;
    border: 1px solid #cbd5e1;
    border-radius: 999px;
    background: #fff;
    color: #334155;
    font-size: 0.82rem;
    font-weight: 800;
}

@media (max-width: 575.98px) {
    .ait-digital-card {
        margin-inline: -0.2rem;
        padding: 0.82rem;
    }

    .ait-browser-body {
        padding: 0.78rem;
    }

    .ait-file-grid {
        grid-template-columns: 1fr 1fr;
    }
}

* { font-family: 'Nunito', sans-serif; }
html { scroll-behavior: smooth; }
body { background: #f8fafc; color: var(--dark); }

.navbar {
    background: rgba(255, 255, 255, .96);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(12px);
}
.navbar-brand {
    color: #2563eb !important;
    font-size: 1.3rem;
    font-weight: 800;
    letter-spacing: -.5px;
}
.brand-accent { color: #f59e0b; }
.nav-link { color: #334155 !important; font-weight: 600; }
.nav-link:hover,
.nav-link.active { color: var(--primary) !important; }
.btn-nav {
    background: var(--primary);
    color: #fff;
    border: 0;
    font-weight: 800;
}
.btn-nav:hover { background: #4338ca; color: #fff; }

.hero {
    position: relative;
    overflow: hidden;
    padding: 84px 0 72px;
    color: #fff;
    background:
        radial-gradient(circle at 88% 16%, rgba(34, 211, 238, .24), transparent 24%),
        linear-gradient(135deg, #1e1b4b 0%, #4338ca 53%, #2563eb 100%);
}
.hero::before {
    content: '';
    position: absolute;
    width: 520px;
    height: 520px;
    right: -190px;
    bottom: -310px;
    border: 70px solid rgba(255, 255, 255, .06);
    border-radius: 50%;
    pointer-events: none;
}
.hero::after {
    content: '';
    position: absolute;
    width: 170px;
    height: 170px;
    top: -92px;
    left: 42%;
    border: 1px solid rgba(255, 255, 255, .18);
    transform: rotate(35deg);
    pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }
.free-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 15px;
    margin-bottom: 20px;
    border: 1px solid rgba(103, 232, 249, .45);
    border-radius: 50px;
    background: rgba(8, 145, 178, .22);
    color: #a5f3fc;
    font-size: .82rem;
    font-weight: 800;
}
.hero h1 {
    max-width: 760px;
    font-size: clamp(2.15rem, 5vw, 3.55rem);
    font-weight: 900;
    line-height: 1.08;
    letter-spacing: -.04em;
}
.hero-lead {
    max-width: 650px;
    margin: 22px 0 28px;
    color: rgba(255, 255, 255, .82);
    font-size: 1.08rem;
    line-height: 1.65;
}
.hero-highlight { color: #67e8f9; }
.hero-note { color: rgba(255, 255, 255, .66); font-size: .88rem; }
.btn-start {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 27px;
    border: none;
    border-radius: 50px;
    background: #fff;
    color: #3730a3;
    font-weight: 900;
    text-decoration: none;
    transition: transform .2s ease, box-shadow .2s ease;
}
.btn-start:hover {
    color: #3730a3;
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(15, 23, 42, .24);
}
.hero-stat {
    min-width: 126px;
    padding: 15px 18px;
    border: 1px solid rgba(255, 255, 255, .09);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, .11);
    backdrop-filter: blur(8px);
}
.hero-stat strong { display: block; font-size: 1.45rem; font-weight: 900; }
.hero-stat span { display: block; color: rgba(255, 255, 255, .68); font-size: .76rem; }

.hero-panel {
    padding: 24px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 24px;
    background: rgba(255, 255, 255, .09);
    box-shadow: 0 24px 70px rgba(15, 23, 42, .18);
    backdrop-filter: blur(10px);
}
.hero-panel-label {
    margin-bottom: 14px;
    color: rgba(255, 255, 255, .56);
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;
}
.skill-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px 14px;
    margin-bottom: 9px;
    border-radius: 12px;
    background: rgba(255, 255, 255, .13);
    font-size: .88rem;
    font-weight: 800;
}
.skill-row:last-child { margin-bottom: 0; }
.skill-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #67e8f9;
    box-shadow: 0 0 0 5px rgba(103, 232, 249, .12);
}
.skill-row small { margin-left: auto; color: #c7d2fe; font-weight: 800; }

.section-title {
    margin: 0;
    color: var(--dark);
    font-size: clamp(1.75rem, 4vw, 2.2rem);
    font-weight: 900;
    letter-spacing: -.035em;
}
.section-sub { max-width: 690px; margin: 10px auto 0; color: var(--muted); }
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 10px;
    color: var(--primary);
    font-size: .74rem;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.category-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 238px;
    padding: 23px;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 20px;
    background: #fff;
    color: var(--dark);
    text-decoration: none;
    box-shadow: 0 10px 34px rgba(15, 23, 42, .045);
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.category-card:hover {
    color: var(--dark);
    border-color: rgba(79, 70, 229, .3);
    box-shadow: 0 19px 48px rgba(79, 70, 229, .11);
    transform: translateY(-4px);
}
.category-card::after {
    content: '';
    position: absolute;
    right: -48px;
    bottom: -61px;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: var(--card-bg);
    opacity: .72;
}
.category-top {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 17px;
}
.category-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 13px;
    background: var(--card-bg);
    color: var(--card-color);
    font-size: 1.25rem;
}
.category-badge {
    padding: 5px 9px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #64748b;
    font-size: .68rem;
    font-weight: 900;
    letter-spacing: .03em;
}
.category-card h2 {
    position: relative;
    z-index: 1;
    margin: 0 0 9px;
    font-size: 1.09rem;
    font-weight: 900;
    letter-spacing: -.02em;
}
.category-card p {
    position: relative;
    z-index: 1;
    margin: 0 0 18px;
    color: var(--muted);
    font-size: .9rem;
    line-height: 1.52;
}
.category-link {
    position: relative;
    z-index: 1;
    margin-top: auto;
    color: var(--card-color);
    font-size: .84rem;
    font-weight: 900;
}
.theme-indigo { --card-color: #4f46e5; --card-bg: #eef2ff; }
.theme-sky { --card-color: #0284c7; --card-bg: #e0f2fe; }
.theme-cyan { --card-color: #0891b2; --card-bg: #cffafe; }
.theme-violet { --card-color: #7c3aed; --card-bg: #f3e8ff; }
.theme-teal { --card-color: #0f766e; --card-bg: #ccfbf1; }
.theme-blue { --card-color: #2563eb; --card-bg: #dbeafe; }
.theme-purple { --card-color: #9333ea; --card-bg: #fae8ff; }
.theme-orange { --card-color: #ea580c; --card-bg: #ffedd5; }
.theme-yellow { --card-color: #ca8a04; --card-bg: #fef9c3; }
.theme-green { --card-color: #16a34a; --card-bg: #dcfce7; }

.diagnostic-wrap {
    background: #fff;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.diagnostic-card {
    position: relative;
    overflow: hidden;
    padding: 34px;
    border: 1px solid #c7d2fe;
    border-radius: 24px;
    background: linear-gradient(135deg, #eef2ff, #ecfeff);
}
.diagnostic-card::after {
    content: '';
    position: absolute;
    top: -70px;
    right: -30px;
    width: 210px;
    height: 210px;
    border: 35px solid rgba(79, 70, 229, .08);
    border-radius: 50%;
}
.diagnostic-card > * { position: relative; z-index: 1; }
.diagnostic-title { font-weight: 900; letter-spacing: -.03em; }
.diagnostic-text { max-width: 720px; }
.btn-primary-ait {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 22px;
    border-radius: 50px;
    background: var(--primary);
    color: #fff;
    font-weight: 900;
    text-decoration: none;
}
.btn-primary-ait:hover { background: #4338ca; color: #fff; }

.step-card {
    height: 100%;
    padding: 25px;
    border: 1px solid var(--border);
    border-radius: 18px;
    background: #fff;
}
.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    margin-bottom: 17px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 900;
}

.sample-section { background: var(--primary-light); }
.question-card {
    max-width: 760px;
    margin: 0 auto;
    padding: 28px;
    border: 1px solid #c7d2fe;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 16px 45px rgba(79, 70, 229, .07);
}
.option-btn {
    display: block;
    width: 100%;
    margin-bottom: 9px;
    padding: 12px 15px;
    border: 1.5px solid var(--border);
    border-radius: 11px;
    background: #f8fafc;
    color: var(--dark);
    text-align: left;
    transition: all .15s ease;
}
.option-btn:hover:not(:disabled) { border-color: var(--primary); background: var(--primary-light); }
.option-btn.correct { border-color: #16a34a; background: #f0fdf4; color: #166534; font-weight: 800; }
.option-btn.wrong { border-color: #dc2626; background: #fef2f2; color: #991b1b; }
.answer-feedback {
    display: none;
    margin-top: 15px;
    padding: 14px 16px;
    border-left: 4px solid #16a34a;
    border-radius: 8px;
    background: #f0fdf4;
    color: #166534;
    font-size: .9rem;
}

.cta-wrap { background: #f8fafc; }
.cta-section {
    position: relative;
    overflow: hidden;
    padding: 48px 24px;
    border-radius: 24px;
    background: linear-gradient(135deg, #1e1b4b, #4338ca);
    color: #fff;
}
.cta-section::after {
    content: '';
    position: absolute;
    width: 240px;
    height: 240px;
    right: -110px;
    top: -120px;
    border-radius: 45px;
    background: rgba(103, 232, 249, .09);
    transform: rotate(25deg);
}
.cta-section > * { position: relative; z-index: 1; }
.cta-badge { width: fit-content; }
.cta-title { font-size: clamp(1.7rem, 4vw, 2.15rem); font-weight: 900; }
.cta-text { max-width: 590px; color: rgba(255, 255, 255, .78); }

footer { background: var(--dark); color: #94a3b8; }
footer a { color: #94a3b8; text-decoration: none; }
footer a:hover { color: #fff; }
.footer-brand { color: #fff; font-size: 1.2rem; font-weight: 900; }
.footer-muted { color: #475569; }
.footer-divider { border-color: #334155; margin-top: 36px; }

@media (max-width: 767.98px) {
    .hero { padding: 62px 0 54px; }
    .hero-lead { font-size: 1rem; }
    .hero-stat { min-width: calc(50% - 8px); }
    .category-card { min-height: auto; padding: 20px; }
    .diagnostic-card,
    .question-card { padding: 22px; }
}

/* Страницы каталогов /ait/tests/ */
.catalog-hero {
    position: relative;
    overflow: hidden;
    padding: 62px 0 58px;
    color: #fff;
    background:
        radial-gradient(circle at 86% 10%, var(--catalog-glow, rgba(103, 232, 249, .22)), transparent 25%),
        linear-gradient(135deg, #1e1b4b 0%, var(--catalog-dark, #3730a3) 52%, var(--catalog-color, #2563eb) 100%);
}
.catalog-hero::after {
    content: '';
    position: absolute;
    width: 350px;
    height: 350px;
    right: -130px;
    bottom: -250px;
    border: 50px solid rgba(255, 255, 255, .06);
    border-radius: 50%;
}
.catalog-hero .container { position: relative; z-index: 1; }
.catalog-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 7px;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, .62);
    font-size: .82rem;
}
.catalog-breadcrumb a { color: #fff; text-decoration: none; }
.catalog-breadcrumb a:hover { text-decoration: underline; }
.catalog-kicker {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 5px 13px;
    margin-bottom: 14px;
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 999px;
    background: rgba(255, 255, 255, .1);
    color: rgba(255, 255, 255, .9);
    font-size: .76rem;
    font-weight: 800;
}
.catalog-hero h1 {
    margin-bottom: 14px;
    font-size: clamp(1.85rem, 4vw, 2.65rem);
    font-weight: 900;
    line-height: 1.13;
    letter-spacing: -.035em;
}
.catalog-hero p {
    max-width: 760px;
    margin: 0;
    color: rgba(255, 255, 255, .8);
    font-size: 1rem;
    line-height: 1.62;
}
.catalog-theme-indigo { --catalog-dark: #3730a3; --catalog-color: #2563eb; --catalog-glow: rgba(103, 232, 249, .22); }
.catalog-theme-sky { --catalog-dark: #075985; --catalog-color: #0284c7; --catalog-glow: rgba(186, 230, 253, .25); }
.catalog-theme-cyan { --catalog-dark: #155e75; --catalog-color: #0891b2; --catalog-glow: rgba(165, 243, 252, .24); }
.catalog-theme-violet { --catalog-dark: #5b21b6; --catalog-color: #7c3aed; --catalog-glow: rgba(221, 214, 254, .23); }
.catalog-theme-teal { --catalog-dark: #115e59; --catalog-color: #0f766e; --catalog-glow: rgba(153, 246, 228, .22); }
.catalog-theme-blue { --catalog-dark: #1e40af; --catalog-color: #2563eb; --catalog-glow: rgba(191, 219, 254, .24); }
.catalog-theme-purple { --catalog-dark: #6b21a8; --catalog-color: #9333ea; --catalog-glow: rgba(240, 171, 252, .22); }
.catalog-theme-orange { --catalog-dark: #9a3412; --catalog-color: #ea580c; --catalog-glow: rgba(254, 215, 170, .24); }
.catalog-theme-yellow { --catalog-dark: #854d0e; --catalog-color: #ca8a04; --catalog-glow: rgba(254, 240, 138, .23); }
.catalog-theme-green { --catalog-dark: #166534; --catalog-color: #16a34a; --catalog-glow: rgba(187, 247, 208, .23); }

.tests-panel {
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 12px 38px rgba(15, 23, 42, .045);
}
.tests-panel-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--border);
    background: #fff;
}
.tests-panel-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 11px;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 1.05rem;
}
.tests-panel-header h2 { margin: 0; font-size: 1.05rem; font-weight: 900; }
.tests-count {
    margin-left: auto;
    padding: 5px 11px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #475569;
    font-size: .75rem;
    font-weight: 800;
}
.tests-panel-body { display: grid; gap: 9px; padding: 14px; background: #f8fafc; }
.test-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 15px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: #fff;
    color: var(--dark);
    text-decoration: none;
    transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.test-item:hover {
    border-color: rgba(79, 70, 229, .35);
    box-shadow: 0 8px 24px rgba(79, 70, 229, .07);
    color: var(--dark);
    transform: translateY(-1px);
}
.test-item-title { margin-bottom: 3px; font-size: .93rem; font-weight: 900; line-height: 1.35; }
.test-item-description { margin-bottom: 5px; color: #475569; font-size: .84rem; line-height: 1.45; }
.test-meta { color: var(--muted); font-size: .76rem; }
.test-item-actions { display: flex; flex-shrink: 0; gap: 8px; }
.test-pill {
    display: inline-flex;
    align-items: center;
    padding: 4px 9px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: #f8fafc;
    color: #334155;
    font-size: .7rem;
    font-weight: 800;
    white-space: nowrap;
}
.test-pill.questions { border-color: #bbf7d0; background: #f0fdf4; color: #166534; }

.catalog-article {
    padding: 32px;
    border: 1px solid var(--border);
    border-radius: 18px;
    background: #fff;
    color: #334155;
    line-height: 1.72;
}
.catalog-article h2,
.catalog-article h3 { color: var(--dark); font-weight: 900; letter-spacing: -.02em; }
.catalog-article h2 { margin: 0 0 15px; font-size: 1.5rem; }
.catalog-article h2:not(:first-child) { margin-top: 30px; }
.catalog-article h3 { margin: 25px 0 12px; font-size: 1.12rem; }
.catalog-article p:last-child { margin-bottom: 0; }
.catalog-skill-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px 18px;
    padding: 0;
    margin: 0;
    list-style: none;
}
.catalog-skill-list li {
    position: relative;
    padding-left: 25px;
}
.catalog-skill-list li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    top: 0;
    color: #16a34a;
    font-weight: 900;
}
.catalog-note {
    padding: 15px 17px;
    margin-top: 24px;
    border-left: 4px solid var(--primary);
    border-radius: 9px;
    background: var(--primary-light);
    color: #3730a3;
    font-size: .9rem;
}

@media (max-width: 767.98px) {
    .catalog-hero { padding: 48px 0 44px; }
    .test-item { display: block; }
    .test-item-actions { margin-top: 11px; }
    .tests-count { margin-left: 0; }
    .catalog-article { padding: 22px; }
    .catalog-skill-list { grid-template-columns: 1fr; }
}

/* Внутренние страницы тестов /ait/test/ */
.ait-test-page { overflow: hidden; }
.ait-quiz-shell {
    position: relative;
    padding: 30px 0 54px;
    overflow: hidden;
    background: linear-gradient(180deg, #f3f5fa 0%, #f8fafc 100%);
}
.ait-quiz-shell > .container { z-index: 1; }
.ait-quiz-bg,
.ait-quiz-bg span { position: absolute; pointer-events: none; }
.ait-quiz-bg { inset: 0; overflow: hidden; }
.ait-quiz-bg span:first-child {
    width: 260px;
    height: 260px;
    top: -140px;
    right: -45px;
    border-radius: 64px;
    background: #a5b4fc;
    opacity: .18;
    filter: blur(8px);
    transform: rotate(30deg);
}
.ait-quiz-bg span:nth-child(2) {
    width: 340px;
    height: 130px;
    left: -155px;
    bottom: -55px;
    background: #67e8f9;
    opacity: .12;
    filter: blur(25px);
    transform: skewX(-20deg) rotate(-8deg);
}
.ait-quiz-bg span:nth-child(3) {
    width: 160px;
    height: 160px;
    right: 18%;
    bottom: -105px;
    border: 25px solid #c4b5fd;
    border-radius: 38px;
    opacity: .14;
    transform: rotate(24deg);
}
.ait-test-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 7px;
    margin: 0 0 16px;
    color: #64748b;
    font-size: .8rem;
}
.ait-test-breadcrumb a { color: #475569; text-decoration: none; }
.ait-test-breadcrumb a:hover { color: var(--primary); text-decoration: underline; }
.ait-test-breadcrumb i { font-size: .65rem; }
.ait-quiz-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
    max-width: 960px;
    margin: 0 auto;
    transition: max-width .2s ease;
}
.ait-quiz-grid.has-explanation {
    grid-template-columns: minmax(0, 1.65fr) minmax(300px, .85fr);
    max-width: 1220px;
}
.ait-quiz-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, .25);
    border-radius: 26px;
    background: rgba(255, 255, 255, .97);
    box-shadow: 0 20px 55px rgba(15, 23, 42, .08);
}
.ait-quiz-toolbar {
    display: grid;
    grid-template-columns: 46px 1fr auto;
    align-items: center;
    gap: 12px;
    min-height: 72px;
    padding: 13px 17px;
    border-bottom: 1px solid #eef2f7;
    background: rgba(248, 250, 252, .75);
}
.ait-quiz-home {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid #cbd5e1;
    border-radius: 13px;
    background: #fff;
    color: #475569;
    text-decoration: none;
    box-shadow: 0 5px 14px rgba(15, 23, 42, .04);
    transition: transform .15s ease, border-color .15s ease, color .15s ease;
}
.ait-quiz-home:hover { color: var(--primary); border-color: #a5b4fc; transform: translateY(-1px); }
.ait-quiz-label {
    justify-self: center;
    padding: 6px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    background: #f1f5f9;
    color: #475569;
    font-size: .68rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.ait-quiz-finish {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 42px;
    padding: 8px 13px;
    border: 1px solid #fecaca;
    border-radius: 12px;
    background: #fff7f7;
    color: #b91c1c;
    font-size: .82rem;
    font-weight: 800;
}
.ait-quiz-finish:hover { border-color: #fca5a5; background: #fef2f2; }
.ait-quiz-heading {
    max-width: 780px;
    padding: 34px 28px 21px;
    margin: 0 auto;
    text-align: center;
}
.ait-quiz-number {
    display: inline-block;
    margin-bottom: 9px;
    color: #7c3aed;
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .09em;
    text-transform: uppercase;
}
.ait-quiz-heading h1 {
    margin: 0;
    font-size: clamp(1.85rem, 4vw, 2.65rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -.04em;
}
.ait-quiz-heading p {
    max-width: 690px;
    margin: 13px auto 0;
    color: #64748b;
    font-size: .98rem;
    line-height: 1.62;
}
.ait-quiz-welcome {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 20px 22px;
    margin: 0 22px 22px;
    border: 1px solid #e2e8f0;
    border-radius: 19px;
    background: linear-gradient(135deg, #f8fafc, #f5f3ff);
}
.ait-quiz-welcome h2 { margin: 0 0 5px; font-size: 1.02rem; font-weight: 900; }
.ait-quiz-welcome p { margin: 0; color: #64748b; font-size: .84rem; line-height: 1.5; }
.ait-quiz-start-area { flex: 0 0 auto; display: grid; justify-items: center; gap: 6px; }
.ait-quiz-start-area small { color: #94a3b8; font-size: .7rem; text-align: center; }
.ait-quiz-start,
.ait-quiz-next,
.ait-quiz-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 10px 19px;
    border-radius: 13px;
    font-weight: 900;
    text-decoration: none;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.ait-quiz-start,
.ait-quiz-next {
    border: 0;
    background: linear-gradient(135deg, #4f46e5, #2563eb);
    color: #fff;
    box-shadow: 0 10px 22px rgba(79, 70, 229, .22);
}
.ait-quiz-start:hover,
.ait-quiz-next:hover { color: #fff; transform: translateY(-1px); box-shadow: 0 13px 28px rgba(79, 70, 229, .28); }
.ait-quiz-secondary { border: 1px solid #cbd5e1; background: #fff; color: #475569; }
.ait-quiz-secondary:hover { border-color: #a5b4fc; color: var(--primary); }
.ait-quiz-secondary:disabled,
.ait-quiz-next:disabled { cursor: not-allowed; opacity: .45; transform: none; }
.ait-quiz-content { padding: 5px 22px 24px; }
.ait-quiz-progress-head { padding: 0 2px 17px; }
.ait-quiz-progress-head > div:first-child { display: flex; justify-content: space-between; gap: 14px; color: #64748b; font-size: .78rem; }
.ait-quiz-progress-head strong { color: #334155; }
.ait-quiz-segments { display: flex; gap: 3px; height: 7px; margin-top: 10px; }
.ait-quiz-segment { flex: 1 1 0; border-radius: 999px; background: #e2e8f0; }
.ait-quiz-segment.is-correct { background: #22c55e; }
.ait-quiz-segment.is-wrong { background: #ef4444; }
.ait-quiz-segment.is-skipped { background: #38bdf8; }
.ait-quiz-question {
    padding: 25px;
    border: 1px solid #dbe3ee;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(15, 23, 42, .045);
}
.ait-quiz-question-text { color: #1e293b; font-size: 1.05rem; font-weight: 800; line-height: 1.65; }
.ait-quiz-question-text p:last-child { margin-bottom: 0; }
.ait-quiz-instruction { margin: 20px 0 10px; color: #64748b; font-size: .8rem; }
.ait-quiz-options { display: grid; gap: 9px; }
.ait-quiz-option {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid #dbe3ee;
    border-radius: 12px;
    background: #f8fafc;
    color: #1e293b;
    text-align: left;
    line-height: 1.45;
    transition: border-color .15s ease, background .15s ease;
}
.ait-quiz-option:hover:not(:disabled) { border-color: #818cf8; background: #f5f3ff; }
.ait-quiz-option:disabled { cursor: default; opacity: 1; }
.ait-quiz-option-letter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 31px;
    width: 31px;
    height: 31px;
    border-radius: 9px;
    background: #e2e8f0;
    color: #475569;
    font-size: .76rem;
    font-weight: 900;
}
.ait-quiz-option.is-correct { border-color: #86efac; background: #f0fdf4; color: #166534; }
.ait-quiz-option.is-correct .ait-quiz-option-letter { background: #22c55e; color: #fff; }
.ait-quiz-option.is-wrong { border-color: #fca5a5; background: #fef2f2; color: #991b1b; }
.ait-quiz-option.is-wrong .ait-quiz-option-letter { background: #ef4444; color: #fff; }
.ait-quiz-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 20px; }
.ait-quiz-explanation {
    align-self: start;
    overflow: hidden;
    border: 1px solid #ddd6fe;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 18px 45px rgba(76, 29, 149, .08);
}
.ait-quiz-explanation-head { display: flex; gap: 12px; padding: 18px; border-bottom: 1px solid #ede9fe; background: #faf5ff; }
.ait-quiz-explanation-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: #ede9fe;
    color: #7c3aed;
}
.ait-quiz-explanation h2 { margin: 0 0 3px; font-size: .95rem; font-weight: 900; }
.ait-quiz-explanation-head p { margin: 0; color: #64748b; font-size: .78rem; }
.ait-quiz-explanation-head p.is-correct { color: #15803d; font-weight: 900; }
.ait-quiz-explanation-head p.is-wrong { color: #dc2626; font-weight: 900; }
.ait-quiz-explanation-body { padding: 19px; color: #475569; font-size: .86rem; line-height: 1.62; }
.ait-quiz-correct-value { padding: 10px 12px; margin: 8px 0 15px; border-radius: 10px; background: #f0fdf4; color: #166534; }
.ait-quiz-explanation-text p:last-child { margin-bottom: 0; }
.ait-quiz-empty,
.ait-quiz-result { padding: 34px 20px 24px; text-align: center; }
.ait-quiz-empty > span,
.ait-quiz-result-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    margin-bottom: 14px;
    border-radius: 17px;
    background: #eef2ff;
    color: var(--primary);
    font-size: 1.45rem;
}
.ait-quiz-empty h2 { margin-bottom: 8px; font-size: 1.25rem; font-weight: 900; }
.ait-quiz-empty p { max-width: 640px; margin: 0 auto 18px; color: #64748b; line-height: 1.62; }
.ait-quiz-empty code { color: #6d28d9; }
.ait-quiz-empty a { color: var(--primary); font-weight: 900; }
.ait-quiz-result-label { margin: 0 0 5px; color: #64748b; font-size: .78rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.ait-quiz-result h2 { margin: 0; color: #312e81; font-size: 3.2rem; font-weight: 900; }
.ait-quiz-result-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; max-width: 520px; margin: 20px auto; }
.ait-quiz-result-stats span { padding: 13px; border-radius: 12px; background: #f8fafc; color: #64748b; font-size: .72rem; }
.ait-quiz-result-stats strong { display: block; margin-bottom: 2px; color: #1e293b; font-size: 1.2rem; }
.ait-quiz-result-stats .result-correct { background: #f0fdf4; }
.ait-quiz-result-stats .result-wrong { background: #fef2f2; }
.ait-quiz-result-stats .result-skipped { background: #f0f9ff; }
.ait-quiz-result-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 9px; }

.ait-reading-guide { background: #fff; }
.ait-reading-guide-card {
    overflow: hidden;
    border: 1px solid #e2e8f0;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 15px 45px rgba(15, 23, 42, .045);
}
.ait-reading-guide-hero { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(260px, .7fr); gap: 28px; align-items: center; padding: 36px; background: linear-gradient(135deg, #f8fafc, #f5f3ff); }
.ait-reading-guide-hero h2 { margin: 0 0 12px; font-size: clamp(1.55rem, 3.4vw, 2.15rem); font-weight: 900; letter-spacing: -.035em; }
.ait-reading-guide-hero p { margin: 0; color: #64748b; line-height: 1.7; }
.ait-reading-guide-rule { padding: 22px; border-radius: 17px; background: #312e81; color: #fff; }
.ait-reading-guide-rule small { display: block; margin-bottom: 8px; color: #c7d2fe; font-size: .7rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.ait-reading-guide-rule strong { font-size: 1.04rem; line-height: 1.5; }
.ait-reading-steps { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid #e2e8f0; border-bottom: 1px solid #e2e8f0; }
.ait-reading-steps section { padding: 26px; border-right: 1px solid #e2e8f0; }
.ait-reading-steps section:last-child { border-right: 0; }
.ait-reading-steps span { display: block; margin-bottom: 10px; color: #7c3aed; font-size: .72rem; font-weight: 900; }
.ait-reading-steps h3 { margin: 0 0 8px; font-size: .98rem; font-weight: 900; }
.ait-reading-steps p { margin: 0; color: #64748b; font-size: .84rem; line-height: 1.58; }
.ait-reading-compare { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; padding: 30px; background: #f8fafc; }
.ait-reading-compare section { padding: 22px; border: 1px solid #e2e8f0; border-radius: 16px; background: #fff; }
.ait-reading-tag { display: inline-block; padding: 4px 9px; margin-bottom: 13px; border-radius: 999px; font-size: .67rem; font-weight: 900; }
.ait-reading-tag.tag-topic { background: #e0f2fe; color: #0369a1; }
.ait-reading-tag.tag-main { background: #ede9fe; color: #6d28d9; }
.ait-reading-tag.tag-detail { background: #dcfce7; color: #15803d; }
.ait-reading-compare h3 { margin: 0 0 8px; font-size: .98rem; font-weight: 900; }
.ait-reading-compare p { margin: 0; color: #64748b; font-size: .84rem; line-height: 1.58; }
.ait-reading-checklist { display: grid; grid-template-columns: minmax(0, .75fr) minmax(0, 1.25fr); gap: 32px; padding: 34px; background: #1e1b4b; color: #fff; }
.ait-reading-checklist .eyebrow { color: #a5b4fc; }
.ait-reading-checklist h2 { margin: 0 0 8px; font-size: 1.45rem; font-weight: 900; }
.ait-reading-checklist p { margin: 0; color: #a5b4fc; }
.ait-reading-checklist ul { display: grid; gap: 10px; padding: 0; margin: 0; list-style: none; }
.ait-reading-checklist li { display: flex; gap: 10px; align-items: flex-start; color: #e0e7ff; line-height: 1.5; }
.ait-reading-checklist li i { margin-top: 2px; color: #67e8f9; }

@media (max-width: 991.98px) {
    .ait-quiz-grid.has-explanation { grid-template-columns: 1fr; max-width: 960px; }
    .ait-quiz-explanation { order: 2; }
    .ait-reading-steps { grid-template-columns: repeat(2, 1fr); }
    .ait-reading-steps section:nth-child(2) { border-right: 0; }
    .ait-reading-steps section:nth-child(-n+2) { border-bottom: 1px solid #e2e8f0; }
    .ait-reading-guide-hero { grid-template-columns: 1fr; }
}

@media (max-width: 767.98px) {
    .ait-quiz-shell { padding: 18px 0 38px; }
    .ait-test-breadcrumb { margin-bottom: 12px; }
    .ait-quiz-card { border-radius: 21px; }
    .ait-quiz-toolbar { grid-template-columns: 42px 1fr auto; min-height: 64px; padding: 10px 12px; }
    .ait-quiz-home { width: 40px; height: 40px; }
    .ait-quiz-label { padding: 5px 8px; font-size: .57rem; letter-spacing: .05em; }
    .ait-quiz-finish { width: 40px; min-height: 40px; padding: 0; justify-content: center; }
    .ait-quiz-finish span { display: none; }
    .ait-quiz-heading { padding: 27px 18px 18px; }
    .ait-quiz-heading p { font-size: .9rem; }
    .ait-quiz-welcome { flex-direction: column; padding: 18px; margin: 0 12px 12px; text-align: center; }
    .ait-quiz-start-area,
    .ait-quiz-start-area .ait-quiz-start { width: 100%; }
    .ait-quiz-content { padding: 4px 12px 14px; }
    .ait-quiz-question { padding: 18px; }
    .ait-quiz-actions .ait-quiz-secondary,
    .ait-quiz-actions .ait-quiz-next { flex: 1 1 0; padding-inline: 12px; }
    .ait-quiz-result { padding-inline: 6px; }
    .ait-quiz-result-stats { grid-template-columns: 1fr; }
    .ait-reading-guide-card { border-radius: 20px; }
    .ait-reading-guide-hero { padding: 25px 21px; }
    .ait-reading-steps,
    .ait-reading-compare,
    .ait-reading-checklist { grid-template-columns: 1fr; }
    .ait-reading-steps section { border-right: 0; border-bottom: 1px solid #e2e8f0; padding: 22px; }
    .ait-reading-steps section:last-child { border-bottom: 0; }
    .ait-reading-compare { padding: 19px; }
    .ait-reading-checklist { padding: 26px 21px; }
}

/* Цветовые и композиционные варианты академического чтения */
.ait-test-page {
    --test-accent: #7c3aed;
    --test-accent-dark: #312e81;
    --test-accent-soft: #f5f3ff;
    --test-accent-mid: #ddd6fe;
    --test-accent-contrast: #ffffff;
    --test-shape-one: #a5b4fc;
    --test-shape-two: #67e8f9;
    --test-shape-three: #c4b5fd;
}
.ait-test-theme-sky {
    --test-accent: #0284c7;
    --test-accent-dark: #0c4a6e;
    --test-accent-soft: #f0f9ff;
    --test-accent-mid: #bae6fd;
    --test-shape-one: #7dd3fc;
    --test-shape-two: #a5f3fc;
    --test-shape-three: #38bdf8;
}
.ait-test-theme-emerald {
    --test-accent: #059669;
    --test-accent-dark: #064e3b;
    --test-accent-soft: #ecfdf5;
    --test-accent-mid: #a7f3d0;
    --test-shape-one: #6ee7b7;
    --test-shape-two: #99f6e4;
    --test-shape-three: #34d399;
}
.ait-test-theme-amber {
    --test-accent: #d97706;
    --test-accent-dark: #78350f;
    --test-accent-soft: #fffbeb;
    --test-accent-mid: #fde68a;
    --test-shape-one: #fbbf24;
    --test-shape-two: #fed7aa;
    --test-shape-three: #f59e0b;
}
.ait-test-theme-rose {
    --test-accent: #e11d48;
    --test-accent-dark: #881337;
    --test-accent-soft: #fff1f2;
    --test-accent-mid: #fecdd3;
    --test-shape-one: #fda4af;
    --test-shape-two: #fbcfe8;
    --test-shape-three: #fb7185;
}
.ait-test-theme-teal {
    --test-accent: #0f766e;
    --test-accent-dark: #134e4a;
    --test-accent-soft: #f0fdfa;
    --test-accent-mid: #99f6e4;
    --test-shape-one: #5eead4;
    --test-shape-two: #a5f3fc;
    --test-shape-three: #2dd4bf;
}
.ait-test-theme-indigo {
    --test-accent: #4f46e5;
    --test-accent-dark: #1e1b4b;
    --test-accent-soft: #eef2ff;
    --test-accent-mid: #c7d2fe;
    --test-shape-one: #818cf8;
    --test-shape-two: #93c5fd;
    --test-shape-three: #6366f1;
}
.ait-test-theme-orange {
    --test-accent: #ea580c;
    --test-accent-dark: #7c2d12;
    --test-accent-soft: #fff7ed;
    --test-accent-mid: #fed7aa;
    --test-shape-one: #fb923c;
    --test-shape-two: #fdba74;
    --test-shape-three: #f97316;
}
.ait-test-theme-blue {
    --test-accent: #2563eb;
    --test-accent-dark: #172554;
    --test-accent-soft: #eff6ff;
    --test-accent-mid: #bfdbfe;
    --test-shape-one: #60a5fa;
    --test-shape-two: #67e8f9;
    --test-shape-three: #3b82f6;
}
.ait-test-theme-fuchsia {
    --test-accent: #c026d3;
    --test-accent-dark: #701a75;
    --test-accent-soft: #fdf4ff;
    --test-accent-mid: #f5d0fe;
    --test-shape-one: #e879f9;
    --test-shape-two: #ddd6fe;
    --test-shape-three: #d946ef;
}
.ait-test-theme-slate {
    --test-accent: #475569;
    --test-accent-dark: #0f172a;
    --test-accent-soft: #f1f5f9;
    --test-accent-mid: #cbd5e1;
    --test-shape-one: #94a3b8;
    --test-shape-two: #a5b4fc;
    --test-shape-three: #64748b;
}
.ait-test-page .ait-quiz-bg span:first-child { background: var(--test-shape-one); }
.ait-test-page .ait-quiz-bg span:nth-child(2) { background: var(--test-shape-two); }
.ait-test-page .ait-quiz-bg span:nth-child(3) { border-color: var(--test-shape-three); }
.ait-test-page .ait-quiz-number,
.ait-test-page .ait-test-breadcrumb a:hover { color: var(--test-accent); }
.ait-test-page .ait-quiz-welcome,
.ait-test-page .ait-reading-guide-hero { background: linear-gradient(135deg, #f8fafc, var(--test-accent-soft)); }
.ait-test-page .ait-quiz-start,
.ait-test-page .ait-quiz-next { background: linear-gradient(135deg, var(--test-accent), var(--test-accent-dark)); }
.ait-test-page .ait-quiz-start:disabled {
    cursor: not-allowed;
    opacity: .45;
    box-shadow: none;
    transform: none;
}
.ait-test-page .ait-quiz-home:hover,
.ait-test-page .ait-quiz-secondary:hover { border-color: var(--test-accent-mid); color: var(--test-accent); }
.ait-test-page .ait-quiz-option:hover:not(:disabled) { border-color: var(--test-accent); background: var(--test-accent-soft); }
.ait-test-page .ait-reading-guide-rule,
.ait-test-page .ait-reading-checklist { background: var(--test-accent-dark); }
.ait-test-page .ait-reading-steps span,
.ait-test-page .ait-reading-checklist .eyebrow { color: var(--test-accent-mid); }

.ait-test-layout-left .ait-quiz-heading { max-width: none; margin: 0; padding-left: 38px; padding-right: 38px; text-align: left; }
.ait-test-layout-left .ait-quiz-heading p { margin-left: 0; }
.ait-test-layout-left .ait-quiz-welcome { border-left: 5px solid var(--test-accent); }
.ait-test-layout-left .ait-reading-guide-rule { transform: translateY(12px); }

.ait-test-layout-soft .ait-quiz-card { border-radius: 18px; box-shadow: 0 12px 36px rgba(15, 23, 42, .06); }
.ait-test-layout-soft .ait-quiz-toolbar { background: var(--test-accent-soft); }
.ait-test-layout-soft .ait-quiz-welcome { border-radius: 8px 20px 20px 8px; }
.ait-test-layout-soft .ait-reading-compare section { border-top: 4px solid var(--test-accent-mid); }

.ait-test-layout-band .ait-quiz-toolbar { border-bottom-color: var(--test-accent-mid); background: var(--test-accent-dark); }
.ait-test-layout-band .ait-quiz-label { border-color: rgba(255,255,255,.22); background: rgba(255,255,255,.1); color: #fff; }
.ait-test-layout-band .ait-quiz-home { border-color: rgba(255,255,255,.2); background: rgba(255,255,255,.1); color: #fff; }
.ait-test-layout-band .ait-quiz-finish { border-color: rgba(255,255,255,.3); background: rgba(255,255,255,.12); color: #fff; }
.ait-test-layout-band .ait-reading-steps { border-top: 5px solid var(--test-accent); }

.ait-test-layout-outline .ait-quiz-card { border: 2px solid var(--test-accent-mid); box-shadow: none; }
.ait-test-layout-outline .ait-quiz-welcome { border-style: dashed; border-color: var(--test-accent-mid); background: #fff; }
.ait-test-layout-outline .ait-reading-guide-card { border: 2px solid var(--test-accent-mid); box-shadow: none; }

.ait-test-layout-round .ait-quiz-card { border-radius: 36px; }
.ait-test-layout-round .ait-quiz-welcome { border-radius: 30px; }
.ait-test-layout-round .ait-reading-guide-card { border-radius: 36px; }
.ait-test-layout-round .ait-reading-compare section { border-radius: 26px; }

.ait-test-layout-offset .ait-quiz-card { border-left: 7px solid var(--test-accent); }
.ait-test-layout-offset .ait-quiz-heading { padding-bottom: 30px; text-align: left; }
.ait-test-layout-offset .ait-quiz-heading p { margin-left: 0; }
.ait-test-layout-offset .ait-reading-guide-hero > div:first-child { order: 2; }
.ait-test-layout-offset .ait-reading-guide-rule { order: 1; }

.ait-test-layout-panel .ait-quiz-heading { max-width: none; margin: 0 18px 20px; border-radius: 0 0 22px 22px; background: var(--test-accent-soft); }
.ait-test-layout-panel .ait-quiz-welcome { background: #fff; }
.ait-test-layout-panel .ait-reading-compare { background: var(--test-accent-soft); }

.ait-test-layout-compact .ait-quiz-heading { padding-top: 25px; padding-bottom: 16px; }
.ait-test-layout-compact .ait-quiz-welcome { margin-left: 0; margin-right: 0; margin-bottom: 0; border-right: 0; border-bottom: 0; border-left: 0; border-radius: 0; }
.ait-test-layout-compact .ait-reading-steps section { padding-top: 20px; padding-bottom: 20px; }

.ait-test-layout-cards .ait-reading-steps { gap: 12px; padding: 24px; border: 0; background: var(--test-accent-soft); }
.ait-test-layout-cards .ait-reading-steps section { border: 1px solid var(--test-accent-mid); border-radius: 16px; background: #fff; }
.ait-test-layout-cards .ait-reading-compare { background: #fff; }
.ait-test-layout-cards .ait-reading-compare section { box-shadow: 0 8px 22px rgba(15,23,42,.05); }

.ait-test-layout-final .ait-quiz-heading { background: linear-gradient(180deg, var(--test-accent-soft), #fff); }
.ait-test-layout-final .ait-quiz-welcome { margin-top: 5px; border-bottom: 4px solid var(--test-accent); }
.ait-test-layout-final .ait-reading-checklist { border-top: 8px solid var(--test-accent); }

@media (max-width: 767.98px) {
    .ait-test-layout-left .ait-quiz-heading,
    .ait-test-layout-offset .ait-quiz-heading { padding-left: 20px; padding-right: 20px; }
    .ait-test-layout-round .ait-quiz-card,
    .ait-test-layout-round .ait-reading-guide-card { border-radius: 23px; }
    .ait-test-layout-offset .ait-reading-guide-hero > div:first-child,
    .ait-test-layout-offset .ait-reading-guide-rule { order: initial; }
    .ait-test-layout-cards .ait-reading-steps { padding: 16px; }
}

/* Учебные тексты, источники и объяснения внутри вопросов */
.ait-reading-passage {
    padding: 20px;
    margin-bottom: 18px;
    border: 1px solid #dbe3ee;
    border-left: 5px solid var(--test-accent);
    border-radius: 14px;
    background: #fbfdff;
    color: #334155;
    font-size: .94rem;
    font-weight: 500;
    line-height: 1.72;
}
.ait-reading-passage h3 {
    margin: 5px 0 12px;
    color: #0f172a;
    font-size: 1.05rem;
    font-weight: 900;
}
.ait-reading-passage p { margin: 0 0 11px; }
.ait-reading-passage p:last-child { margin-bottom: 0; }
.ait-passage-label,
.ait-source-label {
    display: inline-flex;
    padding: 4px 9px;
    border-radius: 999px;
    background: var(--test-accent-soft);
    color: var(--test-accent);
    font-size: .65rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.ait-reading-question-prompt {
    margin: 0;
    color: #172033;
    font-size: 1.02rem;
    font-weight: 900;
    line-height: 1.55;
}
.ait-source-pair {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}
.ait-source-card {
    padding: 18px;
    border: 1px solid #dbe3ee;
    border-radius: 14px;
    background: #fff;
    color: #334155;
    font-size: .88rem;
    font-weight: 500;
    line-height: 1.65;
}
.ait-source-card:first-child { border-top: 4px solid var(--test-accent); }
.ait-source-card:last-child { border-top: 4px solid var(--test-accent-mid); }
.ait-source-card h3 { margin: 8px 0 10px; font-size: .96rem; font-weight: 900; }
.ait-source-card p { margin: 0 0 9px; }
.ait-source-card p:last-child { margin-bottom: 0; }
.ait-reading-term {
    padding: 1px 4px;
    border-radius: 5px;
    background: #fef3c7;
    color: #78350f;
    font-weight: 900;
}
.ait-quiz-explanation-text .step {
    padding: 13px 0;
    border-bottom: 1px solid #e2e8f0;
}
.ait-quiz-explanation-text .step:first-child { padding-top: 0; }
.ait-quiz-explanation-text .step:last-child { padding-bottom: 0; border-bottom: 0; }
.ait-quiz-explanation-text .step-title {
    margin-bottom: 6px;
    color: #1e293b;
    font-size: .74rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.ait-quiz-explanation-text .math-chip { color: #475569; line-height: 1.62; }
.ait-quiz-question-text math,
.ait-quiz-option math,
.ait-quiz-explanation math {
    vertical-align: middle;
    font-family: serif;
}
.ait-quiz-question-text math[display="block"],
.ait-quiz-explanation math[display="block"] {
    display: block;
    margin: 12px auto;
    overflow-x: auto;
    text-align: center;
}

/* Quantitative literacy question cards */
.ait-quant-card {
    position: relative;
    margin-top: 14px;
    padding: 17px 18px;
    border: 1px solid color-mix(in srgb, var(--test-accent) 22%, #dbe4ee);
    border-radius: 16px;
    background: linear-gradient(145deg, #ffffff 0%, color-mix(in srgb, var(--test-accent-soft) 42%, #ffffff) 100%);
    box-shadow: 0 9px 24px rgba(15, 23, 42, .055);
}
.ait-quant-card p { margin: 0; }
.ait-quant-label {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    margin: -3px 0 10px;
    padding: 3px 9px;
    border-radius: 999px;
    background: var(--test-accent);
    color: #fff;
    font-size: .7rem;
    font-weight: 900;
    letter-spacing: .045em;
    line-height: 1.2;
    text-transform: uppercase;
}
.ait-quant-table-wrap {
    width: 100%;
    overflow-x: auto;
    border-radius: 11px;
    background: rgba(255, 255, 255, .72);
}
.ait-quant-table {
    width: 100%;
    min-width: 360px;
    border-collapse: collapse;
    color: #334155;
    font-size: .86rem;
}
.ait-quant-table th,
.ait-quant-table td {
    padding: 9px 11px;
    border-bottom: 1px solid #dce5ef;
    text-align: left;
    vertical-align: middle;
}
.ait-quant-table th {
    background: color-mix(in srgb, var(--test-accent-soft) 65%, #f8fafc);
    color: #1e293b;
    font-size: .75rem;
    font-weight: 900;
}
.ait-quant-table tr:last-child td { border-bottom: 0; }
.ait-quant-formula {
    padding: 8px 4px 4px;
    overflow-x: auto;
    color: #0f172a;
    font-size: 1.2rem;
    text-align: center;
}
.ait-reading-question-prompt {
    margin: 14px 0 0;
    color: #172033;
    font-size: 1rem;
    font-weight: 850;
    line-height: 1.55;
}

/* Research skills scenarios */
.ait-research-case {
    position: relative;
    margin-top: 14px;
    padding: 18px 19px;
    border: 1px solid color-mix(in srgb, var(--test-accent) 24%, #dbe4ee);
    border-radius: 17px;
    background:
        radial-gradient(circle at 100% 0, color-mix(in srgb, var(--test-accent-soft) 72%, transparent) 0, transparent 42%),
        #fff;
    box-shadow: 0 10px 26px rgba(15, 23, 42, .06);
}
.ait-research-case p {
    margin: 0;
    color: #344256;
    line-height: 1.68;
}
.ait-research-label {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    margin: -4px 0 11px;
    padding: 4px 10px;
    border: 1px solid color-mix(in srgb, var(--test-accent) 30%, transparent);
    border-radius: 999px;
    background: color-mix(in srgb, var(--test-accent-soft) 70%, #fff);
    color: var(--test-accent-dark, #334155);
    font-size: .69rem;
    font-weight: 900;
    letter-spacing: .045em;
    line-height: 1.2;
    text-transform: uppercase;
}
.ait-research-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid #dfe7f0;
    border-radius: 12px;
    background: rgba(255, 255, 255, .82);
}
.ait-research-table {
    width: 100%;
    min-width: 390px;
    border-collapse: collapse;
    color: #334155;
    font-size: .84rem;
}
.ait-research-table th,
.ait-research-table td {
    padding: 9px 11px;
    border-right: 1px solid #e3eaf2;
    border-bottom: 1px solid #e3eaf2;
    text-align: left;
    vertical-align: top;
}
.ait-research-table th:last-child,
.ait-research-table td:last-child { border-right: 0; }
.ait-research-table tr:last-child td { border-bottom: 0; }
.ait-research-table th {
    background: color-mix(in srgb, var(--test-accent-soft) 62%, #f8fafc);
    color: #1e293b;
    font-size: .74rem;
    font-weight: 900;
}

@media (max-width: 767.98px) {
    .ait-reading-passage { padding: 16px; font-size: .88rem; }
    .ait-source-pair { grid-template-columns: 1fr; }
    .ait-source-card { padding: 16px; }
    .ait-quant-card { padding: 14px; }
    .ait-quant-table { min-width: 310px; font-size: .8rem; }
    .ait-quant-table th,
    .ait-quant-table td { padding: 8px; }
    .ait-research-case { padding: 15px; }
    .ait-research-table { min-width: 330px; font-size: .79rem; }
    .ait-research-table th,
    .ait-research-table td { padding: 8px; }
}
