/* ═══════════════════════════════════════════════════════
   GLASSMORPHISM DASHBOARD — Design System
   ═══════════════════════════════════════════════════════ */

/* ── Reset ── */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ── Tokens ── */
:root {
  /* Palette */
  --mint-50: #E0F7F1;
  --mint-100: #B2EBD8;
  --mint-200: #80DEBE;
  --mint-300: #4DD0A4;
  --mint-400: #34D399;
  --mint-500: #26B88A;
  --teal-400: #2DD4BF;
  --teal-500: #14B8A6;
  --rose-400: #FB7185;
  --white: #FFFFFF;
  --grey-50: #F9FAFB;
  --grey-100: #F3F4F6;
  --grey-200: #E5E7EB;
  --grey-400: #9CA3AF;
  --grey-500: #6B7280;
  --grey-700: #374151;
  --grey-800: #1F2937;
  --grey-900: #111827;

  /* Glass - Enhanced Frosted Look */
  --glass-bg: rgba(255, 255, 255, 0.22);
  --glass-bg-sidebar: rgba(255, 255, 255, 0.28);
  --glass-blur: 28px;
  --glass-border: linear-gradient(135deg, rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0.05));

  /* Shadows - Subtle for Glass */
  --shadow-card: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
  --shadow-hover: 0 12px 40px 0 rgba(31, 38, 135, 0.25);

  /* Spacing */
  --gap: 22px;

  /* Radius */
  --radius: 18px;
  --radius-sm: 12px;
  --radius-pill: 999px;

  /* Font */
  --font-sans: 'Inter', 'Segoe UI Variable', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'Cascadia Code', 'Consolas', monospace;

  /* Sidebar */
  --sidebar-w: 260px;

  /* Transitions */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── Body ── */
html,
body {
  height: 100%;
  font-family: var(--font-sans);
  font-weight: 400;
  color: var(--grey-800);
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

body {
  display: flex;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  background-color: #e0f5ec;
  background-image:
    radial-gradient(ellipse 80% 60% at 5% 10%, hsla(160, 65%, 75%, 0.9) 0%, transparent 55%),
    radial-gradient(ellipse 50% 70% at 85% 15%, hsla(190, 50%, 82%, 0.8) 0%, transparent 50%),
    radial-gradient(ellipse 60% 50% at 40% 80%, hsla(145, 55%, 70%, 0.7) 0%, transparent 50%),
    radial-gradient(ellipse 70% 55% at 95% 75%, hsla(170, 45%, 78%, 0.6) 0%, transparent 50%),
    radial-gradient(ellipse 45% 80% at 20% 45%, hsla(175, 60%, 85%, 0.5) 0%, transparent 55%),
    radial-gradient(ellipse 90% 40% at 60% 30%, hsla(155, 40%, 88%, 0.6) 0%, transparent 50%),
    linear-gradient(160deg, hsla(165, 50%, 90%, 1) 0%, hsla(180, 35%, 85%, 1) 30%, hsla(150, 45%, 82%, 1) 60%, hsla(170, 40%, 88%, 1) 100%);
  background-size: 200% 200%;
  animation: liquid-gradient 20s ease-in-out infinite alternate;
  background-attachment: fixed;
}

@keyframes liquid-gradient {
  0% {
    background-position: 0% 0%;
    filter: hue-rotate(0deg) brightness(1);
  }

  25% {
    background-position: 50% 25%;
    filter: hue-rotate(5deg) brightness(1.02);
  }

  50% {
    background-position: 100% 50%;
    filter: hue-rotate(10deg) brightness(1);
  }

  75% {
    background-position: 50% 75%;
    filter: hue-rotate(5deg) brightness(0.98);
  }

  100% {
    background-position: 100% 100%;
    filter: hue-rotate(12deg) brightness(1.01);
  }
}

/* ── Reveal-light cursor effect ── */
.reveal-light {
  position: fixed;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.35) 0%, transparent 70%);
  transform: translate(-50%, -50%);
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.25s ease;
  mix-blend-mode: soft-light;
}

