:root {
    --primary-color: #5e3995;
    --secondary-color: #96282f;
    --form-primary: #287141;
    --form-icon-bg: #E8E7FB;
    --form-border: #E5E7EB;
    --form-bg: #F9FAFB;
    --form-label: #111827;
    --form-subtitle: #6B7280;
    --form-icon: #7C7AEC;
    --text-color: #333;
    --bg-light: #f8f9fa;
    --white: #ffffff;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f4f7f6;
    /* Lighter background for the page to make card pop */
}

/* HIGH FIDELITY COMPANY FORM STYLES */

.company-form-card {
    border-radius: 16px;
    border: none;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.04);
    background: #fff;
    overflow: hidden;
    margin-bottom: 2rem;
}

.company-form-header {
    display: flex;
    align-items: center;
    padding: 30px;
    border-bottom: 1px solid #F3F4F6;
}

.header-icon-circle {
    width: 54px;
    height: 54px;
    background-color: var(--form-icon-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--form-primary);
    font-size: 22px;
    margin-right: 18px;
}

.header-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--form-label);
    margin-bottom: 4px;
}

.header-subtitle {
    font-size: 14px;
    color: var(--form-subtitle);
    margin-bottom: 0;
}

.company-form-body {
    padding: 40px 50px;
}

.form-label-custom {
    font-weight: 600;
    color: var(--form-label);
    font-size: 14px;
    margin-bottom: 10px;
    display: block;
}

.custom-input-group {
    display: flex;
    align-items: center;
    border: 1px solid var(--form-border);
    border-radius: 4px;
    /* Exact 4px radius as requested */
    background-color: #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    /* Subtle shadow as requested */
    overflow: hidden;
    height: 52px;
    transition: all 0.2s;
    margin-bottom: 25px;
}

.custom-input-group:focus-within {
    border-color: var(--form-primary);
    box-shadow: 0 0 0 4px rgba(94, 92, 230, 0.08);
}

.custom-input-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 100%;
    color: var(--form-icon);
    font-size: 18px;
}

.custom-input {
    flex: 1;
    height: 100%;
    border: none !important;
    background-color: transparent !important;
    padding: 0 15px 0 0;
    color: #374151;
    font-size: 15px;
}

.custom-input:focus {
    outline: none !important;
    box-shadow: none !important;
}

.custom-input-separator {
    width: 1px;
    height: 26px;
    background-color: #E5E7EB;
    margin: 0 12px;
}

.custom-input-flag {
    display: flex;
    align-items: center;
    padding-right: 12px;
}

/* Select Styling */
.custom-select-wrapper {
    position: relative;
    flex: 1;
    height: 100%;
}

.custom-select-wrapper select {
    width: 100%;
    height: 100%;
    border: none;
    background-color: transparent;
    appearance: none;
    padding: 0 40px 0 0;
    color: #374151;
    cursor: pointer;
}

.custom-select-wrapper::after {
    content: '\f078';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #9CA3AF;
    pointer-events: none;
    font-size: 12px;
}

/* Logo Drop Zone */
.logo-drop-zone {
    border: 1px dashed #C7C6FF;
    border-radius: 12px;
    background-color: #F8F9FF;
    padding: 50px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.logo-drop-zone:hover {
    background-color: #F1F3FF;
    border-color: var(--form-primary);
}

.logo-drop-icon {
    width: 56px;
    height: 56px;
    background-color: #E8E7FF;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--form-primary);
    font-size: 22px;
    margin: 0 auto 18px;
}

.logo-drop-text {
    font-size: 16px;
    font-weight: 700;
    color: #111827;
    margin-bottom: 6px;
}

.logo-drop-link {
    color: var(--form-primary);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
}

.logo-drop-hint {
    color: #6B7280;
    font-size: 13px;
    margin-top: 18px;
}

/* Footer Section */
.company-form-footer {
    padding: 25px 40px;
    background-color: var(--form-bg);
    border-top: 1px solid #F3F4F6;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn-cancel-design {
    background-color: #ffffff;
    border: 1px solid #D1D5DB;
    color: #374151;
    font-weight: 600;
    padding: 12px 28px;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.2s;
}

.btn-cancel-design:hover {
    background-color: #F9FAFB;
    color: #111827;
}

.btn-save-design {
    background-color: var(--form-primary);
    border: none;
    color: #ffffff;
    font-weight: 600;
    padding: 12px 32px;
    border-radius: 8px;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 12px rgba(94, 92, 230, 0.2);
    transition: all 0.2s;
}

.btn-save-design:hover {
    background-color: #4C4AD0;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(94, 92, 230, 0.25);
}

.illustration-container {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    height: 100%;
}

/* HOMEPAGE REDESIGN STYLES */

.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)), url('../images/banner4.jpg');
    background-size: cover;
    background-position: center;
    padding: 120px 0 150px;
    color: white;
    position: relative;
    border-bottom-left-radius: 50px;
    border-bottom-right-radius: 50px;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 30px;
    max-width: 700px;
}

.hero-search-container {
    background: white;
    padding: 10px;
    border-radius: 12px;
    display: flex;
    max-width: 600px;
}

