/*
 * shared/datepicker.css — közös dátumválasztó („Prémium akcent" / koncept-02). PREFIX: .dtp-*
 * A brand-narancs akcenttel, az app-tokeneken. Single + tartomány mód. Világos/sötét témát az app tokenjei viszik.
 */
.dtp {
  position: relative;
}
.dtp-field {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: var(--space-sm) var(--space-md);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg);
  color: var(--text-primary);
  font: inherit;
  font-size: var(--font-base);
  text-align: left;
  cursor: pointer;
  font-variant-numeric: tabular-nums;
}
.dtp-field:hover {
  border-color: var(--border-strong);
}
.dtp-field.is-open {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-tint);
}
.dtp-field svg {
  width: 16px;
  height: 16px;
  color: var(--text-tertiary);
  flex: 0 0 auto;
}
.dtp-val {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dtp-val.is-placeholder {
  color: var(--text-tertiary);
}

.dtp-pop {
  position: fixed; /* viewporthoz , kilóg a modál-body overflow-jából; a JS (positionPop) számolja a top/left-et */
  z-index: 1100; /* a modál (--z-modal: 1000) fölött is */
  width: 300px;
  max-width: calc(100vw - 16px);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow:
    0 1px 2px rgba(15, 23, 41, 0.05),
    0 14px 40px -14px rgba(15, 23, 41, 0.28);
  overflow: hidden;
}
.dtp-pop[hidden] {
  display: none;
}
.dtp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 12px 10px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--primary) 7%, transparent), transparent);
}
.dtp-month {
  font-size: var(--font-sm);
  font-weight: 700;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
}
.dtp-nav {
  border: 0;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-md);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  line-height: 1;
}
.dtp-nav:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}
.dtp-dow {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  padding: 0 10px 6px;
}
.dtp-dow span {
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-tertiary);
}
.dtp-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  padding: 0 10px 10px;
}
.dtp-day {
  position: relative;
  border: 0;
  background: transparent;
  cursor: pointer;
  font: inherit;
  height: 38px;
  font-size: 13.5px;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-variant-numeric: tabular-nums;
}
.dtp-day.out {
  color: var(--text-tertiary);
  opacity: 0.45;
  cursor: default;
}
.dtp-day.we:not(.out):not(.sel) {
  color: var(--primary-dark);
}
.dtp-day:not(.out):not(.sel):not(.in):hover {
  background: var(--bg-secondary);
}
.dtp-day.in {
  background: var(--primary-tint);
  border-radius: 0;
}
.dtp-day.today:not(.sel) {
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--primary) 55%, transparent);
}
.dtp-day.sel {
  background: linear-gradient(180deg, var(--primary-light), var(--primary-dark));
  color: #fff;
  font-weight: 700;
  box-shadow: 0 2px 8px -2px color-mix(in srgb, var(--primary) 55%, transparent);
}
.dtp-day.start {
  border-radius: var(--radius-md) 0 0 var(--radius-md);
}
.dtp-day.end {
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}
.dtp-day.start.end {
  border-radius: var(--radius-md);
}
.dtp-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 12px;
  border-top: 1px solid var(--border);
}
.dtp-today {
  border: 1px solid var(--border-strong);
  background: var(--bg);
  color: var(--text-secondary);
  font: inherit;
  font-size: 12.5px;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  cursor: pointer;
}
.dtp-today:hover {
  color: var(--text-primary);
  border-color: var(--text-tertiary);
}
.dtp-hint {
  font-size: 11.5px;
  color: var(--text-tertiary);
}
