/* Consultorios CSS - Styles for medical offices management */

/* Import Inter font */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

/* Base styles */
* {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Gradient orbs */
.gradient-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(30px);
    opacity: 0.2;
    animation: float-slow 20s infinite ease-in-out;
    pointer-events: none;
}

@keyframes float-slow {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, -30px) scale(1.1); }
    66% { transform: translate(-20px, 20px) scale(0.9); }
}

/* Sidebar */
.sidebar-glass {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-right: 1px solid rgba(229, 231, 235, 0.5);
}

/* Navigation */
.nav-link {
    position: relative;
    transition: all 0.2s ease;
    color: #6b7280;
    font-weight: 500;
    text-decoration: none;
    display: block;
    padding: 0.625rem 0;
}

.nav-link:hover {
    color: #111827;
}

.nav-link.active {
    color: #3b82f6;
    font-weight: 600;
}

.nav-link.active::before {
    content: '';
    position: absolute;
    left: -24px;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 24px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    border-radius: 0 4px 4px 0;
}

/* User profile link */
.user-profile-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 12px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.user-profile-link:hover {
    background: #f3f4f6;
}

/* Buttons */
.btn-primary {
    background: #3d75ef;
    color: white;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(61, 117, 239, 0.3);
}

.btn-secondary {
    background: white;
    color: #374151;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    border: 2px solid #e5e7eb;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-secondary:hover {
    background: #f9fafb;
    border-color: #d1d5db;
}

.btn-danger {
    background: #ef4444;
    color: white;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-danger:hover {
    background: #dc2626;
}

/* Consultorio Cards */
.consultorio-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    position: relative;
}

.consultorio-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

/* Card Header with Carousel - 4:3 RATIO (4032×3024) */
.card-header {
    aspect-ratio: 4 / 3; /* 4032×3024 pixels ratio */
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.card-carousel {
    width: 100%;
    height: 100%;
    position: relative;
}

.card-carousel-images {
    display: flex;
    height: 100%;
    transition: transform 0.3s ease;
}

.card-carousel-image {
    min-width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.card-carousel-image.loaded {
    opacity: 1;
}

.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 3;
    opacity: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.card-header:hover .carousel-nav {
    opacity: 1;
}

.carousel-nav:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
}

.carousel-nav.prev {
    left: 8px;
}

.carousel-nav.next {
    right: 8px;
}

.carousel-indicators {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 4px;
    z-index: 3;
}

.carousel-indicator {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transition: all 0.2s ease;
    cursor: pointer;
}

.carousel-indicator.active {
    background: white;
    width: 20px;
    border-radius: 3px;
}

.card-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,0.3) 100%);
    z-index: 1;
}

.principal-badge {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: #1f2a83;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    z-index: 4;
}

.card-actions {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    gap: 8px;
    opacity: 0;
    transition: opacity 0.2s ease;
    z-index: 4;
}

.consultorio-card:hover .card-actions {
    opacity: 1;
}

.card-action-btn {
    position: relative;
    width: 32px;
    height: 32px;
    background: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.card-action-btn:hover {
    transform: scale(1.1);
    background: #f3f4f6;
}

/* Tooltip global - added to body via JS */
.btn-tooltip {
    position: fixed;
    padding: 6px 12px;
    background: #1a1a2e;
    color: white;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    border-radius: 6px;
    pointer-events: none;
    z-index: 99999;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    opacity: 0;
    transition: opacity 0.15s ease;
}

.btn-tooltip.show {
    opacity: 1;
}

.btn-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #1a1a2e;
}

.card-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    min-height: 140px;
}

.card-title {
    font-size: 18px;
    font-weight: 700;
    color: #111827;
    margin-bottom: 8px;
    /* Fixed height for title - truncate if too long */
    line-height: 1.3;
    max-height: 2.6em;
    overflow: hidden;
}

.card-address {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    /* Fixed height for address */
    min-height: 21px;
}

.card-notes {
    font-size: 13px;
    color: #9ca3af;
    margin-bottom: 8px;
    font-style: italic;
    /* Fixed height for notes area */
    min-height: 20px;
}

.card-features {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
    /* Fixed height for features */
    min-height: 24px;
    align-items: center;
}

.card-features i {
    font-size: 18px;
}

