:root {
    --htcd-navy: #16213e;
    --htcd-blue: #2563eb;
    --htcd-green: #16a34a;
    --htcd-bg: #f4f6f9;
    --htcd-card: #ffffff;
    --htcd-border: #e4e8ef;
    --htcd-text: #27324a;
    --htcd-muted: #697386;
    --htcd-radius: 14px;
    --htcd-shadow: 0 5px 18px rgba(22, 33, 62, 0.06);
}

.htcd-single,
.htcd-directory {
    width: min(1240px, calc(100% - 36px));
    margin: 0 auto;
    padding: 30px 0 64px;
    color: var(--htcd-text);
}

.htcd-single a,
.htcd-directory a {
    text-decoration: none;
}

.htcd-back-link {
    display: inline-flex;
    margin-bottom: 18px;
    padding: 9px 14px;
    border: 1px solid var(--htcd-border);
    border-radius: 8px;
    background: #fff;
    color: var(--htcd-blue);
    font-weight: 600;
}

.htcd-gallery {
    margin-bottom: 20px;
}

.htcd-gallery-main {
    height: 440px;
    overflow: hidden;
    border-radius: var(--htcd-radius);
    background: #e8ecf2;
}

.htcd-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.htcd-gallery-thumbs {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.htcd-gallery-thumb {
    height: 82px;
    padding: 0;
    overflow: hidden;
    border: 2px solid transparent;
    border-radius: 9px;
    background: #e8ecf2;
    cursor: pointer;
}

.htcd-gallery-thumb.is-active {
    border-color: var(--htcd-blue);
}

.htcd-gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.htcd-clinic-header {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 22px;
    padding: 22px;
    border: 1px solid var(--htcd-border);
    border-radius: var(--htcd-radius);
    background: var(--htcd-card);
    box-shadow: var(--htcd-shadow);
}

.htcd-clinic-logo {
    display: grid;
    place-items: center;
    flex: 0 0 92px;
    width: 92px;
    height: 92px;
    overflow: hidden;
    border: 1px solid var(--htcd-border);
    border-radius: 13px;
    background: #fff;
}

.htcd-clinic-logo img {
    width: 100%;
    height: 100%;
    padding: 7px;
    object-fit: contain;
}

.htcd-clinic-logo span {
    color: var(--htcd-navy);
    font-size: 38px;
    font-weight: 800;
}

.htcd-clinic-heading {
    min-width: 0;
}

.htcd-title-line {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 14px;
}

.htcd-title-line h1 {
    margin: 0;
    color: var(--htcd-navy);
    font-size: clamp(28px, 4vw, 40px);
    line-height: 1.15;
}

.htcd-title-verified,
.htcd-verified-badge {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    background: #dcfce7;
    color: #08783b;
    font-size: 13px;
    font-weight: 700;
}

.htcd-title-verified {
    padding: 6px 10px;
}

.htcd-clinic-location {
    margin: 7px 0 4px;
    color: var(--htcd-muted);
}

.htcd-view-count {
    margin: 0;
    color: var(--htcd-muted);
    font-size: 13px;
}

.htcd-technique-chips,
.htcd-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.htcd-technique-chips a,
.htcd-card-tags span {
    padding: 5px 9px;
    border-radius: 999px;
    background: #eef4ff;
    color: #2454a6;
    font-size: 13px;
    font-weight: 700;
}

.htcd-single-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 24px;
    align-items: start;
}

.htcd-main-column,
.htcd-sidebar {
    min-width: 0;
}

.htcd-sidebar {
    position: sticky;
    top: 24px;
}

.htcd-section-card {
    margin-bottom: 22px;
    overflow: hidden;
    border: 1px solid var(--htcd-border);
    border-radius: var(--htcd-radius);
    background: var(--htcd-card);
    box-shadow: var(--htcd-shadow);
}

.htcd-section-card > h2 {
    margin: 0;
    padding: 18px 22px;
    border-bottom: 1px solid var(--htcd-border);
    color: var(--htcd-navy);
    font-size: 20px;
    line-height: 1.3;
}

.htcd-section-content,
.htcd-prose {
    padding: 22px;
}

.htcd-prose {
    font-size: 16px;
    line-height: 1.8;
}

.htcd-prose > :first-child,
.htcd-section-content > :first-child {
    margin-top: 0;
}

.htcd-prose > :last-child,
.htcd-section-content > :last-child {
    margin-bottom: 0;
}

.htcd-check-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 13px 26px;
    padding: 22px;
}

