/* ==========================================================================
   FILE: vendor-flatpickr-dark.css
   ROLE: vendor
   Third-party theme: self-contained dark flatpickr implementation
   (structure + theme). No flatpickr.min.css is loaded.
   Loaded on: home page (/index.php) only.
   ========================================================================== */

/* ---------------------------------------------------------------------------
   Self-contained compact theme for flatpickr (upload page date-time picker).
   Replaces the vendored stock flatpickr dark theme (~24 KB) with only the
   structural rules our instance needs (calendar + time + altInput), styled
   entirely from core-palette.css tokens.
   --------------------------------------------------------------------------- */

/* ---------- wrapper + calendar box ---------- */
.flatpickr-wrapper {
    position: relative;
    display: inline-block;
}.flatpickr-calendar {
    position: absolute;
    display: none;
    visibility: hidden;
    opacity: 0;
    direction: ltr;
    text-align: center;
    padding: 0;
    border: 1px solid var(--hp-color-border-strong);
    border-radius: var(--hp-radius-lg);
    background: var(--hp-color-surface);
    box-shadow: var(--hp-glass-shadow);
    box-sizing: border-box;
    width: 307.875px;
    z-index: 99999;
    color: var(--hp-color-text);
    font-size: 13px;
    line-height: 1.4;
    touch-action: manipulation;
    animation: hpFpFade var(--hp-duration-fast, 0.15s) ease-out;
}.flatpickr-calendar.open,
.flatpickr-calendar.inline {
    visibility: visible;
    opacity: 1;
    max-height: 640px;
}.flatpickr-calendar.open {
    display: inline-block;
}.flatpickr-calendar.inline {
    display: block;
    position: relative;
    top: 2px;
}.flatpickr-calendar.static {
    top: calc(100% + 4px);
}.flatpickr-calendar.arrowTop::before,
.flatpickr-calendar.arrowTop::after,
.flatpickr-calendar.arrowBottom::before,
.flatpickr-calendar.arrowBottom::after {
    content: "";
    position: absolute;
    left: 22px;
    border: 5px solid transparent;
    pointer-events: none;
}.flatpickr-calendar.arrowTop::before,
.flatpickr-calendar.arrowTop::after {
    bottom: 100%;
}.flatpickr-calendar.arrowTop::before {
    border-bottom-color: var(--hp-color-border-strong);
}.flatpickr-calendar.arrowTop::after {
    border-bottom-color: var(--hp-color-surface);
    margin-bottom: -1px;
}.flatpickr-calendar.arrowBottom::before,
.flatpickr-calendar.arrowBottom::after {
    top: 100%;
}.flatpickr-calendar.arrowBottom::before {
    border-top-color: var(--hp-color-border-strong);
}.flatpickr-calendar.arrowBottom::after {
    border-top-color: var(--hp-color-surface);
    margin-top: -1px;
}@keyframes hpFpFade {
    from {
        opacity: 0;
        transform: translateY(-3px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}/* ---------- month header ---------- */
.flatpickr-months {
    display: flex;
    padding: 4px;
}.flatpickr-months .flatpickr-month {
    position: relative;
    flex: 1;
    height: 36px;
    line-height: 1;
    overflow: hidden;
    text-align: center;
    -webkit-user-select: none;
    user-select: none;
}.flatpickr-months .flatpickr-prev-month,
.flatpickr-months .flatpickr-next-month {
    position: absolute;
    top: 4px;
    z-index: 3;
    height: 30px;
    padding: 8px;
    border-radius: var(--hp-radius-sm);
    fill: var(--hp-color-text-muted);
    cursor: pointer;
}.flatpickr-months .flatpickr-prev-month {
    left: 4px;
}.flatpickr-months .flatpickr-next-month {
    right: 4px;
}.flatpickr-months .flatpickr-prev-month:hover,
.flatpickr-months .flatpickr-next-month:hover {
    background: rgba(var(--hp-color-accent-rgb), 0.12);
}.flatpickr-months .flatpickr-prev-month:hover svg,
.flatpickr-months .flatpickr-next-month:hover svg {
    fill: var(--hp-color-white);
}.flatpickr-months .flatpickr-prev-month svg,
.flatpickr-months .flatpickr-next-month svg {
    position: relative;
    width: 14px;
    height: 14px;
}.flatpickr-current-month {
    position: absolute;
    left: 12.5%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    width: 75%;
    height: 36px;
    color: var(--hp-color-text);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    transform: translate3d(0, 0, 0);
}.flatpickr-current-month .flatpickr-monthDropdown-months {
    flex: 0 0 auto;
    margin: 0;
    padding: 2px 4px;
    border: 0;
    border-radius: var(--hp-radius-xs);
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    appearance: none;
}.flatpickr-current-month .flatpickr-monthDropdown-months:hover {
    background: rgba(var(--hp-color-accent-rgb), 0.14);
}.flatpickr-current-month .flatpickr-monthDropdown-month {
    background: var(--hp-color-surface);
    color: var(--hp-color-text);
}.flatpickr-current-month .numInputWrapper {
    display: inline-flex;
    flex: 0 0 auto;
    width: auto;
}.flatpickr-current-month input.cur-year {
    width: 6.4ch;
    text-align: left;
    margin: 0;
    padding: 0 0 0 0.4ch;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    line-height: inherit;
    height: auto;
    vertical-align: initial;
    cursor: text;
    appearance: textfield;
}/* number spinner arrows (year + time fields) */
.numInputWrapper {
    position: relative;
    display: inline-block;
    height: auto;
}.numInputWrapper input {
    display: inline-block;
}/* ---------- weekdays + days ---------- */
.flatpickr-weekdays {
    display: flex;
    width: 100%;
    height: 28px;
    overflow: hidden;
    text-align: center;
}.flatpickr-weekdaycontainer {
    display: flex;
    width: 100%;
}span.flatpickr-weekday {
    display: table-cell;
    flex: 1;
    width: 14.2857143%;
    height: 28px;
    margin: 0;
    color: var(--hp-color-text-muted);
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    cursor: default;
}.flatpickr-innerContainer {
    display: block;
    overflow: hidden;
    box-sizing: border-box;
}.flatpickr-rContainer {
    display: inline-block;
    padding: 0 4px 4px;
    box-sizing: border-box;
}.flatpickr-days {
    position: relative;
    display: flex;
    align-items: flex-start;
    overflow: hidden;
    width: auto;
}.flatpickr-days:focus {
    outline: 0;
}.dayContainer {
    display: flex;
    flex: 1;
    flex-wrap: wrap;
    justify-content: space-around;
    min-width: auto;
    max-width: none;
    padding: 0;
    text-align: left;
    opacity: 1;
}.flatpickr-day {
    display: inline-block;
    position: relative;
    flex: 0 0 14.2857143%;
    max-width: none;
    height: 36px;
    margin: 0;
    border: 1px solid transparent;
    border-radius: 9px;
    background: none;
    box-sizing: border-box;
    color: var(--hp-color-text-soft);
    font-weight: 400;
    line-height: 34px;
    text-align: center;
    cursor: pointer;
    justify-content: center;
}.flatpickr-day:hover,
.flatpickr-day:focus {
    background: rgba(var(--hp-color-accent-rgb), 0.14);
    border-color: rgba(var(--hp-color-accent-rgb), 0.35);
    color: var(--hp-color-white);
    outline: 0;
}.flatpickr-day.today {
    border-color: rgba(var(--hp-color-accent-rgb), 0.5);
}.flatpickr-day.today:hover {
    border-color: var(--hp-color-accent);
}.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange,
.flatpickr-day.selected:hover,
.flatpickr-day.selected:focus {
    background: var(--hp-color-accent);
    border-color: var(--hp-color-accent);
    color: var(--hp-color-white);
}.flatpickr-day.prevMonthDay,
.flatpickr-day.nextMonthDay {
    color: var(--hp-color-text-muted);
    opacity: 0.55;
}.flatpickr-day.flatpickr-disabled,
.flatpickr-day.flatpickr-disabled:hover {
    background: transparent;
    border-color: transparent;
    color: rgba(var(--hp-color-white-rgb), 0.18);
    cursor: default;
}.flatpickr-day.inRange {
    border-radius: 0;
    background: rgba(var(--hp-color-accent-rgb), 0.12);
    border-color: transparent;
}/* ---------- time picker ---------- */
.flatpickr-calendar.hasTime .flatpickr-time {
    display: flex;
}.flatpickr-time {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    border-top: 1px solid var(--hp-color-border);
    box-sizing: border-box;
}.flatpickr-time:after {
    content: "";
    display: table;
    clear: both;
}.flatpickr-time .numInputWrapper {
    flex: 1;
    width: 40%;
    height: 34px;
    margin: 4px;
}.flatpickr-time .numInputWrapper input {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0 2px;
    border: 1px solid var(--hp-color-border);
    border-radius: var(--hp-radius-sm);
    background: rgba(var(--hp-color-white-rgb), 0.06);
    box-shadow: none;
    color: var(--hp-color-text);
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
}.flatpickr-time input:hover,
.flatpickr-time input:focus {
    background: rgba(var(--hp-color-accent-rgb), 0.14);
    outline: 0;
}.flatpickr-time .flatpickr-time-separator {
    width: 2%;
    color: var(--hp-color-text-muted);
    font-weight: 700;
    line-height: 1;
    -webkit-user-select: none;
    user-select: none;
}.flatpickr-time .flatpickr-am-pm {
    width: 18%;
    height: 34px;
    margin: 4px 4px 4px 0;
    padding: 2px 4px 0;
    border-radius: var(--hp-radius-sm);
    color: var(--hp-color-text-muted);
    font-weight: 600;
    line-height: 30px;
    text-align: center;
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
}.flatpickr-time .flatpickr-am-pm:hover,
.flatpickr-time .flatpickr-am-pm:focus {
    background: rgba(var(--hp-color-accent-rgb), 0.14);
    color: var(--hp-color-white);
}.flatpickr-time .flatpickr-am-pm:focus {
    outline: 0;
}/* hide the time panel when the calendar has no time */
.flatpickr-calendar:not(.hasTime) .flatpickr-time {
    display: none;
}.flatpickr-time input,
.flatpickr-current-month input.cur-year {
    appearance: textfield;
    -moz-appearance: textfield;
}/* ---------- time fields: centered numbers + spaced arrow pair ---------- */

.flatpickr-time {
    height: 48px;
}.flatpickr-time .numInputWrapper {
    height: 38px;
    margin: 5px 4px;
}.flatpickr-time .numInputWrapper input {
    height: 100%;
    padding: 0 2px;
    text-align: center;
}/* keep the AM/PM pill aligned with the taller time fields */
.flatpickr-time .flatpickr-am-pm {
    height: 38px;
    margin: 5px 4px 5px 0;
    line-height: 34px;
}

/* native spinner: render it with the browser dark control set so it matches the field */
.flatpickr-time input {
    color-scheme: dark;
}

/* ---------- time stepper: boxed up/down column like the browser spinner ---------- */

/* hide the browser's own spinner so only the column below is painted */
.flatpickr-time input::-webkit-outer-spin-button,
.flatpickr-time input::-webkit-inner-spin-button {
    margin: 0;
    -webkit-appearance: none;
}

.flatpickr-time input {
    appearance: textfield;
    -moz-appearance: textfield;
    padding-right: 4px;
}

.flatpickr-time .numInputWrapper {
    position: relative;
}

.flatpickr-time .numInputWrapper span {
    position: absolute;
    right: 3px;
    display: block;
    width: 20px;
    height: calc(50% - 4px);
    padding: 0;
    border: 0;
    border-radius: 0;
    opacity: 0;
    background: rgba(var(--hp-color-white-rgb), 0.07);
    transition: opacity 0.12s ease;
}

/* like the native spinner: only the hovered / focused field shows the column */
.flatpickr-time .numInputWrapper:hover span,
.flatpickr-time .numInputWrapper:focus-within span {
    opacity: 1;
}

.flatpickr-time .numInputWrapper span.arrowUp {
    top: 3px;
    border-radius: 5px 5px 0 0;
    border-bottom: 1px solid rgba(var(--hp-color-white-rgb), 0.16);
}

.flatpickr-time .numInputWrapper span.arrowDown {
    top: auto;
    bottom: 3px;
    border-radius: 0 0 5px 5px;
}

.flatpickr-time .numInputWrapper span:hover {
    background: rgba(var(--hp-color-accent-rgb), 0.30);
}

.flatpickr-time .numInputWrapper span:after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    margin: 0;
    border: 4px solid transparent;
    transform: translate(-50%, -50%);
}

.flatpickr-time .numInputWrapper span.arrowUp:after {
    border-bottom-color: var(--hp-color-text-soft);
}

.flatpickr-time .numInputWrapper span.arrowDown:after {
    border-top-color: var(--hp-color-text-soft);
}

