/* ============================================
   FARUSAC Informe Mensual - Premium Design System v2.0
   Glassmorphism · Micro-animations · Modern UI
   ============================================ */

/* === CSS Variables / Design Tokens === */
:root {
  /* USAC Brand Colors — UNCHANGED */
  --usac-blue-darkest: #0d1b3e;
  --usac-blue-dark: #152654;
  --usac-blue: #1a3a6b;
  --usac-blue-light: #2a4f8a;
  --usac-gold: #c6a44d;
  --usac-gold-light: #d4b96a;
  --usac-gold-dark: #a88a3a;
  --usac-gold-glow: rgba(198, 164, 77, 0.25);

  /* Neutral Palette */
  --gray-50: #f8f9fb;
  --gray-100: #f1f3f7;
  --gray-200: #e2e6ed;
  --gray-300: #c9cfd9;
  --gray-400: #9aa3b3;
  --gray-500: #6b7689;
  --gray-600: #4a5568;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;

  /* Semantic Colors */
  --success: #059669;
  --success-light: #d1fae5;
  --error: #dc2626;
  --error-light: #fef2f2;
  --warning: #d97706;
  --info: #2563eb;

  /* Typography */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;

  /* Borders & Shadows */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 28px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.07), 0 2px 6px rgba(0,0,0,0.03);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.1), 0 4px 16px rgba(0,0,0,0.05);
  --shadow-xl: 0 24px 60px rgba(0,0,0,0.14), 0 8px 24px rgba(0,0,0,0.07);
  --shadow-gold: 0 4px 24px rgba(198, 164, 77, 0.35);
  --shadow-blue-glow: 0 0 30px rgba(26, 58, 107, 0.15);

  /* Glassmorphism */
  --glass-bg: rgba(255, 255, 255, 0.72);
  --glass-border: rgba(255, 255, 255, 0.4);
  --glass-blur: blur(20px);

  /* Transitions */
  --transition-fast: 180ms ease;
  --transition-normal: 280ms ease;
  --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 600ms cubic-bezier(0.34, 1.56, 0.64, 1);
  --transition-bounce: 500ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-primary);
  color: var(--gray-800);
  background: var(--gray-50);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Smooth selection color */
::selection {
  background: rgba(198, 164, 77, 0.25);
  color: var(--usac-blue-darkest);
}

.hidden {
  display: none !important;
}

/* === SCROLLBAR === */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--gray-300);
  border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--usac-gold);
}

/* ================================================================
   LOGIN SCREEN — Immersive hero with particles & glassmorphism
   ================================================================ */
.login-screen {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, var(--usac-blue-darkest) 0%, #0f2245 30%, var(--usac-blue) 55%, #1e3d70 100%);
  z-index: 9999;
  overflow: hidden;
  padding: var(--space-xl);
}

/* Animated gradient overlay */
.login-screen::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 70% 50% at 70% 40%,
    rgba(198, 164, 77, 0.08) 0%,
    transparent 70%
  );
  animation: gradientShift 8s ease-in-out infinite alternate;
}

@keyframes gradientShift {
  0% { opacity: 0.5; transform: scale(1); }
  100% { opacity: 1; transform: scale(1.1); }
}

/* Grid pattern overlay */
.login-screen::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(198, 164, 77, 0.04) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
}

.login-bg-shapes .shape {
  position: absolute;
  border-radius: 50%;
  background: var(--usac-gold);
  filter: blur(1px);
}

.shape-1 {
  width: 500px;
  height: 500px;
  top: -180px;
  right: -120px;
  opacity: 0.04;
  animation: morphFloat1 18s ease-in-out infinite;
}

.shape-2 {
  width: 350px;
  height: 350px;
  bottom: -80px;
  left: -80px;
  opacity: 0.05;
  animation: morphFloat2 22s ease-in-out infinite;
}

.shape-3 {
  width: 200px;
  height: 200px;
  top: 45%;
  left: 55%;
  opacity: 0.03;
  animation: morphFloat3 14s ease-in-out infinite 3s;
}

@keyframes morphFloat1 {
  0%, 100% { transform: translate(0, 0) scale(1) rotate(0deg); border-radius: 50%; }
  25% { transform: translate(30px, -40px) scale(1.1) rotate(5deg); border-radius: 40% 60% 60% 40%; }
  50% { transform: translate(-20px, 20px) scale(0.95) rotate(-3deg); border-radius: 60% 40% 50% 50%; }
  75% { transform: translate(15px, -10px) scale(1.05) rotate(2deg); border-radius: 50% 50% 40% 60%; }
}

@keyframes morphFloat2 {
  0%, 100% { transform: translate(0, 0) scale(1) rotate(0deg); }
  33% { transform: translate(25px, -35px) scale(1.08) rotate(8deg); }
  66% { transform: translate(-18px, 18px) scale(0.94) rotate(-5deg); }
}

@keyframes morphFloat3 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-25px, 20px) scale(1.15); }
}

/* Login Card — Glassmorphism */
.login-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 480px;
  overflow: hidden;
  box-shadow:
    0 32px 80px rgba(0, 0, 0, 0.25),
    0 0 0 1px rgba(255, 255, 255, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  animation: loginCardEntrance 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  transform: translateY(40px) scale(0.96);
  opacity: 0;
  position: relative;
  z-index: 1;
}

@keyframes loginCardEntrance {
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

.login-header-brand {
  background: linear-gradient(150deg, var(--usac-blue-darkest) 0%, var(--usac-blue) 100%);
  padding: var(--space-xl) var(--space-2xl);
  border-bottom: 3px solid var(--usac-gold);
  position: relative;
  overflow: hidden;
}

/* Shimmer effect on brand header */
.login-header-brand::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(198, 164, 77, 0.06), transparent);
  animation: shimmer 4s ease-in-out infinite;
}

@keyframes shimmer {
  0% { left: -100%; }
  100% { left: 200%; }
}

.login-logo-row {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  position: relative;
  z-index: 1;
}

.usac-emblem {
  width: 64px;
  height: 64px;
  background: rgba(198, 164, 77, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--usac-gold);
  flex-shrink: 0;
  position: relative;
  animation: emblemPulse 3s ease-in-out infinite;
}

/* Pulsing ring on emblem */
.usac-emblem::before {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px solid rgba(198, 164, 77, 0.2);
  animation: ringPulse 3s ease-in-out infinite;
}

@keyframes ringPulse {
  0%, 100% { transform: scale(1); opacity: 0.3; }
  50% { transform: scale(1.1); opacity: 0; }
}

@keyframes emblemPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(198, 164, 77, 0.3); }
  50% { box-shadow: 0 0 20px 4px rgba(198, 164, 77, 0.15); }
}

