/* Importo Google Fonts */
@import url("https://fonts.googleapis.com/css2?family=Titillium+Web:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700&display=swap");

:root {
  --zero: 0px;
  --borderOrange: orange;
  --borderRed: red;
  --borderGreen: green;
  --borderBlue: blue;
  --borderWidth: 1px;
  --borderColor: blue;
  --colorRed: red;
  --fontFamily: "Titillium Web", serif;
  --tachimetroAltezza: 225px;
  --trachimetroLarghezza: 550px;
  --altezzaBox: 690px;
}

/** HELPERS */
.colorRed {
  color: var(--colorRed);
}

/* 
GENERALI */
html {
  height: 100%;
  width: 100%;
}

body {
  overflow: hidden;
  height: 100%;
  width: 100%;
  font-family: var(--fontFamily);
  font-size: 17px;
}

body.home {
  background: linear-gradient(
      rgba(255, 255, 255, 0.5),
      rgba(255, 255, 255, 0.5)
    ),
    url("../img/background.png") no-repeat center center;
}

/** BORDERS */

.borderOrange {
  border-color: var(--borderOrange);
  border-width: var(--borderWidth);
  position: relative;
}

.borderRed {
  border-color: var(--borderRed);
  border-width: var(--borderWidth);
  position: relative;
}

.borderGreen {
  border-color: var(--borderGreen);
  border-width: var(--borderWidth);
  position: relative;
}

.borderBlue {
  border-color: var(--borderBlue);
  border-width: var(--borderWidth);
  position: relative;
}

.borderBlue {
  border: none !important;
}

.boxObiettivo table tr:first-child td.borderBlue {
  border: 2px solid blue !important;
}

/* Inserita classe per centrare verticalmente un div */
.centerFullHeight {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100% !important;
}

/* Fonts per le cose d'errore */
.noDataTabellaObiettivi,
.noDataTabellaSettimanale {
  font-size: 25px;
}

/* CONTAINER GENERALE */
#wrapper {
  height: 100vh;
  padding: 20px;
}

@media (max-width: 768px) {
  #wrapper {
    overflow-x: hidden;
  }
}

.boxes {
  border: 1px solid red;
  height: 500px;
  border-radius: 25px;
}

.chart-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  height: 100%;
}

.chart-container .radarChartBox.topSx {
  top: 0;
  left: 0px;
  position: absolute;
}

.chart-container .radarChartBox.topDx {
  top: 0;
  right: 0;
  position: absolute;
}

.chart-container .radarChartBox.bottomDx {
  position: absolute;
  top: 22vh;
  right: 25%;
}

@media (max-width: 768px) {
  .chart-container {
    display: inline;
  }
}

.titoloRadarChart {
  text-align: center;
  margin-top: 10px;
  margin-bottom: 10px;
}

canvas:not(#graficoTwoBox) {
  height: 135px !important;
}

.radarChartBox {
  width: 400px !important;
  height: 350px !important;
}

.radarChartBox > canvas:not(#graficoTwoBox) {
  height: 100% !important;
  width: 100% !important;
}

canvas#WeeklyChartObiettivo,
canvas#MonthlyChartObiettivo,
canvas#QuarterlyChartObiettivo {
  width: 370px !important;
  height: 280px !important;
}

.radarWeek {
  border: 1px solid var(--borderColor);
  border-radius: 25px;
  margin-bottom: 20px;
  /* height: fit-content; */
  height: var(--altezzaBox);
}

.radarWeek__noGrafici {
  min-height: 395px !important;
}

.boxObiettivo {
  border-radius: 25px;
  border: 1px solid var(--borderColor);
  padding-inline: 25px;
  height: var(--altezzaBox);
}

.boxObiettivo table {
  height: 90%;
  margin-bottom: 0px;
}

.boxObiettivo table tr td {
  vertical-align: middle;
  text-align: center;
  width: fit-content;
}

/* Box che contiene i dati */
.box {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 80px;
  /* Imposta un'altezza fissa per tutti i box */
  width: 100%;
  /* Larghezza uguale per tutti */
  background-color: #e0e0e0;
}

