body {
    text-wrap: balance;
    font-family: 'Open Sans', Arial, sans-serif;
    margin: 0;
    padding: 0;
}

.h1 {
    font-size: 4rem;
    width: 50%;
    margin: 0;
    line-height: 3.8rem;
}

.h4 {
    font-size: 1.5rem;
    width: 50%;
    padding: 0;
    line-height: 2rem;
    margin-block-end: 10px;
    margin-block-start: 20px;
}

header {
    position: relative;
    width: 100vw;
    height: 40vh;
    overflow: hidden;
}

.header-content {
    position: relative;
    width: 100%;
    height: 100%;
}

.header-content img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.header-text {
    position: absolute;
    bottom: 1px;
    left: 10%;
    color: white;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.7);
    margin: 0;
    padding: 0;
}

main {
    padding: 20px;
}

.dates-share {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0 20%;
}

.dates {
    margin-bottom: 20px;
}

.share-icons {
    display: flex;
    gap: 10px;
}

.share-icons img {
    width: 24px;
    height: 24px;
    cursor: pointer;
}

.share-icons .copy-icon {
    filter: invert(33%) sepia(9%) saturate(145%) hue-rotate(186deg) brightness(97%) contrast(89%);
}

.share-icons button {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
}

.search-bar {
    margin-bottom: 20px;
}

.search-bar input {
    width: 60%;
    padding: 10px;
    font-size: 1.3rem;
    margin-left: 20%;
    margin-right: 20%;
    border: 2px solid #232323;
    border-radius: 6px;
}

.grid {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(4, 1fr);
    padding: 20px;
}

.card {
    border: 0px solid #ccc;
    padding: 10px;
    text-align: center;
}

.card img {
    width: 100%;
    height: auto;
    border-radius: 6px;
}

.card h4 {
    margin: 10px 0 5px;
    color: #575757;
}

.card h5 {
    margin: 5px 0 10px;
    font-size: 0.9rem;
    font-weight: 500;
    color: #575757;
}

.card button {
    padding: 10px;
    background-color: #ffffff;
    color: #232323;
    border: none;
    cursor: pointer;
    border-radius: 4px;
    border: 2px solid #232323;
}

.card button:hover {
    background-color: #232323;
    color: #ffffff;
}

.footer-promessas {
    margin-left: 30%;
    margin-right: 30%;
    color: #828181;
}

.creditos {
    text-align: center;
}

.tit-credito {
    font-size: 1rem;
    font-weight: 700;
    text-align: left;
    line-height: 1.5rem;
}

.txt-credito {
    font-size: 1.1rem;
    font-weight: 300;
    line-height: 1.5rem;
    padding-bottom: 10px;
}

.mandato-switch {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 20px 0;
}

.mandato-switch button {
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

.mandato-switch button:hover {
    background-color: #0056b3;
}

.mandato-switch button:focus {
    outline: none;
    box-shadow: 0 0 4px 2px rgba(0, 123, 255, 0.5);
}

@media (min-width: 768px) {
    .grid {
        grid-template-columns: repeat(6, 1fr);
    }
}

@media (max-width: 767px) {
    .grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .h1 {
        font-size: 2.5rem;
        width: 100%;
        margin: 0;
        line-height: 2.6rem;
    }

    .h4 {
        font-size: 1rem;
        width: 100%;
        padding: 0;
        line-height: 1.2rem;
        margin-block-end: 10px;
        margin-block-start: 10px;
    }

    header {
        position: relative;
        width: 100vw;
        height: 40vh;
        overflow: hidden;
    }

    .header-text {
        position: absolute;
        bottom: 1px;
        left: 5%;
        color: white;
        text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.7);
        margin: 0;
        padding: 0;
    }

    main {
        padding: 5px;
    }

    .dates-share {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin: 0 5%;
    }

    .dates {
        margin-bottom: 0px;
    }

    .share-icons {
        display: flex;
        gap: 10px;
        padding-bottom: 0px;
    }

    .search-bar {
        margin-bottom: 10px;
    }

    .search-bar input {
        width: 88%;
        padding: 10px;
        font-size: 1rem;
        margin-left: 3%;
        margin-right: 0%;
        border: 2px solid #232323;
        border-radius: 4px;
    }

    .footer-promessas {
        margin-left: 5%;
        color: #828181;
    }

    .creditos {
        text-align: left;
    }

    .tit-credito {
        font-size: 0.9rem;
        font-weight: 600;
        text-align: left;
        line-height: 1rem;
    }

    .txt-credito {
        font-size: 0.9rem;
        font-weight: 300;
        line-height: 1.5rem;
        padding-bottom: 10px;
    }
}

.lazyload,
.lazyloading {
    opacity: 0;
}

.lazyloaded {
    opacity: 1;
    transition: opacity 300ms;
}
