* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    color: white;
    text-decoration: none;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

:root {
    --blu-scurissimo: #121c31;
    --blu-scuro: #152137;
    --blu: #294582;
    --accento: #3c74f5;
    --oro: #ffcc00;
    --verde: #63c623;
    --rosso: #f21a3c;
}

body {
    background: var(--blu-scurissimo) url("../public/background/pattern.svg") repeat;
    z-index: 0; /* Modificato */
}

.main-container {
    display: flex;
    flex-direction: row;
    height: 100vh;
    overflow: hidden;
}
input{
    padding: 8px;
    border-radius: 5px;
    border: 1px solid #ddd;
    font-size: 14px;
    color: var(--blu-scurissimo);
    width: 40%;
    min-width: 150px;
}

/* Stile paginazione */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
    gap: 8px;
}

.page-btn {
    background-color: var(--blu-scuro, #1a2c56);
    color: white;
    border: 1px solid var(--accento, #3c74f5);
    border-radius: 4px;
    padding: 8px 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.page-btn:hover:not(:disabled) {
    background-color: var(--blu, #294582);
    transform: translateY(-2px);
}

.page-btn.active {
    background-color: var(--accento, #3c74f5);
    font-weight: bold;
}

.page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}


.main-menu {
    width: 20%;
    background-color: var(--blu);
    padding: 40px 20px;
    display: flex;
    align-items: flex-start;
    justify-content: stretch;
    flex-direction: column;
    z-index: 10000;
}

.main-menu .menu-list {
    list-style: none;
    width: 100%;
}

.menu-item {
    background-color: var(--blu-scurissimo);
    margin: 15px 0;
    padding: 15px 20px;
    border-radius: 30px;
    text-align: center;
    font-weight: bold;
    font-size: 1.1rem;
    transition: background 0.3s, transform 0.2s;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.menu-item:hover {
    background-color: var(--accento);
    transform: translateY(-2px);
}

.main-content {
    width: 80%;
    display: flex;
    flex-direction: column;
}

.main-header {
    height: 8%;
    background-color: var(--blu-scuro);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 10px 30px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.main-header h1 {
    font-size: 2rem;
}

.header-content p {
    font-size: 1rem;
    color: #ccc;
}

.main-body {
    height: 82%;
    position: relative; /* Aggiunto */
}

.header-content{
    align-self: center;
}

.main-body-content {
    width: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.division-list {
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 50px;
}

.division-item,
.division-main-item {
    background-color: var(--blu);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-weight: bold;
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    transition: transform 0.3s;
}

.division-item:hover,
.division-main-item:hover {
    transform: scale(1.05);
}

.division-item {
    width: 150px;
    height: 150px;
    font-size: 1.1rem;
}

.division-main-item {
    width: 250px;
    height: 250px;
    font-size: 1.3rem;
    background-color: var(--accento);
}

.main-footer {
    height: 10%;
    background-color: var(--blu-scuro);
    border-top: solid 5px var(--blu);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 10px 0;
    position: relative;
}

.footer-chevron-container {
    width: 90%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: absolute;
}

.footer-list {
    display: flex;
    justify-content: space-around;
    align-items: center;
    width: 90%;
    list-style: none;
    padding: 0;
    z-index: 100;
}

.division-ball {
    width: 70px;
    height: 70px;
    background-color: var(--blu);
    border-radius: 50%;
    box-shadow: inset 0 0 10px rgba(255,255,255,0.1);
    transition: background 0.3s;
}

.division-ball:hover {
    background-color: var(--accento);
}

.menu-header{
    width: 100%;
    text-align: center;
}

.chevron-container {
    position: absolute;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
}

.chevron-left,
.chevron-right {
    width: 40px;
    height: 40px;
    cursor: pointer;
    filter: brightness(0.8);
    transition: transform 0.3s, filter 0.3s;
    z-index: 2000;
}

.back-button{
    background: none;
    border: none;
    cursor: pointer;
    box-shadow: none;
}

.back-button img{
    width: 30px;
    height: 30px;
}

.chevron-left img:hover,
.chevron-right img:hover {
    transform: scale(1.2);
    filter: brightness(1);
}

.main-text-header{
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Stili per Swiper nella sezione principale */
.main-swiper {
    width: 74%;
    height: 100%;
    position: relative;
}

.main-swiper .swiper-slide {
    display: flex;
    justify-content: center;
    align-items: center;
}

.main-nav-prev, .main-nav-next {
    color: white !important;
    --swiper-navigation-size: 40px;
}

.main-nav-prev::after, .main-nav-next::after {
    content: none !important;
}

.main-nav-prev img, .main-nav-next img {
    width: 40px;
    height: 40px;
    filter: brightness(0.8);
    transition: transform 0.3s, filter 0.3s;
}

.main-nav-prev img:hover, .main-nav-next img:hover {
    transform: scale(1.2);
    filter: brightness(1);
}

.main-nav-prev {
    left: -25px;
}

.main-nav-next {
    right: -25px;
}

/* Stili per Swiper nel footer */
.swiper-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.swiper-slide {
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer-nav-prev, .footer-nav-next {
    color: white !important;
    --swiper-navigation-size: 30px;
}

.footer-nav-prev::after, .footer-nav-next::after {
    content: none !important;
}

.footer-nav-prev img, .footer-nav-next img {
    width: 40px;
    height: 40px;
    filter: brightness(0.8);
    transition: transform 0.3s, filter 0.3s;
}

.footer-nav-prev img:hover, .footer-nav-next img:hover {
    transform: scale(1.2);
    filter: brightness(1);
}

.footer-nav-prev {
    left: -45px;
}

.footer-nav-next {
    right: -45px;
}

.division-item > img{
    width: 80%;
    height: 80%;
    border-radius: 50%;
    object-fit: cover;
}

.division-main-item > img{
    width: 90%;
    height: 90%;
    border-radius: 50%;
    object-fit: cover;
}
.division-main-item > a{
    z-index: 10000;
    padding: 125px;
    position: absolute;
    border-radius: 50%;
}.division-item > a{
     z-index: 10000;
     padding: 75px;
     position: absolute;
     border-radius: 50%;
 }

.division-link{
    padding: 35px;
    position: absolute;
    border-radius: 50%;
}

/* Stili per la ricerca avanzata */
.search-container {
    background-color: var(--blu-scuro, #1a2c56);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    margin: 20px auto;
    width: 90%;
    max-width: 800px;
}

.search-wrapper {
    position: relative;
    max-width: 500px;
    margin: 0 auto;
}

.search-input {
    width: 100%;
    padding: 12px 45px 12px 20px;
    border: 2px solid var(--accento, #3c74f5);
    border-radius: 25px;
    background-color: white;
    color: var(--blu-scuro, #1a2c56);
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.search-input:focus {
    border-color: var(--blu, #294582);
    box-shadow: 0 0 0 3px rgba(60, 116, 245, 0.1);
    transform: translateY(-1px);
}

.search-input::placeholder {
    color: #999;
    font-style: italic;
}

.search-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--accento, #3c74f5);
    font-size: 1.2rem;
    pointer-events: none;
}

.clear-search {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #999;
    font-size: 1.3rem;
    cursor: pointer;
    padding: 2px;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: none;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.clear-search:hover {
    background-color: #f0f0f0;
    color: #666;
}

.search-stats {
    text-align: center;
    margin-top: 15px;
    color: white;
    font-size: 0.9rem;
    opacity: 0.8;
}

.highlight {
    background-color: yellow;
    color: black;
    font-weight: bold;
    border-radius: 3px;
    padding: 1px 2px;
}

.no-results {
    text-align: center;
    color: #777;
    font-style: italic;
    padding: 40px 20px;
    background-color: #f9f9f9;
    border-radius: 8px;
    border: 1px dashed #ccc;
    margin: 20px;
}

/*gestione news*/
.news-content {
    min-height: 300px;
    padding: 20px;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.news-item {
    color: black;
    padding: 30px;
    border-radius: 8px;
    border: 2px solid var(--accento);
    background: white;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

.news-item h3 {
    margin-top: 0;
    color: var(--accento);
    font-size: 1.5rem;
    margin-bottom: 10px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.news-item .news-meta {
    font-size: 0.9rem;
    color: #777;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.news-item .news-meta::before {
    content: "📅";
    margin-right: 5px;
}

.news-item .news-contenuto {
    line-height: 1.6;
    color: #333;
}

.news-contenuto > *{
    color: #333;
}

.news-item .news-contenuto p {
    margin-bottom: 15px;
}



.news-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 0 30px 30px;
    flex-wrap: wrap;
}
@media (max-width: 768px) {
    .search-input {
        font-size: 0.9rem;
        padding: 10px 40px 10px 16px;
    }
}

@media (max-width: 480px) {
    .search-wrapper {
        max-width: 100%;
    }
}


/*Tablinks - Nome attuale per i bottoni - cerchiamo di omologare con forma romboidale*/
.tablinks {
    padding: 10px 20px;
    background-color: var(--blu);
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    color: white;
    border: none;
    outline: none;
    font-size: 1rem;
    width: 100%;
}
.tablinks.active {
    background-color: var(--oro);
    color: var(--blu-scurissimo);
}

.tablinks:hover:not(.active) {
    background-color: var(--accento);
}

.tablinks:hover:not(.active) {
    background-color: #2a3a5a;
}

.tablinks-delete{
    position: absolute;
    top: 10px;
    right: 10px;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    font-size: 12px;
    background-color: var(--rosso);
    cursor: pointer;
    border: none;
}

/* Stile per i tab di visualizzazione */
.view-tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
    gap: 10px;
    position: relative;
    z-index: 100;
    flex-wrap: wrap;
}

.view-tab {
    padding: 10px 20px;
    background-color: var(--blu);
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
    color: white;
    border: none;
    outline: none;
}

.view-tab.active {
    background-color: var(--oro);
    color: var(--blu-scurissimo);
}

.view-tab:hover:not(.active) {
    background-color: #2a3a5a;
}


/*stile per la tabella*/
/* BLOCK: Tabella competizioni */
.competizioni-table {
    width: 90%;
    margin: 30px auto;
    border-collapse: separate;
    border-spacing: 0;
    background-color: var(--blu-scuro);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* ELEMENT: Header tabella */
.competizioni-table__header {
    background-color: var(--accento);
}

/* ELEMENT: Cella header */
.competizioni-table__header-cell {
    padding: 18px 15px;
    text-align: center;
    font-weight: bold;
    font-size: 1.1rem;
    letter-spacing: 0.5px;
    width: 33%;
}


.competizioni-table__cell {
    text-align: center;
}

/* ELEMENT: Riga tabella */
.competizioni-table__row {
    transition: background-color 0.3s;
}

/* MODIFIER: Riga pari */
.competizioni-table__row:nth-child(even) {
    background-color: rgba(41, 69, 130, 0.3);
}

/* MODIFIER: Riga hover */
.competizioni-table__row:hover {
    background-color: var(--blu);
}

/* ELEMENT: Cella base */
.competizioni-table__cell {
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* MODIFIER: Cella ID */
.competizioni-table__cell--id {
    font-weight: 600;
    color: #ccc;
}

/* MODIFIER: Cella nome */
.competizioni-table__cell--name {
    font-weight: 500;
}

/* MODIFIER: Cella stagione */
.competizioni-table__cell--season {
    color: #ccc;
}

/* MODIFIER: Cella stato */
.competizioni-table__cell--status {
    text-align: left;
}

/* BLOCK: Badge */
.badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* MODIFIER: Badge attivo */
.badge--active {
    background-color: rgba(76, 175, 80, 0.2);
    color: var(--verde);
    border: 1px solid var(--verde);
}

/* MODIFIER: Badge inattivo */
.badge--inactive {
    background-color: rgba(244, 67, 54, 0.2);
    color: var(--rosso);
    border: 1px solid var(--rosso);
}

select {
    background-color: var(--blu-scuro, #1a2c56);
    color: white;
    border: 2px solid var(--accento, #3c74f5);
    border-radius: 30px;
    padding: 10px 20px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3e%3cpath d='M7 10l5 5 5-5z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 15px;
}

select:hover {
    background-color: var(--blu, #294582);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.3);
}

select:focus {
    outline: none;
    border-color: white;
}

table {
    margin: 20px auto;
    width: 100%;
    line-height: 25px;
    border-collapse: collapse;
    background-color: var(--blu-scuro, #1a2c56);
    border-radius: 15px;
    overflow: hidden;
}

thead {
    background: linear-gradient(135deg, var(--accento, #3c74f5), var(--blu, #294582));
}

th {
    padding: 15px;
    text-align: left;
    font-weight: bold;
    font-size: 1.1rem;
    color: white;
    text-transform: uppercase;
    letter-spacing: 1px;
}

td {
    padding: 12px 15px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    color: #eee;
}

tr:nth-child(even) {
    background-color: rgba(41, 69, 130, 0.2);
}

tr:hover {
    background-color: rgba(60, 116, 245, 0.15);
}

tr:last-child td {
    border-bottom: none;
}


/* Responsive */
@media (max-width: 1200px) {

    .main-container{
        flex-direction: row-reverse;
    }
    .competizioni-table {
        width: 95%;
        font-size: 1rem;
    }

    .competizioni-table__header-cell,
    .competizioni-table__cell {
        padding: 12px 8px;
    }
    .main-menu {
        position: fixed;
        top: 0;
        left: 0;
        width: 40%;
        height: 100%;
        transform: translateX(-100%);
    }

    .main-menu.active {
        transform: translateX(0);
    }

    .main-menu.active{
        display: flex;
    }

    .main-content{
        width: 100%;
    }
    .main-content.active{
        width: 100%;
        pointer-events: none; /* Blocca il clic */
        /*filter: brightness(0.6);*/


    }
    .main-content.active::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.4); /* oscuramento */
        z-index: 2;
        pointer-events: none;
    }

    #hamburger-menu {
        /*font-size: 2rem;*/
        cursor: pointer;
        z-index: 3;
        pointer-events: auto;
    }
    *{
        /*font-size: 1rem;*/
    }
    th{
        padding: 0;
        text-align: center;
        /*font-size: 1rem;*/
    }
    td{
        padding: 10px 8px;
        text-align: center;

    }


}
@media (max-height: 1400px){
    .menu-item{
        padding: 10px 20px;
        margin: 10px 0;
    }

    .division-ball{
        width: 45px;
        height: 45px;
    }

    .main-header{
        height: 8%;
    }

    .main-body{
        height: 84%;
    }

    .main-footer{
        height: 8%;
    }
}
@media (max-width: 992px) {
    .competizioni-table {
        width: 95%;
        /*font-size: 0.9rem;*/
    }

    .competizioni-table__header-cell,
    .competizioni-table__cell {
        padding: 12px 8px;
    }
    .main-menu{
        display: none;
        width: 50%;
    }
    .main-content{
        width: 100%;
    }
    *{
        font-size: 0.9rem;
    }
    th, td{
        padding: 4px;
        text-align: center;
        font-size: 0.8rem;
    }
    .main-header h1{
        font-size: 1.3rem;
    }

    .division-ball{
        width: 50px;
        height: 50px;
    }
    .division-link{
        padding: 25px;
    }

    .back-button img {
        width: 20px;
        height: 20px;
    }
    .tablinks {
        padding: 8px 8px;
    }

}