/* PetsCare extras — new design tokens only. Old navy/AKC styles removed. */

.az-letter {
    width: 2.15rem;
    height: 2.15rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    font-weight: 700;
    font-size: 0.8125rem;
    color: #063737;
    background-color: #fff;
    border: 1px solid rgb(6 55 55 / 0.12);
    cursor: pointer;
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

    .az-letter:hover {
        background-color: #e8c9cf;
        border-color: #e8c9cf;
    }

    .az-letter.active {
        background-color: #063737;
        border-color: #063737;
        color: #fff;
    }

.quiz-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.quiz-option:has(input[type="radio"]:checked) {
    background-color: #e8c9cf;
    border-color: #063737;
}

    .quiz-option:has(input[type="radio"]:checked) .quiz-option-icon {
        background-color: #063737;
        color: #fff;
    }

    .quiz-option:has(input[type="radio"]:checked) .quiz-option-label {
        color: #063737;
        font-weight: 700;
    }

.breed-compare-toggle {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    z-index: 5;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin: 0;
    padding: 0.4rem 0.75rem;
    border-radius: 9999px;
    background: rgb(255 255 255 / 0.96);
    color: #063737;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1;
    box-shadow: 0 4px 14px rgb(6 55 55 / 0.14);
    cursor: pointer;
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

    .breed-compare-toggle:hover {
        background: #fff;
    }

    .breed-compare-toggle:has(.js-compare-toggle:checked) {
        background-color: #e8c9cf;
        color: #063737;
    }

.breed-compare-check {
    display: flex;
    height: 1.15rem;
    width: 1.15rem;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    border-radius: 0.3rem;
    border: 1.5px solid rgb(6 55 55 / 0.35);
    background: #fff;
    color: transparent;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.breed-compare-toggle:has(.js-compare-toggle:checked) .breed-compare-check {
    background-color: #063737;
    border-color: #063737;
    color: #fff;
}

.breed-card-group-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    z-index: 4;
    border-radius: 9999px;
    background: rgb(6 55 55 / 0.8);
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.compare-picker-row {
    display: flex;
    align-items: stretch;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px 12px;
}

.compare-vs {
    display: flex;
    align-items: center;
    font-weight: 800;
    font-size: 0.9rem;
    letter-spacing: 0.08em;
    color: #a25524;
    padding: 0 4px;
}

.compare-picker-card {
    position: relative;
    width: 210px;
    min-height: 260px;
    background: #fff;
    border: 1px solid rgb(6 55 55 / 0.08);
    border-radius: 1.5rem;
    box-shadow: 0 8px 24px rgb(6 55 55 / 0.05);
    padding: 28px 18px 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

    .compare-picker-card.filled {
        border-color: #e8c9cf;
        background-color: #fff;
    }

    .compare-picker-card.add {
        border: 2px dashed rgb(6 55 55 / 0.18);
        background: #fafafa;
        justify-content: center;
    }

.compare-picker-photo {
    width: 5.5rem;
    height: 5.5rem;
    border-radius: 1.25rem;
    overflow: hidden;
    margin-bottom: 14px;
    border: 2px solid #fff;
    background: #f0f0f0;
    box-shadow: 0 4px 16px rgb(6 55 55 / 0.08);
    flex-shrink: 0;
}

    .compare-picker-photo img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

    .compare-picker-photo.is-placeholder {
        display: flex;
        align-items: center;
        justify-content: center;
        color: rgb(6 55 55 / 0.25);
    }

.compare-picker-name {
    font-size: 1.05rem;
    font-weight: 800;
    margin: 0 0 10px;
}

    .compare-picker-name a {
        color: #063737;
    }

.compare-picker-label {
    font-weight: 700;
    color: #063737;
    margin-bottom: 10px;
}

.compare-picker-remove {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    background: #063737;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

    .compare-picker-remove:hover {
        background: #a25524;
    }

.compare-add-trigger {
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    color: #063737;
    font-weight: 700;
    font-size: 1rem;
    width: 100%;
    height: 100%;
    min-height: 220px;
    justify-content: center;
}

.compare-add-plus {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: #063737;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.compare-add-trigger:hover .compare-add-plus {
    background: #a25524;
}

.compare-add-panel {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: center;
}

.compare-picker-card.add.is-open .compare-add-trigger {
    display: none;
}

.compare-picker-card.add.is-open .compare-add-panel {
    display: flex;
}

.compare-select-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
    padding: 0;
    margin: -1px;
}

.compare-combobox {
    position: relative;
    width: 100%;
}

.compare-combobox-input {
    width: 100%;
    padding: 8px 12px;
    font-size: 0.85rem;
    border-radius: 9999px;
    border: 1px solid rgb(6 55 55 / 0.12);
    background: #fff;
    color: #063737;
    outline: none;
}

    .compare-combobox-input:focus {
        border-color: #a25524;
    }

.compare-combobox-list {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 30;
    max-height: 220px;
    overflow-y: auto;
    margin: 0;
    padding: 6px 0;
    list-style: none;
    background: #fff;
    border: 1px solid rgb(6 55 55 / 0.08);
    border-radius: 1rem;
    box-shadow: 0 10px 30px rgb(6 55 55 / 0.1);
    text-align: left;
}

    .compare-combobox-list button {
        display: flex;
        width: 100%;
        align-items: center;
        gap: 10px;
        border: none;
        background: transparent;
        text-align: left;
        padding: 8px 12px;
        font: inherit;
        font-size: 0.85rem;
        color: #063737;
        cursor: pointer;
    }

.compare-combobox-img {
    width: 36px;
    height: 36px;
    border-radius: 9999px;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgb(6 55 55 / 0.08);
    background: #f0f0f0;
}

.compare-combobox-img--placeholder {
    display: block;
}

.compare-combobox-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.compare-combobox-name {
    font-weight: 700;
    line-height: 1.2;
}

.compare-combobox-group {
    font-size: 0.75rem;
    color: rgb(6 55 55 / 0.5);
}

.compare-combobox-list button:hover,
.compare-combobox-list button.is-active {
    background: #e8c9cf;
}

.compare-combobox-empty {
    padding: 10px 12px;
    color: rgb(6 55 55 / 0.55);
    font-size: 0.85rem;
}

.compare-tray {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 90;
    background: #063737;
    color: #fff;
    box-shadow: 0 -8px 24px rgb(6 55 55 / 0.18);
    padding: 14px 0;
}

.compare-tray-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.compare-tray-picks {
    display: flex;
    align-items: center;
    gap: 10px;
    overflow-x: auto;
    min-width: 0;
}

.compare-tray-breed {
    position: relative;
    width: 52px;
    height: 52px;
}

    .compare-tray-breed img {
        width: 52px;
        height: 52px;
        object-fit: cover;
        border-radius: 50%;
        border: 2px solid #e8c9cf;
        display: block;
        background: #f0f0f0;
    }

.compare-tray-remove {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 18px;
    height: 18px;
    border: none;
    border-radius: 50%;
    background: #a25524;
    color: #fff;
    font-size: 0.7rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.compare-tray-actions {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

.compare-tray-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    margin: 0;
    padding: 0;
    border: 1px solid rgb(255 255 255 / 0.25);
    border-radius: 9999px;
    background: transparent;
    color: #fff;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

    .compare-tray-close:hover,
    .compare-tray-close:focus-visible {
        background: rgb(255 255 255 / 0.12);
        border-color: rgb(255 255 255 / 0.45);
        outline: none;
    }

.compare-tray-count {
    font-size: 0.9rem;
    font-weight: 600;
    color: rgb(255 255 255 / 0.7);
    white-space: nowrap;
}

.compare-tray-btn.is-disabled {
    opacity: 0.45;
    pointer-events: none;
}

body.has-compare-tray {
    padding-bottom: 96px;
}

    /* Keep scroll-to-top above the compare tray */
    body.has-compare-tray .scroll-to-top {
        bottom: 6.75rem;
        z-index: 95;
    }

@media (max-width: 640px) {
    body.has-compare-tray .scroll-to-top {
        bottom: 6.25rem;
    }

    .home-pg-hero {
        height: 100vh !important;
    }

    h1.hero-title {
        font-size: 24px !important;
        line-height: 1.2;
    }

    .home-pg-hero .inline-button {
        gap: 8px !important;
    }

        .home-pg-hero .inline-button a {
            min-width: 100px !important;
            font-size: 15px !important;
            white-space: nowrap;
            flex: 1 1 100px !important;
        }
}

.breed-card.is-compare-selected {
    box-shadow: 0 0 0 2px #a25524;
}

.cms-html-content img {
    max-width: 100%;
    width: 100%;
    height: auto;
    border-radius: 1rem;
    margin: 12px 0;
}

.cms-html-content p {
    margin-bottom: 15px;
    font-size: 1.05rem;
    line-height: 1.5;
    color: black;
}

.cms-html-content ul,
.cms-html-content ol {
    margin: 0 0 16px;
    padding-left: 22px;
}

.cms-html-content li {
    margin-bottom: 6px;
    line-height: 1.6;
}

.cms-html-content h2 {
    font-size: clamp(25px, 3vw, 30px);
    color: #063737;
    margin: 0px 0 12px;
}

    .cms-html-content h2:first-child {
        margin-top: 0;
    }

.cms-html-content h3,
.cms-html-content h4 {
    color: #063737;
    margin: 0px 0 12px;
}

.cms-html-content h4 {
    font-size: clamp(18px, 2vw, 21px);
}

.cms-html-content h3 {
    font-size: clamp(20px, 2vw, 25px);
}

.cms-html-content a {
    color: #a25524;
    font-weight: 600;
}

/* CMS Related reading — card grid (all links auto-flow) */
.cms-related-reading ul,
.cms-related-reading ol {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

@media (min-width: 480px) {
    .cms-related-reading ul,
    .cms-related-reading ol {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 768px) {
    .cms-related-reading ul,
    .cms-related-reading ol {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.cms-related-reading li {
    margin: 0;
}

.cms-related-reading li a {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 3.25rem;
    height: 100%;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    background: #fff;
    box-shadow: 0 2px 10px rgb(6 55 55 / 0.08);
    border: 1px solid rgb(6 55 55 / 0.14);
    color: #063737;
    font-weight: 600;
    font-size: 0.9rem;
    line-height: 1.35;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.cms-related-reading li a:hover,
.cms-related-reading li a:focus-visible {
    background: #063737;
    color: #fff;
    box-shadow: 0 4px 14px rgb(6 55 55 / 0.18);
    outline: none;
}

.cms-html-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
}

    .cms-html-content table td,
    .cms-html-content table th {
        border: 1px solid rgb(6 55 55 / 0.08);
        padding: 8px 10px;
    }

.breed-chat-fab {
    position: fixed;
    right: 24px;
    /* Sit above global scroll-to-top so they don't overlap */
    bottom: 5.75rem;
    z-index: 1200;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: none;
    border-radius: 999px;
    padding: 14px 20px;
    background: #a25524;
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    box-shadow: 0 10px 24px rgb(162 85 36 / 0.35);
    cursor: pointer;
}

    .breed-chat-fab:hover {
        background: #8c471e;
    }

.breed-chat-overlay {
    position: fixed;
    inset: 0;
    background: rgb(6 55 55 / 0.45);
    z-index: 1300;
    opacity: 0;
    transition: opacity 0.25s ease;
}

    .breed-chat-overlay.visible {
        opacity: 1;
    }

.breed-chat-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: min(420px, 100%);
    height: 100vh;
    background: #fff;
    z-index: 1400;
    display: flex;
    flex-direction: column;
    box-shadow: -12px 0 40px rgb(6 55 55 / 0.18);
    transform: translateX(105%);
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.28s ease, visibility 0s linear 0.28s;
    overflow: hidden;
}

    .breed-chat-sidebar.open {
        transform: translateX(0);
        visibility: visible;
        pointer-events: auto;
        transition: transform 0.28s ease, visibility 0s;
    }

.breed-chat-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 18px;
    border-bottom: 1px solid rgb(6 55 55 / 0.08);
    background: #063737;
    color: #fff;
}

    .breed-chat-header h3 {
        color: #fff;
        font-size: 1.15rem;
        margin-bottom: 4px;
    }

    .breed-chat-header p {
        color: rgb(255 255 255 / 0.7);
        font-size: 0.82rem;
        margin: 0;
    }

.breed-chat-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    padding: 0;
    border: none;
    border-radius: 8px;
    background: rgb(255 255 255 / 0.12);
    color: #fff;
    cursor: pointer;
    line-height: 0;
}

    .breed-chat-close svg {
        display: block;
    }

.breed-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 18px;
    background: #fafafa;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.breed-chat-bubble {
    max-width: 90%;
    padding: 12px 14px;
    border-radius: 14px;
    font-size: 0.92rem;
    line-height: 1.55;
    word-break: break-word;
}

    .breed-chat-bubble.assistant {
        align-self: flex-start;
        background: #fff;
        border: 1px solid rgb(6 55 55 / 0.08);
        color: #063737;
    }

    .breed-chat-bubble.user {
        align-self: flex-end;
        background: #063737;
        color: #fff;
        white-space: pre-wrap;
    }

    .breed-chat-bubble.thinking {
        display: inline-flex;
        align-items: center;
        gap: 5px;
        min-height: 20px;
        padding-top: 14px;
        padding-bottom: 14px;
        color: rgb(6 55 55 / 0.55);
        font-style: normal;
        white-space: normal;
    }

.breed-chat-typing-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #063737;
    opacity: 0.45;
    animation: breed-chat-typing-bounce 1.2s ease-in-out infinite;
}

    .breed-chat-typing-dot:nth-child(2) {
        animation-delay: 0.15s;
    }

    .breed-chat-typing-dot:nth-child(3) {
        animation-delay: 0.3s;
    }

@keyframes breed-chat-typing-bounce {
    0%,
    60%,
    100% {
        transform: translateY(0);
        opacity: 0.35;
    }

    30% {
        transform: translateY(-5px);
        opacity: 0.9;
    }
}

/* Hero / breeds directory search suggestions */
.breed-suggest {
    position: relative;
    width: 100%;
}

.breed-suggest-list {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 8px);
    z-index: 40;
    max-height: 280px;
    overflow-y: auto;
    margin: 0;
    padding: 8px 0;
    list-style: none;
    background: #fff;
    border: 1px solid rgb(6 55 55 / 0.1);
    border-radius: 1.25rem;
    box-shadow: 0 14px 40px rgb(6 55 55 / 0.14);
    text-align: left;
}

    .breed-suggest-list[hidden] {
        display: none !important;
    }

    .breed-suggest-list button {
        display: flex;
        width: 100%;
        align-items: center;
        gap: 12px;
        border: none;
        background: transparent;
        text-align: left;
        padding: 10px 14px;
        font: inherit;
        font-size: 0.95rem;
        color: #063737;
        cursor: pointer;
    }

    .breed-suggest-list button:hover,
    .breed-suggest-list button.is-active {
        background: #e8c9cf;
    }

.breed-suggest-img {
    width: 40px;
    height: 40px;
    border-radius: 9999px;
    object-fit: cover;
    flex-shrink: 0;
    background: #f0f0f0;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgb(6 55 55 / 0.08);
}

.breed-suggest-img--placeholder {
    display: block;
}

.breed-suggest-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.breed-suggest-name {
    font-weight: 700;
    line-height: 1.25;
}

.breed-suggest-group {
    font-size: 0.75rem;
    color: rgb(6 55 55 / 0.5);
}

.breed-suggest-empty {
    padding: 12px 14px;
    color: rgb(6 55 55 / 0.55);
    font-size: 0.9rem;
}

.breed-suggest--hero .breed-suggest-list {
    left: 0;
    right: 0;
}

    .breed-chat-bubble p {
        margin: 0 0 8px;
    }

        .breed-chat-bubble p:last-child {
            margin-bottom: 0;
        }

    .breed-chat-bubble ul {
        margin: 6px 0 10px;
        padding-left: 18px;
    }

    .breed-chat-bubble strong {
        font-weight: 700;
        color: #063737;
    }

.breed-chat-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 12px;
}

.breed-chat-image-link {
    display: block;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgb(6 55 55 / 0.08);
    background: #f0f0f0;
}

    .breed-chat-image-link img {
        width: 100%;
        height: 110px;
        object-fit: cover;
        display: block;
    }

.breed-chat-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 10px;
    padding: 14px;
    border-top: 1px solid rgb(6 55 55 / 0.08);
    background: #fff;
}

    .breed-chat-form textarea {
        width: 100%;
        min-width: 0;
        resize: none;
        min-height: 44px;
        max-height: 240px;
        border: 1px solid rgb(6 55 55 / 0.12);
        border-radius: 10px;
        padding: 10px 12px;
        font: inherit;
        outline: none;
        color: #063737;
    }

        .breed-chat-form textarea:focus {
            border-color: #a25524;
            box-shadow: 0 0 0 3px rgb(162 85 36 / 0.12);
        }

body.breed-chat-open {
    overflow: hidden;
}

#match-results {
    scroll-margin-top: 96px;
}

.trait-name {
    font-weight: 700;
    color: #063737;
}

@media (max-width: 576px) {
    .breed-chat-fab span {
        display: none;
    }

    .breed-chat-form {
        margin: 0 0 15px;
    }

    .breed-chat-fab {
        width: 56px;
        height: 56px;
        padding: 0;
        justify-content: center;
        border-radius: 50%;
        bottom: 5.25rem;
        right: 1rem;
    }

    .compare-picker-card {
        width: 160px;
        min-height: 240px;
        padding: 22px 12px 14px;
    }

    .compare-vs {
        width: 100%;
        justify-content: center;
    }

    .compare-tray-inner {
        flex-direction: column;
        align-items: stretch;
    }
}

.breed-photo-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

@media (min-width: 640px) {
    .breed-photo-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.breed-photo-grid img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 1rem;
    background: #f3eee8;
}

/* Breed details sidebar — lock related-breed thumbs (designer: h-14 w-14) */
.breed-sidebar-item img {
    width: 3.5rem;
    height: 3.5rem;
    flex-shrink: 0;
    border-radius: 0.75rem;
    object-fit: cover;
}

/* Standalone breed-card-btn (e.g. sidebar) — same fill hover as breed cards */
a.breed-card-btn:hover,
a.breed-card-btn:focus-visible {
    background-color: #063737;
    color: #fff;
}

/* Official Trait Ratings accordion (breed details only) */
.trait-accordion-trigger {
    display: flex;
    width: 100%;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 0 0 1.25rem;
    margin: 0;
    border: none;
    border-bottom: 1px solid rgb(6 55 55 / 0.08);
    background: transparent;
    cursor: pointer;
    text-align: left;
}

.trait-accordion-icon {
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 9999px;
    background: #eef2f6;
    color: #1e293b;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.trait-accordion-trigger:hover .trait-accordion-icon,
.trait-accordion-trigger:focus-visible .trait-accordion-icon {
    background: #e2e8f0;
}

.trait-accordion-trigger:focus-visible {
    outline: none;
}

    .trait-accordion-trigger:focus-visible .trait-accordion-icon {
        box-shadow: 0 0 0 3px rgb(6 55 55 / 0.2);
    }

.trait-accordion .trait-icon-plus {
    display: none;
}

.trait-accordion .trait-icon-minus {
    display: block;
}

.trait-accordion:not(.is-open) .trait-icon-plus {
    display: block;
}

.trait-accordion:not(.is-open) .trait-icon-minus {
    display: none;
}

.trait-accordion-panel {
    display: grid;
    grid-template-rows: 1fr;
    transition: grid-template-rows 0.35s ease;
}

.trait-accordion:not(.is-open) .trait-accordion-panel {
    grid-template-rows: 0fr;
}

.trait-accordion-panel-inner {
    overflow: hidden;
    min-height: 0;
}

.trait-accordion:not(.is-open) .trait-accordion-trigger {
    border-bottom-color: transparent;
    padding-bottom: 0;
}

/* Scroll to top — black badge, white arrow */
.scroll-to-top {
    position: fixed;
    right: 1.25rem;
    bottom: 1.5rem;
    z-index: 60;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3.25rem;
    height: 3.25rem;
    padding: 0;
    border: none;
    border-radius: 0.75rem;
    background: #000;
    color: #fff;
    cursor: pointer;
    box-shadow: 0 4px 16px rgb(0 0 0 / 0.32);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(8px);
    transition: opacity 0.25s ease, visibility 0.25s ease, transform 0.25s ease, background-color 0.2s ease;
}

    .scroll-to-top.is-visible {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    .scroll-to-top:hover,
    .scroll-to-top:focus-visible {
        background: #111;
        outline: none;
    }

    .scroll-to-top:focus-visible {
        box-shadow: 0 0 0 3px rgb(232 201 207 / 0.55);
    }

    .scroll-to-top svg {
        width: 1.35rem;
        height: 1.35rem;
        stroke: #fff;
        color: #fff;
    }

/* Breed details breadcrumb — force visible on forest hero (Tailwind /70 /35 may be purged) */
.breed-detail-breadcrumb,
.breed-detail-breadcrumb a {
    color: #fff;
}

    .breed-detail-breadcrumb a {
        color: rgb(255 255 255 / 0.88);
        text-shadow: 0 1px 2px rgb(0 0 0 / 0.25);
    }

        .breed-detail-breadcrumb a:hover,
        .breed-detail-breadcrumb a:focus-visible {
            color: #fff;
        }

        .breed-detail-breadcrumb a[aria-current="page"] {
            color: #fff;
            font-weight: 700;
        }

    .breed-detail-breadcrumb span[aria-hidden="true"] {
        color: rgb(255 255 255 / 0.55);
    }

@media (max-width: 640px) {
    .scroll-to-top {
        right: 1rem;
        bottom: 1.15rem;
        width: 3rem;
        height: 3rem;
    }
}

/* ===== CMS FAQs accordion (one open at a time) ===== */
.cms-faqs {
    padding-top: 2.75rem;
    padding-bottom: 5rem; /* clear gap before footer */
}

@media (min-width: 640px) {
    .cms-faqs {
        padding-bottom: 6rem;
    }
}

.cms-faqs-title {
    color: #063737;
}

.cms-faqs-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.cms-faq-item {
    position: relative;
}

.cms-faq-trigger {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    width: 100%;
    padding: 0;
    border: none;
    background: transparent;
    text-align: left;
    cursor: pointer;
    color: #063737;
}

    .cms-faq-trigger:focus-visible {
        outline: 2px solid #a25524;
        outline-offset: 4px;
        border-radius: 4px;
    }

.cms-faq-accent {
    flex-shrink: 0;
    width: 3px;
    min-height: 1.35rem;
    margin-top: 0.2rem;
    border-radius: 2px;
    background: #a25524;
    align-self: stretch;
    transition: background-color 0.2s ease;
}

.cms-faq-item.is-open .cms-faq-accent {
    background: #063737;
}

.cms-faq-question {
    flex: 1;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.45;
    color: #063737;
}

.cms-faq-panel {
    padding: 0.65rem 0 0.15rem 1.05rem;
}

.cms-faq-answer {
    margin: 0;
    font-size: 0.975rem;
    font-weight: 500;
    line-height: 1.65;
    color: rgb(6 55 55 / 0.72);
    white-space: pre-wrap;
}

/* ===== Breed match quiz (15-step) ===== */
.breed-match-hero-media {
    height: 65vh;
    min-height: 500px;
}

.match-progress-track {
    height: 0.4rem;
    border-radius: 999px;
    background: rgb(6 55 55 / 0.08);
    overflow: hidden;
}

.match-progress-fill {
    height: 100%;
    width: 0;
    border-radius: 999px;
    background: #a25524;
    transition: width 0.25s ease;
}

.match-quiz-error:not([hidden]) {
    display: block;
}

#breedMatchQuiz .quiz-options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

@media (min-width: 640px) {
    #breedMatchQuiz .quiz-options {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

#breedMatchQuiz .quiz-option {
    min-height: 3.25rem;
    width: 100%;
    margin: 0;
    justify-content: center;
    text-align: center;
}

#breedMatchQuiz .quiz-option-label {
    text-align: center;
}

/* Real spacing — Tailwind pt-* utilities are often missing from output.css */
.match-results-section {
    padding-top: 4.5rem;
    padding-bottom: 4rem;
}

@media (min-width: 640px) {
    .match-results-section {
        padding-top: 5.5rem;
    }
}

.match-how-section {
    padding-top: 1.5rem;
    padding-bottom: 1rem;
}

.match-faq-section {
    padding-top: 3rem;
    padding-bottom: 5rem;
}

.match-results-header {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-bottom: 3.25rem;
}

.match-faq-heading {
    color: #063737;
    text-align: left;
}

@media (min-width: 768px) {
    .match-results-header {
        flex-direction: row;
        align-items: flex-end;
        justify-content: space-between;
    }
}

.match-results-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    flex-shrink: 0;
}

.match-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.75rem;
    padding: 0.65rem 1.35rem;
    border-radius: 999px;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    border: 1px solid transparent;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.match-action-btn--ghost {
    background: #fff;
    color: #063737;
    border-color: rgb(6 55 55 / 0.18);
}

.match-action-btn--ghost:hover {
    background: #e8c9cf44;
}

.match-action-btn--primary {
    background: #a25524;
    color: #fff;
}

.match-action-btn--primary:hover {
    background: #8c471e;
    color: #fff;
}

.match-results-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    align-items: stretch;
}

