:root {
    --bg: #0b1020;
    --bg-2: #131b33;
    --card: #ffffff;
    --muted: #64748b;
    --line: #e2e8f0;
    --primary: #2563eb;
    --primary-2: #1d4ed8;
    --soft: #eff6ff;
    --good: #15803d;
    --warn: #b45309;
    --bad: #b91c1c;
    --shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
    --shadow-soft: 0 10px 30px rgba(15, 23, 42, 0.06);
    --shadow-strong: 0 28px 60px rgba(15, 23, 42, 0.12);
    --hero-grad: linear-gradient(135deg, #ffffff 0%, #f8fbff 52%, #eef4ff 100%);
    --cta-grad: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    --text: #0f172a;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2ff 100%);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a {
    color: inherit;
}

.container {
    width: min(1240px, calc(100% - 30px));
    margin: 0 auto;
}

.topbar {
    background: rgba(11, 16, 32, 0.96);
    color: #fff;
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 26px rgba(2, 6, 23, 0.18);
}

.topbar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 16px 0;
}

.brand {
    color: #fff;
    text-decoration: none;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    letter-spacing: -0.02em;
}

.brand-mark {
    display: inline-flex;
    width: 28px;
    height: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: linear-gradient(135deg, #60a5fa, #2563eb);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.35);
}

.nav {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.nav a {
    color: #dbeafe;
    text-decoration: none;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.nav a:hover {
    color: #ffffff;
}

.page {
    padding: 32px 0 54px;
}

.hero {
    display: grid;
    grid-template-columns: 1.2fr 0.9fr;
    gap: 28px;
    align-items: stretch;
    background: var(--hero-grad);
    border: 1px solid rgba(203, 213, 225, 0.7);
    box-shadow: var(--shadow-strong);
    overflow: hidden;
    position: relative;
}

.hero::before {
    content: "";
    position: absolute;
    right: -80px;
    top: -80px;
    width: 240px;
    height: 240px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(96, 165, 250, 0.22) 0%, rgba(96, 165, 250, 0) 72%);
    pointer-events: none;
}

.card {
    background: rgba(255,255,255,0.96);
    border: 1px solid var(--line);
    border-radius: 24px;
    padding: 28px;
    box-shadow: var(--shadow);
}

.hero-copy {
    position: relative;
    z-index: 1;
}

.hero-copy h1 {
    font-size: clamp(34px, 4.5vw, 58px);
    margin: 0 0 14px;
    line-height: 1.02;
    letter-spacing: -0.035em;
    max-width: 760px;
}

.hero-copy p {
    color: var(--muted);
    font-size: 18px;
    max-width: 760px;
    margin: 0 0 18px;
}

.hero-actions,
.actions-wrap,
.inline-actions,
.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 1rem;
    border: 0;
    border-radius: 14px;
    padding: 13px 20px;
    background: var(--cta-grad);
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    font-weight: 700;
    box-shadow: 0 14px 28px rgba(37, 99, 235, 0.22);
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.btn:hover {
    background: linear-gradient(135deg, #1f58d8 0%, #1948c6 100%);
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(37, 99, 235, 0.28);
}

.btn-secondary {
    background: #111827;
    box-shadow: 0 14px 28px rgba(17, 24, 39, 0.18);
}

.btn-secondary:hover {
    background: #0b1220;
    box-shadow: 0 18px 34px rgba(17, 24, 39, 0.24);
}

.btn-ghost {
    background: #eef2ff;
    color: #1e3a8a;
    box-shadow: none;
}

.btn-ghost:hover {
    background: #e0e7ff;
    color: #1d4ed8;
    box-shadow: none;
}

.btn-soft {
    background: #ecfeff;
    color: #155e75;
    box-shadow: none;
}

.btn-soft:hover {
    background: #cffafe;
    box-shadow: none;
}

.btn-danger {
    background: #991b1b;
    box-shadow: 0 14px 28px rgba(153, 27, 27, 0.22);
}

.btn-danger:hover {
    background: #7f1d1d;
    box-shadow: 0 18px 34px rgba(153, 27, 27, 0.28);
}

.btn-small {
    padding: 9px 14px;
}

.grid-2,
.grid-3,
.grid-4 {
    display: grid;
    gap: 18px;
}

.grid-2 {
    grid-template-columns: repeat(2, minmax(0,1fr));
}

.grid-3 {
    grid-template-columns: repeat(3, minmax(0,1fr));
}

.grid-4 {
    grid-template-columns: repeat(4, minmax(0,1fr));
}

.kpi {
    padding: 22px;
    border-radius: 20px;
    background: linear-gradient(180deg, #ffffff, #f8fbff);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-soft);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.kpi:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 34px rgba(15, 23, 42, 0.10);
}

.kpi strong {
    display: block;
    font-size: 30px;
    margin-bottom: 8px;
    letter-spacing: -0.03em;
}

.kpi span {
    color: var(--muted);
    font-weight: 700;
}

.page-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
    margin-bottom: 22px;
}

.page-head h1,
.page-head h2,
.card h2,
.card h3 {
    margin-top: 0;
    letter-spacing: -0.02em;
}

.page-head h1 {
    margin-bottom: 8px;
    font-size: clamp(30px, 3vw, 42px);
}

.page-head h2,
.card h2 {
    font-size: clamp(24px, 2.2vw, 34px);
    margin-bottom: 12px;
}

.card h3 {
    font-size: 20px;
    margin-bottom: 10px;
}

.meta {
    color: var(--muted);
}

.pill,
.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    padding: 8px 13px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.pill {
    background: var(--soft);
    color: #1d4ed8;
    box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.08);
}

.badge {
    background: #f1f5f9;
    color: #334155;
}

.badge.good {
    background: #ecfdf5;
    color: var(--good);
}

.badge.warn {
    background: #fff7ed;
    color: var(--warn);
}

.badge.bad {
    background: #fef2f2;
    color: var(--bad);
}

.alert {
    margin-bottom: 16px;
    padding: 14px 16px;
    border-radius: 14px;
    font-weight: 700;
}

.alert-success {
    background: #ecfdf5;
    color: var(--good);
    border: 1px solid #86efac;
}

.alert-error {
    background: #fef2f2;
    color: var(--bad);
    border: 1px solid #fecaca;
}

label {
    display: block;
    font-weight: 700;
}

input[type=text],
input[type=email],
input[type=password],
input[type=number],
input[type=url],
select,
textarea {
    width: 100%;
    margin-top: 8px;
    margin-bottom: 16px;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    padding: 12px 14px;
    font: inherit;
    background: #fff;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

input[type=text]:focus,
input[type=email]:focus,
input[type=password]:focus,
input[type=number]:focus,
input[type=url]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #93c5fd;
    box-shadow: 0 0 0 4px rgba(147, 197, 253, 0.18);
}

textarea {
    min-height: 110px;
    resize: vertical;
}

.form-card {
    max-width: 980px;
}

.narrow {
    max-width: 620px;
    margin: 0 auto;
}

.jobs-list,
.candidate-list,
.admin-list,
.timeline {
    display: grid;
    gap: 16px;
}

.job-card,
.candidate-card,
.tile {
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 20px;
    background: linear-gradient(180deg, #fff, #fbfdff);
    box-shadow: var(--shadow-soft);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.job-card:hover,
.candidate-card:hover,
.tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 34px rgba(15, 23, 42, 0.10);
    border-color: #dbeafe;
}

.stat-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.stat-mini {
    border: 1px solid var(--line);
    padding: 14px;
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.stat-mini strong {
    display: block;
    font-size: 22px;
}

.table-wrap {
    overflow-x: auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    text-align: left;
    padding: 12px 10px;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}

.table th {
    font-size: 13px;
    color: #334155;
    font-weight: 800;
    background: #f8fafc;
}

.questionnaire {
    display: grid;
    gap: 16px;
}

.question-block {
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 16px;
    background: #fff;
}

.question-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 12px;
}

.scale-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.radio-card {
    position: relative;
    min-width: 54px;
}

.radio-card input {
    position: absolute;
    opacity: 0;
    inset: 0;
}

.radio-card span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 12px 14px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    background: #fff;
    transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.radio-card.radio-wide {
    flex: 1 1 170px;
}

.radio-card input:checked + span {
    border-color: var(--primary);
    background: #dbeafe;
    color: #1d4ed8;
    font-weight: 700;
    transform: translateY(-1px);
}

.score-bar {
    height: 10px;
    border-radius: 999px;
    background: #e2e8f0;
    overflow: hidden;
}

.score-bar > span {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #60a5fa, #2563eb);
}

.score-high {
    color: var(--good);
}

.score-mid {
    color: var(--warn);
}

.score-low {
    color: var(--bad);
}

.pricing {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 18px;
}

.plan-card {
    position: relative;
    border: 1px solid var(--line);
    border-radius: 22px;
    padding: 24px;
    background: #fff;
    box-shadow: var(--shadow-soft);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.plan-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 36px rgba(15, 23, 42, 0.10);
}

.plan-card.featured {
    border-color: #93c5fd;
    box-shadow: 0 0 0 4px rgba(147,197,253,.15), 0 20px 36px rgba(15, 23, 42, 0.10);
}

.plan-price {
    font-size: 36px;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.list-clean {
    margin: 0;
    padding-left: 18px;
    color: var(--muted);
}

.footer {
    padding: 24px 0 34px;
    color: var(--muted);
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
}

.copy-note {
    font-size: 14px;
    color: var(--muted);
    max-width: 720px;
}

.empty {
    color: var(--muted);
    text-align: center;
    padding: 22px;
    border: 1px dashed #cbd5e1;
    border-radius: 18px;
}

.chart-rows {
    display: grid;
    gap: 12px;
}

.chart-row {
    display: grid;
    grid-template-columns: 220px 1fr 90px;
    gap: 12px;
    align-items: center;
}

.subtle {
    font-size: 13px;
    color: var(--muted);
}

.legal h1,
.legal h2,
.legal h3 {
    margin-top: 0;
}

.legal section {
    margin-bottom: 28px;
}

.hero-copy .pill {
    margin-bottom: 14px;
}

.hero .grid-2 {
    align-self: center;
}

.hero .kpi {
    min-height: 126px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero .kpi strong {
    font-size: 32px;
}

.hero .copy-note {
    margin-top: 16px;
}

.tile h3,
.job-card h3,
.candidate-card h3 {
    letter-spacing: -0.02em;
}

.tile p,
.job-card p,
.candidate-card p {
    margin-bottom: 0;
}

@media (max-width: 1024px) {
    .hero,
    .grid-2,
    .grid-3,
    .grid-4,
    .pricing,
    .stat-strip,
    .chart-row {
        grid-template-columns: 1fr;
    }

    .hero-copy h1 {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .page-head,
    .topbar-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .page {
        padding: 24px 0 40px;
    }

    .card,
    .plan-card,
    .tile,
    .job-card,
    .candidate-card {
        padding: 20px;
        border-radius: 20px;
    }

    .hero-copy h1 {
        font-size: clamp(30px, 9vw, 42px);
        line-height: 1.06;
    }

    .hero-copy p {
        font-size: 16px;
    }

    .btn {
        width: 100%;
    }

    .hero-actions {
        width: 100%;
    }

    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
    }
}

.public-page {
    max-width: 920px;
}

.public-shell {
    display: grid;
    gap: 18px;
}

.public-header {
    display: grid;
    gap: 14px;
}

.identity-strip {
    border-top: 1px solid var(--line);
    padding-top: 14px;
}

.question-scale-hint {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    width: 100%;
    text-align: center;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.scale-row.scale-compact {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    width: 100%;
}

.scale-row.scale-compact .radio-card.radio-compact {
    min-width: 0;
    width: 100%;
}

.scale-row.scale-compact .radio-card.radio-compact span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 42px;
    padding: 8px 0;
    font-weight: 700;
    font-size: 14px;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .public-page {
        width: min(920px, calc(100% - 18px));
    }

    .question-block {
        padding: 12px;
    }

    .question-head strong {
        font-size: 15px;
        line-height: 1.35;
    }

    .question-scale-hint,
    .scale-row.scale-compact {
        grid-template-columns: repeat(5, minmax(0, 1fr));
        gap: 4px;
    }

    .question-scale-hint {
        font-size: 10px;
    }

    .scale-row.scale-compact .radio-card.radio-compact span {
        min-height: 38px;
        padding: 6px 0;
        font-size: 13px;
    }
}