/* =======================================================
   ProInput (Blazor/Components/ProInput) - every form input in one design (Shahin input design system, this project's colours).
   One field = .pf: label row, the box (.pf-box: icon · prefix · control · suffix · buttons), help / error line.
   Colours come from the theme: --inp-primary (focus border, switch / check / selected), --inp-glow (focus ring),
   --inp-tag-bg / --inp-tag-text (selected cards, chips). Everything is .pf-*.
   The legacy theme rules (.custom-input, .custom-input-group, Tom Select) are neutralised inside .pf.
   ======================================================= */

.pf, .pf-section {
    --pf-primary: var(--inp-primary, #2563eb);
    --pf-ring: var(--inp-glow, rgba(37, 99, 235, .16));
    --pf-soft: var(--inp-tag-bg, rgba(37, 99, 235, .08));
    --pf-soft-ink: var(--inp-tag-text, #1d4ed8);
    --pf-on: var(--inp-primary, #2563eb);      /* switch / checkbox / radio "on" */
    --pf-on-ink: #fff;                          /* the tick / knob on --pf-on */
    --pf-text: #172033; --pf-label: #344054; --pf-muted: #98a2b3; --pf-icon: #8a94a6;
    --pf-border: #dde3ed; --pf-border-hover: #c3cddc; --pf-surface: #fff; --pf-sunken: #f5f8fc; --pf-disabled: #f1f4f8;
    --pf-danger: #e5484d; --pf-danger-ring: rgba(229, 72, 77, .14); --pf-success: #16a34a;
    --pf-h: 42px; --pf-r: 10px; --pf-pad: 12px;
}
/* GMRL themes: the yellow "on" colour needs dark ink */
.theme-gmrl-yellow .pf, .theme-gmrl .pf, .theme-gmrl-dark .pf,
.theme-gmrl-yellow .pf-section, .theme-gmrl .pf-section, .theme-gmrl-dark .pf-section { --pf-on-ink: #2b2b2b; --pf-soft-ink: #494949; }

.pf { position: relative; display: flex; flex-direction: column; gap: 6px; min-width: 0; margin-bottom: 16px; font-size: 14px; color: var(--pf-text); }
.pf-grid > .pf, .pf-grid > * > .pf { margin-bottom: 0; }

/* ---------- Label row ---------- */
.pf-label-row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.pf .pf-label { margin: 0; font-size: 13px; font-weight: 600; color: var(--pf-label); letter-spacing: 0; text-transform: none; }
.pf-req { margin-left: 3px; color: var(--pf-danger); font-weight: 700; }
.pf-counter { font-size: 11.5px; color: var(--pf-muted); font-variant-numeric: tabular-nums; }
.pf-counter.is-over { color: var(--pf-danger); font-weight: 600; }

/* ---------- The box ---------- */
.pf-box {
    position: relative; display: flex; align-items: center; gap: 2px; min-height: var(--pf-h); padding: 0 4px 0 0;
    background: var(--pf-surface); border: 1px solid var(--pf-border); border-radius: var(--pf-r);
    transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.pf-box:hover { border-color: var(--pf-border-hover); }
.pf-box:focus-within { border-color: var(--pf-primary); box-shadow: 0 0 0 3px var(--pf-ring); }
.pf.is-invalid .pf-box { border-color: var(--pf-danger); }
.pf.is-invalid .pf-box:focus-within { box-shadow: 0 0 0 3px var(--pf-danger-ring); }
.pf.is-disabled .pf-box { background: var(--pf-disabled); border-color: var(--pf-border); cursor: not-allowed; }
.pf.is-readonly .pf-box { background: var(--pf-sunken); }

.pf-icon { flex: 0 0 auto; width: 38px; text-align: center; font-size: 15px; color: var(--pf-icon); transition: color .15s ease; }
.pf-box:focus-within .pf-icon { color: var(--pf-primary); }
.pf.is-invalid .pf-icon { color: var(--pf-danger); }
.pf-box > .pf-icon + .pf-control, .pf-box > .pf-icon + .pf-affix { padding-left: 0; }

.pf .pf-control {
    flex: 1 1 auto; min-width: 0; height: calc(var(--pf-h) - 2px); padding: 0 var(--pf-pad); margin: 0;
    border: 0 !important; outline: 0; background: transparent !important; box-shadow: none !important;
    font: inherit; font-size: 14px; color: var(--pf-text);
}
.pf .pf-control::placeholder { color: var(--pf-muted); opacity: 1; }
.pf .pf-control:disabled { cursor: not-allowed; color: #667085; -webkit-text-fill-color: #667085; }
.pf .pf-control[type=number] { -moz-appearance: textfield; }
.pf .pf-control::-webkit-outer-spin-button, .pf .pf-control::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.pf .pf-control[type=search]::-webkit-search-cancel-button { display: none; }
.pf-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace !important; letter-spacing: .03em; text-transform: uppercase; }

.pf-affix { flex: 0 0 auto; padding: 0 2px 0 var(--pf-pad); color: var(--pf-muted); font-size: 13.5px; white-space: nowrap; }
.pf-affix + .pf-control { padding-left: 4px; }
.pf-control + .pf-affix { padding: 0 8px 0 0; }

.pf-btn {
    flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0;
    border: 0; border-radius: 8px; background: transparent; color: var(--pf-icon); font-size: 14px; transition: background .12s ease, color .12s ease;
}
.pf-btn:hover { background: var(--pf-sunken); color: var(--pf-text); }
.pf-btn:focus-visible { outline: 0; box-shadow: 0 0 0 2px var(--pf-ring); }
.pf-btn-top { align-self: flex-start; margin-top: 6px; }
.pf-stepper { display: inline-flex; margin-left: 2px; padding-left: 4px; border-left: 1px solid var(--pf-border); }

/* Date / time pickers: the whole field opens the picker; the native indicator is invisible over it */
.pf-box-picker .pf-control { position: relative; cursor: pointer; }
.pf-box-picker .pf-control::-webkit-calendar-picker-indicator { position: absolute; inset: 0; width: auto; height: auto; opacity: 0; cursor: pointer; }
.pf-box-picker .pf-control::-webkit-datetime-edit { color: var(--pf-text); }
.pf-box-picker .pf-control:invalid::-webkit-datetime-edit, .pf-box-picker .pf-control[value=""]::-webkit-datetime-edit { color: var(--pf-muted); }

/* Textarea: grows with the text */
.pf-box-area { align-items: flex-start; }
.pf-box-area .pf-icon { padding-top: 12px; }
.pf .pf-box-area .pf-control { height: auto; min-height: calc(var(--pf-h) * 1.9); padding: 10px var(--pf-pad); line-height: 1.5; resize: vertical; field-sizing: content; max-height: 320px; }

/* ---------- Help / error ---------- */
.pf-help { font-size: 12.5px; color: #667085; line-height: 1.45; }
.pf-error { display: flex; align-items: flex-start; gap: 6px; font-size: 12.5px; font-weight: 500; color: var(--pf-danger); line-height: 1.45; animation: pfIn .15s ease; }
.pf-error i { margin-top: 1px; }
@keyframes pfIn { from { opacity: 0; transform: translateY(-2px); } }

/* ---------- Password strength ---------- */
.pf-strength { display: grid; grid-template-columns: repeat(4, 1fr) auto; align-items: center; gap: 4px; }
.pf-strength span { height: 4px; border-radius: 2px; background: #e5e9f0; transition: background .2s ease; }
.pf-strength em { margin-left: 6px; font-size: 11.5px; font-style: normal; font-weight: 600; color: var(--pf-muted); }
.pf-strength-1 span:nth-child(-n+1) { background: #e5484d; } .pf-strength-1 em { color: #e5484d; }
.pf-strength-2 span:nth-child(-n+2) { background: #f59e0b; } .pf-strength-2 em { color: #d97706; }
.pf-strength-3 span:nth-child(-n+3) { background: #84cc16; } .pf-strength-3 em { color: #65a30d; }
.pf-strength-4 span:nth-child(-n+4) { background: #16a34a; } .pf-strength-4 em { color: #16a34a; }

/* ---------- Checkbox / switch rows ---------- */
.pf-choice {
    display: flex; align-items: flex-start; gap: 12px; margin: 0; padding: 10px 12px; border: 1px solid var(--pf-border); border-radius: var(--pf-r);
    background: var(--pf-surface); cursor: pointer; transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}
.pf-choice:hover { border-color: var(--pf-border-hover); }
.pf-choice:focus-within { border-color: var(--pf-primary); box-shadow: 0 0 0 3px var(--pf-ring); }
.pf-choice.is-on { border-color: color-mix(in srgb, var(--pf-on) 55%, var(--pf-border)); background: color-mix(in srgb, var(--pf-on) 5%, #fff); }
.pf.is-disabled .pf-choice { background: var(--pf-disabled); cursor: not-allowed; }
.pf.is-invalid .pf-choice { border-color: var(--pf-danger); }
.pf-choice-input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.pf-choice-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; text-align: left; }
.pf-choice-label { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 600; color: var(--pf-text); line-height: 1.35; }
.pf-choice-label i { color: var(--pf-icon); }
.pf-choice-desc { font-size: 12.5px; color: #667085; line-height: 1.4; }

.pf-switch { position: relative; flex: 0 0 auto; width: 38px; height: 22px; margin-top: 1px; border-radius: 11px; background: #d0d6e0; transition: background .18s ease; }
.pf-switch-knob { position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(15, 23, 42, .3); transition: transform .18s cubic-bezier(.3, .7, .4, 1); }
.pf-choice.is-on .pf-switch { background: var(--pf-on); }
.pf-choice.is-on .pf-switch-knob { transform: translateX(16px); }

.pf-check {
    flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; margin-top: 1px;
    border: 1.5px solid #c3cddc; border-radius: 6px; background: #fff; color: transparent; font-size: 14px; transition: all .15s ease;
}
.pf-choice.is-on .pf-check { border-color: var(--pf-on); background: var(--pf-on); color: var(--pf-on-ink); }

/* ---------- Radio cards ---------- */
.pf-radios { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; }
.pf-radio {
    display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px; border: 1px solid var(--pf-border); border-radius: var(--pf-r);
    background: #fff; text-align: left; transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}
.pf-radio:hover:not(:disabled) { border-color: var(--pf-border-hover); }
.pf-radio:focus-visible { outline: 0; box-shadow: 0 0 0 3px var(--pf-ring); }
.pf-radio.is-on { border-color: var(--pf-on); background: color-mix(in srgb, var(--pf-on) 6%, #fff); box-shadow: 0 0 0 1px var(--pf-on) inset; }
.pf-radio:disabled { opacity: .55; cursor: not-allowed; }
.pf-radio-dot { flex: 0 0 auto; position: relative; width: 18px; height: 18px; margin-top: 1px; border: 1.5px solid #c3cddc; border-radius: 50%; background: #fff; }
.pf-radio.is-on .pf-radio-dot { border-color: var(--pf-on); }
.pf-radio.is-on .pf-radio-dot::after { content: ""; position: absolute; inset: 3px; border-radius: 50%; background: var(--pf-on); }

/* ---------- Segmented ---------- */
.pf-segmented { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 3px; border-radius: var(--pf-r); background: #eef1f6; align-self: flex-start; max-width: 100%; }
.pf-seg {
    display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px; border: 0; border-radius: 8px; background: transparent;
    color: #5b6576; font-size: 13.5px; font-weight: 600; transition: background .12s ease, color .12s ease, box-shadow .12s ease;
}
.pf-seg:hover:not(:disabled) { color: var(--pf-text); }
.pf-seg.is-on { background: #fff; color: var(--pf-text); box-shadow: 0 1px 3px rgba(15, 23, 42, .14); }
.pf-seg.is-on i { color: var(--pf-primary); }
.pf-seg:focus-visible { outline: 0; box-shadow: 0 0 0 2px var(--pf-ring); }
.pf-seg:disabled { opacity: .5; cursor: not-allowed; }

/* ---------- Range ---------- */
.pf-range { display: flex; align-items: center; gap: 12px; min-height: var(--pf-h); }
.pf-range-input { flex: 1 1 auto; height: 6px; border-radius: 3px; background: #e5e9f0; -webkit-appearance: none; appearance: none; outline: 0; accent-color: var(--pf-primary); }
.pf-range-input::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 2px solid var(--pf-primary); box-shadow: 0 1px 3px rgba(15, 23, 42, .25); cursor: pointer; }
.pf-range-input::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 2px solid var(--pf-primary); cursor: pointer; }
.pf-range-input:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 4px var(--pf-ring); }
.pf-range-value { min-width: 48px; padding: 4px 10px; border-radius: 8px; background: var(--pf-soft); color: var(--pf-soft-ink); font-size: 13px; font-weight: 700; text-align: center; font-variant-numeric: tabular-nums; }

/* ---------- Colour ---------- */
.pf-swatch { position: relative; flex: 0 0 auto; width: 28px; height: 28px; margin: 0 2px 0 8px; border-radius: 8px; box-shadow: inset 0 0 0 1px rgba(15, 23, 42, .15); cursor: pointer; overflow: hidden; }
.pf-swatch input { position: absolute; inset: -6px; width: calc(100% + 12px); height: calc(100% + 12px); opacity: 0; cursor: pointer; }

/* ---------- Select / multi-select (Tom Select inside the box) ---------- */
.pf-box-select { padding-right: 0; }
.pf .pf-box-select > .ts-wrapper { flex: 1 1 auto; min-width: 0; padding: 0 !important; border: 0 !important; background: transparent !important; box-shadow: none !important; min-height: 0 !important; }
.pf .pf-box-select .ts-control {
    min-height: calc(var(--pf-h) - 2px); height: auto !important; padding: 5px 34px 5px var(--pf-pad) !important; border: 0 !important; background: transparent !important;
    box-shadow: none !important; font-size: 14px; color: var(--pf-text); display: flex; flex-wrap: wrap; align-items: center; gap: 4px; cursor: pointer;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%238a94a6' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important; background-position: right 12px center !important; background-size: 12px 12px !important;
}
.pf .pf-box-select > .pf-icon + .ts-wrapper .ts-control { padding-left: 0 !important; }
.pf .pf-box-select .ts-control input { font-size: 14px; color: var(--pf-text); }
.pf .pf-box-select .ts-control input::placeholder { color: var(--pf-muted); }
.pf .pf-box-select .ts-wrapper.multi .ts-control > .item {
    margin: 0 !important; padding: 2px 4px 2px 8px; border: 0 !important; border-radius: 6px; background: var(--pf-soft) !important;
    color: var(--pf-soft-ink) !important; font-size: 12.5px; font-weight: 600;
}
.pf .pf-box-select .ts-wrapper.multi .ts-control > .item .remove { border-left: 0 !important; color: inherit; opacity: .6; margin-left: 2px; }
.pf .pf-box-select .ts-wrapper.multi .ts-control > .item .remove:hover { opacity: 1; background: transparent; }
.pf .pf-box-select .ts-wrapper .clear-button { right: 30px !important; color: var(--pf-icon); }
.pf .ts-dropdown {
    margin-top: 6px; padding: 4px; border: 1px solid var(--pf-border) !important; border-radius: 10px; background: #fff;
    box-shadow: 0 12px 32px rgba(15, 23, 42, .16); z-index: 1060;
}
.pf .ts-dropdown .option, .pf .ts-dropdown .create, .pf .ts-dropdown .no-results { padding: 8px 10px; border-radius: 7px; font-size: 13.5px; color: var(--pf-text); }
.pf .ts-dropdown .option.active { background: var(--pf-sunken) !important; color: var(--pf-text); }
.pf .ts-dropdown .option.selected { background: var(--pf-soft) !important; color: var(--pf-soft-ink); font-weight: 600; }
.pf .ts-dropdown .dropdown-input-wrap { padding: 4px; }

/* ---------- Phone (intl-tel-input inside the box) ---------- */
.pf .pf-box-phone .phone-number-container { flex: 1 1 auto; min-width: 0; }
.pf .pf-box-phone .custom-input-group { border: 0 !important; border-radius: 0 !important; background: transparent !important; box-shadow: none !important; }
.pf .pf-box-phone .custom-input { height: calc(var(--pf-h) - 2px) !important; border: 0 !important; background: transparent !important; box-shadow: none !important; font-size: 14px; color: var(--pf-text); }
.pf .pf-box-phone .iti__selected-country, .pf .pf-box-phone .iti__selected-flag { border-radius: var(--pf-r) 0 0 var(--pf-r); }
.pf .pf-box-phone .iti__selected-country:hover, .pf .pf-box-phone .iti__selected-flag:hover { background: var(--pf-sunken); }

/* ---------- Tags ---------- */
.pf .pf-box-tags .tags-input-wrapper { flex: 1 1 auto; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 5px; min-height: calc(var(--pf-h) - 2px); padding: 5px var(--pf-pad) 5px 0 !important; border: 0 !important; border-radius: 0 !important; background: transparent !important; box-shadow: none !important; }
.pf .pf-box-tags > .tags-input-wrapper:first-child { padding-left: var(--pf-pad) !important; }
.pf .pf-box-tags .tag-chip { padding: 2px 4px 2px 8px; border: 0; border-radius: 6px; background: var(--pf-soft); color: var(--pf-soft-ink); font-size: 12.5px; font-weight: 600; }
.pf .pf-box-tags .tag-chip-remove { color: inherit; opacity: .6; }
.pf .pf-box-tags .tag-chip-remove:hover { opacity: 1; }
.pf .pf-box-tags .tags-input-field { flex: 1 1 120px; min-width: 80px; border: 0; outline: 0; background: transparent; font-size: 14px; }

/* ---------- Sizes ---------- */
.pf-sm { --pf-h: 34px; --pf-pad: 10px; font-size: 13px; }
.pf-sm .pf-control { font-size: 13px !important; }
.pf-lg { --pf-h: 50px; --pf-pad: 14px; }
.pf-lg .pf-control { font-size: 15.5px !important; }

/* ---------- Sections and grid ---------- */
.pf-section { margin-bottom: 18px; padding: 18px; border: 1px solid #e6eaf1; border-radius: 14px; background: #fff; }
.pf-section-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; }
.pf-section-icon { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 10px; background: var(--pf-soft); color: var(--pf-soft-ink); font-size: 17px; }
.pf-section-titles { flex: 1 1 auto; min-width: 0; }
.pf-section .pf-section-title { margin: 0; font-size: 15px; font-weight: 700; color: var(--pf-text); line-height: 1.35; }
.pf-section-desc { margin: 2px 0 0; font-size: 12.5px; color: #667085; }
.pf-section-actions { flex: 0 0 auto; display: flex; gap: 6px; }
.pf-grid { display: grid; grid-template-columns: repeat(var(--pf-cols, 2), minmax(0, 1fr)); gap: 16px 18px; }
.pf-grid > .pf-full, .pf-grid > .pf.pf-full { grid-column: 1 / -1; }

@media (max-width: 767.98px) {
    .pf-grid { grid-template-columns: 1fr; }
    .pf-section { padding: 14px; }
}
@media (prefers-reduced-motion: reduce) {
    .pf-box, .pf-switch, .pf-switch-knob, .pf-check, .pf-error { transition: none; animation: none; }
}

/* Phone: the legacy rule gives the number a 44px line height; keep it the field height */
.pf .pf-box-phone .phone-number-container .custom-input-group input.iti__tel-input { height: calc(var(--pf-h) - 2px) !important; line-height: normal !important; }
.pf .pf-box-phone .iti { width: 100%; }
.pf .pf-box-phone .phone-number-container { min-height: 0 !important; height: auto !important; }
/* With an icon, the dropdown still lines up with the field's left edge */
.pf .pf-box-select > .pf-icon + .ts-wrapper .ts-dropdown { left: -39px !important; width: calc(100% + 39px) !important; }

/* =======================================================
   Date / date-time picker (ProDatePicker): typed field + calendar popover
   ======================================================= */
.pf-date { position: relative; }
.pf-date .pf-control { font-variant-numeric: tabular-nums; letter-spacing: .01em; }
.pf-date-toggle.is-on { background: var(--pf-soft); color: var(--pf-soft-ink); }
.pf-date.is-open .pf-box { border-color: var(--pf-primary); box-shadow: 0 0 0 3px var(--pf-ring); }

.pf-cal {
    position: absolute; z-index: 1065; top: calc(100% + 6px); left: 0; width: 304px; padding: 10px;
    background: #fff; border: 1px solid var(--pf-border); border-radius: 14px; box-shadow: 0 18px 44px rgba(15, 23, 42, .2);
    animation: pfCalIn .14s ease; user-select: none;
}
.pf-date.is-up .pf-cal { top: auto; bottom: calc(100% + 6px); animation-name: pfCalUp; }
.pf-date.is-right .pf-cal { left: auto; right: 0; }
@keyframes pfCalIn { from { opacity: 0; transform: translateY(-4px); } }
@keyframes pfCalUp { from { opacity: 0; transform: translateY(4px); } }

.pf-cal-head { display: flex; align-items: center; gap: 4px; margin-bottom: 6px; }
.pf-cal-nav { flex: 0 0 auto; width: 32px; height: 32px; border: 0; border-radius: 9px; background: transparent; color: #5b6576; display: inline-flex; align-items: center; justify-content: center; }
.pf-cal-nav:hover { background: var(--pf-sunken); color: var(--pf-text); }
.pf-cal-title { flex: 1 1 auto; height: 32px; border: 0; border-radius: 9px; background: transparent; color: var(--pf-text); font-size: 14.5px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.pf-cal-title:hover:not(:disabled) { background: var(--pf-sunken); }
.pf-cal-title:disabled { cursor: default; }
.pf-cal-title i { font-size: 11px; color: var(--pf-icon); }

.pf-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.pf-cal-dow span { padding: 6px 0 4px; text-align: center; font-size: 11.5px; font-weight: 700; letter-spacing: .03em; color: var(--pf-muted); text-transform: uppercase; }
.pf-cal-day {
    position: relative; height: 36px; border: 0; border-radius: 10px; background: transparent; color: var(--pf-text);
    font-size: 13.5px; font-weight: 500; font-variant-numeric: tabular-nums; transition: background .1s ease, color .1s ease;
}
.pf-cal-day:hover:not(:disabled) { background: var(--pf-sunken); }
.pf-cal-day.is-weekend { color: #5b6576; }
.pf-cal-day.is-other { color: #c3cad6; }
.pf-cal-day.is-today { color: var(--pf-soft-ink); font-weight: 700; box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--pf-on) 70%, transparent); }
.pf-cal-day.is-focus { background: var(--pf-sunken); box-shadow: inset 0 0 0 1.5px #c3cddc; }
.pf-cal-day.is-today.is-focus { box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--pf-on) 70%, transparent); }
.pf-cal-day.is-selected, .pf-cal-day.is-selected:hover { background: var(--pf-on); color: var(--pf-on-ink); font-weight: 700; box-shadow: 0 2px 6px color-mix(in srgb, var(--pf-on) 45%, transparent); }
.pf-cal-day:disabled { color: #d0d5dd; text-decoration: line-through; cursor: not-allowed; }

.pf-cal-tiles { grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 4px 0; }
.pf-cal-tile { height: 48px; border: 0; border-radius: 10px; background: transparent; color: var(--pf-text); font-size: 14px; font-weight: 600; }
.pf-cal-tile:hover:not(:disabled) { background: var(--pf-sunken); }
.pf-cal-tile.is-today { box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--pf-on) 70%, transparent); }
.pf-cal-tile.is-selected { background: var(--pf-on); color: var(--pf-on-ink); }
.pf-cal-tile:disabled { color: #d0d5dd; cursor: not-allowed; }

.pf-cal-time { display: flex; align-items: center; gap: 8px; margin-top: 8px; padding: 8px 4px 0; border-top: 1px solid #eef1f6; font-size: 13px; font-weight: 600; color: var(--pf-label); }
.pf-cal-time i { color: var(--pf-icon); }
.pf-cal-time input { margin-left: auto; height: 34px; padding: 0 10px; border: 1px solid var(--pf-border); border-radius: 9px; font: inherit; font-variant-numeric: tabular-nums; outline: 0; }
.pf-cal-time input:focus { border-color: var(--pf-primary); box-shadow: 0 0 0 3px var(--pf-ring); }

.pf-cal-foot { display: flex; align-items: center; gap: 4px; margin-top: 8px; padding-top: 8px; border-top: 1px solid #eef1f6; }
.pf-cal-link { padding: 4px 8px; border: 0; border-radius: 7px; background: transparent; color: var(--pf-soft-ink); font-size: 13px; font-weight: 700; }
.pf-cal-link:hover:not(:disabled) { background: var(--pf-soft); }
.pf-cal-link.is-muted { color: #667085; font-weight: 600; }
.pf-cal-link:disabled { opacity: .4; }
.pf-cal-hint { margin-left: auto; font-size: 11px; color: var(--pf-muted); white-space: nowrap; }
.pf-cal-hint kbd { padding: 0 4px; margin: 0 1px; border-radius: 4px; background: #f1f4f8; color: #475467; box-shadow: inset 0 -1px 0 #dde3ed; font: 600 10.5px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.pf-cal-done { margin-left: auto; height: 32px; padding: 0 14px; border: 0; border-radius: 9px; background: var(--pf-on); color: var(--pf-on-ink); font-size: 13px; font-weight: 700; }

@media (max-width: 575.98px) {
    .pf-cal { width: min(304px, calc(100vw - 32px)); }
}
@media (prefers-reduced-motion: reduce) { .pf-cal { animation: none; } }