.hero-search-container input {
    flex: 1;
    border: none;
    padding: 0 20px;
    font-size: 16px;
    outline: none;
}

.btn-primary-design {
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-primary-design:hover {
    background-color: #e66d50;
    color: white;
}

.quick-link-btn {
    background: rgba(245, 123, 81, 0.8);
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    margin-right: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
}

.quick-link-btn:hover {
    background: var(--primary-color);
    color: white;
    text-decoration: none;
}

.booking-bar-container {
    margin-top: -60px;
    position: relative;
    z-index: 10;
}

.booking-bar {
    background: white;
    padding: 30px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: flex-end;
    gap: 15px;
    flex-wrap: wrap;
}

.booking-field {
    flex: 1;
    min-width: 200px;
}

.booking-field label {
    display: block;
    font-weight: 600;
    color: #555;
    margin-bottom: 8px;
}

.section-label {
    color: var(--secondary-color);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 14px;
    display: block;
    margin-bottom: 10px;
}

.section-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: #111;
}

.section-title-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 50px;
}

/* Category Items */
.category-item {
    text-align: center;
    transition: all 0.3s;
    padding: 20px;
    border-radius: 12px;
}

.category-item:hover {
    transform: translateY(-10px);
}

.category-icon {
    width: 50px;
    height: 50px;
    background: #f0f4ff;
    border-radius: 50%;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.category-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-item h4 {
    font-size: 14px;
    font-weight: 500;
}

/* Service Card */
.service-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s;
    height: 100%;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.service-img {
    position: relative;
    height: 200px;
}

.service-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.service-tag {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(245, 123, 81, 0.9);
    color: white;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

.service-content {
    padding: 20px;
}

.service-content h4 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
}

.service-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
    margin-bottom: 15px;
}

.service-meta {
    font-size: 14px;
    color: #777;
    margin-bottom: 20px;
}

/* Clinic Card */
.clinic-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    height: 100%;
}

.clinic-img {
    position: relative;
    height: 220px;
}

.clinic-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.status-tag {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #28a745;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
}

.clinic-content {
    padding: 25px;
}

.clinic-info {
    font-size: 14px;
    color: #666;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.view-details {
    color: var(--primary-color);
    font-weight: 700;
    text-decoration: underline;
}

/* Doctor Card */
.doctor-card {
    background: #f0f4ff;
    border-radius: 16px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s;
    height: 100%;
}

.doctor-card:hover {
    background: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.doctor-img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin: 0 auto 20px;
    overflow: hidden;
}

.doctor-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.doctor-info h4 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 5px;
}

.doctor-info p {
    color: #777;
    margin-bottom: 15px;
}

.stars {
    color: #ffc107;
    margin-bottom: 15px;
}