.htcd-check-grid a {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    color: var(--htcd-text);
    font-weight: 500;
}

.htcd-check-grid a:hover {
    color: var(--htcd-blue);
}

.htcd-check-grid a span {
    display: inline-grid;
    place-items: center;
    flex: 0 0 21px;
    width: 21px;
    height: 21px;
    margin-top: 1px;
    border-radius: 50%;
    background: #e8f8ee;
    color: var(--htcd-green);
    font-size: 13px;
    font-weight: 800;
}

.htcd-info-block + .htcd-info-block {
    margin-top: 22px;
}

.htcd-info-block h3 {
    margin: 0 0 7px;
    color: var(--htcd-navy);
    font-size: 17px;
}

.htcd-contact-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    padding: 18px 18px 4px;
}

.htcd-contact-actions a,
.htcd-filter-actions button,
.htcd-secondary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 9px 12px;
    border: 0;
    border-radius: 8px;
    background: var(--htcd-blue);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.htcd-contact-actions .is-whatsapp {
    background: #159447;
}

.htcd-contact-list {
    padding: 12px 20px 8px;
}

.htcd-contact-map {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    margin: 4px 20px 20px;
    padding: 9px 12px;
    border: 1px solid #bfd0f6;
    border-radius: 8px;
    background: #f2f6ff;
    color: var(--htcd-blue);
    font-weight: 700;
}

.htcd-contact-list p,
.htcd-location-details p,
.htcd-hours-list p {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 10px;
    margin: 0;
    padding: 12px 0;
    border-bottom: 1px solid #edf0f5;
}

.htcd-contact-list p:last-child,
.htcd-location-details p:last-of-type,
.htcd-hours-list p:last-child {
    border-bottom: 0;
}

.htcd-contact-list strong,
.htcd-location-details strong,
.htcd-hours-list strong {
    color: var(--htcd-navy);
    font-size: 14px;
}

.htcd-contact-list a,
.htcd-contact-list span,
.htcd-location-details span {
    color: var(--htcd-text);
    overflow-wrap: anywhere;
}

.htcd-hours-list {
    padding: 7px 20px 14px;
}

.htcd-hours-list p {
    grid-template-columns: 1fr auto;
}

.htcd-hours-closed {
    color: #9a3412;
}

.htcd-hours-open,
.htcd-hours-24h {
    color: #08783b;
}

.htcd-secondary-button {
    margin-top: 15px;
}

.htcd-directory-header {
    max-width: 820px;
    margin-bottom: 26px;
}

.htcd-directory-header h1 {
    margin: 5px 0 12px;
    color: var(--htcd-navy);
    font-size: clamp(32px, 5vw, 50px);
    line-height: 1.08;
}

.htcd-directory-header > p:last-child {
    color: var(--htcd-muted);
    font-size: 18px;
}

.htcd-eyebrow {
    margin: 0;
    color: var(--htcd-blue);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.htcd-filter-form {
    display: grid;
    grid-template-columns: 1.25fr repeat(4, minmax(130px, 1fr)) auto;
    gap: 12px;
    align-items: end;
    margin-bottom: 22px;
    padding: 18px;
    border: 1px solid var(--htcd-border);
    border-radius: var(--htcd-radius);
    background: #fff;
    box-shadow: var(--htcd-shadow);
}

.htcd-filter-form label {
    display: block;
    margin-bottom: 5px;
    color: var(--htcd-navy);
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.htcd-filter-form input,
.htcd-filter-form select {
    width: 100%;
    min-height: 43px;
    padding: 8px 10px;
    border: 1px solid #cfd6e2;
    border-radius: 7px;
    background: #fff;
}

.htcd-filter-actions {
    display: flex;
    align-items: center;
    gap: 9px;
}

.htcd-filter-actions a {
    color: var(--htcd-muted);
    font-size: 13px;
    font-weight: 700;
}

.htcd-results-summary {
    margin-bottom: 14px;
    color: var(--htcd-muted);
}

.htcd-card-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.htcd-clinic-card {
    overflow: hidden;
    border: 1px solid var(--htcd-border);
    border-radius: var(--htcd-radius);
    background: #fff;
    box-shadow: var(--htcd-shadow);
    transition: transform .2s ease, box-shadow .2s ease;
}

.htcd-clinic-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(22, 33, 62, .1);
}

.htcd-card-image {
    position: relative;
    display: block;
    height: 220px;
    overflow: hidden;
    background: #e9edf4;
}

.htcd-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .25s ease;
}