@media (min-width: 768px) {
    .match-results-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1100px) {
    .match-results-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.match-result-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-width: 0;
    overflow: hidden;
    background: #fff;
    border-radius: 1.25rem;
    box-shadow: 0 10px 30px rgb(6 55 55 / 0.08);
}

.match-result-card-media {
    position: relative;
    flex-shrink: 0;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #e8eee8;
}

.match-result-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.match-result-card-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    padding: 1.15rem 1.25rem 1.35rem;
    min-height: 0;
}

.match-result-card-title {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1.25;
    color: #063737;
    min-height: 2.5rem;
}

.match-result-card-title a {
    color: inherit;
    text-decoration: none;
}

.match-result-card-title a:hover {
    color: #a25524;
}

.match-result-traits {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem 0.85rem;
    margin: 0.9rem 0 0;
    min-height: 7.5rem;
}

.match-result-traits-full {
    grid-column: 1 / -1;
}

.match-result-traits dt {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 500;
    color: rgb(0 0 0 / 0.45);
}

.match-result-traits dd {
    margin: 0.15rem 0 0;
    font-size: 0.9rem;
    font-weight: 700;
    color: #063737;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.4em;
}

.match-result-reasons {
    margin: 0.85rem 0 0;
    padding-left: 1.15rem;
    min-height: 3.4rem;
    list-style: disc;
}

