/* ==========================================================================
   STUDENT MANAGEMENT & ATTENDANCE SYSTEM (SMAS) - IIEC CSMU
   Novish Studio Visual Design & Animation System
   ========================================================================== */

/* 1. GOOGLE FONTS IMPORT */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400;1,600&family=Cormorant+Garamond:ital,wght@0,400;0,600;1,400;1,600&family=Inter:wght@300;400;500;600;700&display=swap');

/* 2. BRAND COLOR PALETTE & VARIABLES */
:root {
  --bg: #F7F2EB;           /* Warm Cream (Primary Background) */
  --bgAlt: #EFE8DF;        /* Alabaster Cream (Secondary/Alternative Background) */
  --accent: #6E0D0D;       /* Novish Maroon (Primary Accent / Brand Color) */
  --accent-hover: #8C1515; /* Bright Maroon (Hover & Active Accent states) */
  --text: #1A1A1A;         /* Off-Black Charcoal (Body and Headings Text) */
  --text-muted: #5B5B5B;   /* Medium Grey (Subtext and Muted Elements) */
  --border: #E6DDD3;       /* Warm Beige Border (Dividers, card outlines) */
  --card: #FFFFFF;         /* White (Card backgrounds) */
  --cream: #F7F2EB;        /* Helper cream variable */

  /* Legacy & Attendance Status Colors */
  --primary-color: #6E0D0D;
  --primary-hover: #8C1515;
  --secondary-color: #1A1A1A;
  
  --color-present: #10b981;
  --bg-present: rgba(16, 185, 129, 0.12);
  --color-absent: #ef4444;
  --bg-absent: rgba(239, 68, 68, 0.12);
  --color-late: #d97706;
  --bg-late: rgba(217, 119, 6, 0.12);
  --color-leave: #2563eb;
  --bg-leave: rgba(37, 99, 235, 0.12);
  --color-excused: #6b7280;
  --bg-excused: rgba(107, 114, 128, 0.12);

  /* Shadows & Radius */
  --shadow-sm: 0 2px 4px rgba(26, 26, 26, 0.05);
  --shadow-md: 0 12px 24px rgba(26, 26, 26, 0.08);
  --shadow-lg: 0 24px 48px rgba(110, 13, 13, 0.10); /* Maroon shadow bloom */

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-full: 9999px;

  --transition-fast: all 0.2s cubic-bezier(0.25, 1, 0.5, 1);
  --transition-smooth: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

/* 3. BASE STYLES & RESET */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  line-height: 1.6;
}

body.loading {
  overflow: hidden;
}

/* Headings Typography Scale (Serif Titles) */
h1, h2, h3, .h-serif {
  font-family: 'Playfair Display', serif;
  color: var(--text);
}

.h1-display {
  font-family: 'Playfair Display', serif;
  font-size: clamp(52px, 8vw, 112px);
  line-height: 1;
  letter-spacing: -0.03em;
}

.h1-medium {
  font-family: 'Playfair Display', serif;
  font-size: clamp(48px, 7.5vw, 104px);
  line-height: 1;
  letter-spacing: -0.03em;
}

.h1-hero {
  font-family: 'Playfair Display', serif;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.1;
  letter-spacing: -0.025em;
  font-weight: 700;
}