.usac-emblem .material-icons-outlined {
  font-size: 30px;
  color: var(--usac-gold);
}

.login-brand-text {
  display: flex;
  flex-direction: column;
}

.login-brand-faculty {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 3.5px;
  color: var(--usac-gold);
  text-transform: uppercase;
  animation: fadeSlideUp 0.6s ease 0.3s both;
}

.login-brand-name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  color: white;
  letter-spacing: 1.5px;
  line-height: 1.2;
  animation: fadeSlideUp 0.6s ease 0.4s both;
}

.login-brand-uni {
  font-size: 0.65rem;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.5px;
  margin-top: 3px;
  animation: fadeSlideUp 0.6s ease 0.5s both;
}

@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.login-body {
  padding: var(--space-2xl) var(--space-2xl) var(--space-xl);
  text-align: center;
}

.login-title {
  font-family: var(--font-display);
  font-size: 1.9rem;
  color: var(--usac-blue-darkest);
  margin-bottom: var(--space-sm);
  animation: fadeSlideUp 0.6s ease 0.5s both;
}

.login-subtitle {
  font-size: 0.9rem;
  color: var(--gray-500);
  margin-bottom: var(--space-xl);
  line-height: 1.6;
  animation: fadeSlideUp 0.6s ease 0.6s both;
}

.login-divider {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
  animation: fadeSlideUp 0.6s ease 0.65s both;
}

.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gray-200), transparent);
}

.login-divider span {
  font-size: 0.72rem;
  color: var(--gray-400);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 600;
}

/* Google Login Button Container — Adjusted for Official Google Button */
.google-login-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: var(--space-xl) 0;
  min-height: 54px;
  background: transparent;
  border: none;
  cursor: pointer;
  animation: fadeSlideUp 0.6s ease 0.7s both;
}

/* Reset inner elements to avoid interference */
.google-login-btn span,
.google-login-btn .google-icon {
  display: none !important;
}

/* Ensure the Google iframe is centered and clean */
.google-login-btn > div {
  margin: 0 auto !important;
  border-radius: 50px; /* Match pill shape */
}

.login-security-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: var(--space-xl);
  font-size: 0.75rem;
  color: var(--gray-400);
  animation: fadeSlideUp 0.6s ease 0.8s both;
}

.login-security-note .material-icons-outlined {
  font-size: 16px;
  color: var(--success);
  animation: securityBadgePulse 2s ease-in-out infinite;
}

@keyframes securityBadgePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

/* ================================================================
   APP CONTAINER — Slide-in entrance
   ================================================================ */
.app-container {
  min-height: 100vh;
  display: flex;
  flex-direction: row; /* Fixed: Sidebar on the left, content on the right */
  background: linear-gradient(180deg, var(--gray-50) 0%, #eef1f6 100%);
  animation: appEnter 0.7s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes appEnter {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ================================================================
   TOP NAVIGATION — Glassmorphism with depth
   ================================================================ */
.top-nav {
  height: 80px;
  background: var(--usac-blue-darkest);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  color: white;
  position: sticky;
  top: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(13, 27, 62, 0.3);
  border-bottom: 2px solid var(--usac-gold);
}

/* Subtle bottom glow */
.top-nav::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 10%;
  right: 10%;
  height: 8px;
  background: radial-gradient(ellipse, rgba(198, 164, 77, 0.15), transparent);
  pointer-events: none;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-shrink: 0;
}

.nav-emblem {
  width: 42px;
  height: 42px;
  background: rgba(198, 164, 77, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--usac-gold);
  transition: all var(--transition-normal);
}

.nav-emblem:hover {
  transform: rotate(10deg) scale(1.05);
  box-shadow: 0 0 16px rgba(198, 164, 77, 0.3);
}

.nav-emblem .material-icons-outlined {
  font-size: 20px;
  color: var(--usac-gold);
}

.nav-brand-text {
  display: flex;
  flex-direction: column;
}

.nav-faculty {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--usac-gold);
}

.nav-uni {
  font-size: 0.55rem;
  color: rgba(255,255,255,0.5);
  letter-spacing: 1px;
}

.nav-title-section {
  flex: 1;
  text-align: center;
}

.nav-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: white;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.nav-user {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  flex-shrink: 0;
}

.user-info {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.user-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 2px solid var(--usac-gold);
  object-fit: cover;
  transition: all var(--transition-normal);
  cursor: pointer;
}

/* Fallback circle with user initials when avatar image fails */
.user-avatar-fallback {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 2px solid var(--usac-gold);
  background: linear-gradient(135deg, var(--usac-gold-dark), var(--usac-gold));
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: white;
  cursor: pointer;
  transition: all var(--transition-normal);
  flex-shrink: 0;
  font-family: var(--font-primary);
  letter-spacing: 0.5px;
}

.user-avatar:hover {
  transform: scale(1.08);
  box-shadow: 0 0 16px rgba(198, 164, 77, 0.4);
}

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

.user-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: white;
  line-height: 1.2;
}

.user-email {
  font-size: 0.65rem;
  color: rgba(255,255,255,0.5);
}

.logout-btn {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-sm);
  color: rgba(255,255,255,0.65);
  padding: 8px 10px;
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 6px;
  position: relative;
  overflow: hidden;
}

.logout-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(220, 38, 38, 0.15);
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.logout-btn:hover {
  border-color: rgba(220, 38, 38, 0.4);
  color: white;
  transform: translateY(-1px);
}

.logout-btn:hover::before {
  opacity: 1;
}

.logout-btn:active {
  transform: translateY(0) scale(0.95);
}

.logout-btn .material-icons-outlined {
  font-size: 20px;
  position: relative;
  z-index: 1;
}

/* ================================================================
   PROGRESS BAR — Animated glow + modern step indicators
   ================================================================ */
/* ================================================================
   COMPACT STEPPER — circles + inline connecting line (one row)
   ================================================================ */

.progress-container {
    background: white;
    padding: 10px var(--space-2xl);
    border-bottom: 1px solid var(--gray-200);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    position: sticky;
    top: 0px;
    z-index: 95;
}

.progress-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  max-width: 640px;
  margin: 0 auto;
}

/* Connecting line between circles */
.step-connector {
  flex: 1;
  height: 3px;
  background: var(--gray-200);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
  margin: 0 4px;
}

/* Fill portion of connector that advances with progress */
.step-connector-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--usac-gold-dark), var(--usac-gold));
  border-radius: 4px;
  transition: width 0.55s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

/* Animated shimmer on the filled connector */
.step-connector-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.55) 50%, transparent 100%);
  animation: shimmerLine 1.6s ease-in-out infinite;
}

@keyframes shimmerLine {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}