/* ═══════════════════════════════════════════════════════
   GLASS PANEL — shared style
   ═══════════════════════════════════════════════════════ */
.glass-panel {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  transition:
    transform 0.4s var(--ease-smooth),
    box-shadow 0.4s var(--ease-smooth),
    background 0.4s var(--ease-smooth);
  will-change: transform, box-shadow;
}

.glass-panel:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  background: rgba(255, 255, 255, 0.32);
}

.glass-panel:active {
  transform: scale(0.98);
  transition-duration: 0.12s;
}

/* Specific border accents for glass depth */
.glass-panel {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border-radius: 28px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow:
    0 8px 32px 0 rgba(0, 0, 0, 0.05),
    inset 0 0 0 1px rgba(255, 255, 255, 0.1);
  transition: transform 0.4s var(--ease-smooth), box-shadow 0.4s var(--ease-smooth), border-color 0.4s var(--ease-smooth);
}

.glass-panel:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow:
    0 12px 40px rgba(0, 0, 0, 0.08),
    0 0 20px rgba(52, 211, 153, 0.15);
  border-color: rgba(52, 211, 153, 0.4);
}

/* ═══════════════════════════════════════════════════════
   SIDEBAR — Floating squircle
   ═══════════════════════════════════════════════════════ */
.sidebar {
  position: fixed;
  left: 20px;
  top: 20px;
  bottom: 20px;
  width: var(--sidebar-w);
  display: flex;
  flex-direction: column;
  padding: 28px 16px 24px;
  z-index: 100;

  /* Glass fill — slightly more opaque than cards */
  background: var(--glass-bg-sidebar);
  backdrop-filter: blur(35px);
  -webkit-backdrop-filter: blur(35px);

  /* Squircle shape via large smooth radius */
  border-radius: 32px;

  /* Crystal border */
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-top: 1px solid rgba(255, 255, 255, 0.50);
  border-left: 1px solid rgba(255, 255, 255, 0.50);

  /* Shadow */
  box-shadow:
    0 8px 40px rgba(0, 0, 0, 0.08),
    0 1.5px 0 rgba(255, 255, 255, 0.35) inset;

  /* Buttery transition */
  transition:
    box-shadow 0.5s var(--ease-smooth),
    background 0.5s var(--ease-smooth);
  will-change: box-shadow, background;
}

.sidebar:hover {
  box-shadow:
    0 12px 48px rgba(0, 0, 0, 0.12),
    0 1.5px 0 rgba(255, 255, 255, 0.45) inset;
  background: rgba(255, 255, 255, 0.38);
}

/* Logo */
.sidebar__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  padding: 0 6px;
}

.sidebar__logo-icon {
  width: 34px;
  height: 34px;
  object-fit: contain;
  border-radius: 4px;
}

.sidebar__logo-text {
  font-size: 1.15rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--mint-400), var(--teal-500));
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Nav links */
.sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.sidebar__link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  border-radius: var(--radius-pill);
  color: var(--grey-700);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  position: relative;

  /* Creative glass border */
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-top: 1px solid rgba(255, 255, 255, 0.4);
  border-left: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);

  transition:
    background 0.35s var(--ease-smooth),
    color 0.35s var(--ease-smooth),
    transform 0.35s var(--ease-smooth),
    box-shadow 0.35s var(--ease-smooth),
    border-color 0.35s var(--ease-smooth),
    backdrop-filter 0.35s var(--ease-smooth);
  will-change: transform, background;
}

.sidebar__link:hover {
  background: rgba(52, 211, 153, 0.12);
  color: var(--grey-900);
  transform: translateX(3px);
  border-top-color: rgba(52, 211, 153, 0.30);
  border-left-color: rgba(52, 211, 153, 0.20);
  box-shadow: 0 2px 12px rgba(52, 211, 153, 0.10);
}

.sidebar__link:active {
  transform: scale(0.97);
  transition-duration: 0.1s;
}