.h2-section {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.h2-mid {
  font-family: 'Playfair Display', serif;
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1.2;
}

/* Paragraphs & Lead Text */
.lead {
  font-family: 'Inter', sans-serif;
  font-size: 18px;
  line-height: 1.7;
  color: var(--text-muted);
}

p {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  line-height: 1.65;
}

/* Editorial Italics (Cormorant Garamond) */
em.serif-em {
  font-family: 'Cormorant Garamond', serif;
  color: var(--accent);
  font-style: italic;
  font-weight: 600;
}

em.serif-em-light {
  font-family: 'Cormorant Garamond', serif;
  color: var(--bgAlt);
  opacity: 0.85;
  font-style: italic;
}

/* Eyebrows (Small uppercase section tags) */
.eyebrow {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 12px;
}

/* 4. LAYOUT CONTAINERS & GRIDS */
.container {
  max-width: 1440px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

@media (min-width: 768px) {
  .container {
    padding-left: 40px;
    padding-right: 40px;
  }
}

.narrow {
  max-width: 1100px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

.grid {
  display: grid;
  gap: 24px;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 768px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
}

.grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 768px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

.grid-12 {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 24px;
}
@media (min-width: 1024px) {
  .grid-12 { grid-template-columns: repeat(12, 1fr); }
  .col-span-3 { grid-column: span 3; }
  .col-span-4 { grid-column: span 4; }
  .col-span-5 { grid-column: span 5; }
  .col-span-6 { grid-column: span 6; }
  .col-span-7 { grid-column: span 7; }
  .col-span-8 { grid-column: span 8; }
}

/* 5. PRELOADER (WIND SPEEDER ANIMATION) */
.preloader-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-color: var(--bg);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s ease, visibility 0.5s ease;
  overflow: hidden;
}

.preloader-overlay.fade-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-overlay .loader {
  position: absolute;
  top: 50%; left: 50%;
  margin-left: -50px;
  animation: speeder 0.4s linear infinite;
}

.preloader-overlay .loader > span {
  height: 5px; width: 35px;
  background: var(--accent);
  position: absolute;
  top: -19px; left: 60px;
  border-radius: 2px 10px 1px 0;
}

.preloader-overlay .base span {
  position: absolute;
  width: 0; height: 0;
  border-top: 6px solid transparent;
  border-right: 100px solid var(--accent);
  border-bottom: 6px solid transparent;
}

.preloader-overlay .base span:before {
  content: "";
  height: 22px; width: 22px;
  border-radius: 50%;
  background: var(--accent);
  position: absolute;
  right: -110px; top: -16px;
}

.preloader-overlay .base span:after {
  content: "";
  position: absolute;
  width: 0; height: 0;
  border-top: 0 solid transparent;
  border-right: 55px solid var(--accent);
  border-bottom: 16px solid transparent;
  top: -16px; right: -98px;
}

.preloader-overlay .face {
  position: absolute;
  height: 12px; width: 20px;
  background: var(--accent);
  border-radius: 20px 20px 0 0;
  transform: rotate(-40deg);
  right: -125px; top: -15px;
}

.preloader-overlay .face:after {
  content: "";
  height: 12px; width: 12px;
  background: var(--accent);
  right: 4px; top: 7px;
  position: absolute;
  transform: rotate(40deg);
  transform-origin: 50% 50%;
  border-radius: 0 0 0 2px;
}

.preloader-overlay .loader > span > span:nth-child(1),
.preloader-overlay .loader > span > span:nth-child(2),
.preloader-overlay .loader > span > span:nth-child(3),
.preloader-overlay .loader > span > span:nth-child(4) {
  width: 30px; height: 1px;
  background: var(--accent);
  position: absolute;
  animation: fazer1 0.2s linear infinite;
}
.preloader-overlay .loader > span > span:nth-child(2) { top: 3px; animation: fazer2 0.4s linear infinite; }
.preloader-overlay .loader > span > span:nth-child(3) { top: 1px; animation: fazer3 0.4s linear infinite; animation-delay: -1s; }
.preloader-overlay .loader > span > span:nth-child(4) { top: 4px; animation: fazer4 1s linear infinite; animation-delay: -1s; }

.preloader-overlay .longfazers {
  position: absolute;
  width: 100%; height: 100%;
}
.preloader-overlay .longfazers span {
  position: absolute;
  height: 2px; width: 20%;
  background: var(--accent);
}
.preloader-overlay .longfazers span:nth-child(1) { top: 20%; animation: lf 0.6s linear infinite; animation-delay: -5s; }
.preloader-overlay .longfazers span:nth-child(2) { top: 40%; animation: lf2 0.8s linear infinite; animation-delay: -1s; }
.preloader-overlay .longfazers span:nth-child(3) { top: 60%; animation: lf3 0.6s linear infinite; }
.preloader-overlay .longfazers span:nth-child(4) { top: 80%; animation: lf4 0.5s linear infinite; animation-delay: -3s; }

/* Preloader Keyframes */
@keyframes speeder {
  0% { transform: translate(2px, 1px) rotate(0deg); }
  10% { transform: translate(-1px, -3px) rotate(-1deg); }
  20% { transform: translate(-2px, 0px) rotate(1deg); }
  30% { transform: translate(1px, 2px) rotate(0deg); }
  40% { transform: translate(1px, -1px) rotate(1deg); }
  50% { transform: translate(-1px, 3px) rotate(-1deg); }
  60% { transform: translate(-1px, 1px) rotate(0deg); }
  70% { transform: translate(3px, 1px) rotate(-1deg); }
  80% { transform: translate(-2px, -1px) rotate(1deg); }
  90% { transform: translate(2px, 1px) rotate(0deg); }
  100% { transform: translate(1px, -2px) rotate(-1deg); }
}

@keyframes fazer1 { 0% { left: 0; } 100% { left: -80px; opacity: 0; } }
@keyframes fazer2 { 0% { left: 0; } 100% { left: -100px; opacity: 0; } }
@keyframes fazer3 { 0% { left: 0; } 100% { left: -50px; opacity: 0; } }
@keyframes fazer4 { 0% { left: 0; } 100% { left: -150px; opacity: 0; } }

@keyframes lf { 0% { left: 200%; } 100% { left: -200%; opacity: 0; } }
@keyframes lf2 { 0% { left: 200%; } 100% { left: -200%; opacity: 0; } }
@keyframes lf3 { 0% { left: 200%; } 100% { left: -100%; opacity: 0; } }
@keyframes lf4 { 0% { left: 200%; } 100% { left: -100%; opacity: 0; } }

/* 6. TOP PROGRESS BAR LOADER */
.top-progress {
  position: fixed; 
  top: 0; left: 0; 
  z-index: 999999;
  height: 3px; 
  width: 0%;
  background-color: var(--accent);
  opacity: 0; 
  pointer-events: none;
  box-shadow: 0 0 12px rgba(110, 13, 13, 0.55);
  transition: width 0.32s ease, opacity 0.38s ease;
}

/* 7. SCROLL REVEAL FADE-UP */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1), 
              transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

/* 8. BUTTONS & STAGGERED NOVISH WAVE HOVER */
.btn-primary, .btn-outline, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-full);
  padding: 12px 24px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
}

