*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
}


body{
    /* To Light */
    --background-color: #fafafa;
    --background-element-color: #fafafa;
    --text-color: #333;

    font-family: Nunito, sans-serif;
    scroll-behavior: smooth;
    background: var(--background-color);
    color: var(--text-color);
}

body.dark-mode{
    /* To Dark */
    --background-color: #202c37;
    --background-element-color: #2b3945;
    --text-color: #ffffff;
    background-color: var(--background-color);
    color: var(--text-color);
}

.container{
    max-width: 1400px;
    width: 100%;
    margin-inline: auto;
}

header{
    width: 100%;
    padding: 1.5rem  2rem;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.131);
    background: var(--background-element-color);
}

header .container{
    display: flex;
    align-items: center;
    justify-content: space-between;
}

header .dark-mode{
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    
}

header .light-mode{
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    display: none;
}

header .mode i{
    font-size: 1.2rem;
    font-weight: 500;
    transform: rotate(-30deg);
}


/* ===============Main==================== */

main{
    margin-top: 2rem;
    width: 100%;
    padding: 1.5rem  2rem;
}

.country-cards {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
}

main .country-cards a .image{width: 100%; max-height: 200px;overflow: hidden;}
main .country-cards a .image img{width: 100%;}

main .country-cards a{
    display: inline-block;
    width: 320px;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    text-decoration: none;
    transition: all 0.3s ease-in-out;
    background: var(--background-element-color);
    color: var(--text-color);
}

main .country-cards a:hover{
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}
main .country-cards a:hover .image img{
    transform: scale(1.03);
}

main .country-cards a .content{
    width: 100%;
    padding: 1.5rem 2rem 3rem 2rem;
}

main .country-cards a .content h2{
    color: inherit;    
    line-height: 40px;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}
main .country-cards a .content p{
    color: inherit;
    font-size: 1.2rem;
    font-weight: 400;
    padding-block: 0.2rem;
}

.search-filter{
    margin-bottom: 3.5rem;
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    align-items: center;
    justify-content: space-between;
}
.search-filter .search-box{
    width: 450px;
    background-color: var(--background-element-color);
    color: var(--text-color);
    display: flex;
    align-items: center;
    gap: 1rem;
    border-radius: 4px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}


.search-filter .filter-box #filter{
    width: 300px;
    padding: 1rem;
    border-radius: 4px;
    border: 0;
    outline: none;
    font-size: 1.1rem;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    background-color: var(--background-element-color);
    color: var(--text-color);
}

    

.search-filter .search-box i{
    padding: 1.1rem 1rem;
    cursor: pointer;
}
.search-filter .search-box input{
    width: 100%;
    display: block;
    background: transparent;
    color: inherit;
    padding: 1.1rem 1rem;
    padding-left: 0;
    outline: none;
    border: 0;
    font-size: 1.1rem;
}

header .logo a{
    font-size: 1.3rem !important;
    color: var(--text-color);
}






@media (max-width: 430px) {
    header {
        padding: 1rem 1rem;
    }
    
    header .logo a{
        font-size: 1.3rem !important;
    }

    header .mode{
        font-size: 0.8rem !important;
    }

    main{
        margin-top: 2rem;
        padding: 1rem  1rem;
    }

    main .country-cards{
        width: 100%;
    }

    main .country-cards a{
        width: 100%;
        overflow: hidden;
        /* border-radius: 8px;
        box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
        text-decoration: none;
        transition: all 0.3s ease-in-out; */
    }
}


@media (max-width: 768px) {
    .container {
        max-width: 100%
    }
    
    header {
        padding: 1rem 1.5rem;
    }

    header .logo a{
        font-size: 1.5rem;
    }

    header .mode{
        font-size: 1rem;
    }

    main{
        margin-top: 2.5rem;
        padding: 1rem  1.5rem;
    }

    .country-cards {
        display: flex;
        flex-wrap: wrap;
        gap: 40px;
        align-items: center;
        justify-content: space-between;
    }

}



