body {
    font-family: Arial, sans-serif;
    font-size: 12px;
    background-color: #f2f3f8;
    margin: 0;
    padding: 0;
}

.navigation {
    background-color: #283991;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding-top: 10px;
    padding: 5px 50px;
    text-align: center;
}

.navigation h1 {
    margin: 0;
    color: white;
    font-size: 24px;
    text-align: left;
}

.nav-links {
    display: flex;
    justify-content: center;
    background-color: #283991;
}

.nav-links a {
    color: white;
    text-decoration: none;
    margin: 0 30px;
    font-size: 16px;
    transition: border 0.3s ease;
    padding: 3px;
    border: transparent solid 1px;
}

.nav-links a:hover {
    border-bottom-color: #fff;
}

/* failed message (only used in unauthorize template) */
 .failed-msg{
    padding: 10px;
    padding-left: 30px;
    background-color: #ff8080;
    border: #981a1a solid 1px;
    font-weight: bold;
    width: auto !important;
}

.search-wrapper{
    align-content: center;
    margin: 0 5px;
}

@media (max-width: 479px) {
    .search-wrapper {
        margin: 5px;
    }
    
}


.add-button {
    display: block;
    margin: 10px;
    padding: 10px 20px;
    background-color: #283991;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.add-button:hover {
    background-color: #1f2c70;
}

.table-wrapper {
    margin: 20px auto;
    width: 80%;
    background: white;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    overflow-x: auto;
}

@media (max-width: 479px) {
    .table-wrapper {
        margin: 0px;
        width: 100%;
        background: white;
        border-radius: 5px;
        box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
        overflow-x: auto;
    }
    
}


.table-wrapper table {
    width: 100%;
    border-collapse: collapse;
}

.table-wrapper th, .table-wrapper td {
    padding-left: 5px;
    text-align: left;
}

.table-wrapper th {
    background-color: #283991;
    padding: 5px;
    color: white;
}

.table-wrapper td {
    border-bottom: 1px solid #ddd;
}

.table-wrapper button {
    padding: 5px 10px;
    background-color: #d4a630;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.table-wrapper button:hover {
    background-color: #a9872a;
}

.table-move{
    margin: 5px;
    text-align: center;
}

.table-move button{
    background-color: #283991;

}

.table-move button:hover{
    background-color: #1f2c70;

}



.hidden {
    display: none;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.overlay.active {
    display: flex;
}

@media (max-width: 479px) {
    .overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        display: none;
        justify-content: center;
        align-items: center;
        z-index: 1000;
    }
    
}


.modal {
    background: white;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.25);
    width: 80%;
    max-width: 600px;
    position: relative;
}

@media (max-width: 479px) {
    .modal {
        background: white;
        border-radius: 10px;
        box-shadow: 0 0 10px rgba(0, 0, 0, 0.25);
        width: 100%;
        max-width: 600px;
        position: relative;
    }
    
}


.form-title{
    padding: 5px;
    text-align: right;
    background-color: #283991;
    color: #fff;
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
}

.form-title h2{
    margin: 0;
    margin-top: 5px;
    margin-left: 5px;
    float: left;
}

.form-title button{
    color: #fff;
    height: fit-content;
    border: none;
    background: transparent;
    font-size: 22px;
}

.modal form {
    margin: 5px;
    display: flex;
    flex-direction: column;
}

.modal form div {
    margin-bottom: 5px;
    width: 60%;
}

.modal form label {
    margin-bottom: 5px;
    font-weight: bold;
}

.modal form input, .modal form select {
    padding: 5px;
    border: 1px solid #ddd;
    border-radius: 5px;
    width: 100%;
}

.modal form input[type="checkbox"] {
    width: unset;
}

.modal form button {
    padding: 5px;
    padding-left: 10px;
    padding-right: 10px;
    margin-right: 20px;
    margin-left: 20px;
    background-color: #283991;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 10px;
}

.modal form button:hover {
    background-color: #1f2c70;
}

.modal form button.delete {
    background-color: #dc3545;
}

.modal form button.delete:hover {
    background-color: #c82333;
}

.modal form button.close:hover {
    color: #000;
}

.modal-action{
    margin: auto;
    width: auto !important;
}

.editor-container {
    margin: 5px;
    background: #fff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    border-radius: 5px;
    overflow: hidden;
    width:auto !important;
}

.editor-container label{
    display: block;
    background: #eee;
    width: 100%;
    margin-bottom:0px !important;
    padding: 5px;
}

.editor-container .toolbar {
    display: flex;
    background: #eee;
    border-bottom: 1px solid #ccc;
    margin: 0px;
    width:auto;
}

.editor-container .toolbar button {
    margin: 0px;
    color:#000;
    background: none;
    border: none;
    padding: 5px;
    padding-left: 10px;
    padding-right: 10px;
    cursor: pointer;
    font-size: 12px;
    width:auto;
}

