/* ============================================================
   COPPER SKY HEARING
   CF7 APPOINTMENT REQUEST FORM
   ============================================================ */

.csh-appointment-form {
    --csh-navy: #0f2f46;
    --csh-navy-dark: #0a2437;
    --csh-copper: #c9682b;
    --csh-copper-dark: #ad5320;
    --csh-copper-soft: #fff5ed;
    --csh-text: #374957;
    --csh-muted: #73808a;
    --csh-border: #dfe5e8;
    --csh-border-light: #edf0f2;
    --csh-white: #ffffff;
    --csh-success: #2f6d4d;
    --csh-error: #c62828;
    width: 100%;
    color: var(--csh-text);
}

.csh-appointment-form *,
.csh-appointment-form *::before,
.csh-appointment-form *::after {
    box-sizing: border-box;
}

.csh-appointment-form .form-grp {
    margin-bottom: 22px;
}

.csh-appointment-form label,
.csh-appointment-form .csh-main-label {
    display: block;
    margin: 0 0 1px;
    color: var(--csh-navy);
    font-size: 14px;
    line-height: 1.4;
    font-weight: 600;
}

.csh-appointment-form label > span,
.csh-appointment-form .csh-main-label > span {
    color: var(--csh-copper);
}

.csh-appointment-form label small {
    color: var(--csh-muted);
    font-weight: 400;
}