.sidebar__link--active {
  background: linear-gradient(135deg, #1B9B73, #0E8A6E);
  color: var(--white);
  box-shadow: 0 3px 16px rgba(52, 211, 153, 0.35);
  border-color: rgba(255, 255, 255, 0.30);
  border-top-color: rgba(255, 255, 255, 0.50);
}

.sidebar__link--active:hover {
  background: linear-gradient(135deg, #1B9B73, #0E8A6E);
  color: var(--white);
  transform: translateX(3px);
  border-color: rgba(255, 255, 255, 0.35);
}

.sidebar__link--active .sidebar__icon {
  fill: var(--white);
  stroke: var(--white);
}

.sidebar__icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
  transition: stroke 0.35s var(--ease-smooth);
}

/* ── Bottom section (Settings) ── */
.sidebar__bottom {
  margin-top: auto;
}

.sidebar__divider {
  height: 1.5px;
  margin: 12px 10px 14px;
  border-radius: 2px;
  background: linear-gradient(90deg,
      transparent 0%,
      rgba(52, 211, 153, 0.5) 30%,
      rgba(45, 212, 191, 0.7) 50%,
      rgba(52, 211, 153, 0.5) 70%,
      transparent 100%);
  box-shadow:
    0 0 8px rgba(52, 211, 153, 0.40),
    0 0 20px rgba(52, 211, 153, 0.15);
  animation: divider-glow 3s ease-in-out infinite alternate;
}

@keyframes divider-glow {
  0% {
    opacity: 0.6;
    box-shadow: 0 0 6px rgba(52, 211, 153, 0.30), 0 0 16px rgba(52, 211, 153, 0.10);
  }

  100% {
    opacity: 1;
    box-shadow: 0 0 10px rgba(52, 211, 153, 0.50), 0 0 28px rgba(52, 211, 153, 0.20);
  }
}

/* ═══════════════════════════════════════════════════════
   MAIN
   ═══════════════════════════════════════════════════════ */
.main {
  margin-left: calc(var(--sidebar-w) + 20px);
  flex: 1;
  padding: 24px 32px 32px;
  display: flex;
  flex-direction: column;
  height: 100vh;
  box-sizing: border-box;
  overflow-y: overlay;
}

/* Header */
.main__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.main__greeting {
  font-size: 0.95rem;
  color: var(--grey-500);
  margin-bottom: 4px;
}

.main__greeting strong {
  color: var(--grey-800);
  font-weight: 600;
}

.main__title {
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--grey-900);
  letter-spacing: -0.5px;
}

.main__header-right {
  display: flex;
  gap: 10px;
  align-items: center;
}

/* Icon button */
.btn {
  cursor: pointer;
  border: none;
  font-family: inherit;
}

.btn--icon {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: grid;
  place-items: center;
  transition: all 0.2s var(--ease-out);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-top: 1px solid rgba(255, 255, 255, 0.45);
  border-left: 1px solid rgba(255, 255, 255, 0.45);
}

.btn--icon svg {
  width: 18px;
  height: 18px;
  stroke: var(--grey-700);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.btn--icon:hover {
  background: rgba(255, 255, 255, 0.7);
  transform: translateY(-1px);
}

.btn__badge {
  position: absolute;
  top: -2px;
  right: -2px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--rose-400);
  color: var(--white);
  font-size: 0.6rem;
  font-weight: 700;
  display: grid;
  place-items: center;
}

/* Primary button */
.btn--primary {
  padding: 10px 22px;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, var(--mint-400), var(--teal-400));
  color: var(--white);
  font-weight: 600;
  font-size: 0.85rem;
  box-shadow: 0 2px 14px rgba(52, 211, 153, 0.30);
  transition: all 0.25s var(--ease-out);
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(52, 211, 153, 0.40);
}

.btn--primary:active {
  transform: scale(0.96);
  transition-duration: 0.08s;
}

/* ═══════════════════════════════════════════════════════
   GRID
   ═══════════════════════════════════════════════════════ */
.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-template-rows: auto auto auto;
  gap: 16px;
  flex: 1;
}

/* Base card layout spans */
.grid__activity {
  grid-column: span 3;
}

