/* MARQ time picker (js/marq-time.js) — website (dark) and admin panel (light). */

/* ---- the field ---- */
.mt-field { position: relative; display: block; width: 100%; flex: 0 1 auto; min-width: 0; }
.mt-field.mt-dt { display: flex; gap: 8px; align-items: stretch; }
.mt-field.mt-dt > input { flex: 1 1 0; min-width: 0; }
.mt-field > .mt-trigger {
  cursor: pointer; caret-color: transparent; font-variant-numeric: tabular-nums;
  padding-right: 38px !important;
  background-repeat: no-repeat; background-position: right 12px center; background-size: 17px 17px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='9' fill='none' stroke='%23ff2c55' stroke-width='1.8'/%3E%3Cpath d='M12 7.5V12l3 2' fill='none' stroke='%23ff2c55' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");
}
.mt-field.mt-t-light > .mt-trigger {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='9' fill='none' stroke='%23b8913a' stroke-width='1.8'/%3E%3Cpath d='M12 7.5V12l3 2' fill='none' stroke='%23b8913a' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");
}
.mt-field > .mt-trigger:disabled { cursor: not-allowed; opacity: .55; }
.mt-field > .mt-trigger.mt-invalid { border-color: #e5484d !important; box-shadow: 0 0 0 3px rgba(229, 72, 77, .18); }
.mt-field > input.mt-native {
  position: absolute !important; left: 50%; bottom: 0; width: 1px !important; height: 1px !important;
  min-width: 0 !important; margin: 0 !important; padding: 0 !important; border: 0 !important;
  opacity: 0 !important; pointer-events: none !important;
}

/* ---- popover ---- */
.mt-pop {
  --mt-bg: #121214; --mt-bg-2: #19191c; --mt-well: #0a0a0b; --mt-ink: #f4f1ea; --mt-ink-2: #b9b4aa; --mt-muted: #8a857b;
  --mt-line: rgba(255, 255, 255, .09); --mt-accent: #ff2c55; --mt-accent-ink: #fff; --mt-accent-soft: rgba(255, 44, 85, .12);
  --mt-accent-line: rgba(255, 44, 85, .38);
  position: fixed; z-index: 100000; width: 320px; padding: 14px 14px 12px; box-sizing: border-box;
  background: linear-gradient(180deg, var(--mt-bg-2), var(--mt-bg)); color: var(--mt-ink);
  border: 1px solid var(--mt-line); border-radius: 18px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, .5), 0 2px 8px rgba(0, 0, 0, .25);
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
  user-select: none; -webkit-user-select: none;
  animation: mt-in .16s cubic-bezier(.2, .8, .2, 1);
}
.mt-pop.mt-light {
  --mt-bg: #ffffff; --mt-bg-2: #fffdf8; --mt-well: #f6f3ec; --mt-ink: #17150f; --mt-ink-2: #3d382d; --mt-muted: #7b7465;
  --mt-line: #e9e3d6; --mt-accent: #b8913a; --mt-accent-ink: #fff; --mt-accent-soft: rgba(184, 145, 58, .12);
  --mt-accent-line: rgba(184, 145, 58, .45);
  box-shadow: 0 24px 60px rgba(15, 14, 11, .18), 0 2px 6px rgba(15, 14, 11, .06);
}
.mt-pop *, .mt-pop *::before, .mt-pop *::after { box-sizing: border-box; }
.mt-pop.mt-sheet {
  left: 0 !important; right: 0; bottom: 0; top: auto !important; width: auto; border-radius: 22px 22px 0 0;
  padding: 18px 18px calc(20px + env(safe-area-inset-bottom));
  animation: mt-up .24s cubic-bezier(.2, .8, .2, 1);
}
.mt-scrim { position: fixed; inset: 0; z-index: 99999; background: rgba(0, 0, 0, .55); animation: mt-fade .16s ease-out; }
@keyframes mt-in { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes mt-up { from { transform: translateY(100%); } to { transform: none; } }
@keyframes mt-fade { from { opacity: 0; } to { opacity: 1; } }

.mt-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 0 4px 10px; }
.mt-title { font-size: 11px; font-weight: 600; letter-spacing: 1.3px; text-transform: uppercase; color: var(--mt-muted); }
.mt-preview { font-size: 23px; font-weight: 700; letter-spacing: .4px; color: var(--mt-accent); font-variant-numeric: tabular-nums; }

