/* ============================================================
   Mosque Prayer Times – Frontend (v2.0 — GSM Design)
   Warm creme / dark theme with tick-arc, refined prayer list
   ============================================================ */

/* ---------- DESIGN TOKENS ---------- */
.mpt-widget {
  --font: "Plus Jakarta Sans", system-ui, sans-serif;
  --radius: 28px;
  --accent-h: 32;
  --accent: oklch(0.68 0.15 var(--accent-h));
  --accent-deep: oklch(0.60 0.16 var(--accent-h));
  --accent-soft: oklch(0.86 0.07 var(--accent-h));

  max-width: 460px;
  margin: 0 auto;
  font-family: var(--font);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.4;
}
.mpt-widget *, .mpt-widget *::before, .mpt-widget *::after { box-sizing: border-box; }
.mpt-widget ::selection { background: var(--accent-soft); }

/* ---------- LIGHT THEME (creme) ---------- */
.mpt-widget[data-theme="light"],
.mpt-widget.mpt-theme-light,
.mpt-widget.mpt-theme-green,
.mpt-widget.mpt-theme-blue,
.mpt-widget.mpt-theme-orange {
  --page: oklch(0.97 0.012 70);
  --surface: oklch(1 0 0);
  --ink: oklch(0.28 0.02 280);
  --muted: oklch(0.58 0.015 280);
  --faint: oklch(0.80 0.012 280);
  --hairline: oklch(0.90 0.012 70);
  --arc-track: oklch(0.86 0.02 70);
  --shadow: 0 18px 50px -28px oklch(0.55 0.06 50 / 0.55);
}

/* ---------- DARK THEME ---------- */
.mpt-widget[data-theme="dark"],
.mpt-widget.mpt-theme-dark {
  --page: oklch(0.20 0.018 280);
  --surface: oklch(0.25 0.02 280);
  --ink: oklch(0.95 0.01 70);
  --muted: oklch(0.72 0.02 70);
  --faint: oklch(0.45 0.02 280);
  --hairline: oklch(0.34 0.02 280);
  --arc-track: oklch(0.38 0.02 280);
  --shadow: 0 18px 50px -28px oklch(0 0 0 / 0.7);
}

/* Theme accent hues */
.mpt-widget.mpt-theme-green {
  --accent-h: 145;
}
.mpt-widget.mpt-theme-blue {
  --accent-h: 220;
}
.mpt-widget.mpt-theme-orange {
  --accent-h: 32;
}

/* ---------- WIDGET STRUCTURE ---------- */
.mpt-inner {
  display: flex;
  flex-direction: column;
}
.mpt-inner.cards { gap: clamp(10px, 2.5vw, 14px); }
.mpt-inner.cards > .mpt-hero,
.mpt-inner.cards > .mpt-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--hairline);
}
.mpt-inner.flat > section + section { border-top: 1px solid var(--hairline); }
.mpt-inner.flat .mpt-wbar { border-bottom: 1px solid var(--hairline); }

/* ---------- TOOLBAR (wbar) ---------- */
.mpt-wbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px clamp(12px, 4vw, 18px);
}
.mpt-wbar-ar, .mpt-wbar-month {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 11px;
  border-radius: 999px;
  border: 1px solid var(--hairline);
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}
.mpt-wbar-ar:hover, .mpt-wbar-month:hover { border-color: var(--accent); color: var(--accent-deep); }
.mpt-wbar-ar-glyph { font-size: 15px; line-height: 1; }
.mpt-wbar-ar.is-on {
  background: color-mix(in oklab, var(--accent) 14%, var(--surface));
  border-color: transparent;
  color: var(--accent-deep);
}
.mpt-wbar-month svg { color: currentColor; }

/* Toast */
.mpt-toast {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  padding: 9px 18px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--page);
  font-size: 12.5px;
  font-weight: 600;
  box-shadow: var(--shadow);
  animation: mpt-fade-in 0.2s ease;
}

/* ---------- HERO (arc section) ---------- */
.mpt-hero {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius) !important;
}

