@import url('/js/leafletjs/leaflet.css');
main{
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}
main #map {
    width: 100%;
    aspect-ratio: 3 / 2;
}

main .text {
    padding: 0 min(6vw, 100px);
    width: 100%;
}

main h1 {
    padding: 0 min(6vw, 100px);
    font-size: min(50px, 8vw);
    text-align: center;
}

main svg {
    height: 35px;
    aspect-ratio: 1;
}

main .map-section {
    display: flex;
    align-items: stretch;
    justify-content: center;
    gap: 10px;
    flex-direction: column;
    width: 100%;
}

main .control-panel {
    display: flex;
    flex-direction: column;
    align-items: start;
    justify-content: start;
    width: 100%;
    min-width: 270px;
    background-color: white;
    border-radius: 20px;
    flex-shrink: 0;
    box-shadow: 4px 4px 17px 0px #000A;
}

main .detail-title,
main .checkered-decor {
    display: none;
}

main .detail-title {
    text-align: left;
    font-size: min(4vw, 60px);
    font-weight: 400;
    margin-top: 40px;
    margin-bottom: 20px;
    padding: 0 min(6vw, 100px);
}

main .checkered-decor {
    background-image: url('/img/decor/checker.png');
    width: 55vw;
    height: 40vw;
    position: absolute;
    bottom: 0;
    left: 0;
    transform: translateX(-30%) translateY(-20%);
    z-index: -1;
}

main a.disabled {
    pointer-events: none;
    filter: grayscale(0.7);
}

#works .control-panel .mid .date,
#works .control-panel .mid .d {
    margin-left: 20px;
    margin-right: 20px;
}

main .control-panel .mid {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: start;
    justify-content: space-evenly;
    flex-direction: column;
    padding-bottom: 5%;
    flex-grow: 1;
}

main .control-panel .mid .date,
main .control-panel .mid .d {
    margin-left: 20px;
    margin-right: 20px;
}

@media only screen and (min-width: 720px) {
    main {
        max-width: 1700px;

    }

    main h2 {
        justify-content: start;
        gap: 40px;
    }

    main .map-section {
        display: flex;
        align-items: stretch;
        justify-content: center;
        padding: 0 min(6vw, 100px);
        flex-direction: row;
        gap: 10px;
    }

    main #map {
        flex-grow: 1;
        width: unset;
        border-radius: 20px;
        box-shadow: 2px 4px 2px 0px #0004;
        aspect-ratio: unset;
    }

    main .control-panel {
        display: flex;
        flex-direction: column;
        align-items: start;
        justify-content: start;
        width: min(400px, 40%);
        min-width: 270px;
        background-color: white;
        border-radius: 20px;
        flex-shrink: 0;
        box-shadow: 4px 4px 17px 0px #000A;
        min-height: 610px;
    }

    main .control-panel #wsel {
        margin: 0 auto;
    }

    main .detail-title,
    main .checkered-decor {
        display: block;
    }

    main p.sm-title {
        font-size: max(1.8vw, 17px);
    }
}

main .date {
    display: flex;
    align-items: center;
    justify-content: start;
    gap: 5px;
    flex-wrap: wrap;
    padding: 0 15px;
}

main .dsection {
    background: white;
    border-radius: 0;
    box-shadow: 0 4px 4px 0 #0004;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

main .dpair {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin: 5px 8px;
}

main .dpair p:nth-child(2) {
    font-weight: 600;
}

main .dpair p {
    margin: 0;
    font-size: 17px;
}

main p.d {
    margin-bottom: 2px;
    font-weight: 600;
    font-size: 17px;
    padding: 0 15px;
}

main img {
    width: 80%;
    height: auto;
    margin: 20px auto;
}

main .sm-title {
    font-weight: 600;
    font-size: 19px;
    text-align: center;
    width: 100%;
    margin-top: 20px;
    margin-bottom: 15px;
}

main select {
    width: 80%;
    margin: auto;
    border: 1px solid #000;
    border-radius: 5px;
    height: 35px;
    font-size: 20px;
}

main select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-color: white;
    border: 1px solid #ccc;
    border-right: none;
    padding: 8px 36px 8px 10px;
    /* Ensure space for custom arrow */
    font-size: 16px;
    cursor: pointer;
    background-image: url('/img/home/dropdown-arrow.png');
    /* Custom arrow */
    background-repeat: no-repeat;
    background-position: right;
    background-size: 36px;
}

/* Hide default arrow in Edge */
main select::-ms-expand {
    display: none;
}

main .button {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: auto;
    margin-top: 30px;
    text-decoration: none;
}

.th2 {
    display: flex;
    width: 100%;
    flex-wrap: wrap;
    justify-content: center;
    align-items: start;
    margin-top: 90px;
    gap: 20px;
}