.match-result-reasons li {
    font-size: 0.875rem;
    line-height: 1.45;
    color: rgb(6 55 55 / 0.65);
}

.match-result-reasons li.is-placeholder {
    list-style: none;
    visibility: hidden;
}

.match-result-card-actions {
    margin-top: auto;
    padding-top: 1.15rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.match-result-guide-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 2.85rem;
    padding: 0.7rem 1rem;
    border-radius: 999px;
    background: #063737;
    color: #fff !important;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.match-result-guide-btn:hover {
    background: #0a4a4a;
    color: #fff !important;
}

.match-result-card:hover .match-result-guide-btn,
.match-result-card:focus-within .match-result-guide-btn {
    background: #063737;
    color: #fff !important;
}

.match-result-compare {
    position: static;
    transform: none;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    align-self: flex-start;
    margin: 0;
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    border: 1px solid rgb(6 55 55 / 0.12);
    background: #fff;
    font-size: 0.8rem;
    font-weight: 600;
    color: #063737;
    cursor: pointer;
}

.match-faq-item {
    border-bottom: 1px solid rgb(6 55 55 / 0.08);
    padding: 0.85rem 0;
}

.match-faq-item summary {
    cursor: pointer;
    font-weight: 700;
    color: #063737;
    list-style: none;
}

