:root {
    --main-color: #f1ba22;
}

body {
    background-image: url("/static/maicesfondo.jpeg");
    background-color: #808080bb;
    background-blend-mode: luminosity;
    background-size: cover;
    background-attachment: fixed;
}

h4 {
    color: var(--main-color);
}

input, textarea, select {
    all: unset;
    border-radius: 1px !important;
}

.contenido{
    padding: 66px;
    margin-left: 300px;
    transition: 0.7s cubic-bezier(.62,0,.18,1);
    min-height: 100vh;
}

.titulo {
    color: var(--main-color);
    background-color: #00000090;
    padding: 20px;
    margin: 0;
}

/* Fondo borroso generico */

.circuloscontenido, .distribuciondivs, .navclass, .tablacontenido, .formcult, .tablacult, .menu-visible{
    backdrop-filter: blur(4px);
}

/* Login */

.cajaform{
    display: flex;
    justify-content: end;
    align-items: center;
    height:100px 0px;    
}

.fondoclaro{
    background: #ffffff90;
}

.fondoform {
    background-color: #272727;
    width: 25rem;
}

.tituloform{
    color: var(--main-color);
}

.formcelda{
    margin: 30px 0px!important;
    border-radius: 0%;
}

.formcelda div{
    border-radius: 0%;
    border: 0;
    padding: 10px 12px;
}

.formcelda input{
    background-color: #00000090;
    border: 0;
    border-radius: 0%;
    color: #dadada;
}

.formcelda input:hover{
    background-color: #ffffff16;
    border: 0;
    border-radius: 0%;
}

.formcelda input:focus{
    background-color: #ffffff20;
    border-width: 0;
    color: #dadada;
    box-shadow: none;
}

.formcelda input::placeholder{
    color: gray;
}

.formlogo{
    background-color: #00000090;
}

.botonform{
    color: var(--main-color);
    border-radius: 0;
    background-color: #fff;    
}

.botonform:hover{
    color: var(--main-color);
    border-radius: 0;
    border-color: var(--main-color);
    background-color: #00000090;
}

.errormsg {
    color: #dadada!important;
}

/* Sidebar */

.navclass{
    display: block!important;
    position: fixed!important;
    background-color: #00000090;
    top: 0;
    float: left!important;
    padding: 0px 0px;
    height: 100vh;
    position: relative;
    width: 300px;
    border-color: #00000090;
    border-style: solid;
    border-width: 0px 14px 0px 0px;
    transform: translateX(0);
    transition: 0.7s cubic-bezier(.62,0,.18,1);
}

.navclass.menu-no-visible {
    transform: translateX(-300px);
}

.titulonav{
    color: var(--main-color);
    padding: 8vh 0px 6vh 0px;
    margin: 0;
    display: flex;
    justify-content: center;
}

.titulonav2{
    color: white;
    padding: 2vh 0px;
    margin: 0;
    display: flex;
    justify-content: center;
    border-color: #ffffff90;
    border-style: solid;
    border-width: 0px 0px 1px 0px;
}

.lateral {
    color: #dadada;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.lateral ul{
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
}

.lateral ul li{
    display: flex;
    border-top-width: 1px;
    border-color: #dadada;
}

.lateral ul li form {
    width: 100%;
    display: flex;
    justify-content: center;  
}