.grid__meeting {
  grid-column: span 6;
}

.grid__date {
  grid-column: span 3;
  grid-row: span 2;
}

.grid__clock {
  grid-column: span 3;
}

.grid__revenue {
  grid-column: span 7;
}

.grid__performance {
  grid-column: span 3;
}

/* Transitions & Smoothness */
* {
  transition: background-color 0.3s var(--ease-smooth), border-color 0.3s var(--ease-smooth), box-shadow 0.3s var(--ease-smooth);
}

.grid__customers {
  grid-column: span 5;
}

/* New objects */
.grid__progress {
  grid-column: span 3;
}

.grid__tasks {
  grid-column: span 7;
}

.grid__workload {
  grid-column: span 5;
}

/* ═══════════════════════════════════════════════════════
   CARDS
   ═══════════════════════════════════════════════════════ */
.card {
  padding: 22px 24px;
}

.card__title {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--grey-500);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 14px;
}

/* Activity */
.card__activity-row {
  display: flex;
  gap: 28px;
  align-items: flex-end;
}

.card__activity-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.card__big-number {
  font-size: 2.6rem;
  font-weight: 700;
  line-height: 1;
  color: var(--grey-900);
}

.card__activity-label {
  font-size: 0.8rem;
  color: var(--grey-500);
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Dots */
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.dot--green {
  background: var(--mint-400);
  box-shadow: 0 0 6px var(--mint-400);
}

.dot--grey {
  background: var(--grey-400);
}

/* Meeting */
.card__meeting-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.card__text {
  font-size: 0.92rem;
  color: var(--grey-700);
  margin-top: 6px;
}

.card__join-btn {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s var(--ease-out);
}

.card.grid__meeting:hover .card__join-btn {
  opacity: 1;
  pointer-events: auto;
}

/* Pulse */
.pulse-text {
  color: var(--mint-500);
  animation: pulse-color 2s ease-in-out infinite;
}

@keyframes pulse-color {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.5;
  }
}

/* Date & Reminders */
.card__date-display {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--grey-800);
  margin-bottom: 16px;
}

.card__subtitle {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--grey-400);
  margin-bottom: 8px;
}

.card__reminder-section {
  margin-bottom: 14px;
}

.card__reminder-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--grey-800);
}

.card__avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--white);
}

.card__avatar--teal {
  background: linear-gradient(135deg, var(--teal-400), var(--mint-400));
}

.card__avatar--rose {
  background: linear-gradient(135deg, var(--rose-400), #F472B6);
}

/* Clock */
.card__clock-display {
  display: block;
  font-family: var(--font-mono);
  font-size: 2.5rem;
  font-weight: 500;
  letter-spacing: 2px;
  color: var(--grey-900);
  text-align: center;
  margin-top: 10px;
}

/* Chart cards */
.card__chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card__tag {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--grey-500);
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  padding: 3px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

canvas {
  width: 100% !important;
  height: 220px !important;
}

/* ═══════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════ */
@media (max-width: 1280px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid__activity,
  .grid__meeting,
  .grid__date,
  .grid__clock,
  .grid__revenue,
  .grid__customers,
  .grid__progress,
  .grid__tasks,
  .grid__workload {
    grid-column: span 1;
    grid-row: auto;
  }
}

@media (max-width: 768px) {
  :root {
    --sidebar-w: 280px;
  }

  .sidebar {
    transform: translateX(-110%);
    left: 10px;
    top: 10px;
    bottom: 10px;
    transition: transform 0.5s var(--ease-smooth);
  }

  body.sidebar-open .sidebar {
    transform: translateX(0);
  }

  /* Overlay when sidebar open */
  body.sidebar-open::after {
    content: '';
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(4px);
    z-index: 90;
  }

  .main {
    margin-left: 0;
    padding: 20px 16px 40px;
    -webkit-overflow-scrolling: touch;
  }

  .main__header {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  /* Ensure new widgets stack correctly on mobile */
  .grid__performance,
  .grid__revenue,
  .grid__customers,
  .grid__tasks,
  .grid__workload {
    grid-column: span 1 !important;
  }

  .btn--menu {
    display: grid !important;
  }

  /* Centered/Narrow-optimized Notifications on Mobile */
  .notifications-popup {
    width: calc(100vw - 32px);
    max-width: 360px;
    right: -16px;
    /* Offset to center better on screen */
    transform-origin: top right;
  }

  .main__header {
    padding: 0 0 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    margin-bottom: 24px;
  }

  .header-right {
    width: 100%;
    justify-content: space-between;
    gap: 8px;
  }

  .search-container {
    flex: 1;
    max-width: none;
  }
}

@media (max-width: 480px) {
  .notifications-popup {
    position: fixed;
    top: 70px;
    left: 16px;
    right: 16px;
    width: auto;
    max-width: none;
    transform-origin: top center;
  }

  .card__clock-display {
    font-size: 2rem;
  }
}

/* ═══════════════════════════════════════════════════════
   SCROLLBAR
   ═══════════════════════════════════════════════════════ */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--grey-200);
  border-radius: 10px;
}

