/* ==========================================================================
   OmniStudy Neo-SaaS / iOS Glassmorphic Design System
   Precision geometry, ambient lighting, zero UI emojis, floating island navbar
   ========================================================================== */

@import '/scripts/onboarding-funnel.css?v=20261003-r1';

:root {
  --omni-radius-hero: 26px;
  --omni-radius-card: 20px;
  --omni-radius-pill: 12px;
  --omni-stroke: rgba(226, 232, 240, 0.7);
  --omni-shadow-subtle: 0 1px 2px 0 rgba(0, 0, 0, 0.05), 0 4px 12px 0 rgba(0, 0, 0, 0.03);
  --omni-shadow-float: 0 10px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
  --omni-glass-bg: rgba(255, 255, 255, 0.85);
  --omni-blur: blur(16px);
  --omni-amber-streak: #d97706;
  --omni-red-heart: #e11d48;
  --omni-gem-cyan: #0284c7;
}

html.dark {
  --omni-stroke: rgba(255, 255, 255, 0.08);
  --omni-shadow-subtle: 0 1px 2px 0 rgba(0, 0, 0, 0.4), 0 4px 12px 0 rgba(0, 0, 0, 0.3);
  --omni-shadow-float: 0 12px 30px -4px rgba(0, 0, 0, 0.6);
  --omni-glass-bg: rgba(15, 23, 42, 0.85);
  --omni-amber-streak: #f59e0b;
  --omni-red-heart: #f43f5e;
  --omni-gem-cyan: #38bdf8;
}

/* ==========================================================================
   Zero-Emoji Status Bar
   ========================================================================== */
.omni-status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 12px 20px;
  background: var(--omni-glass-bg);
  backdrop-filter: var(--omni-blur);
  -webkit-backdrop-filter: var(--omni-blur);
  border: 1px solid var(--omni-stroke);
  border-radius: var(--omni-radius-hero);
  box-shadow: var(--omni-shadow-subtle);
  margin-bottom: 24px;
}

.omni-status-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--omni-radius-pill);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}
.omni-status-item:hover {
  background: rgba(0, 0, 0, 0.03);
  border-color: var(--omni-stroke);
}
html.dark .omni-status-item:hover {
  background: rgba(255, 255, 255, 0.05);
}

.omni-streak-pill {
  color: var(--omni-amber-streak);
}
.omni-heart-pill {
  color: var(--omni-red-heart);
}
.omni-gem-pill {
  color: var(--omni-gem-cyan);
}

