.choice-group {
    border: 0;
    margin: 0 0 22px;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.choice-group legend {
    grid-column: 1 / -1;
    padding: 0;
    margin-bottom: 2px;
    font-size: 0.95rem;
    color: #94a3b8;
}

.choice {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 16px 16px 18px;
    border-radius: 16px;
    border: 1px solid var(--card-border);
    background: rgba(0, 0, 0, 0.18);
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.choice input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    pointer-events: none;
}

.choice-title {
    font-size: 1.02rem;
    font-weight: 700;
    color: #f8fafc;
}

.choice-desc {
    font-size: 0.88rem;
    line-height: 1.4;
    color: #94a3b8;
}

.choice:hover {
    border-color: rgba(56, 189, 248, 0.45);
}

.choice:has(input:checked) {
    border-color: var(--accent);
    background: rgba(56, 189, 248, 0.12);
    box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.25);
}

.choice:has(input:focus-visible) {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

.fields {
    margin-bottom: 20px;
}

.fields[hidden],
#potResults[hidden],
#payoutResults[hidden] {
    display: none !important;
}

.field {
    margin-top: 20px;
}

.field label,
.pair h2,
.working-card h2 {
    font-size: 0.92rem;
    font-weight: 600;
    color: #94a3b8;
}

.adorned {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--card-border);
    border-radius: 14px;
    padding: 0 16px;
    transition: border-color 0.2s;
}

.adorned:focus-within {
    border-color: var(--accent);
}

.adorned.is-invalid {
    border-color: var(--highlight-red);
}

.adorned input {
    flex: 1;
    width: 100%;
    min-width: 0;
    border: 0;
    background: transparent;
    color: white;
    padding: 16px 8px;
    font-size: 1.45rem;
    font-weight: 700;
    outline: none;
    border-radius: 0;
}

.prefix,
.suffix {
    color: #94a3b8;
    font-weight: 700;
    white-space: nowrap;
}

.prefix {
    font-size: 1.25rem;
}

.suffix {
    font-size: 0.95rem;
}

.rate-adorned {
    max-width: 280px;
}

.tax-period {
    max-width: 420px;
    margin-top: 8px;
}

.field-hint {
    margin-top: 8px;
    min-height: 1.2em;
    font-size: 0.85rem;
    color: #94a3b8;
}

.income-row {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(220px, 1fr);
    gap: 12px;
    align-items: end;
}

.income-row .adorned {
    margin-top: 8px;
}

.period {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-top: 8px;
    padding: 5px;
    border-radius: 14px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--card-border);
}

.period-btn,
.rate-chip {
    height: auto;
    min-height: 0;
    padding: 12px 10px;
    border-radius: 10px;
    background: transparent;
    color: #cbd5e1;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    transform: none;
}

.period-btn:hover,
.rate-chip:hover {
    transform: none;
    filter: none;
    background: rgba(255, 255, 255, 0.06);
    color: white;
}

.period-btn[aria-pressed="true"],
.rate-chip[aria-pressed="true"] {
    background: var(--accent);
    color: #0f172a;
}

.period-btn:focus-visible,
.rate-chip:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.rate-chip {
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--card-border);
}

.result-card {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.result-lead {
    text-align: center;
    font-size: 1.08rem;
    line-height: 1.5;
    color: #e2e8f0;
}

.equation {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 14px 16px;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.28);
    border: 1px solid var(--card-border);
    text-align: center;
}

.equation[hidden] {
    display: none !important;
}

.equation p {
    margin: 0;
    font-family: 'Courier New', Courier, monospace;
    font-size: clamp(0.95rem, 2.4vw, 1.15rem);
    line-height: 1.45;
    color: #e2e8f0;
}

.result-kicker {
    text-align: center;
    color: #94a3b8;
    font-size: 0.95rem;
    font-weight: 600;
}

.hero {
    text-align: center;
    font-size: clamp(2.5rem, 7vw, 3.6rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.05;
    color: var(--highlight-green);
}

.pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.pair article {
    background: rgba(0, 0, 0, 0.22);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 18px 14px 16px;
    text-align: center;
}

.pair h2 {
    margin-bottom: 8px;
}

.pair p,
.payout-figure {
    font-size: clamp(1.7rem, 4vw, 2.5rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--highlight-green);
    line-height: 1.1;
}

.pair-quiet p {
    font-size: clamp(1.25rem, 3vw, 1.7rem);
}

.working-card h2 {
    color: var(--accent);
    font-size: 1.05rem;
    margin-bottom: 16px;
}

.working-card ol {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    counter-reset: step;
    margin-bottom: 18px;
}

.working-card li {
    counter-increment: step;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    color: #e2e8f0;
    line-height: 1.45;
}

.working-card li::before {
    content: counter(step);
    flex: 0 0 auto;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(56, 189, 248, 0.16);
    color: var(--accent);
    font-size: 0.82rem;
    font-weight: 700;
}

.caveat {
    color: #94a3b8;
    font-size: 0.9rem;
    line-height: 1.5;
}

.caveat a {
    color: var(--accent);
}

@media (max-width: 680px) {
    .choice-group,
    .income-row,
    .pair {
        grid-template-columns: 1fr;
    }

    .rate-adorned {
        max-width: none;
    }

    .adorned input {
        font-size: 1.25rem;
    }
}