/* Box per gli header */
.header-box {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 60px;
  background-color: #d1d1d1;
}

.containerTabellaBox2 {
  border: 1px solid var(--borderColor);
  border-radius: 25px;
  margin-bottom: 20px;
  height: 325px;
  position: relative;
  width: 735px;
}

/** Imposto larghezza massima */
.containerGraficoBox2 {
  border: 1px solid var(--borderColor);
  border-radius: 25px;
  margin-bottom: 20px;
  height: 325px;
  position: relative;
  width: 770px;
}

/* BOX TIMER */
.boxTimer p {
  margin-bottom: 0;
}

.boxTimer > div {
  height: 100%;
}

.boxTimer .timerTitle {
  font-size: 15.5px;
  font-weight: 700;
}

.boxTimer .subTimer {
  font-size: 18px;
  font-weight: 400;
}

.boxAuthor {
  border-radius: 25px;
  border: 1px solid var(--borderColor);
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  flex-direction: column;
}

.boxTimer {
  border-radius: 25px;
  border: 1px solid var(--borderColor);
}

.boxAuthor,
.boxTimer {
  height: 325px;
}

.boxAuthor {
  width: 350px;
}

.wrapTimer {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
}

#boxOra {
  display: flex;
  justify-content: end;
  padding-right: 0;
}

.boxAuthor p {
  font-size: 1.5rem;
}

.boxAuthor > img {
  height: 100px;
  width: 110px;
  object-fit: contain;
  margin-bottom: 15px;
}

.totalTimer {
  height: 50px;
}

.boxTrimestreTabella {
  border: 1px solid var(--borderColor);
  border-radius: 25px;
  padding-inline: 25px;
  width: 1130px;
  height: 280px;
}

#tabella_obiettivi table tr td {
  height: 100%;
}

#tabella_obiettivi .calcolatePercentage {
  font-weight: 500;
  font-size: 20px;
  display: inherit;
  -webkit-display: inherit;
  position: absolute;
  left: 0;
  right: 0;
  margin: 0 auto;
  /* Per centrare orizzontalmente */
  text-align: center;
  /* Per centrare il testo all'interno */
}

.boxTabellaSettimanale table {
  margin-top: 10px;
}

/*
.boxTabellaSettimanale table thead{
    text-align: center;
}
    */

/** Modalie */
#modaleUtente .modal-header .btn-close {
  padding: 10px;
}

/* Pagina che si occupa di pulizia */
.btnContainer {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  margin-bottom: 16px;
}

#tabella_obiettivi tbody tr:not(:first-child) .borderBlue {
  display: none;
}

/**
TAbella obiettivi */

#tabella_obiettivi th {
  text-align: center;
}

/** Inserita logica per ottimizzaere qualita immagine nei grafici orizzontali */
canvas#WeeklyChartObiettivo,
canvas#MonthlyChartObiettivo,
canvas#QuarterlyChartObiettivo {
  image-rendering: optimizeQuality;
}

#boxTabellaSett {
  padding-inline: 25px;
}

/* Style css per la sezione di importazione dei dati con Excel */
.groupImportazione {
  /* display: flex;
    flex-direction: column;
    */
  display: none;
}

/* Tabelle sotto forma di card su mobile */
@media (max-width: 768px) {
  body {
    overflow: inherit;
    height: unset;
  }

  .containerGraficoBox2 {
    height: fit-content;
    width: 100% !important;
  }

  #prospettoTempo,
  #boxTabellaTrimestrale,
  #boxOra {
    margin-bottom: 25px;
  }

  .chartOrizzontale {
    padding-inline: 0px;
    margin-bottom: 25px;
  }

  .card-container {
    margin-top: 20px;
    margin-bottom: 20px;
  }

  canvas#WeeklyChartObiettivo,
  canvas#MonthlyChartObiettivo,
  canvas#QuarterlyChartObiettivo {
    width: 95% !important;
  }

  .boxObiettivo {
    margin-bottom: 20px;
  }

  .containerTabellaBox2 {
    height: fit-content;
  }
}

.card-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.card {
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 10px;
  background: #fff;
}

.card-field {
  margin-bottom: 5px;
}