/* Each step item */
.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  opacity: 0.38;
  transition: all var(--transition-slow);
  cursor: pointer;
  padding: 4px 6px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

.step:hover {
  opacity: 0.6;
}

.step.active {
  opacity: 1;
}

.step.completed {
  opacity: 0.9;
}

/* Circle */
.step-circle {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--gray-500);
  transition: all var(--transition-slow);
  position: relative;
  border: 2px solid transparent;
}

.step.active .step-circle {
  background: var(--usac-blue);
  color: white;
  border-color: rgba(26, 58, 107, 0.2);
  box-shadow: 0 0 0 4px rgba(26, 58, 107, 0.12);
  animation: stepCirclePop 0.45s var(--transition-bounce) forwards;
}

@keyframes stepCirclePop {
  0%   { transform: scale(0.75); }
  65%  { transform: scale(1.12); }
  100% { transform: scale(1); }
}

.step.completed .step-circle {
  background: var(--success);
  border-color: rgba(5, 150, 105, 0.15);
  color: transparent;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.1);
}

.step.completed .step-circle::after {
  content: '✓';
  position: absolute;
  font-size: 0.85rem;
  font-weight: 800;
  color: white;
}

/* Step label — shown inline below circle */
.step-label {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--gray-500);
  white-space: nowrap;
  transition: color var(--transition-normal);
  line-height: 1;
}

.step.active .step-label {
  color: var(--usac-blue);
  font-weight: 700;
}

.step.completed .step-label {
  color: var(--success);
}

/* ================================================================
   FORM MAIN — Container with depth
   ================================================================ */
.form-main {
  flex: 1;
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
  padding: var(--space-2xl) var(--space-xl);
}

/* ================================================================
   FORM STEPS — Class-based transitions (compatible with display:none)
   ================================================================ */

/* All inactive steps are completely hidden */
.form-step {
  display: none;
}

/* Active step is visible and transitions are enabled */
.form-step.active {
  display: block;
  animation: stepReveal 0.45s cubic-bezier(0.4, 0, 0.2, 1) both;
  background: white;
  border-radius: var(--radius-xl);
  padding: var(--space-2xl);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
  border: 1px solid var(--gray-200);
}

/* Default entry animation */
@keyframes stepReveal {
  from {
    opacity: 0;
    transform: translateY(12px);
    filter: blur(2px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

/* Directional entry: arriving from the right (forward nav) */
.form-step.active.entering-right {
  animation: stepEnterRight 0.42s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes stepEnterRight {
  from { opacity: 0; transform: translateX(50px); filter: blur(3px); }
  to   { opacity: 1; transform: translateX(0);    filter: blur(0); }
}

/* Directional entry: arriving from the left (backward nav) */
.form-step.active.entering-left {
  animation: stepEnterLeft 0.42s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes stepEnterLeft {
  from { opacity: 0; transform: translateX(-50px); filter: blur(3px); }
  to   { opacity: 1; transform: translateX(0);     filter: blur(0); }
}

/* Exit: current step leaves to the left (forward nav) */
.form-step.active.leaving-left {
  animation: stepLeaveLeft 0.3s ease forwards;
  pointer-events: none;
}

@keyframes stepLeaveLeft {
  from { opacity: 1; transform: translateX(0);     filter: blur(0); }
  to   { opacity: 0; transform: translateX(-40px); filter: blur(3px); }
}

/* Exit: current step leaves to the right (backward nav) */
.form-step.active.leaving-right {
  animation: stepLeaveRight 0.3s ease forwards;
  pointer-events: none;
}

@keyframes stepLeaveRight {
  from { opacity: 1; transform: translateX(0);    filter: blur(0); }
  to   { opacity: 0; transform: translateX(40px); filter: blur(3px); }
}

/* Step header with animated icon */
.step-header {
  display: flex;
  align-items: flex-start;
  gap: var(--space-lg);
  margin-bottom: var(--space-2xl);
  padding-bottom: var(--space-lg);
  border-bottom: 2px solid transparent;
  border-image: linear-gradient(90deg, var(--usac-gold), transparent) 1;
  animation: fadeSlideUp 0.5s ease 0.1s both;
}

.step-icon {
  font-size: 36px;
  color: var(--usac-blue);
  background: linear-gradient(135deg, rgba(26, 58, 107, 0.08), rgba(198, 164, 77, 0.06));
  padding: 12px;
  border-radius: var(--radius-md);
  transition: all var(--transition-normal);
  animation: iconBounceIn 0.6s var(--transition-bounce) 0.2s both;
}

@keyframes iconBounceIn {
  from {
    opacity: 0;
    transform: scale(0.5) rotate(-10deg);
  }
  to {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

.step-icon:hover {
  transform: rotate(8deg) scale(1.05);
  box-shadow: 0 4px 16px rgba(26, 58, 107, 0.15);
}

.step-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--usac-blue-darkest);
  margin-bottom: 4px;
  letter-spacing: 0.3px;
}

.step-description {
  font-size: 0.9rem;
  color: var(--gray-500);
  line-height: 1.5;
}

/* ================================================================
   FORM GRID — Staggered field entry animations
   ================================================================ */
.form-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.col-1 { grid-column: span 1; }
.col-2 { grid-column: span 2; }
.col-3 { grid-column: span 3; }
.col-4 { grid-column: span 4; }
.col-5 { grid-column: span 5; }
.col-6 { grid-column: span 6; }
.col-7 { grid-column: span 7; }
.col-8 { grid-column: span 8; }
.col-9 { grid-column: span 9; }
.col-10 { grid-column: span 10; }
.col-11 { grid-column: span 11; }
.col-12, .col-full { grid-column: span 12; }

/* === Week Grid (6-column for semana blocks) ===
   Row 1: 3 ×  col-w2 → semana / contenido / estudiantes  (each 1/3 width)
   Row 2: 2 ×  col-w3 → metodología / plataforma          (each 1/2 width) */
.week-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.col-w2 { grid-column: span 2; }
.col-w3 { grid-column: span 3; }

/* Staggered entrance for form fields */
.form-step.active .form-grid .form-group {
  animation: fieldFadeIn 0.4s ease both;
}

.form-step.active .form-grid .form-group:nth-child(1) { animation-delay: 0.05s; }
.form-step.active .form-grid .form-group:nth-child(2) { animation-delay: 0.1s; }
.form-step.active .form-grid .form-group:nth-child(3) { animation-delay: 0.15s; }
.form-step.active .form-grid .form-group:nth-child(4) { animation-delay: 0.2s; }
.form-step.active .form-grid .form-group:nth-child(5) { animation-delay: 0.25s; }
.form-step.active .form-grid .form-group:nth-child(6) { animation-delay: 0.3s; }
.form-step.active .form-grid .form-group:nth-child(7) { animation-delay: 0.35s; }
.form-step.active .form-grid .form-group:nth-child(8) { animation-delay: 0.4s; }
.form-step.active .form-grid .form-group:nth-child(9) { animation-delay: 0.45s; }
.form-step.active .form-grid .form-group:nth-child(10) { animation-delay: 0.5s; }

@keyframes fieldFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ================================================================
   FORM GROUPS — Modern input styling with animated borders
   ================================================================ */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
  position: relative;
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--gray-700);
  letter-spacing: 0.2px;
  transition: color var(--transition-fast);
}

/* Animate label color on focus-within */
.form-group:focus-within label {
  color: var(--usac-blue);
}

.required {
  color: var(--error);
  font-weight: 700;
}

.link-hint {
  font-weight: 400;
  font-size: 0.73rem;
  color: var(--gray-400);
}

/* === Premium Input Styling === */
.form-group input,
.form-group select,
.form-group textarea {
  font-family: var(--font-primary);
  font-size: 0.9rem;
  padding: 12px 16px;
  border: 1.5px solid var(--gray-300);
  border-radius: var(--radius-sm);
  background: white;
  color: var(--gray-800);
  transition: all var(--transition-normal);
  outline: none;
  position: relative;
}

/* Animated bottom-border highlight on focus */
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--usac-blue);
  box-shadow:
    0 0 0 3px rgba(26, 58, 107, 0.08),
    0 4px 12px rgba(26, 58, 107, 0.06);
  background: #fafbff;
}

/* Subtle scale on focus */
.form-group input:focus,
.form-group textarea:focus {
  transform: translateY(-1px);
}

.form-group input.invalid,
.form-group select.invalid,
.form-group textarea.invalid {
  border-color: var(--error);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.08);
  animation: inputShake 0.4s ease;
}

