/* Estilos para funcionalidades de administración */

/* Editor de texto enriquecido */
.rich-text-editor-wrapper {
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
}

.rich-text-toolbar {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-wrap: wrap;
}

.toolbar-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    padding: 6px 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
}

.toolbar-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: white;
}

.toolbar-btn:active {
    background: rgba(59, 130, 246, 0.3);
    border-color: rgba(59, 130, 246, 0.5);
}

.toolbar-divider {
    width: 1px;
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 4px;
}

.rich-text-editor {
    min-height: 200px;
    max-height: 400px;
    padding: 16px;
    color: rgba(255, 255, 255, 0.9);
    font-family: 'Jost', sans-serif;
    font-size: 15px;
    line-height: 1.6;
    overflow-y: auto;
    outline: none;
}

.rich-text-editor:empty:before {
    content: attr(placeholder);
    color: rgba(255, 255, 255, 0.4);
    pointer-events: none;
}

.rich-text-editor:focus {
    background: rgba(255, 255, 255, 0.03);
}

.rich-text-editor p {
    margin: 0 0 8px 0;
}

.rich-text-editor p:last-child {
    margin-bottom: 0;
}

.rich-text-editor ul,
.rich-text-editor ol {
    margin: 8px 0;
    padding-left: 24px;
}

.rich-text-editor li {
    margin: 4px 0;
}

.rich-text-editor strong {
    font-weight: 700;
}

.rich-text-editor em {
    font-style: italic;
}

.rich-text-editor u {
    text-decoration: underline;
}

/* Deshabilitar scroll del body cuando el modal está abierto */
html.modal-open,
html.modal-open body {
    overflow: hidden !important;
    height: 100% !important;
    position: fixed !important;
    width: 100% !important;
}

/* Botón Agregar en secciones */
.admin-add-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: transparent;
    color: white;
    border: 2px dashed white;
    border-radius: 8px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 24px;
    box-shadow: none;
}

.admin-add-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.4);
}

/* Botones admin en cards */
.admin-card-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.admin-btn-edit,
.admin-btn-delete {
    flex: 1;
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    font-family: 'Jost', sans-serif;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.admin-btn-edit {
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.5);
    color: #60a5fa;
}

.admin-btn-edit:hover {
    background: rgba(59, 130, 246, 0.3);
    transform: translateY(-2px);
}

.admin-btn-delete {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.5);
    color: #ff6b6b;
}

.admin-btn-delete:hover {
    background: rgba(220, 53, 69, 0.3);
    transform: translateY(-2px);
}

/* Modal de edición (lado izquierdo) */
.admin-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    min-height: 100vh;
    max-height: 100vh;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-y: auto;
    overflow-x: hidden;
    box-sizing: border-box;
}

