/* --- Cards de complejos --- */
#lista-complejos .card {
    border: none;
    border-radius: 0.75rem;
    transition: transform 0.2s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

#lista-complejos .card:hover {
    transform: scale(1.02);
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.2);
}

#lista-complejos img {
    height: 180px;
    object-fit: cover;
}

/* --- Modal de reservas --- */
#modal-reservas {
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    padding-top: 40px;
}

#modal-reservas .modal-dialog {
    background-color: #fff;
    margin: auto;
    max-width: 500px;
    border-radius: 0.75rem;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.4);
}

#modal-reservas .modal-content {
    border: none;
    border-radius: 0.75rem;
}

#modal-reservas .close-btn {
    font-size: 1.5rem;
    font-weight: bold;
    color: #333;
    float: right;
}

#modal-reservas .close-btn:hover {
    color: #000;
}

#turnos-lista li {
    cursor: pointer;
}

#turnos-lista li.active {
    background-color: #91ff00;
    color: black;
    font-weight: bold;
}

#turnos-lista li:not(.active):hover {
    background-color: #e0e0e0;
}

/* --- Botón principal --- */
.btn-x3green {
    background-color: #91ff00;
    color: black;
    font-weight: 600;
    border: none;
}

.btn-x3green:hover {
    background-color: #7de600;
    color: black;
}

.btn-reservas-disabled {
    border: 1px solid rgba(255, 255, 255, 0.22);
    background-color: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.72) !important;
    cursor: not-allowed;
    font-weight: 600;
}

/* --- Reserva publica: seleccion compacta de fecha y horario --- */
.x3-ui-next.x3-reservas-hero.x3-public-hero--image {
    background-image: linear-gradient(180deg, rgb(0 0 0 / 54%), rgb(0 0 0 / 68%)), var(--x3-hero-image);
    background-position: center;
}