/* ═══════════════════════════════════════════════════════
   TREND INSIGHTS
   ═══════════════════════════════════════════════════════ */
.card__trend {
  font-size: 0.68rem;
  font-weight: 600;
  margin-top: 2px;
}

.card__trend--up {
  color: var(--mint-500);
}

.card__trend--down {
  color: var(--grey-400);
}

/* ═══════════════════════════════════════════════════════
   CLOCK META
   ═══════════════════════════════════════════════════════ */
.card__clock-meta {
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(0, 0, 0, 0.04);
}

.card__clock-location,
.card__clock-weather {
  font-size: 0.72rem;
  color: var(--grey-400);
  font-weight: 500;
}

/* ═══════════════════════════════════════════════════════
   THEME TOGGLE
   ═══════════════════════════════════════════════════════ */
#btn-theme .icon-moon {
  display: none;
}

[data-theme="dark"] #btn-theme .icon-sun {
  display: none;
}

[data-theme="dark"] #btn-theme .icon-moon {
  display: block;
}

/* ═══════════════════════════════════════════════════════
   RAIN CONTAINER
   ═══════════════════════════════════════════════════════ */
.rain-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.raindrop {
  position: absolute;
  width: 3px;
  border-radius: 50% 50% 50% 50%;
  background: linear-gradient(180deg, rgba(52, 211, 153, 0.12) 0%, rgba(52, 211, 153, 0.03) 100%);
  opacity: 0;
  animation: raindrop-fall linear infinite;
  filter: blur(0.5px);
}

@keyframes raindrop-fall {
  0% {
    transform: translateY(-20px);
    opacity: 0;
  }

  10% {
    opacity: 0.6;
  }

  90% {
    opacity: 0.3;
  }

  100% {
    transform: translateY(105vh);
    opacity: 0;
  }
}

/* ═══════════════════════════════════════════════════════
   NOTIFICATIONS POPUP
   ═══════════════════════════════════════════════════════ */
.notifications-container {
  position: relative;
}

.notifications-popup {
  position: absolute;
  top: calc(100% + 15px);
  right: 0;
  width: 320px;
  padding: 20px;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  background: rgba(255, 255, 255, 0.85);
  /* Reduced transparency */
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
  transform: translateY(10px) scale(0.95);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  transform-origin: top right;
}

.notifications-popup--active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.notifications-popup__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.notifications-popup__title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--grey-900);
}

.notifications-popup__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.notification-item {
  display: flex;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.3);
  transition: background 0.3s ease;
  cursor: pointer;
}

.notification-item:hover {
  background: rgba(255, 255, 255, 0.5);
}

.notification-item--new {
  box-shadow: inset 0 0 0 1px rgba(52, 211, 153, 0.2);
}

.notification-item__icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.notification-item__icon--mint {
  background: rgba(52, 211, 153, 0.15);
  color: #059669;
}

.notification-item__icon--blue {
  background: rgba(59, 130, 246, 0.15);
  color: #2563EB;
}