.btn-primary {
  background-color: var(--accent);
  color: var(--cream);
  border-color: var(--accent);
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  border-color: var(--accent-hover);
  transform: scale(1.03);
}

.btn-outline, .btn-secondary {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.btn-outline:hover, .btn-secondary:hover {
  background-color: var(--text);
  color: var(--cream);
  border-color: var(--text);
  transform: scale(1.03);
}

.btn-outline-danger {
  background: transparent;
  color: var(--color-absent);
  border-color: rgba(239, 68, 68, 0.3);
}

.btn-outline-danger:hover {
  background: var(--color-absent);
  color: #ffffff;
}

.btn-block {
  width: 100%;
}

.btn-primary svg, .btn-outline svg {
  transition: transform 0.3s;
}

.btn-primary:hover svg, .btn-outline:hover svg {
  transform: translate(2px, -2px);
}

/* Staggered Wave Button (.btn-novish) */
.btn-novish {
  -webkit-tap-highlight-color: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  position: relative;
  overflow: hidden;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 0.02em;
  padding: 12px 24px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), 
              background-color 0.3s, 
              border-color 0.3s;
}

.btn-novish:hover {
  transform: scale(1.03);
}

.btn-novish .original {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  inset: 0;
  position: absolute;
  transition: transform 0.4s cubic-bezier(0.87, 0, 0.13, 1);
  width: 100%;
  height: 100%;
}

.btn-novish .original svg {
  transition: transform 0.3s;
}

.btn-novish:hover .original {
  transform: translateY(100%);
}

.btn-novish:hover .original svg {
  transform: translate(2px, -2px);
}

