.ck-tvoed-calculator {
    --ck-primary: var(--e-global-color-primary, #182238);
    --ck-secondary: var(--e-global-color-secondary, #a98b58);
    --ck-accent: var(--e-global-color-accent, #b69762);
    --ck-text: var(--e-global-color-text, #292d35);
    --ck-muted: #6e737d;
    --ck-line: rgba(24, 34, 56, 0.14);
    --ck-soft: #f5f3ee;
    --ck-surface: #ffffff;
    --ck-success: #276749;
    --ck-danger: #a33a3a;
    color: var(--ck-text);
    font-family: var(--e-global-typography-text-font-family, inherit);
    font-size: 16px;
    line-height: 1.6;
    width: 100%;
    max-width: 1180px;
    margin: 36px auto;
    background: var(--ck-surface);
    border: 1px solid var(--ck-line);
    box-shadow: 0 24px 70px rgba(24, 34, 56, 0.1);
    overflow: hidden;
}

.ck-tvoed-calculator *,
.ck-tvoed-calculator *::before,
.ck-tvoed-calculator *::after {
    box-sizing: border-box;
}

.ck-tvoed-calculator h2,
.ck-tvoed-calculator h3,
.ck-tvoed-calculator p {
    margin-top: 0;
}

.ck-tvoed-calculator h2,
.ck-tvoed-calculator h3 {
    color: var(--ck-primary);
    font-family: var(--e-global-typography-primary-font-family, inherit);
    line-height: 1.18;
}

.ck-tvoed-hero {
    position: relative;
    padding: clamp(34px, 6vw, 76px);
    color: #fff;
    background:
        linear-gradient(115deg, rgba(24, 34, 56, 0.98), rgba(24, 34, 56, 0.84)),
        radial-gradient(circle at 85% 20%, rgba(182, 151, 98, 0.48), transparent 32%);
}

.ck-tvoed-hero::after {
    content: '';
    position: absolute;
    right: clamp(24px, 6vw, 78px);
    bottom: 0;
    width: min(260px, 32vw);
    height: 4px;
    background: var(--ck-accent);
}

.ck-tvoed-hero h2 {
    max-width: 780px;
    margin-bottom: 14px;
    color: #fff;
    font-size: clamp(32px, 5vw, 58px);
    font-weight: 600;
    letter-spacing: -0.035em;
}

.ck-tvoed-hero p {
    max-width: 720px;
    margin-bottom: 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: clamp(17px, 2vw, 21px);
}

.ck-tvoed-eyebrow {
    display: inline-block;
    margin-bottom: 14px;
    color: var(--ck-accent);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.ck-tvoed-form,
.ck-tvoed-results {
    padding: clamp(24px, 5vw, 60px);
}

.ck-tvoed-section + .ck-tvoed-section {
    margin-top: 46px;
    padding-top: 46px;
    border-top: 1px solid var(--ck-line);
}

.ck-tvoed-section-heading {
    display: grid;
    grid-template-columns: 44px 1fr;
    gap: 18px;
    align-items: start;
    margin-bottom: 28px;
}

.ck-tvoed-section-heading > span {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid var(--ck-accent);
    color: var(--ck-primary);
    font-size: 13px;
    font-weight: 700;
}

.ck-tvoed-section-heading h3 {
    margin-bottom: 5px;
    font-size: clamp(22px, 3vw, 30px);
}

.ck-tvoed-section-heading p {
    margin-bottom: 0;
    color: var(--ck-muted);
}

.ck-tvoed-grid {
    display: grid;
    gap: 18px;
}

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

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

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

.ck-tvoed-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--ck-primary);
    font-size: 14px;
    font-weight: 650;
}

.ck-tvoed-field input,
.ck-tvoed-field select,
.ck-tvoed-stage-output {
    width: 100%;
    min-height: 52px;
    padding: 12px 14px;
    border: 1px solid rgba(24, 34, 56, 0.24);
    border-radius: 0;
    outline: 0;
    background: #fff;
    color: var(--ck-text);
    font: inherit;
    font-weight: 500;
    transition: border-color 160ms ease, box-shadow 160ms ease;
}


.ck-tvoed-stage-output {
    display: flex;
    align-items: center;
    background: var(--ck-soft);
    color: var(--ck-primary);
    font-weight: 700;
}

.ck-tvoed-field input:focus,
.ck-tvoed-field select:focus {
    border-color: var(--ck-accent);
    box-shadow: 0 0 0 3px rgba(182, 151, 98, 0.17);
}

.ck-tvoed-field > small {
    color: var(--ck-muted);
    font-size: 12px;
    font-weight: 500;
    line-height: 1.45;
}

.ck-tvoed-deadline {
    display: grid;
    gap: 4px;
    margin-top: 20px;
    padding: 18px 20px;
    border-left: 3px solid var(--ck-accent);
    background: var(--ck-soft);
}

.ck-tvoed-deadline > span {
    color: var(--ck-muted);
    font-size: 12px;
    font-weight: 750;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.ck-tvoed-deadline strong {
    color: var(--ck-primary);
    font-size: 15px;
}

.ck-tvoed-deadline small {
    color: var(--ck-muted);
    font-size: 12px;
}

.ck-tvoed-hours-grid {
    margin-top: 20px;
}

.ck-tvoed-quota {
    margin: 14px 0 0;
    color: var(--ck-muted);
    font-size: 14px;
}

.ck-tvoed-quota strong {
    color: var(--ck-primary);
}

.ck-tvoed-comparison {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 20px;
    align-items: stretch;
}

.ck-tvoed-card {
    min-width: 0;
    margin: 0;
    padding: 24px;
    border: 1px solid var(--ck-line);
    background: var(--ck-soft);
}

.ck-tvoed-card--target {
    border-color: rgba(182, 151, 98, 0.52);
    background: rgba(182, 151, 98, 0.09);
}

.ck-tvoed-card legend {
    padding: 0 8px;
    color: var(--ck-primary);
    font-size: 15px;
    font-weight: 750;
}

.ck-tvoed-arrow {
    display: grid;
    place-items: center;
    color: var(--ck-accent);
    font-size: 34px;
}

.ck-tvoed-check {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 13px;
    align-items: start;
    margin-top: 22px;
    padding: 18px 20px;
    border-left: 3px solid var(--ck-accent);
    background: var(--ck-soft);
    cursor: pointer;
}

.ck-tvoed-check input {
    width: 20px;
    height: 20px;
    margin-top: 3px;
    accent-color: var(--ck-primary);
}

.ck-tvoed-check strong,
.ck-tvoed-check small {
    display: block;
}

.ck-tvoed-check strong {
    color: var(--ck-primary);
}

.ck-tvoed-check small {
    margin-top: 2px;
    color: var(--ck-muted);
    font-size: 13px;
}

.ck-tvoed-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-top: 34px;
}

.ck-tvoed-button,
.ck-tvoed-print {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 50px;
    padding: 13px 22px;
    border: 1px solid transparent;
    border-radius: 0;
    cursor: pointer;
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none !important;
    transition: transform 150ms ease, background-color 150ms ease, color 150ms ease, border-color 150ms ease;
}

.ck-tvoed-button:hover,
.ck-tvoed-print:hover {
    transform: translateY(-1px);
}

.ck-tvoed-button--primary {
    background: var(--ck-primary);
    color: #fff !important;
}

.ck-tvoed-button--primary:hover,
.ck-tvoed-button--primary:focus-visible {
    background: var(--ck-accent);
    color: var(--ck-primary) !important;
}

.ck-tvoed-button--secondary,
.ck-tvoed-print {
    border-color: rgba(24, 34, 56, 0.24);
    background: transparent;
    color: var(--ck-primary);
}

.ck-tvoed-button--secondary:hover,
.ck-tvoed-print:hover {
    border-color: var(--ck-primary);
}

.ck-tvoed-error {
    flex-basis: 100%;
    margin: 8px 0 0;
    padding: 12px 15px;
    border-left: 3px solid var(--ck-danger);
    background: rgba(163, 58, 58, 0.08);
    color: var(--ck-danger);
    font-weight: 600;
}

.ck-tvoed-results {
    border-top: 1px solid var(--ck-line);
    background: linear-gradient(180deg, #fff, #faf9f6);
}

.ck-tvoed-result-heading {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: end;
    margin-bottom: 26px;
}

.ck-tvoed-result-heading h3 {
    margin-bottom: 0;
    font-size: clamp(28px, 4vw, 42px);
}

.ck-tvoed-kpis {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    background: var(--ck-line);
    border: 1px solid var(--ck-line);
}

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

.ck-tvoed-kpis--5 {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.ck-tvoed-kpis article {
    padding: clamp(20px, 3vw, 30px);
    background: #fff;
}

.ck-tvoed-kpis span,
.ck-tvoed-kpis small,
.ck-tvoed-kpis strong {
    display: block;
}

.ck-tvoed-kpis span {
    color: var(--ck-muted);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.ck-tvoed-kpis strong {
    margin: 8px 0 4px;
    color: var(--ck-primary);
    font-size: clamp(24px, 3vw, 34px);
    line-height: 1.15;
}

.ck-tvoed-kpis small {
    color: var(--ck-muted);
    font-size: 12px;
}

.ck-tvoed-kpis .ck-tvoed-kpi-main {
    background: var(--ck-primary);
}

.ck-tvoed-kpis .ck-tvoed-kpi-main span,
.ck-tvoed-kpis .ck-tvoed-kpi-main small {
    color: rgba(255, 255, 255, 0.72);
}

.ck-tvoed-kpis .ck-tvoed-kpi-main strong {
    color: #fff;
}

.ck-tvoed-summary {
    margin: 24px 0;
    padding: 16px 18px;
    border-left: 3px solid var(--ck-accent);
    background: rgba(182, 151, 98, 0.09);
}

.ck-tvoed-summary p {
    margin-bottom: 0;
}

.ck-tvoed-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--ck-line);
    background: #fff;
}

.ck-tvoed-table {
    width: 100%;
    min-width: 820px;
    border-collapse: collapse;
    font-variant-numeric: tabular-nums;
}

.ck-tvoed-table caption {
    padding: 18px 20px;
    color: var(--ck-primary);
    font-size: 16px;
    font-weight: 750;
    text-align: left;
}

.ck-tvoed-table th,
.ck-tvoed-table td {
    padding: 14px 18px;
    border-top: 1px solid var(--ck-line);
    text-align: right;
    vertical-align: top;
}

.ck-tvoed-table thead th {
    background: var(--ck-soft);
    color: var(--ck-primary);
    font-size: 12px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.ck-tvoed-table th:first-child,
.ck-tvoed-table td:first-child {
    text-align: left;
}

.ck-tvoed-table tbody th {
    color: var(--ck-primary);
}

.ck-tvoed-table tbody td small {
    display: block;
    margin-top: 3px;
    color: var(--ck-muted);
    font-size: 11px;
    font-weight: 600;
}

.ck-tvoed-table tbody th small {
    display: block;
    color: var(--ck-muted);
    font-size: 11px;
    font-weight: 500;
}

.ck-tvoed-table .is-positive {
    color: var(--ck-success);
    font-weight: 750;
}

.ck-tvoed-table .is-negative {
    color: var(--ck-danger);
    font-weight: 750;
}

.ck-tvoed-table tr.is-excluded-row th,
.ck-tvoed-table tr.is-excluded-row td {
    background: rgba(110, 115, 125, 0.06);
    color: var(--ck-muted);
}

.ck-tvoed-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 104px;
    padding: 5px 8px;
    border: 1px solid currentColor;
    font-size: 11px;
    font-weight: 750;
    line-height: 1.1;
    text-transform: uppercase;
}

.ck-tvoed-status.is-retro {
    color: var(--ck-success);
    background: rgba(39, 103, 73, 0.07);
}

.ck-tvoed-status.is-postclaim {
    color: var(--ck-secondary);
    background: rgba(169, 139, 88, 0.09);
}

.ck-tvoed-status.is-excluded {
    color: var(--ck-muted);
    background: rgba(110, 115, 125, 0.07);
}

.ck-tvoed-note {
    margin-top: 24px;
    padding: 20px;
    border: 1px solid var(--ck-line);
    background: #fff;
}

.ck-tvoed-note strong {
    color: var(--ck-primary);
}

.ck-tvoed-note p {
    margin: 5px 0 0;
    color: var(--ck-muted);
    font-size: 13px;
}

.ck-tvoed-cta {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 30px;
    align-items: center;
    margin-top: 34px;
    padding: clamp(24px, 4vw, 40px);
    background: var(--ck-soft);
    border-left: 4px solid var(--ck-accent);
}

.ck-tvoed-cta h3 {
    margin-bottom: 8px;
    font-size: clamp(22px, 3vw, 30px);
}

.ck-tvoed-cta p {
    margin-bottom: 0;
    color: var(--ck-muted);
}

.ck-tvoed-footer-note {
    padding: 18px clamp(24px, 5vw, 60px);
    border-top: 1px solid var(--ck-line);
    background: var(--ck-soft);
    color: var(--ck-muted);
    font-size: 12px;
}

.ck-tvoed-calculator [hidden] {
    display: none !important;
}

@media (max-width: 1050px) {
    .ck-tvoed-kpis--4,
    .ck-tvoed-kpis--5 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .ck-tvoed-grid--4,
    .ck-tvoed-grid--3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ck-tvoed-comparison {
        grid-template-columns: 1fr;
    }

    .ck-tvoed-arrow {
        height: 24px;
        transform: rotate(90deg);
    }

    .ck-tvoed-kpis {
        grid-template-columns: 1fr;
    }

    .ck-tvoed-cta {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .ck-tvoed-calculator {
        margin: 18px auto;
        border-left: 0;
        border-right: 0;
        box-shadow: none;
    }

    .ck-tvoed-grid--4,
    .ck-tvoed-grid--3,
    .ck-tvoed-grid--2,
    .ck-tvoed-kpis--4,
    .ck-tvoed-kpis--5 {
        grid-template-columns: 1fr;
    }

    .ck-tvoed-result-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .ck-tvoed-actions .ck-tvoed-button,
    .ck-tvoed-print {
        width: 100%;
    }
}

@media print {
    body * {
        visibility: hidden !important;
    }

    .ck-tvoed-calculator,
    .ck-tvoed-calculator * {
        visibility: visible !important;
    }

    .ck-tvoed-calculator {
        position: absolute;
        inset: 0 auto auto 0;
        width: 100%;
        max-width: none;
        margin: 0;
        border: 0;
        box-shadow: none;
    }

    .ck-tvoed-form,
    .ck-tvoed-print,
    .ck-tvoed-cta {
        display: none !important;
    }

    .ck-tvoed-results {
        border-top: 0;
    }

    .ck-tvoed-table-wrap {
        overflow: visible;
    }
}

.ck-tvoed-field--wide {
    grid-column: 1 / -1;
}

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

@media (max-width: 1050px) {
    .ck-tvoed-kpis--6 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .ck-tvoed-kpis--6 {
        grid-template-columns: 1fr;
    }
}