@keyframes inputShake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-4px); }
  40% { transform: translateX(4px); }
  60% { transform: translateX(-3px); }
  80% { transform: translateX(3px); }
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--gray-400);
  transition: opacity var(--transition-fast);
}

.form-group input:focus::placeholder,
.form-group textarea:focus::placeholder {
  opacity: 0.5;
}

.readonly-field {
  background: var(--gray-100) !important;
  color: var(--gray-500) !important;
  cursor: not-allowed;
  border-style: dashed !important;
}

.input-with-icon {
  position: relative;
}

.input-with-icon input {
  padding-right: 42px;
  width: 100%;
}

.input-icon {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gray-400);
  font-size: 20px;
  pointer-events: none;
  transition: all var(--transition-normal);
}

.input-with-icon input:focus ~ .input-icon {
  color: var(--usac-blue);
  transform: translateY(-50%) scale(1.1);
}

/* === Multi-select Premium Styling === */
.multi-select {
  min-height: 120px;
  padding: 6px !important;
  border-radius: var(--radius-sm) !important;
  scrollbar-width: thin;
}

.multi-select option {
  padding: 8px 12px;
  border-radius: 6px;
  margin: 2px 0;
  cursor: pointer;
  transition: all var(--transition-fast);
  font-size: 0.85rem;
}

.multi-select option:checked {
  background: linear-gradient(135deg, var(--usac-blue), var(--usac-blue-light));
  color: white;
  font-weight: 600;
}

.multi-select option:hover {
  background: var(--gray-100);
}

.help-text {
  font-size: 0.72rem;
  color: var(--gray-400);
  font-style: italic;
  display: flex;
  align-items: center;
  gap: 4px;
}

textarea {
  resize: vertical;
  min-height: 80px;
}

/* ================================================================
   WEEK BLOCKS — Card with hover depth + glow accent
   ================================================================ */
.week-block {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: var(--space-xl) var(--space-xl) var(--space-lg);
  margin-bottom: var(--space-xl);
  transition: all var(--transition-slow);
  box-shadow: none;
  position: relative;
  overflow: hidden;
}

/* Left accent border */
.week-block::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--usac-gold), var(--usac-gold-dark));
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.week-block:hover {
  box-shadow: var(--shadow-lg);
  border-color: rgba(198, 164, 77, 0.3);
  transform: translateY(-2px);
}

.week-block:hover::before {
  opacity: 1;
}

/* Staggered entrance for week blocks */
.form-step.active .week-block {
  animation: weekBlockIn 0.5s ease both;
}

.form-step.active .week-block:nth-child(1) { animation-delay: 0.1s; }
.form-step.active .week-block:nth-child(2) { animation-delay: 0.2s; }
.form-step.active .week-block:nth-child(3) { animation-delay: 0.3s; }
.form-step.active .week-block:nth-child(4) { animation-delay: 0.4s; }
.form-step.active .week-block:nth-child(5) { animation-delay: 0.5s; }

@keyframes weekBlockIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.week-header {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.week-badge {
  background: linear-gradient(135deg, var(--usac-blue-darkest), var(--usac-blue));
  color: white;
  padding: 7px 18px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.7px;
  box-shadow: 0 2px 8px rgba(26, 58, 107, 0.2);
  transition: all var(--transition-normal);
}

.week-block:hover .week-badge {
  box-shadow: 0 4px 16px rgba(26, 58, 107, 0.3);
  transform: scale(1.02);
}

.week-optional {
  font-size: 0.78rem;
  color: var(--gray-400);
  font-style: italic;
}

/* ================================================================
   STEP ACTIONS — Enhanced buttons layout
   ================================================================ */
.step-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--space-2xl);
  padding-top: var(--space-xl);
  border-top: 1px solid var(--gray-200);
  background: transparent !important;
  animation: fadeSlideUp 0.5s ease 0.3s both;
}

/* ================================================================
   BUTTONS — Premium with ripple & micro-animations
   ================================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 14px 30px;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-primary);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all var(--transition-normal);
  text-transform: uppercase;
  position: relative;
  overflow: hidden;
}

/* Ripple effect on click */
.btn::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  background: radial-gradient(circle, rgba(255,255,255,0.3) 0%, transparent 70%);
  transform: scale(0);
  opacity: 0;
  transition: transform 0.5s ease, opacity 0.3s ease;
}

.btn:active::after {
  transform: scale(2.5);
  opacity: 1;
  transition: transform 0s, opacity 0s;
}

.btn .material-icons-outlined {
  font-size: 20px;
  transition: transform var(--transition-normal);
}

/* Icon animation on hover */
.btn:hover .material-icons-outlined {
  transform: translateX(3px);
}