.btn-novish .letters {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.btn-novish .letters span {
  display: inline-block;
  opacity: 0;
  transform: translateY(-15px);
  transition: transform 0.35s cubic-bezier(0.87, 0, 0.13, 1), opacity 0.3s;
  white-space: pre;
}

.btn-novish .letters span:nth-child(2n) {
  transform: translateY(15px);
}

.btn-novish:hover .letters span {
  opacity: 1;
  transform: translateY(0);
}

/* Wave Timing Delays */
.btn-novish:hover .letters span:nth-child(1) { transition-delay: 0s; }
.btn-novish:hover .letters span:nth-child(2) { transition-delay: 0.03s; }
.btn-novish:hover .letters span:nth-child(3) { transition-delay: 0.06s; }
.btn-novish:hover .letters span:nth-child(4) { transition-delay: 0.09s; }
.btn-novish:hover .letters span:nth-child(5) { transition-delay: 0.12s; }
.btn-novish:hover .letters span:nth-child(6) { transition-delay: 0.15s; }
.btn-novish:hover .letters span:nth-child(7) { transition-delay: 0.18s; }
.btn-novish:hover .letters span:nth-child(8) { transition-delay: 0.21s; }
.btn-novish:hover .letters span:nth-child(9) { transition-delay: 0.24s; }
.btn-novish:hover .letters span:nth-child(10) { transition-delay: 0.27s; }
.btn-novish:hover .letters span:nth-child(11) { transition-delay: 0.30s; }
.btn-novish:hover .letters span:nth-child(12) { transition-delay: 0.33s; }

.btn-novish-filled {
  background-color: var(--accent);
  border-color: var(--accent);
  color: var(--cream);
}
.btn-novish-filled .original {
  background-color: var(--accent);
  color: var(--cream);
}
.btn-novish-filled:hover {
  background-color: var(--text);
  border-color: var(--text);
  color: var(--cream);
}

.btn-novish-outline {
  background-color: transparent;
  border-color: var(--border);
  color: var(--text);
}
.btn-novish-outline .original {
  background-color: transparent;
  color: var(--text);
}
.btn-novish-outline:hover {
  background-color: var(--text);
  border-color: var(--text);
  color: var(--cream);
}
.btn-novish-outline .letters span {
  color: var(--cream);
}

/* 9. CARDS & ELEVATION BLOOM */
.svc-card, .glass-card, .glass-panel {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), 
              box-shadow 0.4s cubic-bezier(0.25, 1, 0.5, 1), 
              border-color 0.4s;
}

.svc-card:hover, .glass-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.svc-icon-wrap {
  width: 48px; height: 48px;
  border-radius: 9999px;
  display: flex; align-items: center; justify-content: center;
  background-color: var(--cream);
  border: 1px solid var(--border);
  margin-bottom: 16px;
  color: var(--accent);
  font-size: 20px;
}

/* 10. FLOATING ANIMATIONS */
.float-img-1 { animation: bobA 6s ease-in-out infinite; }
.float-img-2 { animation: bobB 5s ease-in-out infinite 0.5s; }
.float-card { animation: wobble 8s ease-in-out infinite; }

@keyframes bobA {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes bobB {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

@keyframes wobble {
  0%, 100% { transform: rotate(-1.5deg); }
  50% { transform: rotate(1.5deg); }
}

/* 11. FORM INPUT DESIGN (MINIMALIST UNDERLINE) */
.field, .form-group {
  display: block;
  margin-bottom: 20px;
}

.field-label, .form-group label {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
  display: block;
  margin-bottom: 6px;
}

.form-input, .field input, .field select, .field textarea {
  width: 100%;
  background: #ffffff;
  outline: none;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: var(--text);
  transition: border-color 0.3s, box-shadow 0.3s;
}

.form-input:focus, .field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(110, 13, 13, 0.1);
}

.password-input-wrapper {
  position: relative;
}

.password-input-wrapper .btn-icon-ghost {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
}

/* 12. AUTH / LOGIN VIEW */
.login-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background-color: var(--bg);
}

.login-card {
  width: 100%;
  max-width: 460px;
  border-radius: 20px;
  padding: 40px 32px;
  background: #ffffff;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
}

.login-header {
  text-align: center;
  margin-bottom: 28px;
}

.login-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 20px;
}

.logo-badge {
  font-weight: 700;
  font-size: 13px;
  padding: 6px 14px;
  border-radius: var(--radius-md);
  letter-spacing: 0.5px;
}

.csmu-logo {
  background: rgba(110, 13, 13, 0.08);
  color: var(--accent);
  border: 1px solid rgba(110, 13, 13, 0.2);
}

.iiec-logo {
  background: rgba(26, 26, 26, 0.08);
  color: var(--text);
  border: 1px solid rgba(26, 26, 26, 0.2);
}

.logo-divider {
  width: 1px;
  height: 20px;
  background: var(--border);
}

.login-header h2 {
  font-size: 22px;
  margin-bottom: 6px;
}

.login-subtitle {
  font-size: 13px;
  color: var(--text-muted);
}

.demo-credentials-note {
  margin-top: 24px;
  padding: 12px;
  background-color: var(--bgAlt);
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: var(--text-muted);
}

/* 13. APP SHELL & SIDEBAR */
.app-shell {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 270px;
  background-color: #ffffff;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease;
  z-index: 100;
}