.match-faq-item summary::-webkit-details-marker {
    display: none;
}

.match-faq-item summary::before {
    content: "";
    display: inline-block;
    width: 3px;
    height: 1.1rem;
    margin-right: 0.75rem;
    vertical-align: -0.15rem;
    border-radius: 2px;
    background: #a25524;
}

.match-faq-item p {
    margin: 0.65rem 0 0.25rem 1.05rem;
    font-size: 0.975rem;
    line-height: 1.65;
    color: rgb(6 55 55 / 0.72);
}

.match-compare-card {
    margin-top: 3rem;
    border-radius: 1.25rem;
    border: 1px solid rgb(6 55 55 / 0.08);
    background: #fff;
    overflow: hidden;
}

.match-compare-card-head {
    padding: 1.25rem 1.25rem 0.85rem;
}

@media (min-width: 640px) {
    .match-compare-card-head {
        padding: 1.5rem 1.5rem 1rem;
    }
}

/* Mobile stacked compare */
.match-compare-mobile {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 0 1rem 1rem;
}

.match-compare-mobile-item {
    padding: 1rem 0;
    border-top: 1px solid rgb(6 55 55 / 0.08);
}

.match-compare-mobile-name {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    font-size: 1rem;
    font-weight: 800;
    color: #063737;
}