.btn-prev:hover .material-icons-outlined {
  transform: translateX(-3px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--usac-gold-dark), var(--usac-gold));
  color: white;
  box-shadow: var(--shadow-gold);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--usac-gold), var(--usac-gold-light));
  transform: translateY(-3px);
  box-shadow: 0 8px 28px rgba(198, 164, 77, 0.45);
}

.btn-primary:active {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(198, 164, 77, 0.3);
}

.btn-secondary {
  background: white;
  color: var(--gray-600);
  border: 1.5px solid var(--gray-300);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background: var(--gray-50);
  color: var(--usac-blue);
  border-color: var(--usac-blue-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-secondary:active {
  transform: translateY(0);
}

/* Submit Button — Extra premium */
.btn-success {
  background: linear-gradient(135deg, var(--usac-gold-dark) 0%, var(--usac-gold) 50%, var(--usac-gold-light) 100%);
  background-size: 200% 100%;
  color: white;
  padding: 16px 42px;
  font-size: 0.95rem;
  box-shadow: var(--shadow-gold);
  letter-spacing: 1.5px;
  animation: gradientMove 3s ease infinite;
}

@keyframes gradientMove {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.btn-success:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 10px 36px rgba(198, 164, 77, 0.5);
}

.btn-success:active {
  transform: translateY(-1px) scale(1);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  filter: grayscale(30%);
}

/* ================================================================
   MODALS — Glassmorphism with entrance effects
   ================================================================ */
.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xl);
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(13, 27, 62, 0.5);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.modal:not(.hidden) .modal-backdrop {
  opacity: 1;
  pointer-events: auto;
  animation: backdropIn 0.4s ease forwards;
}

@keyframes backdropIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-content {
  position: relative;
  background: var(--gray-50);
  border-radius: var(--radius-xl);
  padding: var(--space-3xl) var(--space-2xl) var(--space-2xl);
  max-width: 460px;
  width: 100%;
  text-align: center;
  box-shadow:
    0 32px 80px rgba(0, 0, 0, 0.2),
    0 0 0 1px rgba(255, 255, 255, 0.15);
  opacity: 0;
  transform: scale(0.9) translateY(20px);
}

.modal:not(.hidden) .modal-content {
  opacity: 1;
  transform: scale(1) translateY(0);
  animation: modalBounceIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes modalBounceIn {
  from {
    transform: scale(0.85) translateY(40px);
    opacity: 0;
  }
  to {
    transform: scale(1) translateY(0);
    opacity: 1;
  }
}

.modal-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-lg);
  position: relative;
}

.modal-icon.success {
  background: var(--success-light);
  color: var(--success);
  animation: iconSuccessPop 0.5s var(--transition-bounce) 0.3s both;
}

.modal-icon.error {
  background: var(--error-light);
  color: var(--error);
  animation: iconErrorShake 0.6s ease 0.3s both;
}

@keyframes iconSuccessPop {
  from {
    transform: scale(0) rotate(-30deg);
    opacity: 0;
  }
  to {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

@keyframes iconErrorShake {
  0% { transform: scale(0); opacity: 0; }
  40% { transform: scale(1.15); opacity: 1; }
  50% { transform: scale(1) rotate(5deg); }
  60% { transform: rotate(-5deg); }
  70% { transform: rotate(3deg); }
  80% { transform: rotate(-2deg); }
  100% { transform: rotate(0deg); opacity: 1; }
}

/* Pulsing ring on success */
.modal-icon.success::after {
  content: '';
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 2px solid var(--success);
  animation: successRing 1.5s ease 0.6s forwards;
  opacity: 0;
}

@keyframes successRing {
  0% { transform: scale(0.8); opacity: 0.6; }
  100% { transform: scale(1.3); opacity: 0; }
}

.modal-icon .material-icons-outlined {
  font-size: 42px;
}

.modal-content h2 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--gray-900);
  margin-bottom: var(--space-sm);
}

.modal-content p {
  color: var(--gray-500);
  font-size: 0.9rem;
  margin-bottom: var(--space-xl);
  line-height: 1.6;
}

.modal-details {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: var(--gray-50);
  padding: var(--space-md) var(--space-lg);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-xl);
  font-size: 0.82rem;
  color: var(--gray-600);
  border: 1px solid var(--gray-200);
  font-weight: 500;
}

.modal-course-selector {
  width: 100%;
  border-radius: 8px;
  border: 0px solid transparent;
  font-size: 1rem;
  background-color: transparent;
  padding: 10px;
  color: var(--gray-800);
  cursor: pointer;
  outline: none;
}

/* ================================================================
   LOADING OVERLAY — Modern spinner with context
   ================================================================ */
.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
}

.loading-overlay:not(.hidden) {
  opacity: 1;
  pointer-events: auto;
  animation: backdropIn 0.3s ease forwards;
}

.loading-spinner {
  text-align: center;
  animation: fadeSlideUp 0.4s ease forwards;
}

.spinner {
  width: 52px;
  height: 52px;
  border: 3px solid var(--gray-200);
  border-top-color: var(--usac-gold);
  border-right-color: var(--usac-blue);
  border-radius: 50%;
  animation: spinPulse 0.8s linear infinite;
  margin: 0 auto var(--space-lg);
  position: relative;
}

/* Double ring spinner */
.spinner::before {
  content: '';
  position: absolute;
  inset: 4px;
  border: 2px solid transparent;
  border-top-color: var(--usac-blue);
  border-radius: 50%;
  animation: spinPulse 1.2s linear infinite reverse;
}

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

.loading-spinner p {
  font-size: 0.95rem;
  color: var(--gray-600);
  font-weight: 600;
  letter-spacing: 0.5px;
}

/* ================================================================
   FOOTER — Refined with gradient
   ================================================================ */
.app-footer {
  background: linear-gradient(180deg, var(--usac-blue-darkest), #0a1530);
  color: rgba(255,255,255,0.45);
  text-align: center;
  padding: var(--space-xl) var(--space-xl);
  font-size: 0.78rem;
  margin-top: auto;
  position: relative;
}

/* Top border glow */
.app-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--usac-gold), transparent);
  opacity: 0.5;
}

.app-footer p {
  margin-bottom: 4px;
}

.footer-security {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 0.7rem;
}

.footer-security .material-icons-outlined {
  font-size: 14px;
  color: var(--success);
}

/* ================================================================
   TOAST NOTIFICATIONS — Premium slide-in
   ================================================================ */
.toast {
  position: fixed;
  top: 84px;
  right: 20px;
  background: var(--gray-900);
  color: white;
  padding: 14px 22px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 500;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
  z-index: 1100;
  animation: toastIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  max-width: 380px;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  backdrop-filter: blur(12px);
}

.toast.toast-error {
  border-left: 4px solid var(--error);
  background: linear-gradient(135deg, rgba(30, 20, 20, 0.95), var(--gray-900));
}