/* Background image layer — optional via admin */
.mpt-hero-bg {
  position: absolute;
  inset: 0;
  background-image: var(--hero-bg, none);
  background-size: cover;
  background-position: center 30%;
  filter: blur(10px);
  transform: scale(1.12);
  z-index: 0;
}
/* Fallback: just use surface color (same as prayer list card) */
.mpt-hero-bg.no-image {
  background: var(--surface);
  filter: none;
  transform: none;
}
/* Overlay only when there IS an image */
.mpt-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: transparent;
}
.mpt-hero.has-bg-image::after {
  background: oklch(0.20 0.02 220 / 0.4);
}
[data-theme="dark"] .mpt-hero.has-bg-image::after {
  background: oklch(0.10 0.02 260 / 0.55);
}

.mpt-hero-content {
  position: relative;
  z-index: 2;
  padding: 14px 14px 10px;
}

.mpt-hero-arc-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 26px;
}
.mpt-hero-arc {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

/* Arc ticks — using theme colors */
.mpt-arc-tick {
  stroke: var(--arc-track);
  stroke-width: 1.8;
  stroke-linecap: round;
  transition: stroke 0.5s ease, stroke-width 0.3s ease;
}
.mpt-arc-tick.is-hour {
  stroke-width: 2.2;
  stroke: var(--arc-track);
}
.mpt-arc-tick.is-passed {
  stroke: var(--accent-deep);
  stroke-width: 2.8;
}
.mpt-arc-tick.is-passed.is-hour {
  stroke: var(--accent-deep);
  stroke-width: 3.4;
}

/* When hero has bg image, use white ticks */
.mpt-hero.has-bg-image .mpt-arc-tick { stroke: rgba(255,255,255,0.25); stroke-width: 1.8; }
.mpt-hero.has-bg-image .mpt-arc-tick.is-hour { stroke: rgba(255,255,255,0.35); stroke-width: 2.2; }
.mpt-hero.has-bg-image .mpt-arc-tick.is-passed { stroke: rgba(255,255,255,0.9); stroke-width: 2.8; }
.mpt-hero.has-bg-image .mpt-arc-tick.is-passed.is-hour { stroke: #fff; stroke-width: 3.4; }

/* Dotted inner arc */
.mpt-arc-dotted {
  fill: none;
  stroke: var(--hairline);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-dasharray: 2 8;
}
.mpt-hero.has-bg-image .mpt-arc-dotted { stroke: rgba(255,255,255,0.2); }

/* Marker stem */
.mpt-arc-stem {
  stroke: var(--muted);
  stroke-width: 2;
  stroke-linecap: round;
}
.mpt-hero.has-bg-image .mpt-arc-stem { stroke: rgba(255,255,255,0.6); }

/* Marker circle (sun / moon core) */
.mpt-arc-sun-core {
  fill: var(--ink);
  filter: drop-shadow(0 2px 4px oklch(0 0 0 / 0.12));
}
.mpt-arc-sun-ray {
  stroke: var(--muted);
  stroke-width: 1.8;
  stroke-linecap: round;
}
.mpt-hero.has-bg-image .mpt-arc-sun-core { fill: #fff; }
.mpt-hero.has-bg-image .mpt-arc-sun-ray { stroke: rgba(255, 255, 255, 0.75); }

/* Moon marker */
.mpt-arc-moon-core {
  fill: var(--ink);
  filter: drop-shadow(0 2px 4px oklch(0 0 0 / 0.12));
}
.mpt-arc-moon-cut {
  fill: var(--surface);
}
.mpt-inner.flat .mpt-arc-moon-cut {
  fill: var(--page);
}
.mpt-hero.has-bg-image .mpt-arc-moon-core { fill: #fff; }
.mpt-hero.has-bg-image .mpt-arc-moon-cut { fill: oklch(0.55 0.06 220 / 0.6); }
[data-theme="dark"] .mpt-hero.has-bg-image .mpt-arc-moon-cut { fill: oklch(0.2 0.02 260 / 0.6); }
[data-theme="dark"] .mpt-arc-moon-cut { fill: var(--surface); }


/* Center readout — using theme colors */
.mpt-hero-center {
  position: absolute;
  left: 50%;
  top: 60%;
  transform: translate(-50%, -50%);
  width: 76%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}
.mpt-hero-loc {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
  font-size: clamp(11px, 3.2vw, 13px);
  font-weight: 600;
  letter-spacing: 0.02em;
}
.mpt-hero-loc svg { color: var(--accent); }
.mpt-hero-clock {
  display: flex;
  align-items: baseline;
  gap: 4px;
  line-height: 1;
}
.mpt-hero-clock-main {
  font-size: clamp(36px, 10vw, 48px);
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.mpt-hero-clock-suffix {
  font-size: clamp(13px, 3.5vw, 16px);
  font-weight: 700;
  color: var(--muted);
}
.mpt-hero-mosque {
  font-size: clamp(10px, 2.8vw, 12px);
  font-weight: 600;
  color: var(--muted);
}
.mpt-hero-next {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px 4px 8px;
  border-radius: 999px;
  background: color-mix(in oklab, var(--accent) 14%, var(--surface));
  font-size: clamp(10px, 2.8vw, 12px);
  font-weight: 600;
}
.mpt-hero-next-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 2.5px color-mix(in oklab, var(--accent) 22%, transparent);
}
.mpt-hero-next-name { color: var(--accent-deep); font-weight: 800; }
.mpt-hero-next-time { color: var(--muted); }

/* When hero has bg image, override to white text */
.mpt-hero.has-bg-image .mpt-hero-loc { color: rgba(255,255,255,0.8); }
.mpt-hero.has-bg-image .mpt-hero-loc svg { color: rgba(255,255,255,0.6); }
.mpt-hero.has-bg-image .mpt-hero-clock-main { color: #fff; text-shadow: 0 2px 10px rgba(0,0,0,0.25); }
.mpt-hero.has-bg-image .mpt-hero-clock-suffix { color: rgba(255,255,255,0.7); }
.mpt-hero.has-bg-image .mpt-hero-mosque { color: rgba(255,255,255,0.65); }
.mpt-hero.has-bg-image .mpt-hero-next { background: rgba(255,255,255,0.15); backdrop-filter: blur(8px); border: 1px solid rgba(255,255,255,0.2); }
.mpt-hero.has-bg-image .mpt-hero-next-dot { background: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,0.3); }
.mpt-hero.has-bg-image .mpt-hero-next-name { color: #fff; }
.mpt-hero.has-bg-image .mpt-hero-next-time { color: rgba(255,255,255,0.65); }


/* ---------- HERO SUN ROW (inline under arc) ---------- */
.mpt-hero-sun-row {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  padding: 0 9.25%; /* Math-aligned: matches arc end points of 41px/440px */
  pointer-events: none;
}
.mpt-hero-sun-item {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.5vw, 10px);
  pointer-events: auto;
}
.mpt-hero-sun-item.is-right {
  text-align: right;
}
.mpt-hero-sun-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.mpt-hero-sun-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  font-weight: 700;
}
.mpt-hero-sun-val {
  font-size: clamp(12px, 3.4vw, 14px);
  font-weight: 800;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.mpt-hero-sun-ic {
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.mpt-hero-sun-ic svg,
.mpt-hero-sun-ic img {
  width: clamp(26px, 7vw, 32px);
  height: clamp(26px, 7vw, 32px);
  object-fit: contain;
}

/* Background image overrides for readability */
.mpt-hero.has-bg-image .mpt-hero-sun-label {
  color: rgba(255, 255, 255, 0.7);
}
.mpt-hero.has-bg-image .mpt-hero-sun-val {
  color: #fff;
}
.mpt-hero.has-bg-image .mpt-hero-sun-ic {
  color: #fff;
}

/* Base bookends (Fajr / Maghrib under arc) */
.mpt-hero-base {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 4px;
  padding: 0 4px;
}
.mpt-hero-base-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 12px;
  background: color-mix(in oklab, var(--accent) 8%, var(--surface));
  border: 1px solid var(--hairline);
}
.mpt-hero-base-ic {
  display: grid; place-items: center;
  width: 30px; height: 30px;
  border-radius: 8px;
  background: color-mix(in oklab, var(--accent) 18%, var(--surface));
  color: var(--accent-deep);
}
.mpt-hero-base-ic svg, .mpt-hero-base-ic img { width: 18px; height: 18px; object-fit: contain; }
.mpt-hero-base-txt { display: flex; flex-direction: column; line-height: 1.2; }
.mpt-hero-base-name {
  font-size: 10px; font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.mpt-hero-base-val {
  font-size: clamp(14px, 4.5vw, 17px); font-weight: 800; color: var(--ink);
  font-variant-numeric: tabular-nums;
}

/* When hero has bg image, override bookends */
.mpt-hero.has-bg-image .mpt-hero-base-item { background: rgba(255,255,255,0.12); backdrop-filter: blur(8px); border-color: rgba(255,255,255,0.15); }
.mpt-hero.has-bg-image .mpt-hero-base-ic { background: rgba(255,200,50,0.25); color: #ffc832; }
.mpt-hero.has-bg-image .mpt-hero-base-name { color: rgba(255,255,255,0.6); }
.mpt-hero.has-bg-image .mpt-hero-base-val { color: #fff; }

/* ---------- PRAYER LIST ---------- */
.mpt-list-card { padding: clamp(10px, 3vw, 16px) clamp(14px, 4vw, 22px) clamp(6px, 2vw, 10px); }

.mpt-list-colhead {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 18px;
  padding: 0 4px 8px;
  border-bottom: 1px solid var(--hairline);
}
.mpt-list-colhead .mpt-lc-adhan,
.mpt-list-colhead .mpt-lc-iq {
  width: 72px; text-align: center;
  font-size: 11px; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--faint);
}

.mpt-list-rows { display: flex; flex-direction: column; }

.mpt-prow {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 11px 8px;
  margin: 0 -4px;
  border-radius: 10px;
  border-bottom: 1px solid var(--hairline);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.mpt-prow:last-child { border-bottom: none; }

.mpt-prow:not(.is-current):hover {
  background: color-mix(in oklab, var(--accent) 5%, transparent);
  transform: translateX(4px);
}
.mpt-prow:hover .mpt-prow-ic {
  color: var(--accent-deep);
  transform: scale(1.1);
}

.mpt-prow-ic {
  display: grid; place-items: center;
  color: var(--muted);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), color 0.3s ease;
}
.mpt-prow-ic svg, .mpt-prow-ic img { width: 22px; height: 22px; object-fit: contain; }

/* Boxed icons option */
.mpt-inner.mpt-icon-boxed .mpt-prow-ic {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: color-mix(in oklab, var(--accent) 8%, var(--surface));
  color: var(--accent-deep);
}
.mpt-inner.mpt-icon-boxed .mpt-prow-ic svg,
.mpt-inner.mpt-icon-boxed .mpt-prow-ic img {
  width: 18px;
  height: 18px;
}
.mpt-inner.mpt-icon-boxed .mpt-prow.is-current .mpt-prow-ic {
  background: color-mix(in oklab, var(--accent) 22%, var(--surface));
  color: var(--accent-deep);
}

.mpt-prow-name {
  display: flex; align-items: center; gap: 10px;
  font-size: clamp(15px, 4vw, 17px); font-weight: 600; color: var(--ink);
}
.mpt-prow-ar {
  font-size: 14.5px; font-weight: 600; color: var(--muted);
  direction: rtl; opacity: 0.9;
}
.mpt-prow.is-current .mpt-prow-ar { color: var(--accent-deep); opacity: 1; }

.mpt-prow-times {
  display: grid;
  grid-template-columns: 72px 72px;
  gap: 18px;
}
.mpt-prow-col { display: flex; flex-direction: column; align-items: center; gap: 1px; }
.mpt-prow-adhan {
  font-size: clamp(14px, 4vw, 16px); font-weight: 700; color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.mpt-prow-iq {
  font-size: clamp(14px, 4vw, 16px); font-weight: 700;
  color: var(--accent-deep);
  font-variant-numeric: tabular-nums;
}

/* Range mode (adhan – iqamah inline) */
.mpt-prow-range {
  display: inline-flex; align-items: center; gap: 8px;
  font-variant-numeric: tabular-nums;
}
.mpt-prow-range .mpt-prow-adhan { font-weight: 700; }
.mpt-prow-range .mpt-prow-dash { color: var(--faint); }
.mpt-prow-range .mpt-prow-iq { color: var(--accent-deep); }

/* Current prayer highlight */
.mpt-prow.is-current {
  background: color-mix(in oklab, var(--accent) 12%, var(--surface));
  border-radius: 16px;
  border-bottom-color: transparent;
  margin: 2px 0;
  padding-left: 12px; padding-right: 12px;
  box-shadow: 0 2px 8px color-mix(in oklab, var(--accent) 4%, transparent);
}
.mpt-prow.is-current:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 8px 24px color-mix(in oklab, var(--accent) 14%, transparent);
}
.mpt-prow.is-current + .mpt-prow { border-top: none; }
.mpt-prow.is-current .mpt-prow-name { color: var(--accent-deep); font-weight: 800; }
.mpt-prow.is-current .mpt-prow-adhan { color: var(--accent-deep); }
.mpt-prow.is-current .mpt-prow-ic { color: var(--accent-deep); }

/* Sunrise row dimmed */
.mpt-prow.is-sunrise { opacity: 0.7; }
.mpt-prow.is-sunrise .mpt-prow-name { font-weight: 500; }

/* Badges */
.mpt-badge {
  font-size: 9px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.5px; padding: 2px 6px; border-radius: 8px; line-height: 1.4;
}
.mpt-badge-jumah { background: var(--accent); color: oklch(0.35 0.08 70); }
.mpt-badge-now {
  background: color-mix(in oklab, var(--accent) 20%, var(--surface));
  color: var(--accent-deep);
}
.mpt-badge-next {
  background: color-mix(in oklab, var(--accent) 14%, var(--surface));
  color: var(--accent-deep);
}
.mpt-badge-manual {
  background: oklch(0.90 0.04 25);
  color: oklch(0.55 0.15 25);
}

/* ---------- SUN ROW (footer) ---------- */
.mpt-sun-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
  padding: clamp(8px, 2vw, 11px) 6px;
}
.mpt-sun-item {
  display: flex; flex-direction: row; align-items: center; justify-content: center;
  gap: 8px; position: relative; padding: 2px 4px;
}
.mpt-sun-item-txt { display: flex; flex-direction: column; line-height: 1.15; }
.mpt-sun-item + .mpt-sun-item::before {
  content: ""; position: absolute; left: 0; top: 50%;
  transform: translateY(-50%);
  height: 56%; width: 1px; background: var(--hairline);
}
.mpt-sun-item-ic { color: var(--accent); }
.mpt-sun-item-ic svg, .mpt-sun-item-ic img { width: 20px; height: 20px; object-fit: contain; }
.mpt-sun-item-lbl { font-size: 11px; color: var(--muted); font-weight: 600; }
.mpt-sun-item-val {
  font-size: clamp(13px, 3.6vw, 15px); font-weight: 800; color: var(--ink);
  font-variant-numeric: tabular-nums;
}

/* ---------- RAMADAN BAR ---------- */
.mpt-ramadan-bar {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  margin: 0 clamp(14px, 4vw, 22px) 14px;
  padding: 14px 18px;
  background: color-mix(in oklab, var(--accent) 10%, var(--surface));
  border: 1px solid color-mix(in oklab, var(--accent) 30%, var(--hairline));
  border-radius: 16px;
  gap: 12px;
}
.mpt-ramadan-col { display: flex; flex-direction: column; gap: 2px; }
.mpt-ramadan-col.is-end { align-items: flex-end; }
.mpt-ramadan-divider { width: 1px; align-self: stretch; background: color-mix(in oklab, var(--accent) 30%, var(--hairline)); }
.mpt-ramadan-label { font-size: 11px; font-weight: 600; color: var(--muted); letter-spacing: 0.3px; text-transform: uppercase; }
.mpt-ramadan-time { font-size: 19px; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; line-height: 1; }
.mpt-ramadan-badge {
  display: inline-block; font-size: 10px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.5px; padding: 3px 10px; border-radius: 999px;
  background: var(--accent); color: oklch(0.35 0.08 70);
  margin: 0 clamp(14px, 4vw, 22px) 10px;
}

/* ---------- ACTIONS ---------- */
.mpt-actions {
  padding: 10px clamp(14px, 4vw, 22px) 18px;
  text-align: center;
}
.mpt-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; border-radius: 999px;
  font-size: 14px; font-weight: 600; border: none; cursor: pointer;
  text-decoration: none; font-family: inherit;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.mpt-btn:hover { transform: translateY(-2px); }
.mpt-btn-primary {
  background: var(--accent-deep);
  color: oklch(1 0 0);
  box-shadow: 0 6px 16px color-mix(in oklab, var(--accent-deep) 40%, transparent);
}
.mpt-btn-primary:hover { box-shadow: 0 10px 24px color-mix(in oklab, var(--accent-deep) 55%, transparent); }
.mpt-btn-ghost {
  background: transparent; color: var(--accent-deep);
  border: 1.5px solid var(--accent-deep);
}
.mpt-btn-ghost:hover { background: color-mix(in oklab, var(--accent) 10%, var(--surface)); }
.mpt-btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* ---------- ERROR ---------- */
.mpt-error { padding: 40px 24px; text-align: center; background: var(--surface); border-radius: var(--radius); }
.mpt-error-icon { font-size: 48px; margin-bottom: 12px; }
.mpt-error h3 { color: oklch(0.55 0.18 25); margin: 0 0 8px; }
.mpt-error p { color: var(--muted); margin: 0; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 360px) {
  .mpt-sun-item-lbl { font-size: 11px; }
  .mpt-prow-times { grid-template-columns: 62px 62px; gap: 12px; }
  .mpt-list-colhead .mpt-lc-adhan,
  .mpt-list-colhead .mpt-lc-iq { width: 62px; }
  .mpt-prow-ar { display: none; }
}

@media (max-width: 480px) {
  .mpt-widget { border-radius: 24px; }
}

/* ---------- MODAL (calendar) ---------- */
.mpt-modal {
  position: fixed; inset: 0; z-index: 99999;
  display: flex; align-items: center; justify-content: center; padding: 20px;
  animation: mpt-fade-in 0.2s ease;
}
.mpt-modal[hidden] { display: none; }
@keyframes mpt-fade-in { from { opacity: 0; } to { opacity: 1; } }

.mpt-modal-backdrop {
  position: absolute; inset: 0;
  background: oklch(0.20 0.02 280 / 0.6);
  backdrop-filter: blur(4px);
}
.mpt-modal-dialog {
  position: relative; background: var(--surface, #fff);
  border-radius: 24px; width: 100%; max-width: 920px; max-height: 90vh;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 20px 60px oklch(0 0 0 / 0.25);
  animation: mpt-slide-up 0.25s ease;
}
@keyframes mpt-slide-up { from { transform: translateY(20px); opacity: 0.5; } to { transform: translateY(0); opacity: 1; } }

.mpt-modal-head {
  padding: 18px 24px; border-bottom: 1px solid var(--hairline, #eee);
  display: flex; justify-content: space-between; align-items: center;
  background: var(--accent-deep, #c2603a); color: oklch(1 0 0);
}
.mpt-modal-head h3 { margin: 0; font-size: 20px; font-weight: 700; }
.mpt-modal-x {
  background: oklch(1 0 0 / 0.15); border: none; color: oklch(1 0 0);
  width: 36px; height: 36px; border-radius: 50%; font-size: 24px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: background 0.15s ease;
}
.mpt-modal-x:hover { background: oklch(1 0 0 / 0.3); }

.mpt-modal-body { padding: 22px 24px; overflow-y: auto; flex: 1; }
.mpt-modal-foot {
  padding: 16px 24px; border-top: 1px solid var(--hairline, #eee);
  display: flex; justify-content: flex-end; gap: 10px;
  background: var(--page, #fafafa);
}

.mpt-cal-controls {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px;
}
.mpt-nav {
  width: 40px; height: 40px; border-radius: 50%;
  background: color-mix(in oklab, var(--accent) 12%, var(--surface, #f5f5f5));
  color: var(--ink, #333); border: none; cursor: pointer;
  font-size: 24px; font-weight: 700; transition: all 0.15s ease;
}
.mpt-nav:hover { background: var(--accent-deep); color: oklch(1 0 0); transform: scale(1.05); }

.mpt-cal-selectors { display: flex; gap: 8px; }
.mpt-cal-selectors select {
  padding: 9px 14px; border: 1.5px solid var(--hairline, #ddd); border-radius: 10px;
  font-size: 14px; font-weight: 600; background: var(--surface, #fff);
  color: var(--ink, #333); cursor: pointer; font-family: inherit;
}
.mpt-cal-selectors select:focus { outline: none; border-color: var(--accent-deep); }

.mpt-cal-content { min-height: 300px; }
.mpt-loading {
  text-align: center; padding: 60px 20px; color: var(--muted, #999);
  display: flex; flex-direction: column; align-items: center; gap: 14px;
}
.mpt-spinner {
  width: 40px; height: 40px;
  border: 3px solid var(--hairline, #eee);
  border-top-color: var(--accent-deep);
  border-radius: 50%; animation: mpt-spin 0.8s linear infinite;
}
@keyframes mpt-spin { to { transform: rotate(360deg); } }

.mpt-cal-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.mpt-cal-table th {
  background: var(--accent-deep); color: oklch(1 0 0);
  padding: 10px 6px; text-align: center; font-weight: 600; font-size: 12px;
  position: sticky; top: 0;
}
.mpt-cal-table td {
  padding: 8px 6px; text-align: center;
  border-bottom: 1px solid var(--hairline, #eee);
  font-variant-numeric: tabular-nums;
}
.mpt-cal-table tr:hover td { background: color-mix(in oklab, var(--accent) 6%, var(--surface, #fff)); }
.mpt-cal-table tr.is-friday td { background: color-mix(in oklab, var(--accent) 10%, var(--surface, #fff)); }
.mpt-cal-table tr.is-friday:hover td { background: color-mix(in oklab, var(--accent) 16%, var(--surface, #fff)); }
.mpt-cal-table tr.is-today td { background: color-mix(in oklab, var(--accent) 8%, var(--surface, #fff)); font-weight: 700; }
.mpt-cal-day { font-weight: 700; color: var(--accent-deep); }
.mpt-cal-adhan { font-weight: 600; }
.mpt-cal-iq {
  display: block; font-size: 10px; color: var(--accent-deep);
  font-weight: 700; margin-top: 2px;
}

@media (max-width: 600px) {
  .mpt-cal-table { font-size: 11px; }
  .mpt-cal-table th, .mpt-cal-table td { padding: 6px 3px; }
  .mpt-modal-foot { flex-direction: column; }
  .mpt-modal-foot .mpt-btn { width: 100%; justify-content: center; }
}

/* ---------- PREMIUM ENHANCEMENTS & MICRO-ANIMATIONS ---------- */

/* Live pulse animation for next prayer dot */
@keyframes mpt-pulse {
  0% { transform: scale(0.9); box-shadow: 0 0 0 0 color-mix(in oklab, var(--accent) 55%, transparent); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 5px color-mix(in oklab, var(--accent) 0%, transparent); }
  100% { transform: scale(0.9); box-shadow: 0 0 0 0 color-mix(in oklab, var(--accent) 0%, transparent); }
}
.mpt-hero-next-dot {
  animation: mpt-pulse 2s infinite ease-in-out;
}

/* Stagger load animations for hero elements */
@keyframes mpt-fade-in-up {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.mpt-hero-clock,
.mpt-hero-next,
.mpt-hero-loc,
.mpt-hero-sun-row {
  animation: mpt-fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.mpt-hero-clock { animation-delay: 0.1s; }
.mpt-hero-next { animation-delay: 0.2s; }
.mpt-hero-sun-row { animation-delay: 0.3s; }

/* Ticks cascading reveal animation */
@keyframes mpt-tick-reveal {
  from {
    opacity: 0;
    stroke-width: 0;
  }
  to {
    opacity: 1;
  }
}
.mpt-arc-tick {
  animation: mpt-tick-reveal 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Glow / breathing animation for custom sun and moon markers */
@keyframes mpt-marker-glow {
  0% { filter: drop-shadow(0 0 2px var(--accent)) brightness(1); }
  50% { filter: drop-shadow(0 0 8px var(--accent)) brightness(1.15); }
  100% { filter: drop-shadow(0 0 2px var(--accent)) brightness(1); }
}
.mpt-arc-sun-core, 
.mpt-arc-moon-core {
  animation: mpt-marker-glow 3s infinite ease-in-out;
}