.csh-appointment-form input[type="text"],
.csh-appointment-form input[type="email"],
.csh-appointment-form input[type="tel"],
.csh-appointment-form select,
.csh-appointment-form textarea {
    width: 100%;
    min-height: 54px;
    margin: 0;
    padding: 13px 15px;
    color: var(--csh-navy);
    background: var(--csh-white);
    border: 1px solid var(--csh-border);
    border-radius: 10px;
    outline: none;
    font: inherit;
    font-size: 14px;
    line-height: 1.5;
    box-shadow: none;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.csh-appointment-form textarea {
    min-height: 130px;
    resize: vertical;
}

.csh-appointment-form input::placeholder,
.csh-appointment-form textarea::placeholder {
    color: #99a3aa;
}

.csh-appointment-form input:focus,
.csh-appointment-form select:focus,
.csh-appointment-form textarea:focus {
    border-color: var(--csh-copper);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(201, 104, 43, .10);
}

.csh-appointment-form select {
    cursor: pointer;
}

.csh-section {
    margin: 8px 0 28px;
    padding-top: 24px;
    border-top: 1px solid var(--csh-border-light);
}

.csh-section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.csh-section-head p,
.csh-section-description {
    margin: -2px 0 15px;
    color: var(--csh-muted);
    font-size: 13px;
    line-height: 1.6;
}

/* Date cards */
.csh-date-options {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 9px;
    width: 100%;
}

.csh-date-card {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 88px;
    padding: 12px 6px !important;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 2px;
    appearance: none;
    cursor: pointer !important;
    color: var(--csh-navy) !important;
    background: var(--csh-white) !important;
    border: 1px solid var(--csh-border) !important;
    border-radius: 11px !important;
    font: inherit;
    text-align: center;
    box-shadow: none;
    transition: transform .2s ease, border-color .2s ease, background .2s ease, box-shadow .2s ease;
}

.csh-date-card:hover {
    transform: translateY(-2px);
    border-color: rgba(201, 104, 43, .65);
    box-shadow: 0 8px 20px rgba(15, 47, 70, .07);
}

.csh-date-card:focus-visible {
    outline: 3px solid rgba(201, 104, 43, .22);
    outline-offset: 2px;
}

.csh-date-card .csh-day {
    display: block;
    color: var(--csh-navy);
    font-size: 13px;
    line-height: 1.2;
    font-weight: 700;
}

.csh-date-card .csh-date {
    display: block;
    margin-top: 5px;
    color: var(--csh-muted);
    font-size: 11px;
    line-height: 1.25;
}

.csh-date-card .csh-card-check {
    position: absolute;
    top: 6px;
    right: 6px;
    display: flex;
    width: 18px;
    height: 18px;
    align-items: center;
    justify-content: center;
    opacity: 0;
    color: #fff;
    background: var(--csh-copper);
    border-radius: 50%;
    font-size: 10px;
    line-height: 1;
    transition: opacity .2s ease;
}

.csh-date-card.is-selected {
    color: var(--csh-copper-dark);
    background: var(--csh-copper-soft);
    border-color: var(--csh-copper);
    box-shadow: inset 0 0 0 1px var(--csh-copper), 0 6px 18px rgba(201, 104, 43, .08);
}

.csh-date-card.is-selected .csh-day {
    color: var(--csh-copper-dark);
}

.csh-date-card.is-selected .csh-date {
    color: #8c542e;
}

.csh-date-card.is-selected .csh-card-check {
    opacity: 1;
}

.csh-other-date {
    border-style: dashed;
}

.csh-other-date.is-selected {
    border-style: solid;
}

.csh-calendar-icon {
    display: block;
    margin-bottom: 2px;
    font-size: 18px;
    line-height: 1;
}

.csh-selection-feedback {
    display: none;
    margin-top: 11px;
    padding: 9px 12px;
    color: var(--csh-success);
    background: #f3faf6;
    border: 1px solid #dceee3;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
}

.csh-selection-feedback.is-visible {
    display: block;
}

/* Time cards */
.csh-time-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.csh-time-card {
    position: relative;
    display: flex;
    min-height: 82px;
    padding: 15px 17px !important;
    align-items: center;
    gap: 13px;
    appearance: none;
    cursor: pointer !important;
    color: var(--csh-navy) !important;
    background: var(--csh-white) !important;
    border: 1px solid var(--csh-border) !important;
    border-radius: 12px !important;
    font: inherit;
    text-align: left;
    box-shadow: none;
    transition: transform .2s ease, border-color .2s ease, background .2s ease, box-shadow .2s ease;
    font-weight: 500 !important;
}

.csh-time-card:hover {
    transform: translateY(-2px);
    border-color: rgba(201, 104, 43, .65);
    box-shadow: 0 8px 20px rgba(15, 47, 70, .06);
}

.csh-time-card:focus-visible {
    outline: 3px solid rgba(201, 104, 43, .22);
    outline-offset: 2px;
}

.csh-time-icon {
    display: flex;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    align-items: center;
    justify-content: center;
    color: var(--csh-copper);
    background: var(--csh-copper-soft);
    border-radius: 50%;
    font-size: 20px;
}

.csh-time-content {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.csh-time-content strong {
    color: var(--csh-navy);
    font-size: 14px;
    line-height: 1.3;
}

.csh-time-content small {
    margin-top: 3px;
    color: var(--csh-muted);
    font-size: 12px;
    line-height: 1.3;
}

.csh-time-card .csh-check {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    width: 20px;
    height: 20px;
    align-items: center;
    justify-content: center;
    opacity: 0;
    color: #fff;
    background: var(--csh-copper);
    border-radius: 50%;
    font-size: 11px;
    line-height: 1;
}

.csh-time-card.is-selected {
    background: var(--csh-copper-soft);
    border-color: var(--csh-copper);
    box-shadow: inset 0 0 0 1px var(--csh-copper), 0 6px 18px rgba(201, 104, 43, .08);
}

.csh-time-card.is-selected .csh-check {
    opacity: 1;
}

/* Hidden CF7 fields / calendar trigger */
.csh-hidden-control {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
    clip: rect(0 0 0 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

#csh-mobiscroll-date,
.csh-mobiscroll-input {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    min-height: 1px !important;
    padding: 0 !important;
    margin: 0 !important;
    opacity: 0 !important;
    border: 0 !important;
    pointer-events: none !important;
}

/* Validation / CF7 messages */
.csh-custom-error {
    display: none;
    margin-top: 9px;
    color: var(--csh-error);
    font-size: 12px;
    line-height: 1.4;
}

.csh-custom-error.is-visible {
    display: block;
}

.csh-appointment-form .wpcf7-not-valid-tip {
    margin-top: 6px;
    color: var(--csh-error);
    font-size: 12px;
}

.csh-appointment-form .wpcf7-response-output {
    margin: 18px 0 0 !important;
    padding: 12px 14px !important;
    border-radius: 9px;
    font-size: 13px;
    line-height: 1.5;
}

.csh-appointment-form .wpcf7-spinner {
    margin: 10px 0 0 10px;
}

/* Submit */
.csh-submit-wrap {
    margin-top: 4px;
}

.csh-appointment-form input[type="submit"].csh-submit {
    width: 100%;
    min-height: 57px;
    padding: 14px 22px;
    cursor: pointer;
    color: #fff;
    background: linear-gradient(135deg, var(--csh-copper-dark), var(--csh-copper));
    border: 0;
    border-radius: 10px;
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 8px 22px rgba(201, 104, 43, .20);
    transition: transform .2s ease, box-shadow .2s ease, opacity .2s ease;
}

.csh-appointment-form input[type="submit"].csh-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 11px 28px rgba(201, 104, 43, .27);
}

.csh-appointment-form input[type="submit"].csh-submit:disabled {
    cursor: not-allowed;
    opacity: .65;
    transform: none;
}

.csh-secure {
    display: flex;
    margin-top: 12px;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: var(--csh-muted);
    font-size: 11px;
    line-height: 1.4;
}

/* jQuery UI Datepicker */
#ui-datepicker-div.ui-datepicker {
    display: none;
    width: 330px;
    padding: 17px;
    color: #0f2f46;
    background: #fff;
    border: 1px solid #e7ebee;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(15, 47, 70, .20);
    font-family: inherit;
    z-index: 999999 !important;
}

#ui-datepicker-div .ui-datepicker-header {
    position: relative;
    min-height: 40px;
    padding: 4px 42px;
    margin: 0 0 10px;
    background: transparent;
    border: 0;
}

#ui-datepicker-div .ui-datepicker-title {
    margin: 0;
    color: #0f2f46;
    font-size: 14px;
    line-height: 32px;
    font-weight: 700;
    text-align: center;
}