.notification-item__icon--teal {
  background: rgba(20, 184, 166, 0.15);
  color: #0D9488;
}

.notification-item__icon svg {
  width: 20px;
  height: 20px;
}

.notification-item__content {
  flex: 1;
}

.notification-item__text {
  font-size: 0.85rem;
  line-height: 1.4;
  margin-bottom: 4px;
}

.notification-item__time {
  font-size: 0.75rem;
  color: var(--grey-500);
}

.notifications-popup__footer {
  margin-top: 20px;
  text-align: center;
}

.notifications-popup__view-all {
  font-size: 0.85rem;
  color: var(--mint-600);
  font-weight: 600;
  text-decoration: none;
}

/* ═══════════════════════════════════════════════════════
   SPARK LINES & MICRO VISUALS
   ═══════════════════════════════════════════════════════ */
.sparkline {
  height: 20px;
  width: 100%;
  margin: 6px 0;
  opacity: 0.6;
}

.sparkline--green {
  color: var(--mint-500);
}

.sparkline--grey {
  color: var(--grey-400);
}

.pulse-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--mint-400);
  border-radius: 50%;
  margin-right: 4px;
  animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.4);
  }

  70% {
    transform: scale(1.1);
    box-shadow: 0 0 0 6px rgba(52, 211, 153, 0);
  }

  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0);
  }
}

.card__clock-display {
  font-family: 'JetBrains Mono', monospace;
  font-size: 2.4rem;
  letter-spacing: -1px;
  text-shadow: 0 0 20px rgba(52, 211, 153, 0.2);
  color: var(--grey-900);
}

/* ═══════════════════════════════════════════════════════
   PERFORMANCE WIDGET
   ═══════════════════════════════════════════════════════ */
.card__performance-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.performance-item__label {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--grey-600);
  margin-bottom: 4px;
}

.performance-item__value {
  color: var(--grey-800);
  font-weight: 600;
}

.performance-bar {
  height: 6px;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 10px;
  overflow: hidden;
}

.performance-bar__fill {
  height: 100%;
  background: linear-gradient(90deg, var(--mint-400), var(--teal-400));
  border-radius: 10px;
}

/* ═══════════════════════════════════════════════════════
   STAGGERED ENTRY ANIMATION (Sell the feel)
   ═══════════════════════════════════════════════════════ */
.glass-panel {
  opacity: 0;
  animation: card-reveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes card-reveal {
  0% {
    opacity: 0;
    transform: translateY(30px) scale(0.96);
    filter: blur(10px);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

/* Stagger delays */
#card-activity {
  animation-delay: 0.1s;
}

#card-meeting {
  animation-delay: 0.15s;
}

#card-date {
  animation-delay: 0.2s;
}

#card-clock {
  animation-delay: 0.25s;
}

#card-performance {
  animation-delay: 0.3s;
}

#card-progress {
  animation-delay: 0.35s;
}

#card-tasks {
  animation-delay: 0.4s;
}

#card-workload {
  animation-delay: 0.45s;
}

#card-revenue {
  animation-delay: 0.5s;
}

#card-customers {
  animation-delay: 0.55s;
}

/* ═══════════════════════════════════════════════════════
   DARK MODE — ECLIPSE
   ═══════════════════════════════════════════════════════ */
[data-theme="dark"] {
  /* Background */
  --bg-gradient-start: #0F1419;
  --bg-gradient-end: #1A1F2E;

  /* Glass overrides */
  --glass-bg: rgba(30, 30, 30, 0.60);
  --glass-bg-sidebar: rgba(25, 25, 30, 0.75);

  /* Text */
  --grey-50: #1A1F2E;
  --grey-100: #1E2330;
  --grey-200: #2A2F3E;
  --grey-400: #6B7280;
  --grey-500: #9CA3AF;
  --grey-700: #D1D5DB;
  --grey-800: #E5E7EB;
  --grey-900: #F9FAFB;

  /* Shadows */
  --shadow-card: 0 4px 30px rgba(0, 0, 0, 0.25);
  --shadow-hover: 0 8px 40px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] body {
  background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
  color: var(--grey-800);
}

