/* ===================== AGENDAR CITA ===================== */
.agendar-page {
  position: relative;
  padding: 60px 20px;

  background: linear-gradient(
    135deg,
    #fff4c4 0%,   /* luz suave */
    #bca86c 20%,  /* dorado claro */
    #f3e6c2 35%,  /* dorado vivo */
    #fafaf9 50%,  /* brillo máximo */
    #d5c082 65%,
    #bca86c 80%,
    #fff4c4 100%
  );

  background-size: 250% 250%;
  animation: shimmerMove 8s ease-in-out infinite;

  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.agendar-page h2 {
  font-family: 'Great Vibes', cursive;
  font-size: 2.5rem;
  
  text-shadow: 2px 2px 10px rgba(7, 45, 17, 0.6);

    /* Dorado brillante */
  background: linear-gradient(
    90deg,
    #1b311b,
    #031401,
    #051a05,
    #121412f9,
    #012201
  );

  background-size: 260% auto;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;

  animation: brilloDorado 9s linear infinite;
}


@keyframes brilloDorado {
  to {
    background-position: 200% center;
  }

}

.agendar-form {
  background: linear-gradient(135deg, #152515, #283d1d, #152515);
  border: 2px solid rgb(238, 223, 172);
  border-radius: 15px;
  padding: 30px;
  max-width: 600px;
  width: 100%;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.form-group {
  margin-bottom: 20px;
  text-align: left;
}

.form-group label {
  display: block;
  font-family: 'Montserrat', sans-serif;
  color: rgb(228, 215, 187);
  margin-bottom: 8px;
  font-weight: 500;
  font-size: 0.95rem;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px;
  border: 2px solid rgba(238, 223, 172, 0.5);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  font-family: 'Montserrat', sans-serif;
  font-size: 1rem;
  transition: border 0.3s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: rgb(238, 223, 172);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.checkbox-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.checkbox-group input[type="checkbox"] {
  width: auto;
  cursor: pointer;
}

.info-mensaje {
  background: rgba(238, 223, 172, 0.2);
  border-left: 4px solid rgb(238, 223, 172);
  padding: 15px;
  margin-bottom: 20px;
  border-radius: 8px;
}

.info-mensaje p {
  color: rgb(228, 215, 187);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.95rem;
  margin: 0;
  line-height: 1.6;
}

/* ===================== CALENDARIO FECHA ===================== */
.fecha-calendar {
  background: rgba(21, 37, 21, 0.3);
  border: 1px solid rgba(185, 150, 84, 0.3);
  border-radius: 12px;
  padding: 15px;
  margin-top: 8px;
}

.month-calendar {
  display: grid;
  gap: 12px;
}

.month-calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.month-calendar-title {
  font-family: 'Cinzel', serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #f6e7b4;
  text-transform: capitalize;
  letter-spacing: 0.3px;
}

.month-nav-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(185, 150, 84, 0.45);
  background: rgba(21, 37, 21, 0.45);
  color: #f7ecd0;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.month-nav-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  background: rgba(185, 150, 84, 0.28);
}

.month-nav-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.month-calendar-weekdays,
.month-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.month-calendar-weekday {
  text-align: center;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  color: #d8ccaa;
  padding: 4px 0;
}

.calendar-day {
  min-height: 56px;
  border-radius: 10px;
  border: 1px solid rgba(185, 150, 84, 0.28);
  background: rgba(185, 150, 84, 0.12);
  color: #f7ecd0;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.calendar-day:hover:not(:disabled) {
  transform: translateY(-1px);
}

.calendar-day--empty {
  background: transparent;
  border: none;
  cursor: default;
}

.calendar-day--available {
    background: rgba(68, 96, 68, 0.28);
  color: #50713c;
}

.calendar-day--busy {
    background: rgba(237, 108, 2, 0.35);
  border-color: rgba(237, 108, 2, 0.45);
  color: #fff1d6;
}

.calendar-day--occupied {
    background: rgba(198, 40, 40, 0.38);
  border-color: rgba(198, 40, 40, 0.55);
  color: #ffe6e6;
}

.calendar-day--disabled {
    background: rgba(120, 120, 120, 0.18);
  border-color: rgba(120, 120, 120, 0.2);
  color: rgba(247, 236, 208, 0.35);
  cursor: not-allowed;
}

.calendar-day--full {
    background: rgba(198, 40, 40, 0.38);
  border-color: rgba(198, 40, 40, 0.55);
  color: #ffe6e6;
  cursor: not-allowed;
}

.calendar-day--selected {
  background: #b99654;
  border-color: #f1db97;
  color: white;
  box-shadow: 0 0 0 2px rgba(241, 219, 151, 0.25);
}

.calendar-day-number {
  z-index: 1;
}

.calendar-day-dot {
  position: absolute;
  bottom: 7px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff5d5d;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.15);
}

.calendar-legend--months {
  margin-top: 4px;
  padding-top: 6px;
  border-top: 1px solid rgba(185, 150, 84, 0.2);
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  font-size: 0.9rem;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.legend-dot.free {
  background: rgba(76, 175, 80, 0.4);
  border: 1px solid rgba(76, 175, 80, 0.6);
}

.legend-dot.busy {
  background: rgba(237, 108, 2, 0.4);
  border: 1px solid rgba(237, 108, 2, 0.6);
}

.legend-dot.full {
  background: rgba(198, 40, 40, 0.5);
  border: 1px solid rgba(198, 40, 40, 0.7);
}

#fechaFallback {
  background: rgba(240, 240, 240, 0.8);
  border: 1px solid #ddd;
  padding: 12px;
  border-radius: 6px;
  color: #666;
  text-align: center;
  font-size: 0.95rem;
}

.btn-enviar,
.btn-submit {
  width: 100%;
  background: #8e7d5a;
  color: #ffffff;
  padding: 18px 20px;
  border: none;
  border-radius: 8px;
  font-family: 'Montserrat', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.btn-enviar:hover,
.btn-submit:hover {
  background: #6c5b2c;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
}

.btn-enviar:disabled,
.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

@media (max-width: 768px) {
  .month-calendar-weekdays,
  .month-calendar-grid {
    gap: 4px;
  }

  .calendar-day {
    min-height: 50px;
    font-size: 0.85rem;
  }

  .month-calendar-header {
    align-items: flex-start;
  }
}

.success-message {
  position: fixed;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  z-index: 3000;
  width: min(92vw, 460px);
  padding: 0;
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(21, 37, 21, 0.98), rgba(40, 61, 29, 0.98), rgba(21, 37, 21, 0.98));
  color: #f7ecd0;
  border: 2px solid rgba(238, 223, 172, 0.92);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.45), 0 0 30px rgba(255, 223, 150, 0.28);
  text-align: left;
  font-family: 'Montserrat', sans-serif;
  overflow: hidden;
  animation: popIn 0.28s ease-out;
}

.error-message {
  position: fixed;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  z-index: 3000;
  width: min(92vw, 460px);
  padding: 0;
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(87, 28, 28, 0.98), rgba(123, 35, 35, 0.98), rgba(87, 28, 28, 0.98));
  color: #fff4f4;
  border: 2px solid rgba(255, 207, 207, 0.9);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.45), 0 0 30px rgba(255, 164, 164, 0.2);
  text-align: left;
  font-family: 'Montserrat', sans-serif;
  overflow: hidden;
  animation: popIn 0.28s ease-out;
}