.editor-container .toolbar button:hover {
    background: #ddd;
}

.editor-container .toolbar input[type="color"] {
    padding: 0px;
    border: none;
    background: none;
    cursor: pointer;
    width: 30px;
}

.editor-container .editor {
    padding: 5px;
    outline: none;
    height: 125px;
    overflow-y: auto;
    width:auto;
}

.img-wrapper{
    display: block;
    position:absolute; 
    left:72%; 
    border:1px solid #000; 
    width:130px !important;
    height:150px !important;
    overflow:hidden;
}

@media (max-width: 479px){
    .img-wrapper{
        position:relative; 
        left:0%; 
        border:1px solid #000; 
        width:130px !important;
        height:150px !important;
        overflow:hidden;
    }
}

.ts-wrapper{
    width: auto !important;
}

.ts-wrapper div{
    width: auto !important;
}

.top-action{
    display: flex;
    justify-content: flex-start;
    margin: 10px auto;
    width: 80%;
    gap: 10px;
    background-color: #ffffff;
    border: 2px solid #283991;
    border-radius: 5px;
    padding: 0; 
}
.top-action h1 {
    margin-left: 10px;
}

@media (max-width: 479px){
    .top-action{
        margin: 0px auto;
        width: 100%;
        gap: 2px;
    }
}
.select-saison {
    align-content: center;
}

.total-judoka{
    align-content: center;
}

.bottom-action{
    display: flex;
    justify-content: flex-start;
    margin: 10px auto;
    width: 80%;
    gap: 10px;
    background-color: #ffffff;
    border: 2px solid #283991;
    border-radius: 5px;
    padding: 0; 
}
@media (max-width: 479px){
    .bottom-action{
        margin: 0px auto;
        width: 100%;
        gap: 2px;
    }
}

.add-season-button {
    display: block;
    margin: 10px;
    padding: 10px 20px;
    background-color: #283991;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.add-season-button:hover {
    background-color: #1f2c70;
}

.label-add-del-season {
    padding: 0 10px 0 10px;
}

.flex-align-right {
    margin-left: auto; /* push element to the right in flex container */
}

.flex-align-center {
    margin: auto; /* center element in the flex container */
}

.bareme-update-wrapper button{
    display: block;
    padding: 5px 10px;
    background-color: #449128;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.bareme-update-wrapper button:hover {
    background-color: #36701f;
}

.bareme-update-wrapper input{
    padding: 5px;
    border: 1px solid #ddd;
    border-radius: 5px;
    width: auto;
}

.bareme-update-wrapper label {
    margin-bottom: 5px;
    font-weight: bold;
}

/* loader style */
#loader {
    border: 4px solid #f3f3f3;
    border-top: 4px solid royalblue;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin-top: 10px;
    display: inline-block;
}

/* rotation animation */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Class to hide loader */
.loader-hidden {
    display: none !important;
}

/* class for div to display result (OK or NOK) to an action */
.alert-msg {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 20px 30px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    min-width: 200px;
    max-width: 90%;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.6s ease, transform 0.4s ease;
    font-weight: bold;
  }
  
  /* close button */
  .alert-msg .close-btn {
    position: absolute;
    top: 6px;
    right: 10px;
    font-size: 20px;
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
  }
  
  /* success alert (green) */
  .alert-success {
    background-color: #e7f6e7;
    border: 1px solid #3c763d;
    color: #3c763d;

  }
  
  /* error alert (red) */
  .alert-error {
    background-color: #f8d7da;
    border: 1px solid #721c24;
    color: #721c24;
}
  
  /* fade out effect */
  .alert-msg.fade-out {
    opacity: 0;
    transform: translate(-50%, -48%);
    pointer-events: none;
  }

/* form inline */
.form-inline {
    display: flex;
    flex-flow: row wrap;
    align-items: center;
}
.form-inline label {
    margin: 0 5px 0 0;
}
.form-inline select {
    margin: 0 10px 0 0;
}
.form-inline input {
  vertical-align: middle;
  margin: 0px 10px 0 0;
  padding: 5px;
  background-color: #fff;
  border: 1px solid #ddd;
}

@media (max-width: 479px) {
  .form-inline input {
    margin: 5px 0;
  }

  .form-inline {
    flex-direction: column;
    align-items: stretch;
  }
  .flex-align-right {
    margin-left: initial ; 
  }
}

/* statistics in import judoka page (in bottom action flex container) */
.stats-import{
    margin: 5px;
    padding: 5px; 
}
.stats-import p {
    text-align: center;
    font-weight: bold;
}
.stats-import p.error {
    color: #FF0000;
}
.stats-import p.success {
    color: #0ca30c;
}