#resultsContainer table {
        width: 100%;
        border-collapse: collapse;
        font-size: 0.85rem;
        margin-top: 0.5rem;
    }

    #resultsContainer thead th {
        padding: 0.5rem 0.75rem;
        font-weight: 600;
        border-bottom: 2px solid #979797;
        text-align: left;
        cursor: pointer;
        user-select: none;
    }

    #resultsContainer thead th.sortable:hover {
        opacity: 0.75;
    }

    #resultsContainer tbody td {
        padding: 0.45rem 0.75rem;
        border-bottom: 1px solid #f1f5f9;
        vertical-align: middle;
    }

    #resultsContainer tbody tr:last-child td {
        border-bottom: none;
    }

    #resultsContainer tbody tr.domain-taken {
        opacity: 0.5;
    }

    /* Premium marker — a name the REGISTRY prices individually, so its figure is far
       above the extension's standard rate. Flagged so a large number does not read as a
       bug. Plain values, matching this template's existing convention (it defines no CSS
       custom properties); the tone is the theme's amber, chosen dark enough to clear
       WCAG AA on the white results table. */
    .domain-premium-badge {
        display: inline-block;
        margin-left: .5rem;
        padding: .1rem .45rem;
        border-radius: 999px;
        font-size: .68rem;
        font-weight: 700;
        letter-spacing: .03em;
        text-transform: uppercase;
        vertical-align: middle;
        background: #fef3c7;
        color: #92400e;
        border: 1px solid #fcd34d;
        white-space: nowrap;
    }

    /* Column 2 (Domain) & Column 3 (Status): Left-aligned */
    #results-table th:nth-child(2),
    #results-table td:nth-child(2),
    #results-table th:nth-child(3),
    #results-table td:nth-child(3) {
        text-align: left;
    }

    /* Column 4 (Price): Fixed width of 10rem */
    #results-table th:nth-child(4),
    #results-table td:nth-child(4) {
        min-width: 10rem;
    }

     /* Column 2 (Domain) & Column 3 (Status): Left-aligned */
    #favorites-table th:nth-child(1),
    #favorites-table td:nth-child(1) {
        min-width: 20rem;
    }

    #favorites-table th:nth-child(2),
    #favorites-table td:nth-child(2),
    #favorites-table th:nth-child(5),
    #favorites-table td:nth-child(5) {
        width: 10rem;
        text-align: left;
    }

    #favorites-table th:nth-child(3),
    #favorites-table td:nth-child(3),
    #favorites-table th:nth-child(4),
    #favorites-table td:nth-child(4){
        width: 4rem;
        text-align: left;
    }

    /* Column 4 (Price): Fixed width of 10rem */
    #favorites-table th:nth-child(4),
    #favorites-table td:nth-child(4) {
        min-width: 10rem;
    }

    #results-table tr{
        height: 54px;
    }

    .select-btn, .remove-favorite-btn{
        padding: 8px;
        display: inline-flex;
    }

    /* Favorites/Cart uses the site's standard .enterra-table class for
       consistency. .enterra-table has its own header alignment rules that
       fought a plain ID-selector override before — these use
       table#favorites-table (element+ID, higher specificity) with
       !important as a hard guarantee against that conflict. */
    table#favorites-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 0.85rem;
    }

    table#favorites-table thead th {
        text-align: left !important;
        padding: 0.5rem 0.75rem !important;
        font-weight: 600 !important;
        border-bottom: 2px solid #979797 !important;
        cursor: default !important;
    }

    table#favorites-table tbody td {
        text-align: left !important;
        padding: 0.45rem 0.75rem !important;
        vertical-align: middle !important;
        border-bottom: 1px solid #f1f5f9 !important;
    }

    table#favorites-table tbody tr:last-child td {
        border-bottom: none !important;
    }

    .rank-cell {
        white-space: nowrap;
    }

    .describe-toggle {
        text-align: center;
        margin-top: 1rem;
    }

    .describe-toggle button {
        background: none;
        border: none;
        text-decoration: underline;
        cursor: pointer;
        font-size: 0.85rem;
        color: inherit;
        opacity: 0.85;
    }

    #describe-panel {
        display: none;
        max-width: 32rem;
        margin: 1rem auto 0;
    }

    #describe-panel textarea {
        width: 100%;
        min-height: 4.5rem;
        resize: vertical;
        border-radius: 0.5rem;
        padding: 0.75rem;
        font-size: 0.9rem;
    }

    #describe-panel .char-count {
        text-align: right;
        font-size: 0.75rem;
        opacity: 0.7;
        margin-top: 0.25rem;
    }

    .missed-it {
        text-decoration: line-through;
        opacity: 0.6;
    }

    /* Honeypot: visually and functionally hidden from real users */
    .hp-field {
        position: absolute;
        left: -9999px;
        top: -9999px;
        width: 1px;
        height: 1px;
        overflow: hidden;
    }

/* Two copies of the "?" help link exist (next to the style toggle,
    and inside the search input-group) — only one shows at a time,
    swapped by breakpoint, since they aren't siblings in the DOM and
    can't be relocated with pure CSS. */
    .mobile-help-link {
        display: none;
    }

    /* Mobile: input takes its own full-width row so the placeholder isn't
       truncated ("e.g. flyfishing, my bu..."); the Search button grows to
       fill its row, the "?" swaps from the input-group to next to the
       style toggle instead. */
    @media (max-width: 640px) {
        .desktop-help-link {
            display: none !important;
        }
        .mobile-help-link {
            display: inline-flex !important;
        }

        #domain-search-form .input-group input#search-term {
            flex-basis: 100% !important;
            flex-grow: 0 !important;
            width: 100% !important;
        }

        #domain-search-form .input-group > button#search-button {
            flex: 1 1 auto !important;
            width: auto !important;
            display: inline-flex !important;
        }
    }

    /* Toggle switch for "Show registered domains" */
    .switch-label {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        cursor: pointer;
        font-size: 0.85rem;
        user-select: none;
    }

    .switch-label input[type="checkbox"] {
        position: absolute;
        opacity: 0;
        width: 0;
        height: 0;
    }

    .switch-track {
        position: relative;
        width: 2.5rem;
        height: 1.4rem;
        background: #cbd5e1;
        border-radius: 999px;
        transition: background-color 0.2s ease;
        flex-shrink: 0;
    }

    .switch-track::before {
        content: "";
        position: absolute;
        top: 0.15rem;
        left: 0.15rem;
        width: 1.1rem;
        height: 1.1rem;
        background: #fff;
        border-radius: 50%;
        transition: transform 0.2s ease;
        box-shadow: 0 1px 2px rgba(0,0,0,0.25);
    }

    .switch-label input[type="checkbox"]:checked + .switch-track {
        background: #ff7a2c;
    }

    .switch-label input[type="checkbox"]:checked + .switch-track::before {
        transform: translateX(1.1rem);
    }

    .switch-label input[type="checkbox"]:focus-visible + .switch-track {
        outline: 2px solid #f4b400;
        outline-offset: 2px;
    }