.card-map-link-container {
    margin-top: auto;
    min-height: 21px;
}

.card-map-link {
    display: flex;
    width: 100%;
    box-sizing: border-box;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #2563eb;
    font-size: 12.5px;
    font-weight: 700;
    text-decoration: none;
    padding: 6px 14px;
    border-radius: 999px;
    background: #ffffff;
    border: 1.5px solid #3b82f6;
    transition: background 0.2s ease, transform 0.1s ease;
}

.card-map-link:hover {
    background: #eff6ff;
    color: #1d4ed8;
    transform: translateY(-1px);
}

/* Chip de color = botón que abre Editar → Información Adicional */
.card-color-btn {
    transition: background 0.2s ease, transform 0.1s ease;
}

.card-color-btn:hover {
    background: #f8fafc !important;
    transform: translateY(-1px);
}

/* Modal - FIXED FOR SCROLL */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    z-index: 50;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 0.25rem;
}

.modal.show {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background: white;
    border-radius: 24px;
    max-width: 900px;
    width: 90%;
    max-height: 98vh;
    overflow-y: auto;
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

/* Consultorio Modal - FIXED STRUCTURE */
.consultorio-modal-content {
    display: flex;
    flex-direction: column;
    max-height: 98vh;
    overflow: hidden;
}

.modal.show .modal-content {
    transform: scale(1);
}

/* Close button for modal */
.close-btn-modal {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    background: #f3f4f6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    z-index: 10;
    color: #6b7280;
}

.close-btn-modal:hover {
    transform: scale(1.1);
    background: #e5e7eb;
    color: #374151;
}

/* Modal Body - SCROLLABLE */
.modal-body {
    position: relative;
    padding: 32px;
    flex: 1;
    overflow-y: auto;
}

/* Form */
.form-section {
    margin-bottom: 24px;
}

.form-section-title {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6b7280;
    margin-bottom: 16px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 6px;
}

.input-field {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.input-field:focus {
    outline: none;
    border-color: #6366F1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.input-field:disabled {
    background: #f9fafb;
    color: #9ca3af;
    cursor: not-allowed;
}

/* Phone Input - Match login page design */
.phone-country-select {
    flex: 0 0 110px;
    padding: 0.55rem 0.7rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.4rem;
    font-size: 0.875rem;
    font-weight: 400;
    color: #111827;
    background-color: #ffffff;
    transition: all 0.2s ease;
    outline: none;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    height: 38px;
    box-sizing: border-box;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding-right: 2rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.5rem center;
    background-size: 12px;
    cursor: pointer;
}

.phone-country-select:hover {
    border-color: #e5e7eb;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    background-color: #f9fafb;
}

.phone-country-select:focus {
    border-color: #e5e7eb;
    box-shadow: 0 0 0 3px rgba(92, 179, 166, 0.1), 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    background-color: #ffffff;
}

.phone-local-input {
    flex: 1;
    padding: 0.55rem 0.7rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.4rem;
    font-size: 0.875rem;
    font-weight: 400;
    color: #111827;
    background-color: #ffffff;
    transition: all 0.2s ease;
    outline: none;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    height: 38px;
    box-sizing: border-box;
}

.phone-local-input:hover {
    border-color: #e5e7eb;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    background-color: #f9fafb;
}

.phone-local-input:focus {
    border-color: #e5e7eb;
    box-shadow: 0 0 0 3px rgba(92, 179, 166, 0.1), 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    background-color: #ffffff;
}

.phone-local-input::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

/* Payment Method Toggles */
.toggle-switch-payment {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.toggle-checkbox-payment {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider-payment {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider-payment:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.toggle-checkbox-payment:checked + .toggle-slider-payment {
    background-color: #68ecc0;
}

.toggle-checkbox-payment:checked + .toggle-slider-payment:before {
    transform: translateX(20px);
}

/* Payment Methods Collapsible */
#payment-methods-content {
    transition: all 0.3s ease;
    overflow: hidden;
}

#payment-methods-content.hidden {
    display: none;
}

#payment-methods-chevron {
    transition: transform 0.2s ease;
}

/* Map Preview Collapsible */
#map-preview-content {
    transition: all 0.3s ease;
    overflow: hidden;
}

#map-preview-content.hidden {
    display: none;
}

#map-preview-chevron {
    transition: transform 0.2s ease;
}

