/* ClearCosmetics Booking Page */

.booking-hero {
    padding: 120px 0 48px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--white) 100%);
    text-align: center;
}

.booking-hero .section-title {
    margin-bottom: 12px;
}

.booking-hero-subtitle {
    max-width: 640px;
    margin: 0 auto;
    color: var(--gray);
    font-size: 1.05rem;
    line-height: 1.7;
}

.booking-page {
    padding: 48px 0 80px;
    background: var(--light-gray);
}

.booking-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 32px;
    align-items: start;
}

.booking-main {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.booking-steps {
    display: flex;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    background: var(--white);
}

.booking-step-indicator {
    flex: 1;
    padding: 18px 12px;
    text-align: center;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--gray);
    border-bottom: 3px solid transparent;
    transition: var(--transition);
}

.booking-step-indicator.active {
    color: var(--secondary-color);
    border-bottom-color: var(--secondary-color);
    background: rgba(245, 230, 224, 0.35);
}

.booking-step-indicator.completed {
    color: var(--secondary-color);
}

.booking-step-indicator span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--light-gray);
    font-size: 0.75rem;
    margin-right: 8px;
}

.booking-step-indicator.active span,
.booking-step-indicator.completed span {
    background: var(--secondary-color);
    color: var(--white);
}

.booking-panel {
    display: none;
    padding: 32px;
    animation: fadeIn 0.35s ease;
}

.booking-panel.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.booking-panel h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 8px;
    color: var(--secondary-color);
}

.booking-panel > p {
    color: var(--gray);
    margin-bottom: 24px;
}

.clinic-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.clinic-select-card {
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    overflow: hidden;
    cursor: pointer;
    background: var(--white);
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-align: left;
}

.clinic-select-card:hover,
.clinic-select-card.selected {
    border-color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.clinic-select-card img {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.clinic-select-card .clinic-card-body {
    padding: 20px;
}

.clinic-select-card h4 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-bottom: 6px;
}

.clinic-select-card p {
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 12px;
    line-height: 1.5;
}

.clinic-info p {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: var(--gray);
}

.clinic-info i {
    color: var(--secondary-color);
    width: 16px;
}

.appointment-type-cards {
    display: grid;
    gap: 16px;
}

.appointment-type-card {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 20px;
    border: 2px solid rgba(0, 0, 0, 0.08);
    border-radius: var(--border-radius-small);
    cursor: pointer;
    transition: var(--transition);
}

.appointment-type-card:hover,
.appointment-type-card.selected {
    border-color: var(--secondary-color);
    background: rgba(245, 230, 224, 0.25);
}

.appointment-type-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.appointment-type-icon i {
    font-size: 1.1rem;
    color: var(--secondary-color);
}

.appointment-type-card h4 {
    font-size: 1.05rem;
    margin-bottom: 4px;
}

.appointment-type-card .duration {
    font-size: 0.8rem;
    color: var(--gray);
    margin-bottom: 6px;
}

.appointment-type-card p {
    font-size: 0.9rem;
    color: var(--gray);
    line-height: 1.5;
}

.treatment-select-group {
    margin-bottom: 24px;
}

.treatment-select-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 8px;
}

.treatment-select-group select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: var(--border-radius-small);
    font-family: var(--font-body);
    font-size: 1rem;
    background: var(--white);
}

.treatment-dropdown {
    position: relative;
    width: 100%;
    margin-bottom: 16px;
}

.dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: var(--border-radius-small);
    background: var(--white);
    cursor: pointer;
    transition: var(--transition);
}

.dropdown-header:hover {
    border-color: var(--secondary-color);
}

.dropdown-header.active {
    border-color: var(--secondary-color);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.dropdown-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border: 1px solid var(--secondary-color);
    border-top: none;
    border-radius: 0 0 var(--border-radius-small) var(--border-radius-small);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.dropdown-list.show {
    display: block;
}

.treatment-option {
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.treatment-option:hover {
    background: var(--primary-color);
}

.treatment-option.selected {
    background: var(--primary-color);
    color: var(--secondary-color);
}

.treatment-option:last-child {
    border-bottom: none;
}

.treatment-price {
    font-weight: 500;
    color: var(--secondary-color);
}

.selected-treatments-display {
    display: none;
    margin-bottom: 16px;
}

.selected-treatments-display.show {
    display: block;
}

.selected-treatment-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--primary-color);
    color: var(--secondary-color);
    padding: 8px 12px;
    margin: 4px 4px 4px 0;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.remove-treatment {
    cursor: pointer;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--secondary-color);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
}

.remove-treatment:hover {
    background: #333;
}

.booking-nav-buttons {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.booking-nav-buttons .btn-back {
    background: transparent;
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
}

.booking-nav-buttons .btn-back:hover {
    background: var(--secondary-color);
    color: var(--white);
}

#calendly-embed {
    min-height: 680px;
    margin: -8px -16px 0;
}

#calendly-embed iframe {
    min-width: 100%;
    height: 680px;
}

/* Hide unwanted Cal.com form elements */
#calendly-embed iframe {
    /* These styles will be injected into the iframe if possible */
}

/* Custom styles to clean up the booking form */
.cal-booking-form {
    /* Target Cal.com form elements */
}

/* Hide location field and add guests in Cal.com */
iframe[src*="cal.com"] {
    /* Cal.com iframe styling */
}