.th2 input {
    max-width: 330px;
    width: min(100%, 260px);
    padding-left: 35px;
    position: relative;
}
.th2 .search{
    max-width: 280px;
    width: min(100%, 260px);
    display: flex;
    align-items: center;
}
.th2 .icon {
    position: absolute;
    left: 5px;
    top: 50%;
    filter: brightness(0);
    width: 28px;
    height: 28px;
    margin: 0;
    transform: translateY(-50%);
    cursor: pointer;
}
.th2 input:active ~ .icon,
.th2 input:focus ~ .icon,
.th2 input:not(:placeholder-shown) ~ .icon
{
    filter: brightness(0.5);
}

main .e-card{
    width: 100%;
    height: 350px;
    display: flex;
    align-items: start;
    justify-content: start;
    flex-direction: column;
    background-color: white;
    box-shadow: 0 6px 14px 0 rgba(0, 0, 0, 0.37);
    border-radius: 8px;
    max-width: 330px;
}
main .e-img{
    background-color: #277D31;
    background-image: url('/img/admin/news-placeholder.jpg');
    height: calc(350px - 130px);
    width: 100%;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    border-top-right-radius: 8px;
    border-top-left-radius: 8px;
    margin: 0;
    border-bottom: 2px solid #277D31;
    object-fit: cover;
    overflow-clip-margin: unset;
    overflow: hidden;

}
main .e-cont{
    height: 130px;
    width: 100%;
    padding: 10px;
    display: flex;
    align-items: start;
    justify-content: start;
    flex-direction: column;
}
.cards{
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    flex-direction: column;
    gap: 20px;
}
main .e-title{
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    width: 100%;
    text-overflow: ellipsis;
    overflow-x: hidden;
    text-align: left;
    overflow-y: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Limit to 3 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    max-height: 5em; /* Adjust based on your line-height */
    line-height: 1.5em; /* Set a fixed line-height */
    word-wrap: break-word;
}
main .e-desc{
    font-size: 15px;
    text-overflow: ellipsis;
    width: 100%;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Limit to 3 lines */
    line-clamp: 2; /* Limit to 3 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.5em; /* Set a fixed line-height */
    word-wrap: break-word;
    margin: 0;
}
main .e-card button{
    margin-top: auto;
    margin-bottom: 10px;
    margin-left: 5px;
    text-transform: uppercase;
    color: white;
    font-weight: 400;
    font-size: 20px;
    background-color: #277D31;
    border-radius: 6px;
    padding: 4px 11px;
    border: none;
    cursor: pointer;
    margin: auto;
    margin-bottom: 6px;
}
main .e-card button a{
    text-decoration: none;
}
main .e-card.big{
    width: 490px;
}
main .decor{
    width: 100vw;
    aspect-ratio: 1;
    position: absolute;
    left: 0%;
    bottom: 0;
    transform: translateX(-50%) translateY(20%);
    background-color: #294936;
    border-radius: 50%;
    max-width: 500px;
}
.cards{
    padding: 0 min(6vw, 100px);
    padding-bottom: 50px;
}
.e-card a{
    color: white;
    margin-top: 0;
}
@media only screen and (min-width: 720px){
    main .cards{
        justify-content: start;
    }
    .cards{
        display: flex;
        flex-direction: row;
        justify-content: center;
        align-items: start;
        gap: 20px;
        scrollbar-color: #1f6427 transparent;
        /* padding: 0 10px 20px 10px; */
        margin: 0;
        flex-wrap: wrap;
    }
    .th2{
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 0 min(6vw, 100px);
    }
}
main .e-card button {
    margin-top: auto;
    margin-bottom: 10px;
    margin-left: 5px;
    text-transform: uppercase;
    color: white;
    font-weight: 400;
    font-size: 20px;
    background-color: #277D31;
    border-radius: 6px;
    padding: 4px 11px;
    border: none;
    cursor: pointer;
    margin: auto;
    margin-bottom: 0;
}

.decor{
    top: unset;
    bottom: unset;
    left: unset;
    right: unset
}
.decor:nth-child(1){
    top: 0;
    left: 0;
    width: 50vw;
    height: 50vw;
    max-height: 550px;
    max-width: 550px;
    transform: translateX(-50%) translateY(-20%);
}

.decor:nth-child(2){
    bottom: 0;
    left: 100%;
    width: 40vw;
    max-width: 500px;
    aspect-ratio: 1;
    transform: translateX(-64%) translateY(55%);
    background-color: #277D31;
}

.save{
    margin-bottom: 10px;
    padding: 5px 10px;
}
.cards a.save{
    margin-bottom: 0;
    margin-top: auto;
}


.leaflet-control-container {
    height: 10px;
    position: absolute;
    bottom: 0;
    width: 100ch;
    z-index: 1000;
    right: 0;
}  

.leaflet-control svg{
    height: 10px;
}


.cardnav {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 50px;
}
.cardnav input{
    width: 60px;
    min-width: 20px;
}

.cardnav button{
    background-color: #277D31 !important;
    color: white !important;
    font-weight: bolder;
    border: none;
    width: 25px;
    cursor: pointer;
}