[data-theme="dark"] .glass-panel {
  border-color: rgba(52, 211, 153, 0.08);
  border-top-color: rgba(52, 211, 153, 0.15);
  border-left-color: rgba(52, 211, 153, 0.10);
  border-right-color: rgba(52, 211, 153, 0.04);
  border-bottom-color: rgba(52, 211, 153, 0.03);
  box-shadow:
    var(--shadow-card),
    0 0 1px rgba(52, 211, 153, 0.10) inset;
}

[data-theme="dark"] .glass-panel:hover {
  background: rgba(35, 35, 40, 0.72);
  box-shadow:
    var(--shadow-hover),
    0 0 20px rgba(52, 211, 153, 0.06);
}

/* Sidebar dark */
[data-theme="dark"] .sidebar {
  background: var(--glass-bg-sidebar);
  border-color: rgba(52, 211, 153, 0.08);
  border-top-color: rgba(52, 211, 153, 0.14);
  box-shadow:
    0 8px 40px rgba(0, 0, 0, 0.30),
    0 0 1px rgba(52, 211, 153, 0.15) inset;
}

[data-theme="dark"] .sidebar:hover {
  background: rgba(28, 28, 35, 0.80);
}

[data-theme="dark"] .sidebar__link {
  border-color: rgba(52, 211, 153, 0.06);
  border-top-color: rgba(52, 211, 153, 0.12);
  background: rgba(255, 255, 255, 0.03);
  color: var(--grey-700);
}

[data-theme="dark"] .sidebar__link:hover {
  background: rgba(52, 211, 153, 0.10);
  border-top-color: rgba(52, 211, 153, 0.25);
}

[data-theme="dark"] .sidebar__link--active {
  background: linear-gradient(135deg, #1B9B73, #0E8A6E);
  border-color: rgba(52, 211, 153, 0.25);
  box-shadow: 0 3px 20px rgba(52, 211, 153, 0.25);
}

[data-theme="dark"] .sidebar__divider {
  box-shadow:
    0 0 10px rgba(52, 211, 153, 0.50),
    0 0 30px rgba(52, 211, 153, 0.20);
}

/* Buttons dark */
[data-theme="dark"] .btn--icon {
  background: rgba(30, 30, 30, 0.50);
  border-color: rgba(52, 211, 153, 0.10);
}

[data-theme="dark"] .btn--icon svg {
  stroke: var(--grey-700);
}

[data-theme="dark"] .btn--icon:hover {
  background: rgba(52, 211, 153, 0.12);
}

/* Cards dark neon glow */
[data-theme="dark"] .card__big-number {
  color: var(--grey-900);
}

[data-theme="dark"] .dot--green {
  box-shadow: 0 0 8px var(--mint-400), 0 0 16px rgba(52, 211, 153, 0.20);
}

[data-theme="dark"] .card__clock-meta {
  border-top-color: rgba(255, 255, 255, 0.06);
}

/* Reveal light dark */
[data-theme="dark"] .reveal-light {
  background: radial-gradient(circle, rgba(52, 211, 153, 0.12) 0%, transparent 70%);
  mix-blend-mode: screen;
}

/* Raindrop dark */
[data-theme="dark"] .raindrop {
  background: linear-gradient(180deg, rgba(52, 211, 153, 0.18) 0%, rgba(52, 211, 153, 0.04) 100%);
}

/* Scrollbar dark */
[data-theme="dark"] ::-webkit-scrollbar-thumb {
  background: rgba(52, 211, 153, 0.15);
}

/* ── Page Loader ──────────────────────────────────────── */
.page-loader {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: #e0f5ec;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 400ms ease;
}

.page-loader.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.page-loader__spinner {
  width: 36px;
  height: 36px;
  border: 2px solid rgba(52, 211, 153, 0.2);
  border-top-color: var(--mint-400);
  border-radius: 50%;
  animation: loaderSpin 0.75s linear infinite;
}

@keyframes loaderSpin {
  to { transform: rotate(360deg); }
}