#turnos-online { padding-block: 0.7rem 1.4rem; }
#turnos-online > .x3-next-wide { max-width: 78rem; }
#turnos-online .x3-reservas-title { margin: 0; color: var(--x3-next-text); font-size: clamp(1.3rem, 2vw, 1.6rem); font-weight: 750; }
#turnos-online .x3-reservas-intro { margin: 0.1rem 0 0.6rem; color: var(--x3-next-muted); font-size: 0.9rem; }
#turnos-online .x3-reservas-surface {
    padding: 0.9rem;
    border: 1px solid var(--x3-next-border);
    border-radius: var(--x3-next-radius-md);
    background: var(--x3-next-surface);
    color: var(--x3-next-text);
}
#turnos-online .x3-reservas-step { color: var(--x3-next-green); font-size: 0.78rem; font-weight: 750; letter-spacing: 0.02em; }
#turnos-online .x3-reservas-date-head { display: flex; align-items: end; justify-content: space-between; gap: 0.7rem; }
#turnos-online .dia-fecha-turnos { color: var(--x3-next-text); font-size: 0.92rem; font-weight: 650; text-transform: capitalize; }
#turnos-online .x3-reservas-calendar { display: grid; gap: 0.1rem; width: min(100%, 10rem); color: var(--x3-next-muted); font-size: 0.75rem; }
#turnos-online .x3-reservas-calendar .form-control { width: 100%; min-height: 44px; padding: 0.35rem 0.45rem; background: #fff; color: #111827; }
#turnos-online .x3-reservas-days {
    display: flex; gap: 0.35rem; overflow-x: auto; overscroll-behavior-inline: contain;
    margin-top: 0.55rem; padding: 0 0 0.4rem; scrollbar-width: thin; scroll-snap-type: x proximity;
}
#turnos-online .x3-reservas-day {
    flex: 0 0 4.7rem; min-height: 56px; display: grid; place-content: center; gap: 0;
    border: 1px solid var(--x3-next-border); border-radius: 0.55rem;
    background: #151a1e; color: var(--x3-next-text); text-align: center;
    scroll-snap-align: start; cursor: pointer;
}
#turnos-online .x3-reservas-day small { color: var(--x3-next-muted); font-size: 0.7rem; text-transform: capitalize; }
#turnos-online .x3-reservas-day strong { font-size: 1.1rem; line-height: 1.15; }
#turnos-online .x3-reservas-day:hover { border-color: var(--x3-next-green); }
#turnos-online .x3-reservas-day[aria-pressed="true"] { border-color: var(--x3-next-green); background: var(--x3-next-green); color: var(--x3-next-on-green); }
#turnos-online .x3-reservas-day[aria-pressed="true"] small { color: var(--x3-next-on-green); }
#turnos-online .x3-reservas-day:focus-visible,
#turnos-online .x3-reservas-periods button:focus-visible,
#turnos-online .turno-select:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
#turnos-online .x3-reservas-availability { margin-top: 0.55rem; padding-top: 0.55rem; border-top: 1px solid var(--x3-next-border); }
#turnos-online .x3-reservas-availability-head { display: flex; align-items: end; justify-content: space-between; gap: 0.5rem; }
#turnos-online .x3-reservas-club h3 { margin: 0; color: var(--x3-next-text); font-size: 1.1rem; font-weight: 750; }
#turnos-online .x3-reservas-club p { margin: 0; color: var(--x3-next-muted); font-size: 0.77rem; }
#turnos-online .x3-reservas-refresh { min-height: 44px; white-space: nowrap; font-size: 0.8rem; }
#turnos-online .x3-reservas-periods { display: flex; gap: 0.35rem; overflow-x: auto; margin: 0.55rem 0; padding-bottom: 0.25rem; scrollbar-width: thin; }
#turnos-online .x3-reservas-periods button {
    flex: 0 0 auto; min-height: 44px; padding: 0.3rem 0.65rem;
    border: 1px solid var(--x3-next-border); border-radius: 999px;
    background: transparent; color: var(--x3-next-text); font-size: 0.8rem; font-weight: 650;
}
#turnos-online .x3-reservas-periods button:hover { border-color: var(--x3-next-green); }
#turnos-online .x3-reservas-periods button[aria-pressed="true"] { border-color: var(--x3-next-green); background: rgb(181 230 78 / 14%); color: var(--x3-next-green); }
#turnos-online .x3-reservas-status { color: var(--x3-next-muted); font-size: 0.8rem; }
#turnos-online .x3-reservas-status:empty { display: none; }
#turnos-online #turnos-vacios, #turnos-online .x3-reservas-filter-empty { margin: 0; padding: 0.45rem 0; color: var(--x3-next-muted) !important; font-size: 0.85rem; text-align: left !important; }
#turnos-online .x3-reservas-filter-empty[hidden] { display: none; }
#turnos-lista:not(.d-none) { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); gap: 0.5rem; }
#turnos-lista .x3-reservas-court { min-width: 0; padding: 0.55rem; border: 1px solid var(--x3-next-border); border-radius: 0.6rem; background: #1a2024; }
#turnos-lista .x3-reservas-court[hidden], #turnos-lista .turno-select[hidden] { display: none; }
#turnos-lista .x3-reservas-court h4 { margin: 0 0 0.4rem; color: var(--x3-next-text); font-size: 0.9rem; font-weight: 700; }
#turnos-lista .x3-reservas-slots { display: grid; grid-template-columns: repeat(auto-fit, minmax(5.7rem, 1fr)); gap: 0.3rem; }
#turnos-lista .turno-select {
    display: grid; place-content: center; min-width: 0; min-height: 44px; padding: 0.25rem 0.3rem;
    border: 1px solid rgb(181 230 78 / 32%); border-radius: 0.45rem;
    background: #11161b; color: var(--x3-next-text); text-align: center; cursor: pointer;
}
#turnos-lista .turno-select strong { color: inherit; font-size: 0.9rem; line-height: 1.2; }
#turnos-lista .turno-select small { color: var(--x3-next-muted); font-size: 0.7rem; line-height: 1.2; }
#turnos-lista .turno-select:hover { border-color: var(--x3-next-green); background: #263018; }
#turnos-lista .turno-select.active { border-color: var(--x3-next-green); background: var(--x3-next-green); color: var(--x3-next-on-green); }
#turnos-lista .turno-select.active small { color: var(--x3-next-on-green); }
#resumen-turno { margin: 0.7rem 0 0 !important; padding: 0.55rem 0.7rem; border: 1px solid rgb(181 230 78 / 45%); background: rgb(181 230 78 / 12%); color: #efffd2; text-align: left !important; font-size: 0.87rem; font-weight: 650; }
#turnos-online .x3-reserva-form { margin-top: 0.65rem; padding-top: 0.65rem; border-top: 1px solid var(--x3-next-border); }
#turnos-online:not(:has(#resumen-turno:not(.d-none))) #reserva-form { display: none; }
#turnos-online .x3-reserva-form h3 { margin: 0 0 0.5rem; color: var(--x3-next-text); font-size: 1.05rem; }
#turnos-online .x3-reserva-form .form-control { min-height: 44px; background: #fff; color: #111827; }
#turnos-online .x3-reserva-form .form-label { color: var(--x3-next-text); }
#turnos-online .x3-reservas-contact { margin-top: 0.65rem; text-align: center; }
#turnos-online .reserva-aviso { margin-top: 0.65rem; padding: 0.55rem 0.7rem; border: 1px solid rgb(255 193 7 / 35%); border-radius: 0.55rem; background: rgb(255 193 7 / 10%); color: #fff3cd; font-size: 0.8rem; line-height: 1.4; }
#turnos-online .reserva-aviso strong { color: #ffd86b; }
#turnos-online .btn-x3green { background: var(--x3-next-green); color: var(--x3-next-on-green); }
#turnos-online .btn-x3green:hover { background: var(--x3-next-green-hover); }
#turnos-online .whatsapp-reservas-btn { border: 1px solid rgba(37, 211, 102, 0.55); background-color: rgba(37, 211, 102, 0.14); color: #b8ffd0; font-weight: 700; padding: 0.52rem 1.1rem; }
#turnos-online .whatsapp-reservas-btn:hover,
#turnos-online .whatsapp-reservas-btn:focus { background-color: rgba(37, 211, 102, 0.28); border-color: #25d366; color: #fff; }
#turnos-online .whatsapp-reservas-btn .bi { margin-right: 0.35rem; }
#recuperar-reserva button { min-height: 44px; white-space: normal; }
@media (max-width: 767.98px) {
    #turnos-online .x3-reservas-surface { padding: 0.65rem; }
    #turnos-online .x3-reservas-day { flex-basis: 4.2rem; }
    #turnos-online .x3-reservas-refresh { padding-inline: 0.55rem; }
}
