.dpc-front-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin: 24px 0;
}

.dpc-front-card {
    overflow: hidden;
    border: 1px solid #dbe5ea;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(26, 44, 56, .07);
}

.dpc-thumb {
    display: block;
    min-height: 180px;
    background: #eef4f7;
}

.dpc-thumb img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.dpc-doctor-card {
    display: grid;
    grid-template-columns: 132px minmax(0, 1fr);
}

.dpc-doctor-card .dpc-thumb {
    min-height: 100%;
}

.dpc-doctor-card .dpc-thumb img {
    height: 100%;
}

.dpc-card-body {
    padding: 16px;
}

.dpc-card-body h3 {
    margin: 0 0 8px;
    font-size: 20px;
}

.dpc-card-body h3 a {
    color: #17212b;
    text-decoration: none;
}

.dpc-card-body p {
    color: #657180;
    line-height: 1.7;
}

.dpc-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 8px;
    font-size: 13px;
}

.dpc-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.dpc-row strong,
.dpc-benefit-card strong {
    color: #f08a4b;
    font-size: 24px;
}

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

.dpc-slots span {
    padding: 6px 9px;
    border-radius: 6px;
    color: #0958d9;
    background: #e6f4ff;
    font-size: 13px;
}

.dpc-benefit-card {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 18px;
}

.dpc-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 16px;
    border: 0;
    border-radius: 8px;
    color: #fff;
    background: #1677ff;
    text-decoration: none;
}

.dpc-appointment-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    max-width: 760px;
    padding: 18px;
    border: 1px solid #dbe5ea;
    border-radius: 8px;
    background: #fff;
}

.dpc-appointment-form.has-subject-picker {
    overflow: hidden;
    gap: 16px;
    padding: 0 28px 28px;
    border-color: rgba(219, 229, 234, .86);
    border-radius: 8px;
    box-shadow: 0 20px 48px rgba(23, 33, 43, .12);
}

.dpc-appointment-form.has-subject-picker.is-search-only {
    display: block;
    max-width: none;
    padding: 0;
    border: 0;
    box-shadow: none;
}

.side-form .dpc-appointment-form {
    grid-template-columns: 1fr;
    gap: 14px;
    width: 100%;
    max-width: none;
    padding: 22px;
    box-shadow: 0 12px 30px rgba(23, 33, 43, .08);
}

.dpc-form-context {
    display: grid;
    gap: 5px;
    grid-column: 1 / -1;
    padding: 14px;
    border-radius: 8px;
    color: #17212b;
    background: #e6f4ff;
}

.dpc-form-context span {
    color: #0958d9;
    font-size: 13px;
    font-weight: 700;
}

.dpc-form-context strong {
    font-size: 18px;
    line-height: 1.35;
}

.dpc-form-context em {
    color: #667481;
    font-style: normal;
    line-height: 1.45;
}

.dpc-subject-panel {
    display: grid;
    gap: 0;
    grid-column: 1 / -1;
    margin: 0 -28px 4px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: #fff;
}

.dpc-appointment-form.is-search-only .dpc-subject-panel {
    margin: 0;
}

.dpc-subject-title {
    color: #17212b;
    font-size: 15px;
    font-weight: 800;
}

.dpc-subject-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    border-bottom: 1px solid #e6edf3;
    background: #fbfdff;
}

.dpc-subject-tabs label {
    display: block;
}

.dpc-subject-tabs input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.dpc-subject-tabs span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 72px;
    border: 0;
    border-radius: 0;
    color: #667481;
    background: transparent;
    font-size: 22px;
    font-weight: 800;
    cursor: pointer;
    transition: color .2s ease, background .2s ease;
}

.dpc-subject-tabs span::before {
    content: "";
    display: inline-block;
    width: 21px;
    height: 21px;
    border: 2px solid currentColor;
    border-radius: 50%;
    box-sizing: border-box;
}

.dpc-subject-tabs label:nth-child(2) span::before {
    border-radius: 4px;
    box-shadow: inset 0 -6px 0 rgba(102, 116, 129, .16);
}

.dpc-subject-tabs input:checked + span {
    color: #0958d9;
    background: #e6f4ff;
}

.dpc-subject-fields {
    display: grid;
    gap: 18px;
    padding: 26px 28px 22px;
    background: rgba(255, 255, 255, .94);
}

.dpc-subject-selects {
    display: grid;
}

.dpc-appointment-form .dpc-subject-select {
    display: none;
}

.dpc-appointment-form .dpc-subject-select.is-active,
.dpc-appointment-form:has(input[name="subject_type"][value="doctor"]:checked) .dpc-subject-select.is-doctor,
.dpc-appointment-form:has(input[name="subject_type"][value="clinic"]:checked) .dpc-subject-select.is-clinic {
    display: grid;
}

