@charset "UTF-8";

.calendar {
  display: none;
  position: absolute;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,.15);
  padding: 16px;
  width: 620px;
  font-family: system-ui, sans-serif;
  z-index: 1000;
}

/* header */
.cal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.cal-header button {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
}

/* mesi */
.cal-months {
  display: flex;
  gap: 20px;
}

.cal-month {
  width: 280px;
}

.cal-title {
  text-align: center;
  font-weight: 600;
  margin-bottom: 8px;
  font-size: 14px;
}

/* Nomi giorni */
.cal-days-header {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 4px;
  font-weight: 600;
  font-size: 12px;
  color: #666;
}

.cal-day-name {
  text-align: center;
}

/* griglia */
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-day {
  padding: 8px 0;
  border-radius: 6px; /* rettangolo leggermente arrotondato */
  border: none;
  background: none;
  cursor: pointer;
  font-size: 13px;
  position: relative;
}

/* hover */
.cal-day:hover {
  background: #f1f1f1;
}

/* disabilitati */
.cal-day.disabled {
  color: #ccc;
  cursor: not-allowed;
}

/* range */
.cal-day.in-range {
  background: #E8F0FE;
  border-radius: 6px;
}

/* selezione arrivo/partenza */
.cal-day.start,
.cal-day.end {
  background: #1CA8CB; /* colore selezione */
  color: #fff;
  border-radius: 6px; /* rettangolo */
}

/* rimuovi bordo evidenziazione */
.cal-day.start::after,
.cal-day.end::after {
  content: none;
}

@media (max-width: 768px) {
  .page-home .calendar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 16px 16px 0 0;
    padding: 14px;
  }
	
.page-contatti .calendar {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
}


  .cal-months {
    flex-direction: column;
    gap: 20px;
  }

  .cal-month {
    width: 100%;
  }

  .cal-day {
    padding: 12px 0;
    font-size: 15px;
  }

  .cal-title {
    font-size: 13px;
  }

  .cal-day {
    font-size: 12px;
  }
}