.toast.toast-success {
  border-left: 4px solid var(--success);
  background: linear-gradient(135deg, rgba(20, 30, 20, 0.95), var(--gray-900));
}

.toast.toast-warning {
  border-left: 4px solid var(--warning);
  background: linear-gradient(135deg, rgba(30, 28, 20, 0.95), var(--gray-900));
}

@keyframes toastIn {
  from {
    transform: translateX(120%) scale(0.9);
    opacity: 0;
  }
  to {
    transform: translateX(0) scale(1);
    opacity: 1;
  }
}

@keyframes toastOut {
  from {
    transform: translateX(0) scale(1);
    opacity: 1;
  }
  to {
    transform: translateX(120%) scale(0.9);
    opacity: 0;
  }
}

/* ================================================================
   VALIDATION STATES — Enhanced with animations
   ================================================================ */
.form-group.error input,
.form-group.error select,
.form-group.error textarea {
  border-color: var(--error);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.08);
  animation: inputShake 0.4s ease;
}

.form-group .error-message {
  font-size: 0.72rem;
  color: var(--error);
  font-weight: 500;
  display: none;
}

.form-group.error .error-message {
  display: block;
  animation: fadeSlideUp 0.3s ease forwards;
}

/* ================================================================
   RESPONSIVE DESIGN
   ================================================================ */
@media (max-width: 1024px) {
  .form-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .col-1, .col-2, .col-3, .col-4, .col-5, .col-6 { grid-column: span 1; }
  .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col-full { grid-column: span 2; }

  /* Week grid: collapse first row to 2 cols, selects stay full width */
  .week-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .col-w2 { grid-column: span 1; }
  .col-w3 { grid-column: span 2; }
}

@media (max-width: 768px) {
  .top-nav {
    padding: 0 var(--space-md);
    height: auto;
    min-height: 60px;
    flex-wrap: wrap;
    padding-top: var(--space-sm);
    padding-bottom: var(--space-sm);
    gap: var(--space-sm);
  }

  .nav-title-section {
    order: 3;
    flex-basis: 100%;
    display: none;
  }

  .nav-brand-text {
    display: none;
  }

  .user-details {
    display: none;
  }

  .progress-container {
    padding: var(--space-md);
  }

  .step-label {
    display: none;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col-full {
    grid-column: span 1;
  }

  /* Week grid: all fields stack to single column on mobile */
  .week-grid {
    grid-template-columns: 1fr;
  }
  .col-w2, .col-w3 { grid-column: span 1; }

  .form-main {
    padding: var(--space-lg) var(--space-md);
  }

  .week-block {
    padding: var(--space-md);
  }

  .step-actions {
    flex-direction: column-reverse;
    gap: var(--space-md);
  }

  .step-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .btn-success {
    padding: 14px 24px;
    font-size: 0.9rem;
  }

  .step-header {
    border-image: none;
    border-bottom-color: var(--gray-200);
  }

  .toast {
    right: 10px;
    left: 10px;
    max-width: none;
  }
}

@media (max-width: 480px) {
  .login-card {
    border-radius: var(--radius-lg);
  }

  .login-header-brand {
    padding: var(--space-lg);
  }

  .login-body {
    padding: var(--space-xl) var(--space-lg);
  }

  .login-brand-name {
    font-size: 1.1rem;
  }

  .login-title {
    font-size: 1.4rem;
  }

  .step-title {
    font-size: 1.2rem;
  }

  .modal-content {
    padding: var(--space-2xl) var(--space-lg);
  }
}

/* ================================================================
   PRINT STYLES
   ================================================================ */
@media print {
  .top-nav,
  .progress-container,
  .step-actions,
  .app-footer,
  .logout-btn {
    display: none !important;
  }

  .form-step {
    display: block !important;
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }

  .week-block {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid var(--gray-300);
  }

  body {
    background: white;
  }
}

/* ================================================================
   REDUCED MOTION — Accessibility
   ================================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .login-card,
  .form-step,
  .form-step.active,
  .modal-content,
  .toast,
  .week-block,
  .form-group {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }
}

/* ================================================================
   DOCENTE DATA CARD — Floating panel (desktop only)
   ================================================================ */

.docente-card {
    position: fixed;
    top: calc(var(--nav-height, 64px) + 100px);
    right: 24px;
    width: 280px;
    background: rgba(13, 27, 62, 0.82);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(198, 164, 77, 0.2);
    border-radius: 20px;
    padding: 20px;
    z-index: 90;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(198, 164, 77, 0.15);
    animation: cardSlideIn 0.5s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes cardSlideIn {
  from { opacity: 0; transform: translateX(30px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* Header: avatar + name */
.docente-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 0;
}

.docente-card-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--usac-gold-dark), var(--usac-gold));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 700;
  color: white;
  font-family: var(--font-primary);
  flex-shrink: 0;
  border: 2px solid rgba(198, 164, 77, 0.4);
}

.docente-card-identity {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.docente-card-name {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--usac-gold-light);
  font-family: var(--font-display);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.docente-card-reg {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.5);
  font-family: var(--font-primary);
}

.docente-card-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(198, 164, 77, 0.25), transparent);
  margin: 14px 0;
}

/* Body rows */
.docente-card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.docente-card-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.docente-card-icon {
  font-size: 1rem !important;
  color: var(--usac-gold);
  flex-shrink: 0;
  margin-top: 1px;
  opacity: 0.85;
}

.docente-card-row > div {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.docente-card-label {
  font-size: 0.67rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.45);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-family: var(--font-primary);
}

.docente-card-value {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.9);
  font-family: var(--font-primary);
  line-height: 1.3;
  word-break: break-word;
}

/* Loader state */
.docente-card-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 16px 0;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.8rem;
  font-family: var(--font-primary);
}

.spinner-ring {
  width: 28px;
  height: 28px;
  border: 3px solid rgba(198, 164, 77, 0.2);
  border-top-color: var(--usac-gold);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* Empty state */
.docente-card-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 12px 0;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.75rem;
  font-family: var(--font-primary);
  text-align: center;
  line-height: 1.4;
}

.docente-card-empty .material-icons-outlined {
  font-size: 2rem;
  opacity: 0.4;
}

/* ================================================================
   COURSE SELECTOR BANNER
   ================================================================ */

.course-selector-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: rgba(198, 164, 77, 0.2);
  border: 1px solid var(--usac-gold);
  border-radius: 8px;
  padding: 10px 20px;
  margin: 16px auto;
  max-width: 900px;
  animation: cardSlideIn 0.4s ease both;
  flex-wrap: nowrap;
  position: sticky;
  top: 137px; /* Below progress container (72px + 65px) */
  z-index: 94;
  backdrop-filter: blur(8px); /* Optional premium touch */
}