/** Box countdown */
#numeroContoAllaRovescia {
  margin-left: 20px;
  margin-top: 10px;
  height: 0px;
}

@media (max-width: 768px) {
  .radarWeek,
  .boxObiettivo {
    height: fit-content;
  }

  .boxTrimestreTabella {
    width: unset;
    height: fit-content !important;
  }

  .boxAuthor {
    width: 100%;
  }

  .boxAuthor,
  .boxTimer {
    height: fit-content !important;
  }
}

.titoloTabella {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  margin-top: 8px;
}

@media (max-width: 768px) {
  .boxRadarSettimanele {
    padding-inline: 0;
  }
}

/* CSS PER IL TACHIMETRO */
.titleTachimetro {
  text-align: center;
  font-weight: 600;
}

.tachimetro {
  position: relative;
  width: 190px;
}

.tachimetro svg {
  width: 100%;
  height: 100%;
}

.tachimetro .valore {
  text-align: center;
  font-size: 18px;
  margin-top: 20px;
}

/** CSS PER I BOX QUADRATI AL POSTO DEI GRAFICI ORIZZONTALI */
.chartOrizzontale {
  display: flex;
  align-items: center;
  flex-direction: column;
  width: 190px;
}

.chartOrizzontale .titoloBox {
  font-weight: 600;
}

.boxQuadrattoUtente {
  height: 45px;
  color: white;
  position: relative;
  margin-bottom: 20px;
}

@media (max-width: 768px) {
  .boxQuadrattoUtente {
    width: 80%;
  }
}

.boxQuadrattoUtente .boxPercentuale {
  display: flex;
  justify-content: space-around;
  align-items: center;
  text-align: center;
  height: 100%;
  width: 80px;
}

.boxQuadrattoUtente .boxPercentuale p {
  text-align: center;
  margin-top: 0;
  margin-bottom: 0;
}

.prospettoTempoTachimetro {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  flex-direction: column;
  margin-bottom: 50px;
}

.boxBoxQuadratiContainerSettimanale,
.boxBoxQuadratiContainerMensile,
.boxBoxQuadratiContainerTrimestrale {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  text-align: center;
}

.bgGreen {
  background-color: green !important;
}

.bgOrange {
  background-color: orange !important;
}

.bgRed {
  background-color: red !important;
}

/* Form login e registrazione */
.formLogin {
  display: flex;
  align-items: center;
  padding-top: 40px;
  padding-bottom: 40px;
  background-color: #f5f5f5;
  text-align: center;
}

.form-signin {
  width: 100%;
  max-width: 330px;
  padding: 15px;
  margin: auto;
}

.form-signin .checkbox {
  font-weight: 400;
}

.form-signin .form-floating:focus-within {
  z-index: 2;
}

.form-signin input[type="email"] {
  margin-bottom: -1px;
  border-bottom-right-radius: 0;
  border-bottom-left-radius: 0;
}

.form-signin input[type="password"] {
  margin-bottom: 10px;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

.form-signin .btn-check:focus + .btn-primary,
.form-signin .btn-primary:focus,
.form-signin input.form-control:focus {
  box-shadow: none !important;
}

.table-borderless > :not(caption) > * > * {
  padding-bottom: 17px !important;
}

.bgSuccessBold {
  background-color: #198754 !important;
  color: black !important;
  font-weight: 600;
}

.bgWarningBold {
  background-color: #ffc107 !important;
  color: black !important;
  font-weight: 600;
}

.bgDangerbold {
  background-color: #dc3545 !important;
  color: black !important;
  font-weight: 600;
}

#tabella_obiettivi.table > :not(caption) > * > * {
  padding: 0.3rem 0.3rem !important;
}

.boxBoxQuadratiContainerTotale,
.boxBoxQuadratiContainerAndrietti,
.boxBoxQuadratiContainerDurando,
.boxBoxQuadratiContainerPatrasc {
  display: flex;
  flex-direction: column;
  gap: 4px; /* spazio verticale tra righe */
}

.titoloBox {
  margin-bottom: 20px;
}

.contenitoreGenerale {
  position: relative;
  height: 100%;
  width: 100%;
}