.message-card {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 22px 22px 18px;
}

.message-card__icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 48px;
  font-size: 1.5rem;
  background: rgba(238, 223, 172, 0.16);
  border: 1px solid rgba(238, 223, 172, 0.55);
}

.message-card__body {
  flex: 1;
}

.message-card__title {
  font-family: 'Great Vibes', cursive;
  font-size: 2rem;
  color: rgb(238, 223, 172);
  margin-bottom: 6px;
}

.message-card__text {
  font-size: 0.98rem;
  line-height: 1.55;
  color: #f7ecd0;
}

.message-card__actions {
  display: flex;
  justify-content: flex-end;
  padding: 0 22px 22px;
}

.message-card__button {
  border: 1px solid rgba(238, 223, 172, 0.88);
  background: rgba(238, 223, 172, 0.16);
  color: #fff8e6;
  padding: 10px 18px;
  border-radius: 999px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.message-card__button:hover {
  transform: translateY(-1px);
  background: rgba(238, 223, 172, 0.28);
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: translate(-50%, -46%) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

@media (max-width: 480px) {
  .message-card {
    padding: 18px 16px 14px;
    gap: 12px;
  }

  .message-card__title {
    font-size: 1.7rem;
  }

  .message-card__text {
    font-size: 0.92rem;
  }

  .message-card__actions {
    padding: 0 16px 16px;
  }
}

/* ===================== FORMULARIO DINÁMICO ===================== */
.service-fields {
  margin-bottom: 20px;
}

.service-fieldset {
  border: 1px solid rgba(238, 223, 172, 0.35);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 14px;
  background: rgba(255, 255, 255, 0.04);
}

.service-fieldset legend {
  padding: 0 8px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  color: rgb(238, 223, 172);
}

.service-options {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.service-option {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: rgb(228, 215, 187);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.95rem;
}

.service-option input {
  margin-top: 3px;
  width: auto;
}

.service-option small {
  display: block;
  color: rgba(228, 215, 187, 0.8);
  font-size: 0.82rem;
  line-height: 1.4;
}

.service-note {
  margin: 12px 0 18px;
  padding: 14px 16px;
  border-radius: 12px;
  border-left: 4px solid rgb(238, 223, 172);
  background: rgba(238, 223, 172, 0.12);
  color: rgb(243, 234, 210);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.95rem;
}

.readonly-field {
  background: rgba(255, 255, 255, 0.86) !important;
  color: #2c2c2c;
}

.time-summary {
  margin-top: 8px;
  font-size: 0.92rem;
  color: rgb(228, 215, 187);
  font-family: 'Montserrat', sans-serif;
}