.htcd-clinic-card:hover .htcd-card-image img {
    transform: scale(1.025);
}

.htcd-card-placeholder {
    display: grid;
    place-items: center;
    height: 100%;
    color: var(--htcd-navy);
    font-size: 58px;
    font-weight: 800;
}

.htcd-verified-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 5px 9px;
}

.htcd-card-content {
    padding: 18px;
}

.htcd-card-title {
    margin: 0 0 7px;
    font-size: 21px;
    line-height: 1.25;
}

.htcd-card-title a {
    color: var(--htcd-navy);
}

.htcd-card-location {
    margin: 0 0 12px;
    color: var(--htcd-muted);
    font-size: 14px;
}

.htcd-card-location span {
    color: var(--htcd-blue);
    font-size: 8px;
}

.htcd-card-excerpt {
    margin: 13px 0;
    color: var(--htcd-muted);
    font-size: 14px;
    line-height: 1.6;
}

.htcd-card-link {
    display: inline-flex;
    gap: 7px;
    margin-top: 15px;
    color: var(--htcd-blue);
    font-weight: 800;
}

.htcd-pagination {
    margin-top: 30px;
}

.htcd-pagination ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 7px;
    padding: 0;
    list-style: none;
}

.htcd-pagination a,
.htcd-pagination span {
    display: grid;
    place-items: center;
    min-width: 40px;
    min-height: 40px;
    padding: 7px 11px;
    border: 1px solid var(--htcd-border);
    border-radius: 7px;
    background: #fff;
    color: var(--htcd-text);
}

.htcd-pagination .current {
    border-color: var(--htcd-blue);
    background: var(--htcd-blue);
    color: #fff;
}

.htcd-empty-state {
    padding: 50px 20px;
    border: 1px solid var(--htcd-border);
    border-radius: var(--htcd-radius);
    background: #fff;
    text-align: center;
}

@media (max-width: 1100px) {
    .htcd-filter-form {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .htcd-filter-actions {
        align-self: end;
    }
}

@media (max-width: 900px) {
    .htcd-single-grid {
        display: flex;
        flex-direction: column;
    }

    .htcd-main-column,
    .htcd-sidebar {
        display: contents;
        position: static;
    }

    .htcd-description-card {
        order: 1;
        width: 100%;
    }

    .htcd-techniques-card {
        order: 2;
        width: 100%;
    }

    .htcd-treatments-card {
        order: 3;
        width: 100%;
    }

    .htcd-features-card {
        order: 4;
        width: 100%;
    }

    .htcd-medical-team-card {
        order: 5;
        width: 100%;
    }

    .htcd-location-card {
        display: none;
    }

    .htcd-contact-card {
        order: 6;
        width: 100%;
    }

    .htcd-hours-card {
        order: 7;
        width: 100%;
    }

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

@media (max-width: 680px) {
    .htcd-single,
    .htcd-directory {
        width: min(100% - 24px, 1240px);
        padding-top: 18px;
    }

    .htcd-gallery-main {
        height: 270px;
    }

    .htcd-gallery-thumbs {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .htcd-gallery-thumb {
        height: 64px;
    }

    .htcd-clinic-header {
        align-items: flex-start;
        padding: 16px;
    }

    .htcd-clinic-logo {
        flex-basis: 70px;
        width: 70px;
        height: 70px;
    }

    .htcd-title-line h1 {
        font-size: 27px;
    }

    .htcd-title-verified {
        padding: 4px 8px;
        font-size: 11px;
    }

    .htcd-section-card > h2 {
        padding: 16px 17px;
    }

    .htcd-section-content,
    .htcd-prose,
    .htcd-check-grid {
        padding: 17px;
    }

    .htcd-check-grid {
        grid-template-columns: 1fr;
    }

    .htcd-contact-actions {
        padding: 15px 15px 4px;
    }

    .htcd-contact-list,
    .htcd-hours-list {
        padding-right: 16px;
        padding-left: 16px;
    }

    .htcd-contact-list p,
    .htcd-location-details p {
        grid-template-columns: 78px minmax(0, 1fr);
    }

    .htcd-filter-form {
        grid-template-columns: 1fr;
    }

    .htcd-filter-actions {
        justify-content: space-between;
    }

    .htcd-filter-actions button {
        flex: 1;
    }

    .htcd-card-grid {
        grid-template-columns: 1fr;
    }

    .htcd-card-image {
        height: 210px;
    }
}
