

/* ---- Date field (text input + picker) ---------------------------------- */
.date-field {
  position: relative;
  display: block;
}

.date-field .date-input {
  padding-right: 38px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}

.date-field .date-input.is-invalid {
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.14);
}

.date-field__btn {
  position: absolute;
  top: 50%;
  right: 4px;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-700);
  cursor: pointer;
}

.date-field__btn:hover,
.date-field__btn:focus-visible {
  background: var(--surface-muted);
  color: var(--text-900);
}

.date-field__btn svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
}

.date-picker {
  position: absolute;
  z-index: 1080;
  width: 268px;
  padding: 10px;
  border: 1px solid var(--surface-border-strong);
  border-radius: 12px;
  background: var(--surface-strong);
  box-shadow: var(--surface-shadow);
  color: var(--text-900);
  font-size: 0.86rem;
}

.date-picker__head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}

.date-picker__head select {
  flex: 1 1 auto;
  min-width: 0;
  height: 30px;
  padding: 0 6px;
  border: 1px solid var(--surface-border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text-900);
  font-size: 0.84rem;
}

.date-picker__nav {
  width: 26px;
  height: 30px;
  padding: 0;
  border: 1px solid var(--surface-border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text-700);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
}

.date-picker__nav:hover {
  background: var(--surface-muted);
}

.date-picker__week,
.date-picker__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}

.date-picker__week {
  margin-bottom: 4px;
  color: var(--text-500, var(--text-700));
  font-size: 0.74rem;
  text-align: center;
}

.date-picker__day {
  height: 30px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-900);
  font-size: 0.82rem;
  cursor: pointer;
}

.date-picker__day:hover {
  background: var(--surface-muted);
}

.date-picker__day.is-today {
  box-shadow: inset 0 0 0 1px var(--surface-border-strong);
}

.date-picker__day.is-selected {
  background: #2f6fd0;
  color: #ffffff;
  font-weight: 600;
}

.date-picker__foot {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--surface-border);
}

.date-picker__foot .btn {
  min-height: 28px;
  padding: 2px 10px;
  font-size: 0.78rem;
}