.admin-modal,
.admin-modal-content {
    width: 500px;
    max-width: calc(100vw - 40px);
    background: linear-gradient(135deg, #2e335a 0%, #1a1a2e 50%, #0e0e0e 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    margin: auto;
    position: relative;
    max-height: calc(100vh - 40px);
    height: auto;
    min-height: 400px;
    overflow-y: auto;
    overflow-x: hidden;
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

.admin-modal-header {
    padding: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    background: linear-gradient(135deg, #2e335a 0%, #1a1a2e 50%, #0e0e0e 100%);
    z-index: 10;
}

.admin-modal-header h2 {
    color: var(--light-color);
    font-family: 'Jost', sans-serif;
    font-size: 24px;
    font-weight: 600;
    margin: 0;
}

.admin-modal-close {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.3s ease;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.admin-modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--light-color);
    transform: rotate(90deg);
}

.admin-modal-body {
    padding: 24px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0; /* Permite que el flex funcione correctamente */
}

/* Estilos para scrollbar personalizado en modales */
.admin-modal-body::-webkit-scrollbar,
.admin-modal::-webkit-scrollbar,
.admin-modal-content::-webkit-scrollbar {
    width: 8px;
}

.admin-modal-body::-webkit-scrollbar-track,
.admin-modal::-webkit-scrollbar-track,
.admin-modal-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

.admin-modal-body::-webkit-scrollbar-thumb,
.admin-modal::-webkit-scrollbar-thumb,
.admin-modal-content::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.admin-modal-body::-webkit-scrollbar-thumb:hover,
.admin-modal::-webkit-scrollbar-thumb:hover,
.admin-modal-content::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.admin-form-group {
    margin-bottom: 20px;
}

.admin-form-group label {
    display: block;
    color: var(--light-color);
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

.admin-form-group input[type="checkbox"] {
    width: auto;
}

.admin-form-group input,
.admin-form-group textarea,
.admin-form-group select {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--light-color);
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.admin-form-group input:focus,
.admin-form-group textarea:focus,
.admin-form-group select:focus {
    outline: none;
    border-color: #3b82f6;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.admin-form-group textarea {
    min-height: 100px;
    resize: vertical;
}

.admin-form-group input[type="number"] {
    width: 100%;
}

.admin-modal-actions {
    display: flex;
    gap: 12px;
    padding: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    position: sticky;
    bottom: 0;
    background: linear-gradient(135deg, #2e335a 0%, #1a1a2e 50%, #0e0e0e 100%);
}

.admin-modal-actions button {
    flex: 1;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.admin-btn-save {
    background: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%);
    color: white;
}

.admin-btn-save:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.admin-btn-cancel {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.admin-btn-cancel:hover {
    background: rgba(255, 255, 255, 0.15);
}

.admin-btn-save:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Compatibilidad con clases usadas en home admin */
.admin-modal-footer {
    display: flex;
    gap: 12px;
    padding: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    position: sticky;
    bottom: 0;
    background: linear-gradient(135deg, #2e335a 0%, #1a1a2e 50%, #0e0e0e 100%);
    z-index: 10;
}

.btn-save,
.admin-btn-save {
    background: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1;
}

.btn-save:hover:not(:disabled),
.admin-btn-save:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.btn-save:disabled,
.admin-btn-save:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-cancel,
.admin-btn-cancel,
.admin-btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 12px 24px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 100px;
}

.btn-cancel:hover,
.admin-btn-cancel:hover,
.admin-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.admin-btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    min-width: 100px;
}

.admin-btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.4);
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
}

.admin-btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.admin-btn-primary i.fa-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Confirmación de eliminación */
.admin-confirm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.admin-confirm-modal {
    background: linear-gradient(135deg, #2e335a 0%, #1a1a2e 50%, #0e0e0e 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    max-width: 450px;
    width: 100%;
    padding: 32px;
    text-align: center;
}

.admin-confirm-modal h3 {
    color: var(--light-color);
    font-family: 'Jost', sans-serif;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 16px;
}

.admin-confirm-modal p {
    color: rgba(255, 255, 255, 0.8);
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    margin-bottom: 24px;
    line-height: 1.6;
}

.admin-confirm-actions {
    display: flex;
    gap: 12px;
}

.admin-confirm-actions button {
    flex: 1;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.admin-confirm-delete {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.5);
    color: #ff6b6b;
}

.admin-confirm-delete:hover {
    background: rgba(220, 53, 69, 0.3);
}

.admin-confirm-cancel {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.admin-confirm-cancel:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* Upload de imágenes */
.admin-image-upload-wrapper {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.admin-upload-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.admin-upload-label {
    cursor: pointer;
    display: inline-block;
}

.admin-upload-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    width: fit-content;
}

.admin-upload-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.4);
}

.admin-upload-progress {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 13px;
    font-family: 'Jost', sans-serif;
    padding: 8px 12px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 6px;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.admin-upload-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.9);
    font-family: 'Jost', sans-serif;
}

.admin-upload-info span {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.admin-upload-remove {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.4);
    color: #ff6b6b;
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
}

.admin-upload-remove:hover {
    background: rgba(220, 53, 69, 0.3);
    transform: scale(1.05);
}

.admin-url-section input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.admin-image-preview {
    margin-top: 12px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.2);
    max-width: 400px;
}

.admin-preview-image {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: contain;
    display: block;
}

/* Clase para deshabilitar scroll del body cuando el modal está abierto */
.no-scroll {
    overflow: hidden !important;
    height: 100% !important;
    position: fixed !important;
    width: 100% !important;
    left: 0 !important;
}

html.no-scroll {
    overflow: hidden !important;
    height: 100% !important;
    position: fixed !important;
    width: 100% !important;
    left: 0 !important;
}

/* Botón de edición admin en secciones */
.admin-edit-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(59, 130, 246, 0.9);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.admin-edit-btn:hover {
    background: rgba(59, 130, 246, 1);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.5);
}

/* Estilos para modales de home admin */
.home-admin-modal {
    max-width: 600px;
    width: 100%;
    max-height: calc(100vh - 40px);
    height: auto;
    min-height: 400px;
    overflow-y: auto;
    box-sizing: border-box;
}

.home-admin-modal .admin-modal-body {
    padding: 24px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}

.home-admin-modal .admin-form-group {
    margin-bottom: 20px;
}