.match-compare-mobile-name strong {
    flex-shrink: 0;
    font-size: 0.9rem;
    color: #a25524;
}

.match-compare-mobile-traits {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem 0.75rem;
    margin: 0;
}

.match-compare-mobile-traits dt {
    margin: 0;
    font-size: 0.72rem;
    font-weight: 500;
    color: rgb(0 0 0 / 0.45);
}

.match-compare-mobile-traits dd {
    margin: 0.1rem 0 0;
    font-size: 0.875rem;
    font-weight: 700;
    color: #063737;
    line-height: 1.35;
}

.match-compare-scroll {
    display: none;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
}

.match-compare-table {
    width: 100%;
    min-width: 40rem;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.875rem;
}

.match-compare-table th,
.match-compare-table td {
    vertical-align: top;
    padding: 0.85rem 1rem;
    border-top: 1px solid rgb(6 55 55 / 0.08);
}

.match-compare-table thead th {
    background: rgb(248 248 246);
    font-weight: 700;
    color: #063737;
}

.match-compare-table thead th:first-child,
.match-compare-table tbody th {
    position: sticky;
    left: 0;
    z-index: 1;
    background: #fff;
    color: rgb(0 0 0 / 0.5);
    font-weight: 600;
    min-width: 7.5rem;
    box-shadow: 4px 0 8px rgb(6 55 55 / 0.04);
}

.match-compare-table thead th:first-child {
    background: rgb(248 248 246);
    z-index: 2;
}

.match-compare-table tbody td {
    color: #063737;
    min-width: 8rem;
}

@media (min-width: 768px) {
    .match-compare-mobile {
        display: none;
    }

    .match-compare-scroll {
        display: block;
    }
}

#match-results {
    scroll-margin-top: 96px;
}

#breedMatchQuiz {
    scroll-margin-top: 96px;
}

/* Footer social — terracotta accent so icons read clearly on forest */
.social-btn {
    background-color: #a25524;
    color: #fff;
    border: 1px solid rgb(255 255 255 / 0.18);
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.social-btn:hover,
.social-btn:focus-visible {
    background-color: #fff;
    color: #063737;
    border-color: #fff;
    outline: none;
}
