
:root {
    --primary-color: #4e73df;
    --secondary-color: #f8f9fc;
    --accent-color: #2e59d9;
    --text-color: #5a5c69;
}

body {
    background-color: var(--secondary-color);
    color: var(--text-color);
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.booking-container {
    max-width: 1000px;
    margin: 50px auto;
    background: white;
    border-radius: 10px;
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
    overflow: hidden;
}

.booking-header {
    background: var(--primary-color);
    color: white;
    padding: 20px;
    text-align: center;
}

.booking-steps {
    display: flex;
    justify-content: space-between;
    padding: 20px;
    background-color: #f1f3f9;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 1;
    margin-right: 20px;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.step.active .step-number {
    background-color: var(--primary-color);
    color: white;
}

.step.completed .step-number {
    background-color: #28a745;
    color: white;
}

.step-title {
    font-size: 14px;
    text-align: center;
    color: #6c757d;
    transition: all 0.3s ease;
}

.step.active .step-title {
    color: var(--primary-color);
    font-weight: bold;
}

.step.completed .step-title {
    color: #28a745;
}

.booking-content {
    padding: 15px;
    min-height: 400px;
}


.booking-step {
    display: none;
    animation: fadeIn 0.5s ease;
}

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

.booking-footer {
    padding: 20px;
    border-top: 1px solid #e3e6f0;
    display: flex;
    justify-content: space-between;
}

.category-card,
.service-card,
.employee-card {
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    margin-bottom: 20px;
    height: 100%;
}

.category-card:hover,
.service-card:hover,
.employee-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.category-card.selected,
.service-card.selected,
.employee-card.selected {
    border-color: var(--primary-color);
    background-color: rgba(78, 115, 223, 0.1);
    border: 1px solid #4087ff !important;
}


.card-icon {
    font-size: 2rem;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.time-slot {
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 10px;
    margin: 5px;
    text-align: center;
}

.time-slot:hover {
    background-color: rgba(78, 115, 223, 0.1);
    color: var(--accent-color); /* azul oscuro */
}

.time-slot.selected {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.time-slot.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #f8f9fa;
    pointer-events: none;
}

/* Grid uniforme para los turnos */
.slots-grid{
    display: grid;
    grid-template-columns: 1fr;      /* 1 columna en móvil */
    gap: 10px;
}

/* 2 columnas desde pantallas medianas */
@media (min-width: 576px){
    .slots-grid{
        grid-template-columns: 1fr 1fr;
    }
}

/* Botón de turno: mismo tamaño siempre */
.slots-grid .time-slot{
    width: 100%;
    margin: 0;               /* elimina el “descuadre” del flex */
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;     /* evita que se parta en 2 líneas */
}

/* En tablet: 1 columna para que no se aplaste el texto */
@media (max-width: 991.98px){
  .slots-grid{
    grid-template-columns: 1fr;
  }
}

/* Cuando ya se apilan (tablets y abajo), que el calendario no se quede angosto */
@media (max-width: 991.98px){
  #calendar-container,
  .calendar-container,
  .calendar-card,
  .calendar-wrapper,
  .flatpickr-calendar {
    width: 100% !important;
    max-width: 100% !important;
  }
}

.calendar-day {
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-day:hover:not(.disabled) {
    background-color: rgba(78, 115, 223, 0.1);
}

.calendar-day.selected {
    background-color: var(--primary-color);
    color: white;
}

/* Si el día está seleccionado y paso el cursor, que el número se vea */
.calendar-day.selected:hover {
    background-color: rgba(78, 115, 223, 0.1); /* el celeste que ya usas */
    color: var(--accent-color);                 /* azul oscuro */
}

.calendar-day.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #f8f9fa;
    pointer-events: none;      /* evita clics */
    color: #b0b0b0;   
}

.summary-item {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e3e6f0;
}

/* Secciones dentro del paso 5 (Paciente / Facturación / Resumen) */
.form-section{
    background: var(--secondary-color);
    border: 1px solid #e3e6f0;
    border-radius: 10px;
    padding: 18px;
    margin-bottom: 18px;
}

.section-title{
    font-weight: 700;
    color: var(--accent-color);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        transform: translateX(50px);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.animate-slide-in {
    animation: slideIn 0.5s ease forwards;
}

/* ================================
   RESPONSIVE PASOS DEL PROCESO
   ================================ */

/* 480px a 512px → DEJAR COMO ESTABA (tu comportamiento actual) */
@media (min-width: 480px) and (max-width: 512px) {
    .booking-steps {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 12px 25px;
        padding: 15px 10px;
    }

    .step {
        flex: 0 1 28%; /* 3 pasos por fila */
        margin-right: 0;
        text-align: center;
    }

    .step-number {
        width: 38px;
        height: 38px;
        margin-bottom: 6px;
    }

    .step-title {
        font-size: 13px;
        white-space: normal;
    }
}

/* 513px a 700px → 2 filas, 3 pasos por fila, todo alineado */
@media (min-width: 513px) and (max-width: 700px) {
    .booking-steps {
        display: flex;
        flex-wrap: wrap;
        justify-content: space-between; /* columnas fijas */
        padding: 15px 20px;
        gap: 12px 0; /* solo separación vertical */
    }

    .step {
        flex: 0 0 33.333%;  /* 3 columnas exactas por fila */
        margin-right: 0;
        text-align: center;
    }

    .step-number {
        width: 38px;
        height: 38px;
        margin-bottom: 6px;
    }

    .step-title {
        font-size: 13px;
        white-space: normal;
    }
}

/* ≤ 479px → una sola columna, todos centrados (arregla el paso 6) */
@media (max-width: 479px) {
    .booking-steps {
        display: flex;
        flex-direction: column;   /* uno debajo de otro */
        align-items: center;      /* centrados */
        gap: 10px;
        padding: 12px 5px;
    }

    .step {
        width: 100%;
        max-width: 180px;         /* mismo ancho para todos */
        text-align: center;
        margin-right: 0;
        flex: 0 0 auto;
    }

    .step-number {
        width: 34px;
        height: 34px;
        margin-bottom: 4px;
    }

    .step-title {
        font-size: 12px;
        white-space: normal;
    }
}

/* Logo */
.brand-logo {
    height: 40px;   /* Cambia a lo que necesites */
    width: auto;
}

.iti {
  width: 100%;
}
.iti__tel-input,
.iti input {
  width: 100%;
}

/* intl-tel-input + Bootstrap alignment */
.iti {
  width: 100%;
  display: block;
}

.iti input.form-control {
  width: 100%;
  padding-left: 52px !important; /* espacio para bandera/prefijo */
}

.iti--separate-dial-code .iti__selected-flag {
  background: transparent;
}

.iti__flag-container {
  z-index: 5;
}

/* Opcional: que el dropdown no quede detrás de cards/modals */
.iti__country-list {
  z-index: 9999;
}

/* Botón flotante "Siguiente" */
#next-step-floating{
  position: fixed;
  right: 24px;
  z-index: 2000;
  border-radius: 999px;
  padding: 10px 16px;
}

#urgent-help-banner {
  animation: fadeSlideIn .25s ease-out;
}

@keyframes fadeSlideIn {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Campos bloqueados visualmente */
.readonly-field {
  background-color: #f3f4f6 !important;
  border-color: #e5e7eb !important;
  color: #6b7280 !important;
}

/* Para que el placeholder también se vea apagado */
.readonly-field::placeholder {
  color: #9ca3af !important;
}

/* El wrapper del intl-tel-input (por si algún día lo bloqueas) */
.readonly-field .iti__selected-flag,
.readonly-field .iti__country-list {
  opacity: 0.75;
}

@media (max-width: 576px) {

  /* Paciente */
  #patient_address::placeholder,

  /* Facturación */
  #billing-name::placeholder,
  #billing-address::placeholder {
    color: transparent;
  }

}

.summary-item:last-child{
  border-bottom: 0;
  padding-bottom: 0;
  margin-bottom: 0;
}

/* Términos y condiciones - texto justificado */
.terms-body p,
.terms-body li {
    text-align: justify;
}

.text-justify {
    text-align: justify;
}

.alert-warning {
    line-height: 1.6;
}

/* Input file estilizado (Step 6 - Transferencia) */
.file-input-soft {
    background-color: #ffffff; /* fondo blanco para el texto */
    border: 1px solid #d0d5dd;
    border-radius: 6px;
    padding: 6px;
}

/* Botón "Seleccionar archivo" */
.file-input-soft::file-selector-button {
    background-color: #eef2f6;   /* gris azulado suave */
    color: #1f2937;
    border: 1px solid #d0d5dd;
    padding: 8px 14px;
    margin-right: 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

/* Hover del botón */
.file-input-soft::file-selector-button:hover {
    background-color: #e2e8f0;
}

/* Focus */
.file-input-soft:focus {
    border-color: #86b7fe;
    box-shadow: none;
}

/* ===== Paso 6 (Payment): valores del resumen en negro ===== */
#step6 .summary-item .row > :not(.text-muted) {
  color: #212529 !important;  /* negro normal */
  font-weight: 400 !important; /* normal, NO bold */
}

/* Labels del resumen de pago en negro */
.form-section .d-flex > span {
    color: #212529; /* negro Bootstrap */
}

/* ===== Paso 6: labels de transferencia en negro (SIN negrita) ===== */
#step6 label,
#step6 .form-label {
    color: #212529 !important;   /* negro */
    font-weight: 400 !important; /* normal, NO negrita */
}

#payphone-container {
    max-width: 420px;   /* 👈 más pequeño */
    margin: 0 auto;
    padding: 4px;       /* 👈 menos aire */
    background: transparent; /* 👈 quita el bloque visual */
    text-align: center;
}