.mt-presets { display: flex; gap: 6px; overflow-x: auto; padding: 0 2px 10px; scrollbar-width: none; }
.mt-presets::-webkit-scrollbar { display: none; }
.mt-chip {
  flex: 1 0 auto; padding: 6px 8px; border-radius: 999px; font: inherit; font-size: 11.5px; font-weight: 500; white-space: nowrap;
  border: 1px solid var(--mt-line); background: transparent; color: var(--mt-ink-2); cursor: pointer;
}
.mt-chip:hover { border-color: var(--mt-accent-line); color: var(--mt-ink); }

.mt-wheels {
  position: relative; display: flex; align-items: stretch; justify-content: center; gap: 2px; padding: 0 8px;
  background: var(--mt-well); border: 1px solid var(--mt-line); border-radius: 13px;
}
.mt-band {
  position: absolute; left: 6px; right: 6px; pointer-events: none; border-radius: 10px;
  background: var(--mt-accent-soft); border: 1px solid var(--mt-accent-line);
}
.mt-col { flex: 1; min-width: 0; position: relative; z-index: 1; }
.mt-col.mt-ampm { flex: .9; }
.mt-wheel {
  overflow-y: auto; scroll-snap-type: y mandatory; overscroll-behavior: contain; outline: none;
  scrollbar-width: none; box-sizing: border-box;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 32%, #000 68%, transparent 100%);
          mask-image: linear-gradient(180deg, transparent 0, #000 32%, #000 68%, transparent 100%);
}
.mt-wheel::-webkit-scrollbar { display: none; }
.mt-wheel:focus-visible { box-shadow: inset 0 0 0 1px var(--mt-accent-line); border-radius: 10px; }
.mt-item {
  scroll-snap-align: center; display: flex; align-items: center; justify-content: center; cursor: pointer;
  font-size: 19px; color: var(--mt-ink-2); font-variant-numeric: tabular-nums;
}
.mt-item.on { color: var(--mt-ink); font-weight: 700; }
.mt-colon { align-self: center; z-index: 1; font-size: 20px; font-weight: 700; color: var(--mt-accent); padding-bottom: 2px; }

.mt-foot { display: flex; align-items: center; gap: 8px; padding-top: 12px; }
.mt-spacer { flex: 1; }
.mt-btn {
  font: inherit; font-size: 13px; font-weight: 600; letter-spacing: .3px; cursor: pointer;
  padding: 9px 14px; border-radius: 10px; border: 1px solid var(--mt-line); background: transparent; color: var(--mt-ink-2);
}
.mt-btn:hover { border-color: var(--mt-accent-line); color: var(--mt-ink); }
.mt-btn.mt-done { background: var(--mt-accent); border-color: var(--mt-accent); color: var(--mt-accent-ink); padding: 9px 22px; }
.mt-btn.mt-done:hover { filter: brightness(1.08); }
.mt-sheet .mt-btn { padding: 12px 16px; font-size: 14px; }
.mt-sheet .mt-btn.mt-done { padding: 12px 28px; }

/* ---- admin: Admin Configuration → Time Format ---- */
.tfa-seg { display: inline-flex; gap: 4px; padding: 4px; border-radius: 14px; background: var(--mq-surface-2, #faf8f3); border: 1px solid var(--mq-line, #e9e3d6); }
.tfa-opt {
  display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 128px; padding: 10px 18px;
  border: 0; border-radius: 10px; background: transparent; color: var(--mq-ink-2, #3d382d); font: inherit; cursor: pointer;
  transition: background .15s, color .15s, box-shadow .15s;
}
.tfa-opt b { font-size: 13.5px; font-weight: 700; letter-spacing: .2px; }
.tfa-opt span { font-size: 12px; color: var(--mq-muted, #7b7465); font-variant-numeric: tabular-nums; }
.tfa-opt:hover:not(.on):not(:disabled) { background: #fff; }
.tfa-opt.on { background: var(--mq-obsidian, #0f0e0b); color: #fff; box-shadow: 0 6px 16px rgba(15, 14, 11, .18); }
.tfa-opt.on span { color: var(--mq-gold-bright, #d9b562); }
.tfa-opt:disabled { cursor: progress; }