.lateral ul li a{
    color: #dadada;
    text-decoration: none;
    padding: 12px 50px;
    width: 100%;
    font-size: 18px;
    border-style: solid;
    border-width: 0px 0px 1px 0px;
    background: linear-gradient(90deg, #ffffff16 10%, #00000090 50%, #00000090 50%, #00000090 100%);
    background-size: 200% 100%;
    background-position: -285px;
    transition: 0.3s ease-in-out;
}

.lateral ul li a:hover{
    background-position: 0px;
    color: var(--main-color);
}

/* Estilos para la tabla de viabilidad */
.viabilidad-popup {
    background: rgb(0, 0, 0);
    padding: 20px;
    margin-top: 20px;
    border-radius: 8px;
    border: 2px solid var(--main-color);
    box-shadow: inset 0 0px 15px #f1ba22ab,
                0 0px 13px rgba(0, 0, 0, 0.8);
    position: relative;
    z-index: 2001;
}

.viabilidad-popup h5 {
    color: var(--main-color);
    margin-bottom: 20px;
    font-weight: bold;
    font-size: 1.5rem;
    text-align: center;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--main-color);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.viabilidad-general {
    font-size: 18px;
    margin-bottom: 20px;
    padding: 15px;
    color: var(--main-color);
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

#porcentaje-viabilidad {
    font-weight: bold;
    color: var(--main-color);
    font-size: 24px;
    margin: 0 8px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.table-success td {
    background-color: rgba(198, 239, 206, 0.8) !important;
    color: #0c5460;
}

.table-warning td {
    background-color: rgba(255, 236, 181, 0.8) !important;
    color: #856404;
}

.table-danger td {
    background-color: rgba(255, 204, 204, 0.8) !important;
    color: #721c24;
}

.viabilidad-popup .table-neutral td {
    background-color: rgba(52, 58, 64, 0.8) !important;
    color: #ffffff !important;
}

.viabilidad-popup table {
    border-collapse: separate;
    border-spacing: 0;
    width: 100%;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 0;
}

.viabilidad-popup table thead th {
    background-color: rgba(0, 0, 0, 0.7);
    color: var(--main-color);
    padding: 12px 15px;
    font-weight: 600;
    text-align: center;
    border: none;
}

.viabilidad-popup table tbody td {
    padding: 10px 15px;
    border: none;
    text-align: center;
    vertical-align: middle;
    color: #ffffff;
}

.viabilidad-popup table tbody tr:last-child td {
    border-bottom: none;
}

.lateral ul li b{
    text-decoration: none;
    padding: 16px 50px;
    width: 100%;
    border-style: solid;
    border-width: 0px 0px 1px 0px;
}

.lateral ul li a, .lateral ul li b {
    border-color: #ffffff90;
}

.usernamenav {
    color: var(--main-color);
    background: none!important;
    position: absolute;
    left: 50px;
    bottom: 50px;
}

.usernamenav a{
    background: none!important;
}

.usernamenav a div{
    padding-right: 5px;
}

.botonnav{
    display: flex;
    justify-content: center;
    /* margin: 0% 20%; */
    color: #dadada;
    border-radius: 0;
    width: 150px!important;
    position: absolute;
    bottom: 110px;
}

.botonnav:hover{
    color: var(--main-color);
    border-radius: 0;
    border-color: var(--main-color);
    background-color: #00000090;
}

.menu-visible{
    margin: -45px 0 0 300px;
    color: white;
    padding: 0px 0px;
    display: block!important;
    position: absolute!important;
    background-color: #000000d0;
    float: left!important;
    top: 50vh;
    height: 90px;
    position: relative;
    width: 30px;
    border: 0;
    transition: all 0.3s ease;
}

.menu-no-visible{
    transform: translateX(-300px);
}

.menu-minimizado .contenido {
    margin-left: 0;
}

/* Contenido */
.tablacontenido {
    /* border-style: solid;
    border-width: 10px;
    border-color: #dadada; */
    /* width: 50%; */
    background-color: #00000090;
    margin: 50px 0px;
}

.tablacontenido p{
    color: #2e2e2e;
    font-size: 26px; 
}

.distribuciondivs {
    display: flex;
    flex-direction: row;
    background-color: #000000d0;
}

/* grafica */

.chart{
    width: auto;
    min-height: 400px;
    background-color: #00000090;
    padding: 0px 20px 20px 20px;
    position: relative;
    z-index: 1000;
}

/* .chart div{
    width: inherit!important;
}

.chart div canvas{
    width: inherit!important;
} */

/* mapa */

.leaflet-container .leaflet-control-attribution {
    display: none!important;
}

.visibilidadmapa{
    width: 50%;
}

.fondomapa {
    padding: 25px 25px 25px 0px;
}

.fondomapa div div div{
    position:relative!important;
    width:100%!important;
    height:100%!important;
    padding-bottom:525px!important;
}

/* Datatable */

.fondodatatable{
    width: 100%;
    /* border-style: solid;
    border-width: 10px;
    border-color: #00000090; */
}

.fondodatatable label{
    width: 100%;
    color: #dadada;
}

.fondodatatable div{
    color: #dadada;
}

.iniciotabla{
    padding: 50px 0px;
}

.table-responsive{
    margin: 25px;
    overflow-x: unset;
}

.centrao{
    text-align: center !important;
    vertical-align: middle !important;
    color: #dadada;
}

.table{
    border: 1px  solid #ffffff60!important;
    background-color: #00000090;
    padding: 0%;
    width: 100%;
    margin: 15px 0px;
    overflow-x: scroll;
}

.pagination {
    --bs-pagination-border-width: none;
    --bs-pagination-border-color: transparent;
    border: none;
  }

.dt-paging.paging_full_numbers ul{
    border: 1px  solid #808080!important;
}

.dt-paging.paging_full_numbers li{
    border: 0!important;
    color: #dadada!important;
}

.dt-paging.paging_full_numbers li a{
    color: #dadada!important;
}

.dt-paging-button.page-item.active a{
    color: black!important;
}

#dt-search-0, #dt-search-1, #dt-search-2{
    color: var(--main-color);
    border-radius: 0;
    border-color: var(--main-color);
    background-color: #00000090;
}

#dt-length-0 {
    background-color: #000000 !important; /* Fondo negro translúcido */
}