/* intl-tel-input: que el dropdown responda rápido */
.iti__country-list {
  scroll-behavior: auto !important;
}

.iti__country, .iti__country-list {
  transition: none !important;
}

.login-link {
    color: #2563eb !important;        /* azul médico moderno */
    border: 1px solid #2563eb;
    padding: 6px 14px;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
}

.login-link:hover {
    background-color: #2563eb;
    color: #ffffff !important;
}

/* Mantener logo + menú (Iniciar sesión) en una sola línea en pantallas medianas/pequeñas */
@media (max-width: 990px) {

  /* Evita que el contenedor de navegación se baje como bloque */
  #navbarNav.navbar-collapse {
    display: flex !important;
    flex-basis: auto !important;
    flex-grow: 0 !important;
    width: auto !important;
  }

  /* Tu UL actual: <ul class="navbar-nav ms-auto"> */
  #navbarNav .navbar-nav {
    flex-direction: row !important;
    align-items: center !important;
    gap: 10px;
    margin-left: auto !important;
  }

  /* Botón login: evita que se estire y que ocupe toda la fila */
  #navbarNav .login-link {
    width: auto !important;
    margin-top: 0 !important;
    white-space: nowrap;
    padding: 6px 12px;
  }

  /* Asegura que el navbar no haga wrap (para que no baje el menú) */
  .navbar .container,
  .navbar .container-fluid {
    flex-wrap: nowrap !important;
    align-items: center;
  }
}