.calendly-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    color: var(--gray);
    gap: 16px;
}

.calendly-loading i {
    font-size: 2rem;
    color: var(--secondary-color);
}

.calendly-setup-notice {
    background: #fff8e6;
    border: 1px solid #f0d78c;
    border-radius: var(--border-radius-small);
    padding: 20px;
    margin-bottom: 20px;
}

.calendly-setup-notice h4 {
    color: #8a6d00;
    margin-bottom: 8px;
}

.calendly-setup-notice p {
    font-size: 0.9rem;
    color: #6b5600;
    line-height: 1.6;
}

.booking-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.sidebar-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 24px;
}

.sidebar-card h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    margin-bottom: 16px;
    color: var(--secondary-color);
}

.sidebar-card ul {
    list-style: none;
}

.sidebar-card ul li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
    font-size: 0.9rem;
    color: var(--gray);
    line-height: 1.5;
}

.sidebar-card ul li i {
    color: var(--secondary-color);
    margin-top: 3px;
    flex-shrink: 0;
}

.sidebar-summary-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    font-size: 0.9rem;
}

.sidebar-summary-item:last-child {
    border-bottom: none;
}

.sidebar-summary-item .label {
    color: var(--gray);
}

.sidebar-summary-item .value {
    font-weight: 500;
    text-align: right;
    max-width: 60%;
}

.sidebar-contact {
    text-align: center;
}

.sidebar-contact p {
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 16px;
}

.sidebar-contact .btn {
    width: 100%;
    margin-bottom: 8px;
}


.booking-confirmation-banner {
    display: none;
    background: linear-gradient(135deg, #e8f5e9, #f1f8e9);
    border-radius: var(--border-radius-small);
    padding: 16px 20px;
    margin-bottom: 20px;
    align-items: center;
    gap: 12px;
}

.booking-confirmation-banner.visible {
    display: flex;
}

.booking-confirmation-banner i {
    font-size: 1.5rem;
    color: #2e7d32;
}

@media (max-width: 992px) {
    .booking-layout {
        grid-template-columns: 1fr;
    }

    /* Main booking section comes first */
    .booking-main {
        order: 1;
    }

    /* Sidebar comes second, with reordered cards */
    .booking-sidebar {
        order: 2;
        display: flex;
        flex-direction: column;
    }

    /* Reorder sidebar cards within the sidebar */
    .sidebar-card:nth-child(1) { /* Your Booking */
        order: 4;
    }

    .sidebar-card:nth-child(2) { /* Clinic Schedule */
        order: 3;
    }

    .sidebar-card:nth-child(3) { /* Before You Book */
        order: 2;
    }

    .sidebar-card:nth-child(4) { /* Need Help */
        order: 5;
    }

    /* Center the contact buttons */
    .sidebar-contact {
        text-align: center;
    }

    .sidebar-contact .btn {
        width: auto !important;
        min-width: 180px;
        margin: 0 auto 12px auto !important;
        display: block;
    }
}

/* Payment Styles */
.payment-summary {
    background: var(--primary-color);
    border-radius: var(--border-radius-small);
    padding: 20px;
    margin-bottom: 24px;
}

.payment-summary h4 {
    margin-bottom: 16px;
    font-family: var(--font-heading);
}

.price-breakdown {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.price-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 0.95rem;
}

.price-item.deposit-highlight {
    font-weight: 600;
    color: var(--secondary-color);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding: 12px 0;
}

.price-item.remaining {
    color: var(--gray);
    font-size: 0.9rem;
}

.payment-methods {
    margin-bottom: 24px;
}

.payment-methods h4 {
    margin-bottom: 16px;
    font-family: var(--font-heading);
}

.payment-options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.payment-option-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 16px;
    border: 2px solid rgba(0, 0, 0, 0.08);
    border-radius: var(--border-radius-small);
    background: var(--white);
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}

.payment-option-btn:hover,
.payment-option-btn.active {
    border-color: var(--secondary-color);
    background: rgba(245, 230, 224, 0.25);
}

.payment-option-btn i {
    font-size: 1.5rem;
    margin-bottom: 8px;
    color: var(--secondary-color);
}

.payment-option-btn span {
    font-weight: 500;
    margin-bottom: 4px;
}

.payment-option-btn small {
    font-size: 0.8rem;
    color: var(--gray);
}

.payment-form {
    margin-bottom: 24px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.form-row:has(.form-group:nth-child(2)) {
    grid-template-columns: 2fr 1fr;
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: var(--border-radius-small);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(34, 34, 34, 0.1);
}

.paypal-container {
    text-align: center;
    padding: 40px 20px;
}

.paypal-container p {
    margin-bottom: 20px;
    color: var(--gray);
}

.payment-security {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 20px;
}

.payment-security i {
    color: var(--secondary-color);
}

@media (max-width: 768px) {
    .booking-hero {
        padding: 100px 0 32px;
    }

    .clinic-cards {
        grid-template-columns: 1fr;
    }

    .booking-step-indicator {
        font-size: 0.75rem;
        padding: 14px 6px;
    }

    .booking-step-indicator span {
        display: none;
    }

    .booking-panel {
        padding: 20px 16px;
    }

    #calendly-embed {
        margin: 0 -8px;
    }

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

    .form-row:has(.form-group:nth-child(2)) {
        grid-template-columns: 1fr;
    }
}