.botonmapa {
    color: var(--main-color);
    border-radius: 1;
    border-color: var(--main-color);
    background-color: #00000090;
}

.botonmapa:hover{
    color: white;
    border-radius: 1;
    border-color: #dadada;
    background-color: #00000090;
}

.botonmapa:active{
    color: black!important;
    border-radius: 1;
    border-color: #00000090!important;
    background-color: #dadada!important;
    
}

.pagination li a{
    border-radius: 0%!important;
    border-color: #dadada;
    border-width: 1px 0px 1px 0px;
    background-color: #00000090!important;
}

.pagination li.active a{
    border-radius: 0%!important;
    border-color: #dadada;
    border-width: 1px 0px 1px 0px;
    background-color: var(--main-color)!important;
}

.selected {
    background-color: #ebe1c733;
    color: white!important;
}

.dt-search {
    display: flex!important;
    align-items: center;
}
.dt-search label{
    width: 100px;
}

.dt-length label{
    display: flex!important;
    align-items: center;
}

.form-select.form-select-sm{
    margin: 0px 10px;
    color: var(--main-color);
    border-radius: 0;
    border-color: var(--main-color);
    background-color: #00000090;
}

.botonesest{
    justify-content: space-evenly;
    margin: 0;
}

.botonest{
    margin-bottom: 25px;
    color: var(--main-color);
    border-radius: 0;
    border-color: var(--main-color);
    background-color: #00000090;
    width: 200px!important;
}

.botonest:hover{
    color: #dadada;
    border-radius: 0;
    border-color: var(--main-color);
    background-color: #00000090;
}

.botonescult {
    display: flex;
    justify-content: space-evenly;
}

/* Popups */
.rowpopup{
    display: flex;
    justify-content: center;
}

.popup {
    position: fixed;
    min-width: 40%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgb(0, 0, 0);
    border: 1px solid var(--main-color);
    border-radius: 8px;
    box-shadow: inset 0 0px 15px #f1ba22ab,
                0 0px 13px rgba(0, 0, 0, 0.8);
    padding: 35px;
    z-index: 2000;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1999;
}

.mostrando {
    display: none; /* Oculto por defecto */
}

.ocultando {
    display: none; /* Oculto por defecto */
}

.ajustecontenido{
    padding: 15px 0px;
}

.displaycajas{
    display: flex;
    padding: 15px 0px;
}

.botonpopup{
    display: flex;
    margin: 15px 0px;
    justify-content: center;
    background-color: var(--main-color);
    /* margin: 0% 20%; */
    color: black;
    border-color: var(--main-color);
    border-radius: 5;
    width: 150px!important;
}

.botonpopup:hover{
    color: black;
    background-color: #f3cb5b;
    border-radius: 5;
    border-color: var(--main-color);
}

.botoncerrarpopup{
    position: absolute;
    top: -50px;
    right: -50px;
    color: var(--main-color);
    border: none;
    background-color: rgba(0, 0, 0, 0);
    font-size: 20px;
    /* border-color: var(--main-color);
    border-width: 1px;
    border-radius: 5;
    background-color: black; */
    /* width: 100px; */
}

.botoncerrarpopup:hover{
    color: white;
    background-color: rgba(0, 0, 0, 0);
    /* border-color: var(--main-color);
    border-width: 1px;
    border-radius: 5;
    background-color: black;
    width: 100px; */
}

