* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background: #f5f5f5;
}

#app {
    display: flex;
    flex-direction: column;
}

.max-content {
    width: max-content;
}

.br-gray {
    border-right: 1px solid rgb(226, 226, 226);
}

header {
    left: 0;
}

.header {
    background: #ffffff;
    color: rgb(48, 47, 47);
    padding: 5px 10px;
    text-align: left;
    border-bottom: 1px solid rgba(0, 0, 0, 0.2);
}

main {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.bottom-nav {
    display: flex;
    border-top: 1px solid #ddd;
    background: white;
}

.bottom-nav button {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    flex: 1;
    padding: 10px;
    border: none;
    background: none;
    font-size: 14px;
}

.bottom-nav button:active {
    background: #e5e7eb;
}

/* Cards */
.card {
    background: white;
    padding: 16px;
    border-radius: 10px;
    margin-bottom: 16px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .1);
}

/* Forms */
label {
    display: block;
    font-weight: 500;
}

input,
select {
    width: 100%;
    padding: 10px;
    margin-top: 6px;
    border-radius: 8px;
    border: 1px solid #f3f3f3;
}

button.primary {
    width: 100%;
    padding: 12px;
    background: #2563eb;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
}

#form-dinamico {
    margin-top: 20px;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
}

.form-dinamico {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
}

th,
td {
    padding: 8px;
    text-align: left;
    border-bottom: 1px solid #ddd;
    font-size: 14px;
}

button.ver {
    padding: 6px 10px;
    background: #2563eb;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 12px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 100;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background: white;
    margin: 10% auto;
    padding: 16px;
    border-radius: 12px;
    width: 90%;
}

.close {
    float: right;
    font-size: 22px;
    font-weight: bold;
    cursor: pointer;
}

/* Fondo semitransparente sobre toda la pantalla */
.spinner-overlay {
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.show {
    display: flex !important;
}

.delete-content {
    display: none;
    align-items: center;
    justify-content: space-between;
    background: white;
    padding: 5px;
    border-radius: 5px;
    box-shadow: 0 3px 10px 0 rgba(0, 0, 0, 0.1);

}

.btn-delete {
    display: flex;
    align-items: center;
    justify-content: center;
    /* background: #c92c2c; */
    border: 0;
    padding: 3px;
    border-radius: 5px;
    color: #3f3e3e;
}

/* El spinner giratorio */
.spinner {
    border: 3px solid #f3f3f3;
    /* color de fondo */
    border-top: 3px solid #2563eb;
    /* color del borde superior */
    border-radius: 50%;
    width: 25px;
    height: 25px;
    animation: spin 1s linear infinite;
}

/* Animación de giro */
@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}



/* Contenedor de ajuste */
.ajuste-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

/* Texto del ajuste */
.ajuste-text p.nota {
    font-size: 12px;
    color: #555;
    margin: 4px 0 0 0;
}

/* Switch estilo moderno */
.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
}

.switch input {
    opacity: 0;
    width: 50px;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.4s;
    border-radius: 28px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.4s;
    border-radius: 50%;
}

input:checked+.slider {
    background-color: #2563eb;
}

input:checked+.slider:before {
    transform: translateX(22px);
}

.w-100 {
    width: 100%;
}

/* Botón */
.btn-primary {
    background-color: #2563eb;
    color: white;
    border: none;
    padding: 10px 14px;
    border-radius: 8px;
    cursor: pointer;
}

#detalleEvento {
    margin-top: 20px;
}

.form-control {
    display: flex;
    width: 100%;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
    padding: 5px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.2);
}

.modal-footer {
    margin-top: 25px;
    padding: 5px;
}

.btn {
    background-color: #ddd;
    color: rgb(36, 35, 35);
    border: 0;
    border-radius: 15px;
    padding: 12px;
    justify-content: center;
}

.fadeInOverlay {
    animation: fadeInOverlay 0.2s linear forwards;
}

@keyframes fadeInOverlay {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.fadeInDialog {
    animation: entrada 0.2s linear forwards;
}

@keyframes entrada {
    0% {
        opacity: 0;
        transform: scale(0);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes dropdownSlideOut {
    0% {
      opacity: 1;
      transform: scale(1) translateY(0);
    }
  
    100% {
      opacity: 0;
      transform: scale(0.85) translateY(-8px);
    }
  }
  
  
  .closing {
    animation: dropdownSlideOut 0.2s cubic-bezier(0.4, 0, 0.2, 1) forwards !important;
  }

.modal-title {
    font-size: x-large;
}

.menu-content {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 100vw;
    background-color: #8b8b8b2c;
    z-index: 999;
}

.menu-content .menu {
    padding: 10px 0;
    border-radius: 10px;
    background-color: white;
    box-shadow: 0 3px 10px 0 rgba(0, 0, 0, 0.2);
    height: max-content;
    width: max-content;
    margin-top: 3.5rem;
    margin-left: 1rem;
    display: flex;
    flex-direction: column;
    animation: mostrar .1s linear;
}

.pointer {
    cursor: pointer;
}

.menu a {
    padding: 5px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.menu a:hover {
    background-color: #dbeafe80;
}

@keyframes mostrar {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }

}

.menu-content .menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 15px;
    margin-bottom: 3px;
}

#formDinamicoEditar,
#formDinamicoNuevosDatos {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
}

.hidden {
    display: none !important;
}

/* Animaciones de entrada/salida para modales */
@keyframes mFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes mBoxIn {
    from {
        opacity: 0;
        transform: translateY(18px) scale(.97);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes mFadeOut {
    to {
        opacity: 0;
    }
}

@keyframes mBoxOut {
    to {
        opacity: 0;
        transform: translateY(12px) scale(.97);
    }
}

.m-in {
    animation: mFadeIn .22s ease-out;
}

.m-in-box {
    animation: mBoxIn .26s cubic-bezier(.21, 1.02, .73, 1);
}

.m-out {
    animation: mFadeOut .18s ease-in forwards;
}

.m-out-box {
    animation: mBoxOut .18s ease-in forwards;
}