.dpc-subject-select select,
.dpc-keyword-field input {
    width: 100%;
    min-height: 62px;
    padding: 0 18px 0 48px;
    border: 1px solid #dbe5ea;
    border-radius: 8px;
    background: #fff;
    color: #17212b;
    font-size: 18px;
    outline: none;
}

.dpc-keyword-field,
.dpc-subject-select {
    position: relative;
}

.dpc-keyword-field::before,
.dpc-subject-select::before {
    content: "";
    position: absolute;
    left: 18px;
    bottom: 20px;
    width: 18px;
    height: 18px;
    border: 2px solid #17212b;
    border-radius: 50%;
    opacity: .78;
    pointer-events: none;
    box-sizing: border-box;
}

.dpc-keyword-field::after {
    content: "";
    position: absolute;
    left: 34px;
    bottom: 18px;
    width: 8px;
    height: 2px;
    background: #17212b;
    opacity: .78;
    transform: rotate(45deg);
    transform-origin: left center;
    pointer-events: none;
}

.dpc-subject-select::before {
    border-radius: 4px;
    border-color: #17212b;
}

.dpc-subject-select select:focus,
.dpc-keyword-field input:focus {
    border-color: #1677ff;
    box-shadow: 0 0 0 3px rgba(22, 119, 255, .12);
}

.dpc-appointment-form .dpc-filter-group {
    display: none;
    gap: 12px;
}

.dpc-appointment-form .dpc-filter-group.is-active,
.dpc-appointment-form:has(input[name="subject_type"][value="doctor"]:checked) .dpc-filter-group.is-doctor,
.dpc-appointment-form:has(input[name="subject_type"][value="clinic"]:checked) .dpc-filter-group.is-clinic {
    display: grid;
}

.dpc-filter-group > span {
    color: #667481;
    font-size: 15px;
    font-weight: 700;
}

.dpc-filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.dpc-filter-chips label {
    display: block;
}

.dpc-filter-chips input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.dpc-filter-chips span {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 15px;
    border: 1px solid #dbe5ea;
    border-radius: 8px;
    color: #667481;
    background: #fff;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: color .2s ease, border-color .2s ease, background .2s ease;
}

.dpc-filter-chips input:checked + span {
    color: #0958d9;
    border-color: #91caff;
    background: #e6f4ff;
}

.dpc-availability-button {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 66px;
    width: 100%;
    border: 0;
    border-radius: 8px;
    color: #fff;
    background: #1677ff;
    font-size: 22px;
    font-weight: 800;
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

.dpc-availability-button:hover,
.dpc-availability-button:focus {
    background: #0958d9;
    transform: translateY(-1px);
}

.dpc-appointment-form label {
    display: grid;
    gap: 7px;
    min-width: 0;
}

.dpc-appointment-form label span {
    color: #344054;
    font-size: 14px;
    font-weight: 700;
}

.dpc-appointment-form .dpc-subject-tabs span {
    color: #667481;
    font-size: 22px;
    font-weight: 800;
}

.dpc-appointment-form .dpc-subject-tabs input:checked + span {
    color: #0958d9;
}

.dpc-appointment-form .dpc-filter-group > span {
    color: #667481;
    font-size: 15px;
    font-weight: 700;
}

.dpc-appointment-form .dpc-filter-chips span {
    color: #667481;
    font-size: 15px;
    font-weight: 700;
}

.dpc-appointment-form .dpc-filter-chips input:checked + span {
    color: #0958d9;
}

.dpc-appointment-form input {
    width: 100%;
    min-height: 42px;
    padding: 0 12px;
    border: 1px solid #dbe5ea;
    border-radius: 8px;
    outline: none;
}

.dpc-appointment-form input:focus {
    border-color: #1677ff;
    box-shadow: 0 0 0 3px rgba(22, 119, 255, .12);
}

.dpc-appointment-form.has-subject-picker .dpc-keyword-field input {
    min-height: 62px;
    padding: 0 18px 0 48px;
    font-size: 18px;
}

.dpc-appointment-form button {
    grid-column: 1 / -1;
    width: 100%;
}

.dpc-appointment-form.has-subject-picker > label,
.dpc-appointment-form.has-subject-picker > button[type="submit"] {
    position: relative;
}

.dpc-success {
    max-width: 760px;
    margin: 16px 0;
    padding: 12px 14px;
    border: 1px solid #91caff;
    border-radius: 8px;
    color: #0958d9;
    background: #e6f4ff;
}

@media (max-width: 980px) {
    .dpc-front-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 680px) {
    .dpc-front-grid,
    .dpc-appointment-form {
        grid-template-columns: 1fr;
    }

    .dpc-doctor-card {
        grid-template-columns: 96px minmax(0, 1fr);
    }

    .dpc-thumb img {
        height: 180px;
    }

    .dpc-subject-tabs {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