/* Card Type Options */
.card-type-option {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.card-type-option input[type="checkbox"] {
    display: none;
}

.card-type-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    font-size: 0.8rem;
    font-weight: 500;
    color: #374151;
    background-color: #fff;
    transition: all 0.2s ease;
    width: 100%;
}

.card-type-option input[type="checkbox"]:checked + .card-type-label {
    border-color: #3d75ef;
    background-color: #eff6ff;
    color: #1e40af;
}

.card-type-option:hover .card-type-label {
    border-color: #93c5fd;
    background-color: #f8fafc;
}

.card-logo {
    height: 24px;
    width: auto;
    max-width: 50px;
    object-fit: contain;
}

/* Container for card/insurance options - no scroll */
#card-types-container .grid,
#insurance-types-container .grid {
    max-height: none;
    overflow-y: visible;
    padding-right: 4px;
}

#card-types-container .grid::-webkit-scrollbar,
#insurance-types-container .grid::-webkit-scrollbar {
    width: 4px;
}

#card-types-container .grid::-webkit-scrollbar-track,
#insurance-types-container .grid::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

#card-types-container .grid::-webkit-scrollbar-thumb,
#insurance-types-container .grid::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

#card-types-container .grid::-webkit-scrollbar-thumb:hover,
#insurance-types-container .grid::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

.checkbox {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* Estado Select - Custom styling */
.estado-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    padding-right: 40px;
    cursor: pointer;
    max-height: 200px;
    font-size: 14px;
}

.estado-select:hover {
    border-color: #6366F1;
}

.estado-select option {
    padding: 8px 12px;
    font-size: 14px;
    background: white;
    color: #111827;
}

.estado-select option:hover {
    background: #f3f4f6;
}


/* Extras icon rotation when expanded */
#extras-icon.rotate-up {
    transform: rotate(180deg);
}

/* Map Container */
.map-container {
    height: 300px;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid #e5e7eb;
}