.home-admin-modal .admin-form-group label {
    display: block;
    color: var(--light-color);
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

.home-admin-modal .admin-form-group input,
.home-admin-modal .admin-form-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--light-color);
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.home-admin-modal .admin-form-group input:focus,
.home-admin-modal .admin-form-group textarea:focus {
    outline: none;
    border-color: #3b82f6;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.home-admin-modal .admin-form-group textarea {
    min-height: 20px;
    resize: vertical;
}

.stat-input-group {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

.stat-input-group input {
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.9);
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.stat-input-group input:focus {
    outline: none;
    border-color: #3b82f6;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.benefit-input-group {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
}

.benefit-input-group textarea {
    flex: 1;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.9);
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    resize: vertical;
}

.benefit-input-group .remove-btn {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.4);
    color: #ff6b6b;
    border-radius: 6px;
    padding: 10px 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.benefit-input-group .remove-btn:hover:not(:disabled) {
    background: rgba(220, 53, 69, 0.3);
}

.benefit-input-group .remove-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-add-item {
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.4);
    color: #60a5fa;
    border-radius: 6px;
    padding: 10px 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
}

.btn-add-item:hover {
    background: rgba(59, 130, 246, 0.3);
}

.image-upload-wrapper {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.btn-upload, .btn-url {
    padding: 10px 16px;
    border: none;
    border-radius: 6px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-upload {
    background: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%);
    color: white;
}

.btn-url {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.9);
}

.btn-upload:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-url:hover {
    background: rgba(255, 255, 255, 0.15);
}

.images-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.image-preview-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.3);
}

.image-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.remove-image-btn {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(220, 53, 69, 0.9);
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 12px;
}

.remove-image-btn:hover {
    background: rgba(220, 53, 69, 1);
    transform: scale(1.1);
}

/* Estilos adicionales para modales home admin */
.home-admin-modal small {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    display: block;
    margin-top: 8px;
}

.home-admin-modal small i {
    margin-right: 6px;
}

.placeholder-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.3);
    color: rgba(255, 255, 255, 0.3);
    font-size: 24px;
}

/* Ajustes para inputs de estadísticas */
.stat-input-group label {
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    font-weight: 400;
}

.stat-input-group input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

/* Mejoras visuales para el grid de imágenes */
.images-grid {
    margin-top: 16px;
}

.images-grid .image-preview-item:empty {
    display: none;
}

/* Lightbox Galería */
.lightbox-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    min-width: 100vw !important;
    min-height: 100vh !important;
    max-width: 100vw !important;
    max-height: 100vh !important;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 20px;
    box-sizing: border-box;
    margin: 0 !important;
    transform: none !important;
    overflow: hidden !important;
}

.lightbox-container {
    position: relative;
    width: 100%;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10001;
    font-size: 24px;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10001;
    font-size: 28px;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-image-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
}

.lightbox-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-family: 'Jost', sans-serif;
    font-size: 14px;
    font-weight: 600;
}

/* Responsive */
@media (max-width: 768px) {
    .admin-modal,
    .admin-modal-content {
        width: 100%;
        max-width: 100%;
        margin: 0;
        border-radius: 0;
        max-height: 100vh;
        height: 100vh;
    }
    
    .admin-modal-overlay {
        padding: 0;
    }
    
    .home-admin-modal {
        max-width: 100%;
        border-radius: 0;
        height: 100vh;
        max-height: 100vh;
    }
    
    .admin-image-preview {
        max-width: 100%;
    }
    
    .stat-input-group {
        grid-template-columns: 1fr;
        gap: 8px;
    }
    
    .stat-input-group input {
        width: 100%;
    }
    
    .image-upload-wrapper {
        flex-direction: column;
        gap: 8px;
    }
    
    .btn-upload,
    .btn-url {
        width: 100%;
    }
    
    .images-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 8px;
    }
    
    .admin-modal-header {
        padding: 16px;
    }
    
    .admin-modal-header h2 {
        font-size: 20px;
    }
    
    .admin-modal-body {
        padding: 16px;
    }
    
    .admin-modal-footer {
        padding: 16px;
        flex-direction: column;
    }
    
    .admin-modal-footer .btn-save,
    .admin-modal-footer .btn-cancel,
    .admin-modal-footer .admin-btn-save,
    .admin-modal-footer .admin-btn-cancel {
        width: 100%;
    }
    
    .lightbox-nav {
        width: 45px;
        height: 45px;
        font-size: 20px;
    }
    
    .lightbox-prev {
        left: 10px;
    }
    
    .lightbox-next {
        right: 10px;
    }
    
    .lightbox-close {
        width: 40px;
        height: 40px;
        font-size: 20px;
        top: 10px;
        right: 10px;
    }
}

