/* =====================================================
   Mido Hasan — 404 / Empty States
   /assets/css/21__empty-states.css
   MIDO PHASE 10.7 404 PAGE REBUILD ACTIVE

   Lightweight CSS-only animated visual. No video, no libraries.
   Dark editorial, lavender orbit circles, pulsing glow orbs.
   Used for: 404, no-posts-found, no-projects-found.
   ===================================================== */

/* ── Page wrapper ── */
.mht-empty-page {
  display: block;
  overflow: clip;
}

/* ── Section ── */
.mht-empty {
  position: relative;
  width: 100%;
  background-color: #141017;
  min-height: calc(100svh - 86px);
  min-height: calc(100dvh - 86px);
  padding-top: calc(var(--nav-h, 58px) + var(--nav-top-offset, 28px) + clamp(32px, 5vh, 64px));
  padding-bottom: clamp(48px, 7vh, 80px);
  padding-inline: clamp(20px, 6vw, 60px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: clip;
  overflow-x: clip;
  isolation: isolate;
  box-sizing: border-box;
}

/* ── Orb glow spots ── */
.mht-empty__orbs {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.mht-empty__orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  will-change: transform, opacity;
  filter: blur(1px);
}

.mht-empty__orb--a {
  width: clamp(200px, 36vw, 380px);
  height: clamp(200px, 36vw, 380px);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(142,99,163,.22), transparent 68%);
  animation: mht-empty-pulse-a 7s ease-in-out infinite;
}

.mht-empty__orb--b {
  width: clamp(160px, 28vw, 320px);
  height: clamp(160px, 28vw, 320px);
  bottom: 15%;
  left: 10%;
  background: radial-gradient(circle, rgba(183,140,255,.14), transparent 68%);
  animation: mht-empty-pulse-b 9s ease-in-out infinite 1.2s;
}

.mht-empty__orb--c {
  width: clamp(120px, 20vw, 240px);
  height: clamp(120px, 20vw, 240px);
  top: 18%;
  right: 12%;
  background: radial-gradient(circle, rgba(76,52,93,.28), transparent 68%);
  animation: mht-empty-pulse-b 11s ease-in-out infinite 2.8s;
}

@keyframes mht-empty-pulse-a {
  0%, 100% { transform: translate(-50%, -50%) scale(.9);  opacity: .6; }
  50%       { transform: translate(-50%, -50%) scale(1.1); opacity: 1; }
}
@keyframes mht-empty-pulse-b {
  0%, 100% { transform: scale(.85); opacity: .5; }
  50%       { transform: scale(1.15); opacity: .9; }
}

/* ── Animated orbit rings ── */
.mht-empty__rings {
  position: absolute;
  top: 50%;
  left: 50%;
  pointer-events: none;
  z-index: 1;
}

.mht-empty__ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(197,166,211,.12);
  transform: translate(-50%, -50%);
  animation: mht-empty-ring-pulse 8s ease-in-out infinite;
}

.mht-empty__ring--1 {
  width: clamp(180px, 30vw, 340px);
  height: clamp(180px, 30vw, 340px);
  animation-delay: 0s;
}
.mht-empty__ring--2 {
  width: clamp(280px, 48vw, 520px);
  height: clamp(280px, 48vw, 520px);
  border-color: rgba(142,99,163,.08);
  animation-delay: 1.4s;
}
.mht-empty__ring--3 {
  width: clamp(380px, 64vw, 720px);
  height: clamp(380px, 64vw, 720px);
  border-color: rgba(44,37,50,.18);
  animation-delay: 2.8s;
}

@keyframes mht-empty-ring-pulse {
  0%, 100% { transform: translate(-50%, -50%) scale(.95); opacity: .5; }
  50%       { transform: translate(-50%, -50%) scale(1.05); opacity: 1; }
}

/* ── Content ── */
.mht-empty__content {
  position: relative;
  z-index: 2;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(10px, 1.8vw, 18px);
}

/* ── Eyebrow ── */
.mht-empty__eyebrow {
  font-family: var(--font-sans, "Blauer Nue", system-ui, sans-serif);
  font-size: clamp(.7rem, 1.2vw, .8rem);
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #AFA4B8;
  margin: 0;
}