#ui-datepicker-div .ui-datepicker-prev,
#ui-datepicker-div .ui-datepicker-next {
    position: absolute;
    top: 3px;
    display: flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background: #fff5ed;
    border: 0;
    border-radius: 50%;
}

#ui-datepicker-div .ui-datepicker-prev {
    left: 0;
}

#ui-datepicker-div .ui-datepicker-next {
    right: 0;
}

#ui-datepicker-div .ui-datepicker-prev span,
#ui-datepicker-div .ui-datepicker-next span {
    display: none;
}

#ui-datepicker-div .ui-datepicker-prev::before,
#ui-datepicker-div .ui-datepicker-next::before {
    color: #0f2f46;
    font-size: 25px;
    line-height: 1;
}

#ui-datepicker-div .ui-datepicker-prev::before {
    content: "‹";
}

#ui-datepicker-div .ui-datepicker-next::before {
    content: "›";
}

#ui-datepicker-div table {
    width: 100%;
    margin: 0;
    border-collapse: separate;
    border-spacing: 3px;
}

#ui-datepicker-div th {
    padding: 6px 2px;
    color: #818d95;
    border: 0;
    font-size: 11px;
    font-weight: 600;
    text-align: center;
}

#ui-datepicker-div td {
    padding: 0;
    border: 0;
}

#ui-datepicker-div td a,
#ui-datepicker-div td span {
    display: flex;
    width: 36px;
    height: 36px;
    margin: auto;
    padding: 0;
    align-items: center;
    justify-content: center;
    color: #0f2f46;
    background: transparent;
    border: 0;
    border-radius: 50%;
    font-size: 12px;
    font-weight: 500;
    text-align: center;
}

#ui-datepicker-div td a:hover {
    color: #ad5320;
    background: #fff5ed;
}

#ui-datepicker-div .ui-state-active {
    color: #fff !important;
    background: #c9682b !important;
}

#ui-datepicker-div .ui-datepicker-today a {
    box-shadow: inset 0 0 0 1px #c9682b;
}

#ui-datepicker-div .ui-datepicker-other-month {
    opacity: .35;
}

#ui-datepicker-div .ui-state-disabled {
    opacity: .28;
}

#ui-datepicker-div .ui-state-disabled span {
    cursor: not-allowed;
}

/* Responsive */
@media (max-width: 1199px) {
    .csh-date-options {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .csh-appointment-form .form-grp {
        margin-bottom: 18px;
    }

    .csh-section {
        margin-bottom: 24px;
        padding-top: 20px;
    }

    .csh-date-options {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 8px;
    }

    .csh-date-card {
        min-height: 82px;
    }

    .csh-time-options {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 575px) {
    .csh-date-options {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .csh-date-card {
        min-height: 76px;
    }

    .csh-time-card {
        min-height: 76px;
        padding: 13px 14px;
    }

    #ui-datepicker-div.ui-datepicker {
        width: calc(100vw - 30px);
        max-width: 340px;
        padding: 15px;
    }

    #ui-datepicker-div td a,
    #ui-datepicker-div td span {
        width: 34px;
        height: 34px;
    }
}