/* Daily Goal Progress Ring Dial */
.omni-goal-dial {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
}
.omni-dial-ring {
  transform: rotate(-90deg);
  transform-origin: 50% 50%;
}
.omni-dial-circle-bg {
  stroke: var(--edu-line, rgba(226, 232, 240, 0.6));
}
.omni-dial-circle-fill {
  stroke: var(--edu-red, #e11d48);
  stroke-linecap: round;
  transition: stroke-dashoffset 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ==========================================================================
   4-Grid Core Metric Tiles
   ========================================================================== */
.omni-metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.omni-metric-tile {
  padding: 18px 20px;
  border-radius: var(--omni-radius-card);
  background: var(--omni-glass-bg);
  backdrop-filter: var(--omni-blur);
  -webkit-backdrop-filter: var(--omni-blur);
  border: 1px solid var(--omni-stroke);
  box-shadow: var(--omni-shadow-subtle);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.omni-metric-tile:hover {
  transform: translateY(-2px);
  box-shadow: var(--omni-shadow-float);
}

.omni-tile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  color: var(--edu-muted, #64748b);
  font-size: 12.5px;
  font-weight: 500;
}
.omni-tile-header .omni-vector-icon {
  font-size: 16px;
  color: var(--edu-text);
}

.omni-tile-value {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--edu-text, #0f172a);
}

.omni-tile-meta {
  font-size: 12px;
  color: var(--edu-muted, #64748b);
  margin-top: 4px;
}

/* ==========================================================================
   Weekly Competitive Division Leagues (Duolingo-Style)
   ========================================================================== */
.omni-leagues-panel {
  padding: 22px;
  border-radius: var(--omni-radius-card);
  background: var(--omni-glass-bg);
  backdrop-filter: var(--omni-blur);
  -webkit-backdrop-filter: var(--omni-blur);
  border: 1px solid var(--omni-stroke);
  box-shadow: var(--omni-shadow-subtle);
  margin-bottom: 24px;
}

.omni-leagues-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--omni-stroke);
}

.omni-tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.omni-tier-gold {
  background: rgba(245, 158, 11, 0.15);
  color: #d97706;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.omni-leaderboard-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 4px;
}
.omni-leaderboard-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 13.5px;
  background: var(--edu-surface);
  border: 1px solid transparent;
  transition: all 0.15s ease;
}
.omni-leaderboard-row.user-pinned {
  border: 1.5px solid var(--edu-red, #e11d48);
  background: rgba(225, 29, 72, 0.05);
  font-weight: 700;
}
.omni-zone-promotion {
  border-left: 3px solid #10b981;
}
.omni-zone-relegation {
  border-left: 3px solid #f59e0b;
}

/* ==========================================================================
   Active Subject Cards
   ========================================================================== */
.omni-subjects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

.omni-subject-card {
  padding: 22px;
  border-radius: var(--omni-radius-hero);
  background: var(--omni-glass-bg);
  backdrop-filter: var(--omni-blur);
  -webkit-backdrop-filter: var(--omni-blur);
  border: 1px solid var(--omni-stroke);
  box-shadow: var(--omni-shadow-subtle);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.omni-subject-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--omni-shadow-float);
}

/* ==========================================================================
   Floating Island Bottom Navbar (Mobile / Tablet)
   ========================================================================== */
.omni-floating-island-nav {
  display: none;
  position: fixed;
  bottom: calc(16px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  z-index: 999;
  height: 60px;
  width: calc(100% - 32px);
  max-width: 440px;
  background: var(--omni-glass-bg);
  backdrop-filter: var(--omni-blur);
  -webkit-backdrop-filter: var(--omni-blur);
  border: 1px solid var(--omni-stroke);
  border-radius: 30px;
  box-shadow: var(--omni-shadow-float);
  align-items: center;
  justify-content: space-around;
  padding: 0 10px;
}
.dark .omni-floating-island-nav {
  background: #0b1220;
  border-color: #26384f;
}

@media (max-width: 840px) {
  .omni-floating-island-nav {
    display: flex;
  }
  body.edu-menu-open .omni-floating-island-nav {
    display: none !important;
  }
  /* The fixed upgrade strip otherwise covers the essential bottom navigation. */
  body:has(.omni-floating-island-nav) #edu-sticky-ad-bar {
    display: none !important;
  }
  body.edu-has-bottom-nav {
    padding-bottom: calc(92px + env(safe-area-inset-bottom)) !important;
  }
}

.omni-island-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--edu-muted, #64748b);
  text-decoration: none;
  font-size: 10px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 20px;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.omni-floating-island-nav .omni-island-link {
  color: var(--edu-muted, #64748b) !important;
}
.omni-island-link .omni-vector-icon {
  font-size: 18px;
}
.omni-island-link .omni-ai-mark {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.08em;
  line-height: 26px;
}
.omni-island-link .omni-ai-mark span {
  font-size: 14px;
  font-weight: 800;
  transform: translateY(-5px);
}
.dark .omni-island-link .omni-ai-mark {
  color: inherit;
  border-color: transparent;
  background: transparent;
}
.omni-island-link.active,
.omni-island-link[aria-current="page"] {
  color: var(--edu-ink, #172033) !important;
  background: transparent;
  transform: none;
  font-weight: 800;
}

/* ==========================================================================
   Annotated Model Essays Styling
   ========================================================================== */
.essay-paragraph {
  line-height: 1.8;
  font-size: 15px;
  margin-bottom: 18px;
}

.essay-comment-blue {
  background: rgba(2, 132, 199, 0.12);
  color: inherit;
  border-bottom: 2px solid #0284c7;
  padding: 1px 3px;
  border-radius: 4px;
  cursor: help;
}

.essay-comment-green {
  background: rgba(16, 185, 129, 0.12);
  color: inherit;
  border-bottom: 2px solid #10b981;
  padding: 1px 3px;
  border-radius: 4px;
  cursor: help;
}

.essay-comment-purple {
  background: rgba(168, 85, 247, 0.12);
  color: inherit;
  border-bottom: 2px solid #a855f7;
  padding: 1px 3px;
  border-radius: 4px;
  cursor: help;
}

/* ==========================================================================
   Clean A4 Print Stylesheet
   ========================================================================== */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }
  .edu-rail,
  .study-top,
  .edu-mobile-topbar,
  .edu-sidebar-toggle,
  .omni-floating-island-nav,
  .omni-status-bar,
  .actions.print-hidden,
  .edu-premium-footer,
  #toast {
    display: none !important;
  }
  .panel {
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
  }
}