.course-selector-banner .material-icons-outlined {
  color: var(--usac-blue);
  font-size: 1.3rem;
  flex-shrink: 0;
}

.course-selector-banner label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--usac-blue); /* Dark text for readability */
  font-family: var(--font-primary);
  white-space: nowrap;
  margin: 0;
}

.course-selector-select {
  background: white;
  border: 1px solid var(--usac-gold);
  border-radius: 6px;
  color: var(--usac-blue);
  font-weight: 600;
  font-family: var(--font-primary);
  font-size: 0.85rem;
  padding: 6px 14px;
  cursor: pointer;
  flex-grow: 1;
  max-width: 400px;
  min-width: 200px;
  transition: border-color var(--transition-normal);
}

.course-selector-select:focus {
  outline: none;
  border-color: var(--usac-gold);
  box-shadow: 0 0 0 2px rgba(198, 164, 77, 0.2);
}

.course-selector-select option {
  background: var(--usac-blue-dark);
  color: white;
}

/* Hide card and banner entirely on mobile / narrow screens */
@media (max-width: 1200px) {
  .docente-card {
    display: none !important;
  }
}

@media (max-width: 768px) {
  .course-selector-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .course-selector-select {
    width: 100%;
    min-width: unset;
  }
}



/* ============================================
   BULK IMPORT STYLES
   ============================================ */
.bulk-modal {
  max-width: 800px !important;
}

/* Refactorizado arriba */

.bulk-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--usac-blue);
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: var(--radius-md);
  font-family: var(--font-primary);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-normal);
  margin-right: var(--space-lg);
}

.bulk-btn:hover {
  background: #2a5a9b;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.bulk-tabs {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid var(--gray-100);
  margin-bottom: var(--space-xl);
}

.tabs-group {
  display: flex;
  gap: 16px;
}

.bulk-tab-btn {
  background: none;
  border: none;
  padding: 12px 16px;
  font-family: var(--font-primary);
  font-weight: 600;
  color: var(--gray-500);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all var(--transition-normal);
}

.bulk-tab-btn.active {
  color: var(--usac-blue);
  border-bottom-color: var(--usac-blue);
}

.file-drop-area {
  border: 3px dashed var(--gray-200);
  border-radius: var(--radius-lg);
  padding: var(--space-3xl) var(--space-2xl);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-normal);
  background: var(--gray-50);
}

.file-drop-area.dragover {
  background: #e0e7ff;
  border-color: var(--usac-blue);
}

.file-drop-area .material-icons-outlined {
  font-size: 3rem;
  color: var(--usac-blue);
  margin-bottom: var(--space-md);
}

#bulk-paste-area {
  width: 100%;
  height: 200px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--gray-200);
  padding: var(--space-md);
  font-family: 'Inter', monospace;
  font-size: 0.85rem;
  resize: vertical;
}

.bulk-hint {
  font-size: 0.8rem;
  color: var(--gray-500);
  margin-top: 8px;
  font-style: italic;
}

.bulk-preview {
  margin-top: var(--space-2xl);
  border-top: 1px solid var(--gray-200);
  padding-top: var(--space-xl);
}

.preview-table-container {
  max-height: 300px;
  overflow-y: auto;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  margin-top: var(--space-md);
}

#bulk-preview-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.75rem;
}

#bulk-preview-table th, #bulk-preview-table td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--gray-100);
  text-align: left;
}

#bulk-preview-table th {
  background: var(--gray-50);
  position: sticky;
  top: 0;
  z-index: 10;
  font-weight: 700;
  color: var(--gray-700);
}

.row-count {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--usac-blue);
  margin-top: 12px;
}

.hidden-file-input {
  display: none;
}

.bulk-modal .modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-xl);
  border-bottom: 1px solid var(--gray-100);
  padding-bottom: var(--space-md);
}

.bulk-modal .header-main {
  display: flex;
  align-items: center;
  gap: 12px;
}

.text-link-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  color: var(--usac-blue);
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  transition: all var(--transition-normal);
}

.text-link-btn:hover {
  background: var(--gray-50);
  text-decoration: underline;
}

.close-modal {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  font-size: 28px;
  line-height: 1;
  color: var(--gray-400);
  cursor: pointer;
  transition: all var(--transition-normal);
  padding: 4px;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}


/* ============================================
   SIDEBAR & LAYOUT REFACTOR
   ============================================ */

.main-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
}

