/* ============================================================
   날짜 선택 달력 (js/date-picker.js)
   input[data-date-picker] 를 클릭하면 달력이 열려 날짜를 클릭으로 고른다.
   ============================================================ */

form input[data-date-picker][type="text"] {
  cursor: pointer;
  padding-right: 44px;
  caret-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231C2B4B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2'/%3E%3Cpath d='M16 2v4M8 2v4M3 10h18'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 20px;
}

.dp-pop {
  position: absolute;
  left: 0;
  top: calc(100% + 6px);
  z-index: 50;
  width: min(320px, 100%);
  box-sizing: border-box;
  padding: 14px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 8px 28px rgba(28, 43, 75, 0.18);
}
.dp-pop[hidden] { display: none; }

.dp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.dp-title { font-weight: 700; font-size: 0.98rem; color: var(--navy); }

.dp-nav {
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--white);
  color: var(--navy);
  font: inherit;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}
.dp-nav:hover:not(:disabled) { background: var(--sky-soft); }
.dp-nav:disabled { opacity: 0.35; cursor: default; }

.dp-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  text-align: center;
}
.dp-week {
  padding: 4px 0 6px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
}
.dp-week.is-sun { color: #C0392B; }
.dp-week.is-sat { color: #2F6DB5; }

.dp-day {
  aspect-ratio: 1;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}
.dp-day:hover:not(:disabled) { background: var(--sky-soft); }
.dp-day.is-sun { color: #C0392B; }
.dp-day.is-sat { color: #2F6DB5; }
.dp-day:disabled,
.dp-day.is-sun:disabled,
.dp-day.is-sat:disabled { color: #C8CCD4; cursor: default; }
.dp-day.is-today { box-shadow: inset 0 0 0 1.5px var(--gold); }
.dp-day.is-selected,
.dp-day.is-selected:hover {
  background: var(--navy);
  color: var(--white);
  font-weight: 700;
}