/* Solo si la pantalla es súper pequeña, ahí sí permitimos que baje */
@media (max-width: 360px) {
  .navbar .container,
  .navbar .container-fluid {
    flex-wrap: wrap !important;
  }

  #navbarNav.navbar-collapse {
    width: 100% !important;
  }

  #navbarNav .navbar-nav {
    width: 100%;
    justify-content: flex-start;
    margin-top: 10px;
  }
}

/* En pantallas MUY pequeñas: centrar logo y botón */
@media (max-width: 360px) {

  /* Contenedor del navbar */
  .navbar .container,
  .navbar .container-fluid {
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center;
    text-align: center;
  }

  /* Logo centrado */
  .navbar-brand {
    margin: 0 auto;
    text-align: center;
  }

  .navbar-brand img {
    margin: 0 auto;
    display: block;
  }

  /* Contenedor de navegación */
  #navbarNav.navbar-collapse {
    width: 100% !important;
    display: flex !important;
    justify-content: center;
    margin-top: 8px;
  }

  /* UL */
  #navbarNav .navbar-nav {
    flex-direction: column !important;
    align-items: center !important;
    margin-left: 0 !important;
    gap: 8px;
  }

  /* Botón login centrado */
  #navbarNav .login-link {
    width: auto !important;
    margin: 0 auto;
    padding: 6px 14px;
  }
}