.patients-count {
    background: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

/* App Promo */
.app-promo-section {
    background: #f0f4ff;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.try-now-text {
    position: absolute;
    top: -50px;
    right: 50px;
    font-family: 'Permanent Marker', cursive;
    color: var(--secondary-color);
    font-size: 24px;
}

/* FAQ */
.faq-accordion .card {
    border: none;
    margin-bottom: 15px;
    border-radius: 12px !important;
}

.faq-accordion .card-header {
    background: white;
    border: none;
    padding: 20px;
}

.faq-accordion .btn-link {
    width: 100%;
    text-align: left;
    font-weight: 700;
    color: #333;
    text-decoration: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Footer */
.main-footer {
    background: #111;
    color: white;
    padding: 80px 0 30px;
}

.footer-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 30px;
}

.footer-links li {
    margin-bottom: 15px;
}

.footer-links a {
    color: #aaa;
    transition: all 0.3s;
}

.footer-links a:hover {
    color: white;
    text-decoration: none;
    padding-left: 10px;
}

.footer-service-card {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.footer-service-img {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
}

.footer-service-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.footer-service-info h5 {
    font-size: 14px;
    margin-bottom: 5px;
}

.footer-service-info p {
    font-size: 12px;
    color: #777;
}

.col-lg-2-4 {
    flex: 0 0 20%;
    max-width: 20%;
}

@media (max-width: 991px) {
    .col-lg-2-4 {
        flex: 0 0 33.333%;
        max-width: 33.333%;
    }
}

@media (max-width: 767px) {
    .col-lg-2-4 {
        flex: 0 0 50%;
        max-width: 50%;
    }
}
/* ── Formulaire de demande de rendez-vous (accueil) ── */
.rdv-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(94, 57, 149, 0.18);
    overflow: hidden;
}
.rdv-card-head {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 24px;
    color: #fff;
    background: linear-gradient(135deg, var(--primary-color), #7a52b3);
}
.rdv-card-head > i { font-size: 30px; opacity: .95; }
.rdv-card-head h4 { margin: 0; font-size: 20px; font-weight: 700; color: #fff; }
.rdv-card-head p { margin: 2px 0 0; font-size: 13px; opacity: .9; color: #fff; }
.rdv-card-body { padding: 22px 24px 24px; }
.rdv-card-body .form-control {
    height: 44px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    font-size: 14px;
}
.rdv-card-body textarea.form-control { height: auto; }
.rdv-card-body .form-control:focus {
    background: #fff;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(94, 57, 149, 0.15);
}
.rdv-card-body .form-group { margin-bottom: 14px; }

.rdv-card-body .rdv-label { font-size: 13px; font-weight: 600; color: #374151; margin-bottom: 6px; }
.rdv-calendar .flatpickr-calendar.inline {
    width: 100%; max-width: 100%; box-shadow: none; border: 1px solid #e5e7eb;
    border-radius: 10px; background: #f9fafb;
}
.rdv-calendar .flatpickr-innerContainer, .rdv-calendar .flatpickr-rContainer,
.rdv-calendar .flatpickr-days, .rdv-calendar .dayContainer { width: 100%; min-width: 100%; max-width: 100%; }
.rdv-calendar .flatpickr-day { max-width: none; height: 36px; line-height: 36px; border-radius: 8px; }
.rdv-calendar .flatpickr-day.selected, .rdv-calendar .flatpickr-day.selected:hover {
    background: var(--primary-color); border-color: var(--primary-color); color: #fff;
}
.rdv-calendar .flatpickr-day.today:not(.selected) { border-color: var(--primary-color); }
.rdv-calendar .flatpickr-day.flatpickr-disabled { color: #c9cdd3; }
.rdv-slots { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; min-height: 24px; }
.rdv-slot {
    border: 1px solid var(--primary-color); background: #fff; color: var(--primary-color);
    border-radius: 20px; padding: 4px 14px; font-size: 13px; font-weight: 600; cursor: pointer; transition: all .15s;
}
.rdv-slot:hover { background: #f2edf8; }
.rdv-slot.active { background: var(--primary-color); color: #fff; }

.rdv-steps { display: flex; gap: 8px; list-style: none; padding: 0; margin: 0 0 18px; }
.rdv-step-dot {
    flex: 1; display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600;
    color: #9ca3af; padding-bottom: 8px; border-bottom: 3px solid #e5e7eb;
}
.rdv-step-dot span {
    width: 24px; height: 24px; border-radius: 50%; background: #e5e7eb; color: #6b7280;
    display: inline-flex; align-items: center; justify-content: center; font-size: 12px;
}
.rdv-step-dot.active { color: var(--primary-color); border-bottom-color: var(--primary-color); }
.rdv-step-dot.active span, .rdv-step-dot.done span { background: var(--primary-color); color: #fff; }
.rdv-step-dot.done { color: var(--primary-color); border-bottom-color: #c9b8e3; }
.rdv-panel[hidden] { display: none; }
.rdv-recap {
    display: flex; align-items: center; gap: 10px; background: #f2edf8; color: #4a2c77;
    border-radius: 10px; padding: 10px 14px; margin-bottom: 16px; font-size: 13px; font-weight: 600;
}
.rdv-recap i { color: var(--primary-color); }
.rdv-recap .btn-link { color: var(--primary-color); font-size: 13px; }
#rdv-next:disabled { opacity: .5; cursor: not-allowed; }

.rdv-doctors { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.rdv-doctors .rdv-doctor { margin: 0; cursor: pointer; min-width: 0; }
.rdv-doctors .rdv-doctor input { position: absolute; opacity: 0; pointer-events: none; }
.rdv-doctors .rdv-doctor-card {
    display: flex; flex-direction: row; align-items: center; text-align: left; gap: 10px;
    padding: 8px 10px; border: 2px solid #e5e7eb; border-radius: 10px; background: #f9fafb;
    transition: all .15s; position: relative; line-height: 1.25;
}
.rdv-doctors .rdv-doctor-card img {
    width: 40px; height: 40px; max-width: none; flex: 0 0 40px; border-radius: 50%; object-fit: cover;
    margin: 0; border: 2px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.15);
}
.rdv-doctors .rdv-doctor-text { display: flex; flex-direction: column; min-width: 0; padding-right: 14px; }
.rdv-doctors .rdv-doctor-card strong { font-size: 13px; color: #1f2937; letter-spacing: .2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rdv-doctors .rdv-doctor-card small { font-size: 11px; color: #6b7280; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rdv-doctors .rdv-doctor:hover .rdv-doctor-card { border-color: #c9b8e3; }
.rdv-doctors .rdv-doctor input:checked + .rdv-doctor-card { border-color: var(--primary-color); background: #f2edf8; box-shadow: 0 2px 8px rgba(94,57,149,.18); }
.rdv-doctors .rdv-doctor input:checked + .rdv-doctor-card::after {
    content: "\f00c"; font-family: "Font Awesome 5 Free"; font-weight: 900; position: absolute; top: 5px; right: 6px;
    width: 16px; height: 16px; border-radius: 50%; background: var(--primary-color); color: #fff;
    font-size: 8px; display: flex; align-items: center; justify-content: center;
}
.rdv-doctor input:focus-visible + .rdv-doctor-card { outline: 2px solid var(--primary-color); outline-offset: 2px; }