/* Secondary Photos - CAROUSEL SINGLE ROW FORMAT */
.secondary-photos-grid {
    display: flex;
    flex-wrap: nowrap;
    gap: 10px;
    overflow-x: auto;
    padding: 8px 4px;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.secondary-photos-grid::-webkit-scrollbar {
    height: 6px;
}

.secondary-photos-grid::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.secondary-photos-grid::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.secondary-photos-grid::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

.secondary-photo {
    position: relative;
    width: 100px;
    height: 133px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    background: #f3f4f6;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.secondary-photo:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

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

/* Toggle Switch Principal */
.toggle-switch-principal {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
    cursor: pointer;
}

.toggle-checkbox-principal {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider-principal {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider-principal:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    border-radius: 50%;
    transition: 0.3s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.toggle-checkbox-principal:checked + .toggle-slider-principal {
    background-color: #68ecc0;
}

.toggle-checkbox-principal:checked + .toggle-slider-principal:before {
    transform: translateX(20px);
}

.toggle-checkbox-principal:focus + .toggle-slider-principal {
    box-shadow: 0 0 0 3px rgba(104, 236, 192, 0.2);
}

/* Toggle Switch Estacionamiento */
.toggle-switch-estacionamiento {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
    cursor: pointer;
}

.toggle-checkbox-estacionamiento {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider-estacionamiento {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider-estacionamiento:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    border-radius: 50%;
    transition: 0.3s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.toggle-checkbox-estacionamiento:checked + .toggle-slider-estacionamiento {
    background-color: #68ecc0;
}

.toggle-checkbox-estacionamiento:checked + .toggle-slider-estacionamiento:before {
    transform: translateX(20px);
}

.toggle-checkbox-estacionamiento:focus + .toggle-slider-estacionamiento {
    box-shadow: 0 0 0 3px rgba(96, 196, 166, 0.2);
}

/* Toggle Switch Pet Friendly */
.toggle-switch-pet {
    position: relative;
    display: inline-block;
    width: 52px;
    height: 28px;
    cursor: pointer;
}

.toggle-checkbox-pet {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider-pet {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    border-radius: 34px;
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.toggle-slider-pet:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-checkbox-pet:checked + .toggle-slider-pet {
    background: linear-gradient(to right, rgb(96, 196, 166), rgb(52, 211, 153));
    box-shadow: 0 2px 8px rgba(52, 211, 153, 0.3);
}

.toggle-checkbox-pet:checked + .toggle-slider-pet:before {
    transform: translateX(24px);
}

.toggle-checkbox-pet:focus + .toggle-slider-pet {
    box-shadow: 0 0 0 3px rgba(96, 196, 166, 0.2);
}

.remove-photo-btn {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 20px;
    height: 20px;
    font-size: 0.6rem;
    background: rgba(239, 68, 68, 0.9);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.secondary-photo:hover .remove-photo-btn {
    opacity: 1;
}

.add-photo-box {
    width: 100px;
    height: 133px;
    flex-shrink: 0;
    border: 2px dashed #d1d5db;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #9ca3af;
    background: white;
    font-size: 0.75rem;
    gap: 4px;
}

.add-photo-box i {
    font-size: 1.25rem;
}

.add-photo-box span {
    text-align: center;
    line-height: 1.2;
}

.add-photo-box:hover {
    border-color: #6366F1;
    color: #6366F1;
    background: #eef2ff;
}

.add-photo-box.at-limit {
    border-color: #10b981;
    background: #ecfdf5;
    color: #065f46;
    opacity: 0.9;
}

.add-photo-box.at-limit:hover {
    border-color: #10b981;
    background: #ecfdf5;
    color: #065f46;
}

/* Modal Footer - FIXED POSITION */
.modal-footer {
    padding: 24px 32px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    flex-shrink: 0;
    background: white;
    border-radius: 0 0 24px 24px;
}

/* Map Modal */
.map-modal-content {
    max-width: 800px;
    width: 90%;
    background: white;
    border-radius: 16px;
    overflow: hidden;
}

.map-modal-header {
    padding: 20px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.full-map {
    height: 500px;
}

.map-modal-footer {
    padding: 20px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Toast */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: #111827;
    color: white;
    padding: 16px 24px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 100;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

/* Confirm Modal */
.confirm-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 60;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.confirm-modal.show {
    opacity: 1;
    pointer-events: auto;
}

.confirm-modal-content {
    background: white;
    border-radius: 16px;
    padding: 24px;
    max-width: 400px;
    width: 90%;
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.confirm-modal.show .confirm-modal-content {
    transform: scale(1);
}

/* Loading Overlay */
#loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(249, 250, 251, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    flex-direction: column;
    gap: 1rem;
}

#loading-overlay.hidden {
    display: none;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid #e5e7eb;
    border-top: 3px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-message {
    font-size: 14px;
    color: #6b7280;
    font-weight: 500;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Empty State */
#empty-state {
    text-align: center;
    padding: 60px 20px;
}

/* Scrollbar Styles for Modal */
.modal-body::-webkit-scrollbar {
    width: 8px;
}

.modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.modal-body::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Responsive */
@media (max-width: 768px) {
    .sidebar-glass {
        display: none;
    }
    
    .consultorio-card {
        margin-bottom: 16px;
    }
    
    .card-header {
        height: 200px; /* Slightly smaller on mobile */
    }
    
    .modal-content {
        width: 95%;
        max-height: 95vh;
    }
    
    .consultorio-modal-content {
        max-height: 95vh;
    }

    .modal-body {
        padding: 20px;
        max-height: calc(95vh - 100px);
    }
    
    .modal-footer {
        padding: 16px 20px;
    }
    
    .secondary-photos-grid {
        gap: 6px;
    }

    .secondary-photo,
    .add-photo-box {
        width: 55px;
        height: 73px;
    }
}

/* Google Places Autocomplete Dropdown - Fix position in modals */
.pac-container {
    position: fixed !important;
    z-index: 100000 !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15) !important;
    border-radius: 8px !important;
    border: 1px solid #e5e7eb !important;
    font-family: 'Inter', sans-serif !important;
}

.pac-item {
    padding: 10px 12px !important;
    cursor: pointer !important;
    font-size: 14px !important;
    border-bottom: 1px solid #f3f4f6 !important;
}

.pac-item:hover {
    background-color: #f9fafb !important;
}

.pac-item-selected {
    background-color: #eff6ff !important;
}

.pac-icon {
    margin-right: 10px !important;
}

.pac-item-query {
    font-weight: 500 !important;
    color: #111827 !important;
}