/* .popup-header {
    position: relative;
    text-align: right;
}

.close-button {
    position: absolute;
    top: -75px;
    right: -75px;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    font-size: 30px;
    font-weight: bold;
    color: var(--main-color);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    background-color: #00000000;
} */

.descripcion-popup{
    margin-top: 10px;
}


#select-parcela, #select-cultivo{
    background-color: #000000;
    color: white;
    border-color: var(--main-color);
}

#select-parcela:focus, #select-cultivo:focus{
    border-color: var(--main-color);
}

#select-parcela option, #select-cultivo option{
    color: var(--main-color);
}

/*Oculta Texto informativo de mapa*/
.leaflet-bottom{
    display: none !important;
}

/* Parametros mas importantes, circulos index */

.circuloscontenido {
    background-color: #00000090;
    margin: 0px;
    /* padding: 25px; */
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.titulocir{
    color: var(--main-color);
    background-color: #00000090;
    padding: 20px;
    margin: 0;
    width: 100%;
    font-weight: 500;
}

.divcircle{
    position: relative;
    background-color: #00000090;
    padding: 25px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 75vh;
}

/* Contenedor circular */
#chartcircular {
    width: 600px;
    height: 600px;
    border-radius: 50%;
    overflow: hidden;
    background-color: #69696996;
    background: radial-gradient(at top left, #979797c5 20%, #272727bb);
    border: 2px solid #808080;
}
  
svg {
    width: 100%;
    height: 100%;
}
  
  /* Estilo moderno para las esferas */
.bubble {
    stroke: none;
    cursor: pointer;
    filter: url(#drop-shadow);
    transition: transform 0.3s ease;
}
  
.bubble:hover {
    transform: scale(1.01);
}
  
  
text.top-label {
    font-family: 'Comic Neue', Helvetica, Arial, sans-serif;
    font-weight: bold;
    font-size: 1.2rem;
    pointer-events: none;
    text-anchor: middle;
    fill: #fff;
}
  
.tooltip {
    position: absolute!important;
    top: 2%!important;
    left: 80%!important;
    width: 150px;
    height: 150px;
    text-align: center;
    padding: 8px;
    font-size: 14px;
    background-color: #69696996;
    background: radial-gradient(at top left, #979797c5 20%, #272727bb);
    color: #fff;
    border: 2px solid #dadada;
    border-radius: 50%;
    pointer-events: none;
    display: flex;
    align-items: center;
    flex-direction: column;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
    /* left: 90%!important;
    top: 50%!important; */
}

/* formulario cultivo */

.pagcultivos {
    display: flex;
}

.tablacult {
    margin: 0 0 0 25px;
    max-width: 33%;
    width: 100%;
    padding: 25px;
    display: flex;
    flex-direction: column;
    background-color: #000000d0;
}

.tablacult ul {
    list-style: none;
    padding: 60px 0%;
}

.tablacult ul li .cultivo-detalles {
    opacity: 0;
    visibility: hidden;
    transform: translateY(-16);
    transition: opacity 0.3s ease-out, transform 0.3s ease-out, visibility 0s 0.3s;
    max-height: 0;
    overflow: hidden;
}

.tablacult ul li .cultivo-detalles.mostrar {
    padding: 10px;
    border: 1px solid #00000090;
    margin: 5px 0px;
    color: #dadada;
    background-color: #80808030;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.3s ease-out, transform 0.3s ease-out, max-height 0.3s ease-out, visibility 0s;
    max-height: auto;
}

.cultivo-nombre {
    cursor: pointer;
    color: #dadada;
    font-weight: bold;
    padding: 5px;
    margin: 4px 0;
    border-style: solid;
    border-color:#808080bb;
    border-width: 0px 0px 1px 0px;
    background: none;
    background-color: #00000090;
    text-align: left;
    width: 100%;
}

.formcult {
    max-width: 66%;
    background-color: #000000d0;
    padding: 25px;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* justify-content: center; */
    width: 100%;
}

.formcult h1, .tablacult h1 {
    width: 100%;
    padding: 0%!important;
    background: none!important;
}

.formcult p{
    color: #dadada;
}

.camposformcult {
    width: 75%;
    max-width: 800px;
}

.formcultdivs {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
    padding: 60px 0px;
}

.formcultdivs p {
    display: flex;
    justify-content: center;
}

.formcultdivs p label {
    flex: 1;
    min-width: 50%;
    text-align: right;
    padding-right: 15px;
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    font-size: 18px;
}

.formcultdivs p input,
.formcultdivs p textarea {
    background-color: #00000090;
    color: var(--main-color);
    padding: 6px;
    margin: 0px 10px;
    flex: 1;
    text-align: left;
    border: 2px solid #808080;
    border-radius: 1px!important;
    transition: border 0.2s ease-in-out;
}

.formcultdivs p input:focus,
.formcultdivs p textarea:focus,
.formcultdivs p select:focus {
    border: 2px groove #fff;
    box-shadow: 0px 0px 10px var(--main-color)!important;
    border-radius: 1px!important;
}

.formcultdivs p input[type="checkbox"] {
    width: 10px!important;
    height: 10px!important;
    max-width: 10px!important;
    max-height: 10px!important;
    cursor: pointer;
    box-shadow: inset 0px 0px 0px 11px black;
    background-color: var(--main-color);
    transition: box-shadow 0.15s ease;
    /* appearance: auto!important; */
    /* margin: 0 46.74% 0 10px; */
}

.formcultdivs p input[type="checkbox"]:focus {
    box-shadow: 0px 0px 10px var(--main-color), inset 0px 0px 0px 11px black!important;
    transition: box-shadow 0.15s ease;
}

.formcultdivs p input[type="checkbox"]:checked {
    background-color: var(--main-color);
    box-shadow: inset 0px 0px 0px 3px black;
    z-index: 30;
}

.formcultdivs p input[type="checkbox"]:focus:checked {
    box-shadow: 0px 0px 10px var(--main-color), inset 0px 0px 0px 3px black!important;    
}

.formcultdivs p select option {
    background-color: #000000; /* Color de fondo */
    color: #dadada; /* Color del texto */
    padding: 5px;
}

.formcultdivs p select option:checked {
    background-color: #272727;
    color: white;
}

.botcult {
    margin: 10px 10px;
}

.formcultdivs p select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 100%;
    background-color: #00000090;
    color: var(--main-color);
    padding: 6px 30px 6px 6px;   /* ojo al padding-right para dejar hueco */
    margin: 0px 10px;
    flex: 1;
    border: 2px solid #808080;
    border-radius: 1px !important;
    transition: border 0.2s ease-in-out;
    box-sizing: border-box;
  
    /* 2) Aquí metemos el SVG de la flechita — sin tocar HTML ni JS */
    background-image: url("data:image/svg+xml;charset=UTF-8, <svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'> <path fill='%23f1ba22' d='M0 0l5 6 5-6z'/> </svg>");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 10px 10px;
  }



/* botones editar y eliminar cultivo */
.botones-acciones{
    display: flex;
    justify-content: end;
}

.editar-btn, .eliminar-btn {
    margin-left: 8px;
    min-height: 20px;
    min-width: 20px;
    color: var(--main-color);
    border-style: solid;
    border-width: 1px;
    border-radius: 3px;
    border-color: var(--main-color);
    background-color: #00000090;
}

.editar-btn:hover, .eliminar-btn:hover{
    color: white;
    border-radius: 1;
    border-color: #dadada;
    background-color: #00000090;
}

.editar-btn:active, .eliminar-btn:active{
    color: black!important;
    border-radius: 1;
    border-color: #00000090!important;
    background-color: #dadada!important;
    
}

/* botones confirmar eliminar cultivo */

.botones-confirmacion-eliminar {
    margin-top: 8px;
    display: flex;
    justify-content: space-evenly;
    gap: 10px;
}

.cancelar-supr {
    background-color: #dadada;
    color: black;
    padding: 5px 10px;
    border: 1px solid #dadada;
    cursor: pointer;
    border-radius: 3px;
}

.supr-confirm {
    background-color: #c42614;
    color: white;
    padding: 5px 10px;
    border: 1px solid #c42614;
    cursor: pointer;
    border-radius: 3px;
}

.cancelar-supr:hover {
    border: 1px solid;
    border-color: var(--main-color);
    color: var(--main-color);
    background-color: #00000090;
}

.supr-confirm:hover {
    animation: blink 1.2s infinite;
}

@keyframes blink {
    0%, 100% {
        background-color: #c42614;
        border-color: #c42614;
    }
    60% {
        background-color: #911e11;
        border-color: #911e11;
    }
}