.main-content {
  flex: 1;
  overflow-y: auto;
  position: relative;
  background: var(--gray-50);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.modal:not(.hidden) {
  pointer-events: all;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(13, 27, 62, 0.7);
  backdrop-filter: blur(4px);
}

.modal-content {
  position: relative;
  z-index: 10;
  background: white;
  border-radius: var(--radius-xl);
  padding: 30px;
  box-shadow: var(--shadow-2xl);
  width: 90%;
  max-width: 600px;
  animation: modalEnter 0.4s var(--transition-bounce);
}

@keyframes modalEnter {
  from { opacity: 0; transform: scale(0.9) translateY(20px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.sidebar {
  width: 260px;
  background: var(--usac-blue-darkest);
  color: white;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 1000;
  box-shadow: 4px 0 15px rgba(0,0,0,0.2);
  transition: all var(--transition-normal);
}

.sidebar-brand {
  height: 80px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-logo {
  height: 60px;
}

.sidebar-nav {
  flex: 1;
  padding: 20px 0;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 24px;
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  font-weight: 500;
  transition: all var(--transition-normal);
  cursor: pointer;
  border-left: 4px solid transparent;
}

.nav-item:hover {
  background: rgba(255,255,255,0.1);
  color: white;
}

.nav-item.active {
  background: rgba(255,255,255,0.15);
  color: white;
  border-left-color: var(--usac-gold);
}

.nav-item .material-icons-outlined {
  font-size: 20px;
}

.sidebar-footer {
  padding: 20px;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.logout-btn-sidebar {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  color: white;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
}

.logout-btn-sidebar:hover {
  background: var(--error);
  border-color: var(--error);
}

.main-content {
  flex: 1;
  padding: 0;
  overflow-x: hidden;
}

.view {
  display: none;
  animation: fadeIn 0.4s ease-out;
}

.view.active {
  display: block;
}

/* DASHBOARD STYLES */
.view-header {
  padding: 1.25rem 40px;
  background: white;
  border-bottom: 1px solid var(--gray-100);
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}

.view-header h1 {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 4px;
}

.view-header p {
  color: var(--gray-500);
}

.dashboard-card {
  margin: var(--space-xl) auto;
  max-width: 1400px;
  padding: var(--space-2xl);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(13, 27, 62, 0.1);
  border-radius: var(--radius-2xl);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
  animation: cardSlideIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.dashboard-filters {
  display: flex;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
  align-items: center;
  flex-wrap: wrap;
}

.dashboard-filters .form-control {
  min-width: 200px;
  background: white;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 12px 18px;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}

.dashboard-filters .form-control:focus {
  border-color: var(--usac-gold);
  box-shadow: 0 0 0 4px rgba(198, 164, 77, 0.1);
}

#dashboard-search {
  flex: 2;
  min-width: 300px;
}

.data-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 8px;
}

.data-table th {
  background: transparent;
  color: var(--gray-500);
  font-weight: 700;
  text-align: left;
  padding: 12px 20px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.data-table tr {
  background: white;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.02);
}

.data-table td {
  padding: 20px;
  border-top: 1px solid var(--gray-50);
  border-bottom: 1px solid var(--gray-50);
  font-size: 0.95rem;
  color: var(--usac-blue-dark);
}

.data-table td:first-child {
  border-left: 1px solid var(--gray-50);
  border-radius: var(--radius-lg) 0 0 var(--radius-lg);
}

.data-table td:last-child {
  border-right: 1px solid var(--gray-50);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}

.data-table tr:hover {
  transform: translateY(-2px) scale(1.005);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  background: #fdfdfd;
  z-index: 10;
}

.badge {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
}

.badge-success {
  background: var(--success-light);
  color: var(--success);
}

.action-btns {
  display: flex;
  gap: 8px;
}

.btn-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid var(--gray-100);
}

.btn-icon:hover {
  background: var(--gray-100);
  color: var(--usac-blue);
}

/* COORDINATOR FORM STYLES */
.coordinator-form-grid {
  display: grid;
  grid-template-columns: 12fr;
  gap: 24px;
  padding: 40px;
}

.form-section-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--usac-blue);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--usac-gold);
}


/* ============================================
   PDF RENDERING STYLES
   ============================================ */
.pdf-container {
  padding: 40px;
  font-family: 'Inter', sans-serif;
  background: white;
  color: #1a1a1a;
  max-width: 800px;
  margin: 0 auto;
}

.pdf-header {
  border-bottom: 2px solid #003366;
  padding-bottom: 20px;
  margin-bottom: 30px;
  text-align: center;
}

.pdf-header h1 {
  font-size: 24px;
  color: #003366;
  margin: 15px 0 5px;
  text-transform: uppercase;
}

.pdf-body h3 {
  font-size: 16px;
  color: #003366;
  border-left: 4px solid #cc9900;
  padding-left: 10px;
  margin: 25px 0 15px;
}

.pdf-body p {
  margin: 8px 0;
  line-height: 1.5;
}

.report-checkbox {
  width: 18px;
  height: 18px;
  cursor: pointer;
}

/* ============================================
   APP SPLASH / VALIDATION LOADER
   ============================================ */
.app-splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.app-splash.splash-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.splash-backdrop {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #060d1f 0%, #0d1b3e 45%, #0a2252 70%, #071530 100%);
}
.splash-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  padding: 48px 40px;
  text-align: center;
}

/* Logo ring */
.splash-logo-wrap {
  position: relative;
  width: 140px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.splash-logo {
  width: 100px;
  height: 100px;
  object-fit: contain;
  animation: splashLogoIn 0.8s cubic-bezier(0.34,1.56,0.64,1) both;
  filter: drop-shadow(0 0 24px rgba(198,164,77,0.35));
}
.splash-logo-fallback {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: rgba(198,164,77,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 56px;
  color: #c6a44d;
}
.splash-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2.5px solid transparent;
  border-top-color: #c6a44d;
  border-right-color: rgba(198,164,77,0.3);
  animation: splashSpin 1.2s linear infinite;
}

/* Title */
.splash-title {
  display: flex;
  flex-direction: column;
  gap: 4px;
  animation: splashFadeUp 0.7s 0.2s ease both;
}
.splash-faculty {
  font-family: 'Outfit', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}
.splash-usac {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.5px;
}

/* Spinner dots */
.splash-status-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  animation: splashFadeUp 0.7s 0.4s ease both;
}
.splash-spinner {
  position: relative;
  width: 36px;
  height: 36px;
}
.spin-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #c6a44d;
  animation: spinOrbit 1.4s linear infinite;
}
.spin-dot:nth-child(1) { animation-delay: 0s;     top: 0;    left: 50%; transform: translateX(-50%); }
.spin-dot:nth-child(2) { animation-delay: 0.35s;  top: 50%;  right: 0;  transform: translateY(-50%); }
.spin-dot:nth-child(3) { animation-delay: 0.7s;   bottom: 0; left: 50%; transform: translateX(-50%); }
.spin-dot:nth-child(4) { animation-delay: 1.05s;  top: 50%;  left: 0;   transform: translateY(-50%); }
@keyframes spinOrbit {
  0%   { opacity: 1;   transform: scale(1); }
  50%  { opacity: 0.3; transform: scale(0.6); }
  100% { opacity: 1;   transform: scale(1); }
}

.splash-status-text {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
  margin: 0;
  min-height: 20px;
  transition: opacity 0.3s ease;
  letter-spacing: 0.3px;
}

/* Progress bar */
.splash-progress-bar {
  width: 240px;
  height: 3px;
  background: rgba(255,255,255,0.1);
  border-radius: 99px;
  overflow: hidden;
  animation: splashFadeUp 0.7s 0.5s ease both;
}
.splash-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #c6a44d, #f0d080, #c6a44d);
  border-radius: 99px;
  transition: width 0.5s ease;
  background-size: 200% 100%;
  animation: shimmer 1.5s linear infinite;
}
@keyframes shimmer {
  0%   { background-position: 200% center; }
  100% { background-position: -200% center; }
}

/* Keyframes */
@keyframes splashSpin    { to { transform: rotate(360deg); } }
@keyframes splashLogoIn  { from { opacity:0; transform: scale(0.6); } to { opacity:1; transform: scale(1); } }
@keyframes splashFadeUp  { from { opacity:0; transform: translateY(16px); } to { opacity:1; transform: translateY(0); } }

/* ================================================================
   DASHBOARD TABLE LOADER
   ================================================================ */
.table-loader {
  width: 38px;
  height: 38px;
  border: 3px solid var(--gray-200);
  border-bottom-color: var(--usac-gold);
  border-radius: 50%;
  display: inline-block;
  box-sizing: border-box;
  animation: tableRotation 1s linear infinite;
}

@keyframes tableRotation {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loader-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  animation: tableFadeIn 0.4s ease-out;
}

@keyframes tableFadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