.sidebar-header {
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
}

.brand-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-icon {
  width: 36px; height: 36px;
  border-radius: var(--radius-md);
  background-color: var(--accent);
  color: var(--cream);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}

.brand-text h3 {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  font-weight: 700;
}

.version-tag {
  font-size: 11px;
  color: var(--text-muted);
}

.user-profile-badge {
  padding: 16px 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--border);
  background-color: var(--bgAlt);
}

.avatar {
  width: 40px; height: 40px;
  border-radius: 9999px;
  background-color: var(--accent);
  color: var(--cream);
  display: flex; align-items: center; justify-content: center;
  font-weight: 600;
  font-size: 14px;
}

.user-details {
  display: flex;
  flex-direction: column;
}

.user-name {
  font-weight: 600;
  font-size: 14px;
}

.user-role {
  font-size: 11px;
  color: var(--accent);
  font-weight: 500;
}

.sidebar-nav {
  flex: 1;
  padding: 16px 0;
  overflow-y: auto;
}

.nav-list {
  list-style: none;
}

.nav-item {
  margin-bottom: 4px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 24px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
  border-left: 3px solid transparent;
}

.nav-link:hover, .nav-item.active .nav-link {
  color: var(--accent);
  background-color: rgba(110, 13, 13, 0.05);
  border-left-color: var(--accent);
}

.sidebar-footer {
  padding: 20px 24px;
  border-top: 1px solid var(--border);
}

/* 14. MAIN CONTENT & TOP HEADER */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.top-header {
  height: 72px;
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.page-title-heading h1 {
  font-size: 22px;
  font-weight: 700;
}

.page-title-heading p {
  font-size: 13px;
  color: var(--text-muted);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.api-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  background: var(--bgAlt);
  border: 1px solid var(--border);
}

.status-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #10b981;
}

.content-body {
  padding: 32px;
  flex: 1;
  overflow-y: auto;
}

/* 15. DASHBOARD STATS GRID & CHARTS */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 16px;
}

.stat-icon {
  width: 48px; height: 48px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
  background-color: rgba(110, 13, 13, 0.08);
  color: var(--accent);
}

.stat-value {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  font-weight: 700;
}

.stat-label {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.quick-actions-bar {
  margin-bottom: 28px;
}

.quick-actions-bar h4 {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  margin-bottom: 16px;
}

.quick-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.charts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-bottom: 28px;
}
@media (min-width: 1024px) {
  .charts-grid { grid-template-columns: 2fr 1fr; }
}

.chart-wrapper {
  position: relative;
  height: 280px;
  margin-top: 16px;
}

/* 16. DATA TABLES */
.table-responsive {
  width: 100%;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
  text-align: left;
}

.data-table th, .data-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

.data-table th {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  background-color: var(--bgAlt);
}

.data-table tr:hover {
  background-color: rgba(110, 13, 13, 0.02);
}

/* Status Badges */
.badge-status {
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  display: inline-block;
}

.badge-present { background: var(--bg-present); color: var(--color-present); }
.badge-absent { background: var(--bg-absent); color: var(--color-absent); }
.badge-late { background: var(--bg-late); color: var(--color-late); }
.badge-leave { background: var(--bg-leave); color: var(--color-leave); }
.badge-excused { background: var(--bg-excused); color: var(--color-excused); }

/* 17. TOAST NOTIFICATIONS */
.toast-container {
  position: fixed;
  top: 24px; right: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.toast {
  min-width: 280px;
  padding: 14px 20px;
  border-radius: var(--radius-md);
  background: #ffffff;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  display: flex; align-items: center; gap: 12px;
  font-size: 14px;
  animation: slideInRight 0.3s ease-out;
}

.toast-success { border-left: 4px solid var(--color-present); }
.toast-error { border-left: 4px solid var(--color-absent); }

@keyframes slideInRight {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* 18. UTILITY HELPERS & RESPONSIVE */
.hidden { display: none !important; }
.view-section { display: none; }
.view-section.active { display: block; }
.mobile-only { display: none; }

@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    top: 0; left: 0; bottom: 0;
    transform: translateX(-100%);
  }
  .sidebar.mobile-open {
    transform: translateX(0);
  }
  .mobile-only { display: inline-flex; }
  .content-body { padding: 16px; }
  .top-header { padding: 0 16px; }
}