/* ── 404 number — sans font, solid brand gradient ── */
.mht-empty__code {
  font-family: var(--font-sans, "Blauer Nue", system-ui, sans-serif);
  font-size: clamp(5rem, 18vw, 13rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -.04em;
  padding-top: .05em;
  padding-bottom: .05em;
  color: transparent;
  background: linear-gradient(150deg, #E6D8FF 0%, #B78CFF 50%, #8E63A3 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0;
  animation: mht-empty-code-drift 8s ease-in-out infinite;
}

@keyframes mht-empty-code-drift {
  0%, 100% { opacity: .85; transform: translateY(0); }
  50%       { opacity: 1;   transform: translateY(-5px); }
}

.mht-empty__heading {
  font-family: var(--font-display, "Migra", Georgia, serif);
  font-size: clamp(1.5rem, 3.5vw, 2.6rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.02em;
  color: var(--text-primary, #F6F2F7);
  max-width: 520px;
  margin: 0;
}

.mht-empty__body {
  font-size: clamp(.88rem, 1.5vw, 1rem);
  color: var(--text-muted, #AFA4B8);
  max-width: 420px;
  line-height: 1.7;
  margin: 0;
}

.mht-empty__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: clamp(12px, 2vw, 20px);
}

/* ── No-results block (used in archive templates) ── */
.mht-no-results {
  position: relative;
  padding: clamp(60px, 8vh, 100px) 0;
  text-align: center;
  overflow: clip;
  isolation: isolate;
}
.mht-no-results__orb {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: clamp(200px, 40vw, 400px);
  height: clamp(200px, 40vw, 400px);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(142,99,163,.14), transparent 68%);
  pointer-events: none;
  animation: mht-empty-pulse-a 8s ease-in-out infinite;
}
.mht-no-results__heading {
  position: relative;
  z-index: 1;
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: .5em;
}
.mht-no-results__body {
  position: relative;
  z-index: 1;
  color: var(--text-muted);
  max-width: 380px;
  margin-inline: auto;
  margin-bottom: clamp(20px, 3vw, 32px);
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  .mht-empty__orb,
  .mht-empty__ring,
  .mht-empty__code,
  .mht-no-results__orb { animation: none !important; }
}

/* =====================================================
   Phase 151M — light-mode public empty-state consistency
   Keeps 404 and archive empty states within the same light canvas family.
   ===================================================== */

html[data-mht-theme-effective="light"] .mht-empty,
html[data-mht-theme="light"] .mht-empty {
  background-color: var(--mht-p70-page-soft, #FBF8FD);
}

html[data-mht-theme-effective="light"] .mht-empty::after,
html[data-mht-theme="light"] .mht-empty::after {
  content: '';
  position: absolute;
  inset: auto 0 0;
  height: clamp(120px, 18vh, 220px);
  pointer-events: none;
  background: linear-gradient(180deg, rgba(251, 248, 253, 0), var(--mht-p70-page-soft, #FBF8FD));
  z-index: 1;
}

html[data-mht-theme-effective="light"] .mht-empty__eyebrow,
html[data-mht-theme="light"] .mht-empty__eyebrow,
html[data-mht-theme-effective="light"] .mht-empty__body,
html[data-mht-theme="light"] .mht-empty__body,
html[data-mht-theme-effective="light"] .mht-no-results__body,
html[data-mht-theme="light"] .mht-no-results__body {
  color: rgba(47, 31, 58, .70);
}

html[data-mht-theme-effective="light"] .mht-empty__heading,
html[data-mht-theme="light"] .mht-empty__heading,
html[data-mht-theme-effective="light"] .mht-no-results__heading,
html[data-mht-theme="light"] .mht-no-results__heading {
  color: #2F1F3A;
}

html[data-mht-theme-effective="light"] .mht-empty__orb--a,
html[data-mht-theme="light"] .mht-empty__orb--a {
  background: radial-gradient(circle, rgba(183, 140, 255, .18), transparent 68%);
}

html[data-mht-theme-effective="light"] .mht-empty__orb--b,
html[data-mht-theme="light"] .mht-empty__orb--b,
html[data-mht-theme-effective="light"] .mht-no-results__orb,
html[data-mht-theme="light"] .mht-no-results__orb {
  background: radial-gradient(circle, rgba(197, 166, 211, .18), transparent 68%);
}

html[data-mht-theme-effective="light"] .mht-empty__orb--c,
html[data-mht-theme="light"] .mht-empty__orb--c {
  background: radial-gradient(circle, rgba(142, 99, 163, .12), transparent 68%);
}

html[data-mht-theme-effective="light"] .mht-empty__ring,
html[data-mht-theme="light"] .mht-empty__ring {
  border-color: rgba(76, 52, 93, .10);
}
