.tp-front :is(.tests-page-main, .tp-test-detail) [hidden] {
    display: none !important;
}

.tp-tests-steps {
    list-style: none;
    margin: 0;
    padding: 0;
}

.tp-tests-steps .how-step-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text-heading);
}

.tp-tests-faq-item .faq-header {
    list-style: none;
}

.tp-tests-faq-item .faq-header::-webkit-details-marker {
    display: none;
}

.tp-tests-faq-item[open] {
    border-color: var(--primary);
}

.tp-tests-faq-item[open] .faq-body {
    display: block;
    max-height: none;
    opacity: 1;
    padding-bottom: 24px;
}

.tp-tests-faq-item[open] .faq-header i {
    transform: rotate(180deg);
}

.tp-front .test-card {
    min-width: 0;
}

.tests-page-main .test-card-desc {
    min-height: 4.65em;
    margin-bottom: 24px;
}

.tests-page-main .test-card-content {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.tests-page-main .test-card-meta {
    margin-top: auto;
}

.tests-page-main .test-card:hover .test-icon-img,
.tp-test-detail .test-intro-icon-img {
    filter: none;
}

.tp-front .tests-grid {
    min-width: 0;
    grid-template-columns: repeat(auto-fill, minmax(min(350px, 100%), 1fr));
}

.tp-test-detail :is(.test-quiz-screen, .test-email-gate-screen, .test-result-screen):not([hidden]) {
    display: block;
}

.tp-test-detail :is(.test-quiz-screen, .test-email-gate-screen, .test-result-screen) {
    scroll-margin-top: 100px;
}

.tp-test-detail .quiz-question-box {
    min-width: 0;
    padding: 0;
    margin: 0;
    border: 0;
}

.tp-test-detail .quiz-q-text {
    float: none;
    padding: 0;
}

.tp-test-detail .tp-question-text {
    display: block;
}

.tp-test-detail .tp-test-option {
    justify-content: flex-start;
    gap: 14px;
}

.tp-test-option input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
}

.tp-test-detail .quiz-option-radio {
    flex-shrink: 0;
}

.tp-test-detail .quiz-option-item:focus-within {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.tp-test-detail .test-guideline-box h2 {
    color: var(--primary);
    font-size: .95rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tp-test-detail .tp-test-option-text {
    flex: 1;
    min-width: 0;
}

.tp-test-detail :is(.quiz-option-label, .quiz-option-sub) {
    display: block;
}

.tp-test-detail .quiz-option-check {
    flex-shrink: 0;
}

.tp-test-detail .result-sent-recipient {
    max-width: 100%;
}

.tp-test-detail [data-test-recipient] {
    overflow-wrap: anywhere;
    min-width: 0;
}

.tp-test-detail .tp-test-error {
    color: #b91c1c;
}

.tp-test-detail :is(.gate-consent-checkbox, .gate-consent-label) {
    flex-shrink: 0;
}

.tp-test-detail :is(button, a, summary):focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 3px;
}

/* Existing API thumbnails fill their square without the icon padding. */
.tests-page-main .test-card-icon.tp-test-thumbnail {
    padding: 0;
    overflow: hidden;
}
.tests-page-main .tp-test-thumbnail .test-icon-img {
    width: 100%;
    height: 100%;
    object-fit: fill;
}

.tp-test-detail .test-intro-icon-wrap {
    padding: 0;
    overflow: hidden;
    aspect-ratio: 1;
}

.tp-test-detail .test-intro-icon-img {
    width: 100%;
    height: 100%;
    object-fit: fill;
}
