/* ÜFÜQ Web App - Custom Styles */

/* CSS Variables for brand colors */
:root {
  --ufuq-primary: #4F46E5;
  --ufuq-primary-dark: #3730A3;
  --ufuq-secondary: #EC4899;
  --ufuq-accent: #F59E0B;
  --ufuq-gray-50: #F9FAFB;
  --ufuq-gray-100: #F3F4F6;
  --ufuq-gray-900: #111827;
}

/* Base styles */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Custom button styles */
.btn-primary {
  background: linear-gradient(135deg, var(--ufuq-primary), var(--ufuq-primary-dark));
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(79, 70, 229, 0.3);
}

.btn-secondary {
  background: linear-gradient(135deg, var(--ufuq-secondary), #DB2777);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
}

.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(236, 72, 153, 0.3);
}

/* Card styles */
.card {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Chat bubble styles */
.message-bubble {
  max-width: 80%;
  margin: 0.5rem 0;
  padding: 0.75rem 1rem;
  border-radius: 1rem;
  word-wrap: break-word;
}

.message-bubble.own {
  background: linear-gradient(135deg, var(--ufuq-primary), var(--ufuq-primary-dark));
  color: white;
  margin-left: auto;
  border-bottom-right-radius: 0.25rem;
}

.message-bubble.other {
  background: var(--ufuq-gray-100);
  color: var(--ufuq-gray-900);
  border-bottom-left-radius: 0.25rem;
}

.message-bubble.system {
  background: linear-gradient(135deg, var(--ufuq-accent), #D97706);
  color: white;
  text-align: center;
  margin: 1rem auto;
  font-style: italic;
}

/* Mood tracker styles */
.mood-slider {
  width: 100%;
  height: 8px;
  border-radius: 5px;
  background: linear-gradient(to right, #EF4444, #F59E0B, #10B981);
  outline: none;
  -webkit-appearance: none;
}

.mood-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: white;
  border: 3px solid var(--ufuq-primary);
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.mood-slider::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: white;
  border: 3px solid var(--ufuq-primary);
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

/* Room card styles */
.room-card {
  background: white;
  border-left: 4px solid var(--ufuq-primary);
  border-radius: 0.5rem;
  padding: 1.5rem;
  margin: 1rem 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  cursor: pointer;
}

.room-card:hover {
  border-left-color: var(--ufuq-secondary);
  transform: translateX(4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.room-card.active {
  border-left-color: var(--ufuq-accent);
  background: linear-gradient(135deg, #FEF3C7, #FDE68A);
}

/* Resource card styles */
.resource-card {
  background: white;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
  transition: all 0.3s ease;
}

.resource-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.resource-card .resource-type {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.resource-type.article {
  background: #DBEAFE;
  color: #1E40AF;
}

.resource-type.audio {
  background: #D1FAE5;
  color: #065F46;
}

.resource-type.video {
  background: #FEE2E2;
  color: #991B1B;
}

.resource-type.exercise {
  background: #F3E8FF;
  color: #6B21A8;
}

/* Progress bar styles */
.progress-bar {
  width: 100%;
  height: 8px;
  background: var(--ufuq-gray-100);
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--ufuq-primary), var(--ufuq-secondary));
  border-radius: 4px;
  transition: width 0.3s ease;
}

/* Loading spinner */
.spinner {
  border: 3px solid var(--ufuq-gray-100);
  border-top: 3px solid var(--ufuq-primary);
  border-radius: 50%;
  width: 30px;
  height: 30px;
  animation: spin 1s linear infinite;
  margin: 0 auto;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Chat input styles */
.chat-input {
  border: 2px solid var(--ufuq-gray-100);
  border-radius: 1.5rem;
  padding: 0.75rem 1rem;
  transition: all 0.3s ease;
}

.chat-input:focus {
  border-color: var(--ufuq-primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
  outline: none;
}

/* Navigation styles */
.nav-link {
  position: relative;
  padding: 0.5rem 1rem;
  color: var(--ufuq-gray-900);
  text-decoration: none;
  transition: all 0.3s ease;
}

.nav-link:hover {
  color: var(--ufuq-primary);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 1rem;
  right: 1rem;
  height: 2px;
  background: var(--ufuq-primary);
  border-radius: 1px;
}

/* Sidebar styles */
.sidebar {
  background: linear-gradient(180deg, #FAFBFE 0%, #F4F5F9 100%);
  border-right: 1px solid var(--ufuq-gray-100);
}

.sidebar-link {
  display: flex;
  align-items: center;
  padding: 0.75rem 1rem;
  color: var(--ufuq-gray-900);
  text-decoration: none;
  transition: all 0.3s ease;
  border-radius: 0.5rem;
  margin: 0.25rem 0.5rem;
}

.sidebar-link:hover {
  background: white;
  color: var(--ufuq-primary);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sidebar-link.active {
  background: linear-gradient(135deg, var(--ufuq-primary), var(--ufuq-primary-dark));
  color: white;
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

/* Badge styles */
.badge {
  display: inline-block;
  padding: 0.25rem 0.5rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-success {
  background: #D1FAE5;
  color: #065F46;
}

.badge-warning {
  background: #FEF3C7;
  color: #92400E;
}

.badge-danger {
  background: #FEE2E2;
  color: #991B1B;
}

.badge-info {
  background: #DBEAFE;
  color: #1E40AF;
}

/* Modal styles */
.modal-overlay {
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
}

.modal-content {
  animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translate(-50%, -60%);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%);
  }
}

/* Responsive design */
@media (max-width: 768px) {
  .message-bubble {
    max-width: 95%;
  }
  
  .room-card {
    margin: 0.5rem 0;
    padding: 1rem;
  }
  
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }
  
  .sidebar.open {
    transform: translateX(0);
  }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
  :root {
    --ufuq-gray-50: #1F2937;
    --ufuq-gray-100: #374151;
    --ufuq-gray-900: #F9FAFB;
  }
}

/* ÜFÜQ Landing Page Animations & Theme */

/* Hero Section Animations */
.hero-section {
  position: relative;
  min-height: 80vh;
  overflow: hidden;
}

/* Floating Background Shapes */
.floating-shapes {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.shape {
  position: absolute;
  border-radius: 50%;
  background: linear-gradient(45deg, rgba(79, 70, 229, 0.1), rgba(236, 72, 153, 0.1));
  animation: float 20s infinite linear;
}

.shape-1 {
  width: 80px;
  height: 80px;
  top: 10%;
  left: 10%;
  animation-delay: 0s;
}

.shape-2 {
  width: 120px;
  height: 120px;
  top: 70%;
  left: 80%;
  animation-delay: -5s;
}

.shape-3 {
  width: 60px;
  height: 60px;
  top: 20%;
  left: 70%;
  animation-delay: -10s;
}

.shape-4 {
  width: 100px;
  height: 100px;
  top: 80%;
  left: 20%;
  animation-delay: -15s;
}

.shape-5 {
  width: 40px;
  height: 40px;
  top: 50%;
  left: 50%;
  animation-delay: -2s;
}

@keyframes float {
  0% {
    transform: translateY(0px) rotate(0deg);
  }
  33% {
    transform: translateY(-30px) rotate(120deg);
  }
  66% {
    transform: translateY(30px) rotate(240deg);
  }
  100% {
    transform: translateY(0px) rotate(360deg);
  }
}

/* Hero Content Animations */
.fade-in {
  animation: fadeInUp 1s ease-out;
}

.slide-in-left {
  animation: slideInLeft 1s ease-out;
}

.slide-in-right {
  animation: slideInRight 1s ease-out 0.3s both;
}

.slide-up {
  animation: slideUp 1s ease-out 0.6s both;
}

.action-buttons {
  animation: slideUp 1s ease-out 0.9s both;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Motivational Badge */
.motivational-badge {
  display: inline-flex;
  align-items: center;
  background: linear-gradient(135deg, #FEF3C7, #FDE68A);
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  margin: 1rem 0;
  font-size: 0.875rem;
  font-weight: 600;
  color: #92400E;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
  from {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  }
  to {
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.3);
  }
}

/* Heartbeat Animation */
.heartbeat {
  animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
  0% {
    transform: scale(1);
  }
  14% {
    transform: scale(1.2);
  }
  28% {
    transform: scale(1);
  }
  42% {
    transform: scale(1.2);
  }
  70% {
    transform: scale(1);
  }
}

/* Bounce Animation */
.bounce {
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-10px);
  }
  60% {
    transform: translateY(-5px);
  }
}

/* CTA Button Animations */
.cta-button-primary {
  position: relative;
  overflow: hidden;
}

.cta-button-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.cta-button-primary:hover::before {
  left: 100%;
}

/* Success Ticker */
.success-ticker {
  animation: slideUp 1s ease-out 1.2s both;
}

.ticker-content {
  animation: ticker 15s linear infinite;
  white-space: nowrap;
}

@keyframes ticker {
  0% {
    transform: translateX(100%);
  }
  100% {
    transform: translateX(-100%);
  }
}

.pulse {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

/* Right Side Illustration */
.animated-gradient {
  animation: gradientShift 8s ease-in-out infinite;
}

@keyframes gradientShift {
  0%, 100% {
    background: linear-gradient(45deg, rgba(168, 85, 247, 0.1), rgba(236, 72, 153, 0.1), rgba(251, 146, 60, 0.1));
  }
  50% {
    background: linear-gradient(45deg, rgba(59, 130, 246, 0.1), rgba(168, 85, 247, 0.1), rgba(236, 72, 153, 0.1));
  }
}

/* Floating Elements */
.floating-element {
  position: absolute;
  animation: floatElement 6s ease-in-out infinite;
}

.element-1 {
  top: 20%;
  left: 20%;
  animation-delay: 0s;
}

.element-2 {
  top: 10%;
  right: 30%;
  animation-delay: -1s;
}

.element-3 {
  top: 60%;
  right: 20%;
  animation-delay: -2s;
}

.element-4 {
  bottom: 30%;
  left: 30%;
  animation-delay: -3s;
}

.element-5 {
  top: 40%;
  left: 10%;
  animation-delay: -4s;
}

@keyframes floatElement {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
    opacity: 0.6;
  }
  50% {
    transform: translateY(-20px) rotate(180deg);
    opacity: 1;
  }
}

/* Central Illustration */
.illustration-container {
  animation: fadeInScale 1.5s ease-out 1s both;
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.illustration-circle {
  width: 120px;
  height: 120px;
  background: linear-gradient(135deg, #EBF4FF, #DBEAFE);
  border: 3px solid #3B82F6;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  position: relative;
  animation: rotate 20s linear infinite;
}

.inner-circle {
  width: 80px;
  height: 80px;
  background: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.group-icon {
  animation: pulse 3s ease-in-out infinite;
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* Connection Lines */
.connection-lines {
  position: absolute;
  width: 200px;
  height: 200px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.line {
  position: absolute;
  width: 2px;
  height: 40px;
  background: linear-gradient(to bottom, #3B82F6, transparent);
  animation: pulse 2s ease-in-out infinite;
}

.line-1 {
  top: -50px;
  left: 50%;
  transform: translateX(-50%);
  animation-delay: 0s;
}

.line-2 {
  bottom: -50px;
  left: 50%;
  transform: translateX(-50%) rotate(180deg);
  animation-delay: 0.5s;
}

.line-3 {
  top: 50%;
  left: -50px;
  transform: translateY(-50%) rotate(90deg);
  animation-delay: 1s;
}

.line-4 {
  top: 50%;
  right: -50px;
  transform: translateY(-50%) rotate(-90deg);
  animation-delay: 1.5s;
}

/* Enhanced Features Section Animation */
#features {
  animation: slideUp 1s ease-out;
}

.features-header {
  animation: slideUp 1s ease-out 0.2s both;
}

.feature-item {
  animation: featureSlideIn 1s ease-out both;
  transition: all 0.3s ease;
}

.feature-item:nth-child(1) {
  animation-delay: 0.4s;
}

.feature-item:nth-child(2) {
  animation-delay: 0.6s;
}

.feature-item:nth-child(3) {
  animation-delay: 0.8s;
}

.feature-item:nth-child(4) {
  animation-delay: 1s;
}

@keyframes featureSlideIn {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.feature-item:hover {
  transform: translateY(-8px);
}

.feature-icon-container {
  position: relative;
  overflow: hidden;
}

.feature-icon-container::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: rotate(45deg);
  transition: all 0.6s ease;
  opacity: 0;
}

.feature-item:hover .feature-icon-container::before {
  animation: shimmer 0.6s ease;
}

@keyframes shimmer {
  0% {
    opacity: 0;
    transform: rotate(45deg) translateX(-200%);
  }
  50% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: rotate(45deg) translateX(200%);
  }
}

.feature-icon {
  transition: all 0.3s ease;
}

.feature-item:hover .feature-icon {
  transform: scale(1.1) rotate(5deg);
}

/* Bonus Features Animation */
.bonus-feature {
  animation: bonusFeatureFade 1s ease-out both;
}

.bonus-feature:nth-child(1) {
  animation-delay: 1.2s;
}

.bonus-feature:nth-child(2) {
  animation-delay: 1.4s;
}

.bonus-feature:nth-child(3) {
  animation-delay: 1.6s;
}

@keyframes bonusFeatureFade {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.bonus-feature:hover {
  transform: translateY(-5px);
}

.bonus-feature:hover > div {
  transform: scale(1.1);
  animation: wiggle 0.6s ease-in-out;
}

@keyframes wiggle {
  0%, 100% {
    transform: scale(1.1) rotate(0deg);
  }
  25% {
    transform: scale(1.1) rotate(-3deg);
  }
  75% {
    transform: scale(1.1) rotate(3deg);
  }
}

/* Statistics Section Animations */
.stats-header {
  animation: slideUp 1s ease-out;
}

.slide-in-up {
  animation: slideInUp 1s ease-out 0.3s both;
}

.slide-in-up-delay {
  animation: slideInUp 1s ease-out 0.6s both;
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.stat-card {
  animation: statCardFadeIn 1s ease-out both;
  position: relative;
  overflow: hidden;
}

.stat-card:nth-child(1) {
  animation-delay: 0.9s;
}

.stat-card:nth-child(2) {
  animation-delay: 1.1s;
}

.stat-card:nth-child(3) {
  animation-delay: 1.3s;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transition: left 0.8s ease;
}

.stat-card:hover::before {
  left: 100%;
}

@keyframes statCardFadeIn {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.animate-number {
  animation: numberCountUp 2s ease-out 1.5s both;
}

@keyframes numberCountUp {
  from {
    opacity: 0;
    transform: scale(0.5);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Testimonial Card Animation */
.testimonial-card {
  animation: testimonialFade 1s ease-out 1.6s both;
  position: relative;
}

.testimonial-card::after {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, #4F46E5, #7C3AED, #EC4899, #F59E0B);
  border-radius: 1rem;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.testimonial-card:hover::after {
  opacity: 0.7;
}

@keyframes testimonialFade {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Number Animation Effect */
.animate-number {
  display: inline-block;
  animation: digitRoll 3s ease-out 2s both;
}

@keyframes digitRoll {
  0% {
    transform: rotateX(90deg);
    opacity: 0;
  }
  50% {
    transform: rotateX(0deg);
    opacity: 0.5;
  }
  100% {
    transform: rotateX(0deg);
    opacity: 1;
  }
}

/* Gradient Text Animation */
.bg-gradient-to-r {
  background-size: 200% auto;
  animation: gradientFlow 3s linear infinite;
}

@keyframes gradientFlow {
  0%, 100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

/* Responsive Animations */
@media (max-width: 768px) {
  .floating-shapes {
    display: none;
  }
  
  .illustration-container {
    display: none;
  }
  
  .floating-element {
    display: none;
  }
  
  .motivational-badge {
    font-size: 0.75rem;
    padding: 0.375rem 0.75rem;
  }
}

/* Accessibility - Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .shape,
  .floating-element,
  .illustration-circle,
  .ticker-content,
  .heartbeat,
  .bounce {
    animation: none !important;
  }
  
  .fade-in,
  .slide-in-left,
  .slide-in-right,
  .slide-up,
  .action-buttons {
    animation: none !important;
    opacity: 1;
    transform: none;
  }
}

/* Dashboard Enhancement Styles */
.dashboard-container {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  min-height: 100vh;
  padding: 0;
}

.dashboard-header {
  background: linear-gradient(135deg, #4338ca 0%, #6366f1 100%);
  color: white;
  padding: 1rem 0 1.5rem;
  box-shadow: 0 4px 20px rgba(67, 56, 202, 0.15);
  border-radius: 0 0 16px 16px;
  margin-bottom: 1rem;
  animation: slideDown 0.8s ease-out;
}

@media (min-width: 640px) {
  .dashboard-header {
    padding: 1.5rem 0 2rem;
    border-radius: 0 0 24px 24px;
    margin-bottom: 2rem;
  }
}

@keyframes slideDown {
  from {
    transform: translateY(-100px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.dashboard-nav {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.nav-btn {
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.2);
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.3s ease;
  cursor: pointer;
  backdrop-filter: blur(10px);
  animation: navBtnSlide 0.6s ease-out both;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  text-align: center;
  font-size: 0.875rem;
}

@media (min-width: 1024px) {
  .nav-btn {
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    min-width: auto;
  }
}

.nav-btn:nth-child(1) { animation-delay: 0.1s; }
.nav-btn:nth-child(2) { animation-delay: 0.2s; }
.nav-btn:nth-child(3) { animation-delay: 0.3s; }
.nav-btn:nth-child(4) { animation-delay: 0.4s; }
.nav-btn:nth-child(5) { animation-delay: 0.5s; }
.nav-btn:nth-child(6) { animation-delay: 0.6s; }

@keyframes navBtnSlide {
  from {
    transform: translateX(-50px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.nav-btn:hover, .nav-btn.active {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.dashboard-content {
  padding: 0 1rem 1rem;
  max-width: 1200px;
  margin: 0 auto;
}

@media (min-width: 640px) {
  .dashboard-content {
    padding: 0 1.5rem 1.5rem;
  }
}

@media (min-width: 1024px) {
  .dashboard-content {
    padding: 0 2rem 2rem;
  }
}

.dashboard-section {
  display: none;
  animation: sectionFadeIn 0.5s ease-out;
}

.dashboard-section.active {
  display: block;
}

@keyframes sectionFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section-header {
  display: flex;
  justify-content: between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid #e2e8f0;
}

.section-title {
  color: #1e293b;
  font-size: 2rem;
  font-weight: 700;
  margin: 0;
  position: relative;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 50px;
  height: 4px;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  border-radius: 2px;
  animation: titleUnderline 1s ease-out 0.5s both;
}

@keyframes titleUnderline {
  from {
    width: 0;
  }
  to {
    width: 50px;
  }
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.dashboard-card {
  background: #ffffff !important;
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid #f1f5f9;
  transition: all 0.3s ease;
  animation: cardSlideUp 0.6s ease-out both;
  position: relative;
  overflow: hidden;
}

.dashboard-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.dashboard-card:hover::before {
  transform: scaleX(1);
}

.dashboard-card:nth-child(1) { animation-delay: 0.1s; }
.dashboard-card:nth-child(2) { animation-delay: 0.2s; }
.dashboard-card:nth-child(3) { animation-delay: 0.3s; }
.dashboard-card:nth-child(4) { animation-delay: 0.4s; }

@keyframes cardSlideUp {
  from {
    transform: translateY(30px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.dashboard-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

.card-header {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 1rem;
  font-size: 1.5rem;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  color: white;
  animation: iconPulse 2s ease-in-out infinite;
}

@keyframes iconPulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.card-title {
  color: #1e293b;
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0;
}

.card-content {
  color: #64748b;
  line-height: 1.6;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: #4338ca;
  margin-bottom: 0.5rem;
  animation: countUp 2s ease-out;
}

@keyframes countUp {
  from {
    transform: scale(0.5);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.chat-room-list {
  display: grid;
  gap: 1rem;
  margin-top: 1.5rem;
}

.room-item {
  background: white;
  border-radius: 12px;
  padding: 1.25rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  border: 1px solid #f1f5f9;
  transition: all 0.3s ease;
  cursor: pointer;
  animation: roomSlide 0.5s ease-out both;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.room-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
  border-color: #e2e8f0;
}

.room-item:nth-child(odd) {
  animation-delay: 0.1s;
}

.room-item:nth-child(even) {
  animation-delay: 0.2s;
}

@keyframes roomSlide {
  from {
    transform: translateX(-30px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.room-item:hover {
  transform: translateX(5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  border-color: #4338ca;
}

.room-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.room-name {
  font-weight: 600;
  color: #1e293b;
  margin: 0 0 0.25rem 0;
}

.room-description {
  color: #64748b;
  font-size: 0.9rem;
  margin: 0;
}

.room-meta {
  text-align: right;
  font-size: 0.8rem;
  color: #94a3b8;
}

.participants-count {
  background: #4338ca;
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  display: inline-block;
  margin-top: 0.25rem;
  animation: bounceIn 0.8s ease-out;
}

@keyframes bounceIn {
  0% {
    transform: scale(0.3);
    opacity: 0;
  }
  50% {
    transform: scale(1.05);
  }
  70% {
    transform: scale(0.9);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.mood-tracker {
  text-align: center;
}

.mood-buttons {
  display: flex;
  justify-content: space-around;
  margin: 1.5rem 0;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mood-btn {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 50px;
  padding: 1rem 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1.5rem;
  animation: moodFloat 0.6s ease-out both;
}

.mood-btn:nth-child(1) { animation-delay: 0.1s; }
.mood-btn:nth-child(2) { animation-delay: 0.2s; }
.mood-btn:nth-child(3) { animation-delay: 0.3s; }
.mood-btn:nth-child(4) { animation-delay: 0.4s; }
.mood-btn:nth-child(5) { animation-delay: 0.5s; }

@keyframes moodFloat {
  from {
    transform: translateY(30px) rotate(-10deg);
    opacity: 0;
  }
  to {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
}

.mood-btn:hover {
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.mood-btn.selected {
  background: #4338ca;
  color: white;
  border-color: #4338ca;
  transform: scale(1.1);
  animation: selectedPulse 0.5s ease-out;
}

@keyframes selectedPulse {
  0% {
    transform: scale(1.1);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1.1);
  }
}

.resources-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.resource-item {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  animation: resourceReveal 0.6s ease-out both;
  cursor: pointer;
}

.resource-item:nth-child(3n+1) { animation-delay: 0.1s; }
.resource-item:nth-child(3n+2) { animation-delay: 0.2s; }
.resource-item:nth-child(3n+3) { animation-delay: 0.3s; }

@keyframes resourceReveal {
  from {
    transform: scale(0.8) rotateY(20deg);
    opacity: 0;
  }
  to {
    transform: scale(1) rotateY(0deg);
    opacity: 1;
  }
}

.resource-item:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

.resource-content {
  padding: 1.5rem;
}

.resource-title {
  font-weight: 600;
  color: #1e293b;
  margin: 0 0 0.5rem 0;
  font-size: 1.1rem;
}

.resource-description {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.5;
  margin: 0;
}

.resource-category {
  background: linear-gradient(135deg, #4338ca, #6366f1);
  color: white;
  padding: 0.25rem 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.loading-spinner {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid #4338ca;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 0.5rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.success-message, .error-message {
  padding: 1rem 1.5rem;
  border-radius: 8px;
  margin: 1rem 0;
  font-weight: 500;
  animation: messageSlide 0.5s ease-out;
}

@keyframes messageSlide {
  from {
    transform: translateX(-100px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.success-message {
  background: #dcfce7;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.error-message {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
}

.profile-section {
  max-width: 600px;
  margin: 0 auto;
}

.profile-form {
  display: grid;
  gap: 1.5rem;
}

.form-group {
  animation: formSlide 0.5s ease-out both;
}

.form-group:nth-child(1) { animation-delay: 0.1s; }
.form-group:nth-child(2) { animation-delay: 0.2s; }
.form-group:nth-child(3) { animation-delay: 0.3s; }
.form-group:nth-child(4) { animation-delay: 0.4s; }

@keyframes formSlide {
  from {
    transform: translateX(-30px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.form-label {
  display: block;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.5rem;
}

.form-input, .form-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 1rem;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.form-input:focus, .form-textarea:focus {
  outline: none;
  border-color: #4338ca;
  box-shadow: 0 0 0 3px rgba(67, 56, 202, 0.1);
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, #4338ca, #6366f1);
  color: white;
  border: none;
  padding: 0.875rem 2rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
  animation: btnAppear 0.6s ease-out both;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(67, 56, 202, 0.3);
}

@keyframes btnAppear {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

/* Additional Button Styles */
.btn-secondary {
  background: #f8fafc;
  color: #4338ca;
  border: 2px solid #4338ca;
  padding: 0.875rem 2rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
  animation: btnAppear 0.6s ease-out both;
}

.btn-secondary:hover {
  background: #4338ca;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(67, 56, 202, 0.3);
}

.btn-sm {
  padding: 0.5rem 1rem !important;
  font-size: 0.875rem !important;
}

/* Pulse Animation for Online Indicator */
.pulse-animation {
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.1);
  }
}

/* Enhanced Space Utilities */
.space-y-3 > * + * {
  margin-top: 0.75rem;
}

/* Loading States */
.loading-state {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  color: #64748b;
  font-style: italic;
}

/* Enhanced Card Interactions */
.dashboard-card:active {
  transform: translateY(-2px) scale(0.98);
}

.resource-item:active {
  transform: translateY(-5px) scale(0.98);
}

.room-item:active {
  transform: translateX(3px) scale(0.98);
}

/* Progress Indicators */
.progress-bar {
  width: 100%;
  height: 8px;
  background: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
  margin: 0.5rem 0;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  border-radius: 4px;
  transition: width 0.3s ease;
  animation: progressGrow 2s ease-out;
}

@keyframes progressGrow {
  from {
    width: 0;
  }
}

/* Enhanced Modal Animations */
.modal-overlay {
  animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-content {
  animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translate(-50%, -60%) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

/* Enhanced Hover States */
.nav-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Badge Styles */
.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

.badge-info {
  background-color: #dbeafe;
  color: #1e40af;
}

.badge-success {
  background-color: #dcfce7;
  color: #166534;
}

.badge-warning {
  background-color: #fef3c7;
  color: #92400e;
}

.badge-error {
  background-color: #fecaca;
  color: #dc2626;
}

/* Enhanced Typography */
.text-gradient {
  background: linear-gradient(135deg, #4338ca, #6366f1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Glassmorphism Effects */
.glass-effect {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Enhanced Chat Styles */
.message-bubble {
  padding: 0.75rem 1rem;
  border-radius: 18px;
  max-width: 100%;
  word-wrap: break-word;
  animation: messageSlide 0.3s ease-out;
}

@keyframes messageSlide {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.message-bubble.own {
  background: linear-gradient(135deg, #4338ca, #6366f1);
  color: white;
  margin-left: 2rem;
}

.message-bubble.other {
  background: white;
  color: #1f2937;
  border: 1px solid #e5e7eb;
  margin-right: 2rem;
}

.message-bubble.system {
  background: #f3f4f6;
  color: #4b5563;
  border: 1px solid #d1d5db;
  text-align: center;
  font-style: italic;
}

/* Chat Input Enhancement */
.chat-input {
  border: 2px solid #e5e7eb;
  border-radius: 24px;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  transition: all 0.3s ease;
  width: 100%;
  outline: none;
}

.chat-input:focus {
  border-color: #4338ca;
  box-shadow: 0 0 0 3px rgba(67, 56, 202, 0.1);
}

.chat-input:disabled {
  background: #f9fafb;
  cursor: not-allowed;
}

/* Typing Indicator Animation */
.typing-dots {
  display: inline-flex;
  align-items: center;
  space-x: 2px;
}

.typing-dots span {
  height: 4px;
  width: 4px;
  background: #6b7280;
  border-radius: 50%;
  display: inline-block;
  animation: typingBounce 1.4s ease-in-out infinite both;
}

.typing-dots span:nth-child(1) {
  animation-delay: -0.32s;
}

.typing-dots span:nth-child(2) {
  animation-delay: -0.16s;
}

.typing-dots span:nth-child(3) {
  animation-delay: 0s;
}

@keyframes typingBounce {
  0%, 80%, 100% {
    transform: scale(0);
  }
  40% {
    transform: scale(1);
  }
}

/* Art Wall - Masonry Grid Styles */
.art-grid-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
}

.art-masonry-grid {
  display: columns;
  columns: 4;
  column-gap: 1.5rem;
  padding: 1rem 0;
}

@media (max-width: 1024px) {
  .art-masonry-grid {
    columns: 3;
    column-gap: 1rem;
  }
}

@media (max-width: 768px) {
  .art-masonry-grid {
    columns: 2;
    column-gap: 0.75rem;
  }
}

@media (max-width: 480px) {
  .art-masonry-grid {
    columns: 1;
    column-gap: 0;
  }
}

.art-item {
  break-inside: avoid;
  margin-bottom: 1.5rem;
  border-radius: 12px;
  overflow: hidden;
  background: white;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  animation: artItemFadeIn 0.6s ease-out both;
  cursor: pointer;
  position: relative;
}

.art-item:nth-child(4n+1) { animation-delay: 0.1s; }
.art-item:nth-child(4n+2) { animation-delay: 0.2s; }
.art-item:nth-child(4n+3) { animation-delay: 0.3s; }
.art-item:nth-child(4n+4) { animation-delay: 0.4s; }

@keyframes artItemFadeIn {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.art-item:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  z-index: 10;
}

.art-image {
  width: 100%;
  height: auto;
  display: block;
  transition: all 0.3s ease;
}

.art-item:hover .art-image {
  transform: scale(1.05);
}

.art-content {
  padding: 1.25rem;
  background: white;
}

.art-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1e293b;
  margin: 0 0 0.5rem 0;
  line-height: 1.4;
}

.art-description {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.5;
  margin: 0 0 1rem 0;
}

.art-author {
  color: #94a3b8;
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.art-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 0.75rem;
  border-top: 1px solid #f1f5f9;
}

.art-likes {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.like-btn {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.5rem;
  border-radius: 6px;
  transition: all 0.3s ease;
  color: #64748b;
  font-size: 0.9rem;
}

.like-btn:hover {
  background: #f1f5f9;
  color: #e11d48;
  transform: scale(1.05);
}

.like-btn.liked {
  color: #e11d48;
  animation: likeHeartbeat 0.6s ease-out;
}

@keyframes likeHeartbeat {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}

.like-count {
  font-weight: 600;
  min-width: 20px;
  text-align: center;
}

.art-date {
  color: #94a3b8;
  font-size: 0.8rem;
}

/* Art Wall Header */
.artwall-header {
  text-align: center;
  margin: 2rem 0 3rem;
  animation: slideDown 0.8s ease-out;
}

.artwall-title {
  font-size: 2.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, #4338ca, #6366f1, #ec4899);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1rem;
  animation: gradientFlow 3s linear infinite;
}

.artwall-subtitle {
  color: #64748b;
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 2rem;
}

.submit-art-btn {
  background: linear-gradient(135deg, #ec4899, #f97316);
  color: white;
  border: none;
  padding: 1rem 2rem;
  border-radius: 12px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  animation: btnBounce 2s ease-in-out infinite;
  position: relative;
  overflow: hidden;
}

.submit-art-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.submit-art-btn:hover::before {
  left: 100%;
}

.submit-art-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 15px 35px rgba(236, 72, 153, 0.4);
}

@keyframes btnBounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-5px);
  }
}

/* Art Submission Modal */
.art-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  animation: modalFadeIn 0.3s ease-out;
  padding: 1rem;
}

.art-modal-content {
  background: white;
  border-radius: 16px;
  padding: 2rem;
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlideIn 0.3s ease-out;
  position: relative;
}

.art-modal h3 {
  color: #1e293b;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 1.5rem 0;
  text-align: center;
}

.art-form {
  display: grid;
  gap: 1.5rem;
}

.art-form-group {
  animation: formGroupSlide 0.5s ease-out both;
}

.art-form-group:nth-child(1) { animation-delay: 0.1s; }
.art-form-group:nth-child(2) { animation-delay: 0.2s; }
.art-form-group:nth-child(3) { animation-delay: 0.3s; }
.art-form-group:nth-child(4) { animation-delay: 0.4s; }

@keyframes formGroupSlide {
  from {
    transform: translateX(-30px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.art-form label {
  display: block;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.5rem;
}

.art-form input,
.art-form textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 1rem;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.art-form input:focus,
.art-form textarea:focus {
  outline: none;
  border-color: #ec4899;
  box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.1);
  transform: translateY(-1px);
}

.art-form textarea {
  resize: vertical;
  min-height: 100px;
}

.art-checkbox-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: #f8fafc;
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.art-checkbox-group input[type="checkbox"] {
  width: auto;
  margin: 0;
}

.art-checkbox-group label {
  margin: 0;
  cursor: pointer;
  font-weight: 500;
  color: #64748b;
}

.art-form-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 1rem;
}

.art-btn-submit {
  background: linear-gradient(135deg, #ec4899, #f97316);
  color: white;
  border: none;
  padding: 0.875rem 2rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
}

.art-btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(236, 72, 153, 0.3);
}

.art-btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.art-btn-cancel {
  background: #f8fafc;
  color: #64748b;
  border: 2px solid #e2e8f0;
  padding: 0.875rem 2rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
}

.art-btn-cancel:hover {
  background: #e2e8f0;
  transform: translateY(-1px);
}

.art-close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: #f1f5f9;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
  font-size: 1.25rem;
  transition: all 0.3s ease;
}

.art-close-btn:hover {
  background: #e2e8f0;
  color: #374151;
  transform: rotate(90deg);
}

/* Lightbox for Art Viewing */
.art-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1001;
  animation: modalFadeIn 0.3s ease-out;
  padding: 2rem;
}

.art-lightbox-content {
  max-width: 90vw;
  max-height: 90vh;
  position: relative;
  animation: lightboxZoom 0.3s ease-out;
}

@keyframes lightboxZoom {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.art-lightbox img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.art-lightbox-close {
  position: absolute;
  top: -50px;
  right: 0;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.3);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.art-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.5);
  transform: rotate(90deg);
}

/* Loading State for Art Wall */
.art-loading {
  text-align: center;
  padding: 4rem 2rem;
  color: #64748b;
}

.art-loading-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #f3f4f6;
  border-top: 4px solid #ec4899;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

.art-empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: #64748b;
}

.art-empty-icon {
  font-size: 4rem;
  color: #cbd5e1;
  margin-bottom: 1rem;
}

/* Featured Art Spotlight */
.art-featured {
  position: relative;
  overflow: visible;
}

.art-featured::before {
  content: '⭐';
  position: absolute;
  top: -5px;
  right: -5px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  z-index: 10;
  animation: featuredPulse 2s ease-in-out infinite;
  box-shadow: 0 4px 15px rgba(245, 158, 11, 0.4);
}

@keyframes featuredPulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

.art-featured .art-item {
  border: 2px solid #f59e0b;
  box-shadow: 0 8px 30px rgba(245, 158, 11, 0.2);
}

/* Responsive Adjustments for Art Wall */
@media (max-width: 640px) {
  .artwall-title {
    font-size: 2rem;
  }
  
  .artwall-subtitle {
    font-size: 1rem;
    padding: 0 1rem;
  }
  
  .submit-art-btn {
    padding: 0.875rem 1.5rem;
    font-size: 0.9rem;
  }
  
  .art-modal-content {
    margin: 1rem;
    padding: 1.5rem;
  }
  
  .art-form-buttons {
    flex-direction: column;
  }
  
  .art-btn-submit,
  .art-btn-cancel {
    width: 100%;
  }
  
  .art-lightbox {
    padding: 1rem;
  }
  
  .art-lightbox-close {
    top: -40px;
    width: 36px;
    height: 36px;
  }
}
  margin-right: 2px;
  animation: typingDot 1.4s ease-in-out infinite both;
}

.typing-dots span:nth-child(1) {
  animation-delay: -0.32s;
}

.typing-dots span:nth-child(2) {
  animation-delay: -0.16s;
}

@keyframes typingDot {
  0%, 80%, 100% {
    opacity: 0.3;
    transform: scale(0.8);
  }
  40% {
    opacity: 1;
    transform: scale(1);
  }
}

/* Participant List Styles */
.participant-item {
  display: flex;
  align-items: center;
  padding: 0.5rem;
  border-radius: 8px;
  transition: all 0.2s ease;
  animation: participantSlide 0.3s ease-out;
}

@keyframes participantSlide {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.participant-item:hover {
  background: #f3f4f6;
}

.participant-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.875rem;
  font-weight: 600;
  margin-right: 0.75rem;
}

.participant-status {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-left: auto;
}

.participant-status.online {
  background: #10b981;
  animation: pulse 2s ease-in-out infinite;
}

.participant-status.offline {
  background: #6b7280;
}

/* Message Item Hover Effects */
.message-item {
  transition: all 0.2s ease;
}

.message-item:hover {
  transform: translateY(-1px);
}

.message-item:hover .message-bubble {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Mobile Sidebar Animation */
#mobileSidebar {
  transition: transform 0.3s ease-in-out;
}

#mobileSidebarOverlay {
  transition: opacity 0.3s ease-in-out;
}

/* Enhanced Scrollbar for Chat */
#messagesContainer::-webkit-scrollbar {
  width: 6px;
}

#messagesContainer::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

#messagesContainer::-webkit-scrollbar-thumb {
  background: #c1c1c1;
  border-radius: 3px;
}

#messagesContainer::-webkit-scrollbar-thumb:hover {
  background: #a8a8a8;
}

/* Date Separator Styles */
.date-separator {
  display: flex;
  align-items: center;
  margin: 1rem 0;
}

.date-separator::before,
.date-separator::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #e5e7eb;
}

.date-separator span {
  padding: 0 1rem;
  font-size: 0.75rem;
  color: #6b7280;
  background: white;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
}

/* Enhanced Room Info Cards */
.room-info-card {
  background: white;
  border-radius: 12px;
  padding: 1rem;
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
}

.room-info-card:hover {
  border-color: #4338ca;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(67, 56, 202, 0.1);
}

/* Enhanced Button Styles for Chat */
.chat-action-btn {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #64748b;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
}

.chat-action-btn:hover {
  background: #4338ca;
  color: white;
  border-color: #4338ca;
  transform: translateY(-1px);
}

.chat-action-btn:active {
  transform: translateY(0);
}

/* Online Status Indicator */
.online-indicator {
  display: inline-flex;
  align-items: center;
  font-size: 0.75rem;
  color: #10b981;
}

.online-indicator::before {
  content: '';
  width: 6px;
  height: 6px;
  background: #10b981;
  border-radius: 50%;
  margin-right: 0.5rem;
  animation: pulse 2s ease-in-out infinite;
}

/* Character Counter Styles */
#charCount {
  transition: color 0.2s ease;
}

input:focus + #charCount {
  color: #4338ca;
}

/* Emergency Alert Box Enhancement */
.emergency-alert {
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border: 2px solid #fecaca;
  border-radius: 12px;
  padding: 1rem;
  text-align: center;
  animation: emergencyPulse 3s ease-in-out infinite;
}

@keyframes emergencyPulse {
  0%, 100% {
    border-color: #fecaca;
  }
  50% {
    border-color: #f87171;
  }
}

/* Notification Badge */
.notification-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ef4444;
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 600;
  animation: badgeBounce 0.5s ease-out;
}

@keyframes badgeBounce {
  0% {
    transform: scale(0);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}

/* Enhanced Mood Tracking Styles */
.mood-slider, .energy-slider, .anxiety-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 8px;
  border-radius: 5px;
  outline: none;
  opacity: 0.7;
  transition: opacity 0.2s;
  cursor: pointer;
  margin: 0.5rem 0;
}

.mood-slider {
  background: linear-gradient(to right, #ef4444, #f59e0b, #10b981);
}

.energy-slider {
  background: linear-gradient(to right, #6b7280, #10b981, #22c55e);
}

.anxiety-slider {
  background: linear-gradient(to right, #22c55e, #f59e0b, #ef4444);
}

.mood-slider:hover, .energy-slider:hover, .anxiety-slider:hover {
  opacity: 1;
}

/* Slider thumbs */
.mood-slider::-webkit-slider-thumb,
.energy-slider::-webkit-slider-thumb,
.anxiety-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  height: 20px;
  width: 20px;
  border-radius: 50%;
  background: #4338ca;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  transition: all 0.2s ease;
}

.mood-slider::-webkit-slider-thumb:hover,
.energy-slider::-webkit-slider-thumb:hover,
.anxiety-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 4px 12px rgba(67, 56, 202, 0.4);
}

/* Firefox */
.mood-slider::-moz-range-thumb,
.energy-slider::-moz-range-thumb,
.anxiety-slider::-moz-range-thumb {
  height: 20px;
  width: 20px;
  border-radius: 50%;
  background: #4338ca;
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  transition: all 0.2s ease;
}

/* Enhanced Progress Bar */
.progress-bar {
  width: 100%;
  height: 8px;
  background: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
  margin: 0.5rem 0;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.progress-fill {
  height: 100%;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  border-radius: 4px;
  transition: width 0.8s ease-out;
  animation: progressGlow 2s ease-in-out infinite alternate;
  position: relative;
}

@keyframes progressGlow {
  0% {
    box-shadow: 0 0 5px rgba(67, 56, 202, 0.3);
  }
  100% {
    box-shadow: 0 0 20px rgba(67, 56, 202, 0.6);
  }
}

.progress-fill::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  animation: progressShine 2s ease-in-out infinite;
}

@keyframes progressShine {
  0% {
    left: -100%;
  }
  100% {
    left: 100%;
  }
}

/* Mood Statistics Cards */
.stat-card {
  background: white;
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid #f1f5f9;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.stat-card:hover::before {
  transform: scaleX(1);
}

.stat-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

/* Chart Container Enhancements */
.chart-container {
  position: relative;
  padding: 1rem;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* Mood Emoji Animation */
#moodEmoji {
  font-size: 2rem;
  transition: all 0.3s ease;
  display: inline-block;
}

#moodEmoji:hover {
  transform: scale(1.2) rotate(10deg);
}

/* Enhanced Insight Cards */
.insight-card {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-left: 4px solid #4338ca;
  border-radius: 0 12px 12px 0;
  padding: 1rem 1.5rem;
  margin: 0.5rem 0;
  transition: all 0.3s ease;
  animation: insightSlide 0.5s ease-out;
}

@keyframes insightSlide {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.insight-card:hover {
  background: linear-gradient(135deg, #4338ca 0%, #6366f1 100%);
  color: white;
  transform: translateX(5px);
  box-shadow: 0 8px 25px rgba(67, 56, 202, 0.25);
}

/* Grid Layout Enhancements */
.grid {
  display: grid;
}

.grid-cols-1 {
  grid-template-columns: repeat(1, minmax(0, 1fr));
}

.grid-cols-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.gap-4 {
  gap: 1rem;
}

.gap-6 {
  gap: 1.5rem;
}

/* Responsive Grid */
@media (min-width: 768px) {
  .md\:grid-cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .lg\:grid-cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Enhanced Mood Button Styles */
.mood-buttons {
  display: flex;
  justify-content: space-around;
  margin: 1.5rem 0;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mood-btn {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: moodBtnFloat 0.6s ease-out both;
  position: relative;
}

.mood-btn::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  padding: 4px;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.mood-btn:hover::after {
  opacity: 1;
}

.mood-btn:nth-child(1) { animation-delay: 0.1s; }
.mood-btn:nth-child(2) { animation-delay: 0.2s; }
.mood-btn:nth-child(3) { animation-delay: 0.3s; }
.mood-btn:nth-child(4) { animation-delay: 0.4s; }
.mood-btn:nth-child(5) { animation-delay: 0.5s; }

@keyframes moodBtnFloat {
  from {
    transform: translateY(30px) rotate(-10deg);
    opacity: 0;
  }
  to {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
}

.mood-btn:hover {
  transform: scale(1.15) rotate(5deg);
  box-shadow: 0 8px 25px rgba(67, 56, 202, 0.2);
  border-color: #4338ca;
}

.mood-btn:active {
  transform: scale(1.05);
}

/* Text Utilities */
.text-center { text-align: center; }
.font-semibold { font-weight: 600; }
.text-indigo-600 { color: #4338ca; }
.text-green-600 { color: #10b981; }
.text-yellow-600 { color: #d97706; }
.text-red-600 { color: #dc2626; }
.text-gray-600 { color: #4b5563; }
.text-gray-500 { color: #6b7280; }

/* Spacing Utilities */
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.p-3 { padding: 0.75rem; }

/* Enhanced Resource Management Styles */
.resource-item.enhanced {
  background: white;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  animation: resourceReveal 0.6s ease-out both;
  cursor: pointer;
  border: 1px solid #f1f5f9;
  position: relative;
}

.resource-item.enhanced:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  border-color: #4338ca;
}

.resource-item.enhanced::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.resource-item.enhanced:hover::before {
  transform: scaleX(1);
}

.resource-category {
  background: linear-gradient(135deg, #4338ca, #6366f1);
  color: white;
  padding: 0.5rem 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.featured-badge {
  font-size: 0.875rem;
  animation: twinkle 2s ease-in-out infinite;
}

@keyframes twinkle {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(1.1); }
}

.resource-content {
  padding: 1.5rem;
}

.resource-title {
  font-weight: 600;
  color: #1e293b;
  margin: 0 0 0.75rem 0;
  font-size: 1.1rem;
  line-height: 1.4;
  transition: color 0.2s ease;
}

.resource-item.enhanced:hover .resource-title {
  color: #4338ca;
}

.resource-description {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.5;
  margin: 0 0 1rem 0;
}

.resource-meta {
  border-top: 1px solid #f1f5f9;
  border-bottom: 1px solid #f1f5f9;
  padding: 0.75rem 0;
  margin: 1rem 0;
}

.difficulty-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  background: rgba(67, 56, 202, 0.1);
}

.rating-stars {
  display: flex;
  gap: 1px;
}

.rating-stars i {
  font-size: 0.75rem;
}

.view-count {
  color: #64748b;
  font-size: 0.75rem;
}

.resource-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.resource-tag {
  background: #f1f5f9;
  color: #4338ca;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.resource-tag:hover {
  background: #4338ca;
  color: white;
  transform: translateY(-1px);
}

/* Category Filter Tags */
.category-tag {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #64748b;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
}

.category-tag:hover {
  background: #4338ca;
  color: white;
  border-color: #4338ca;
  transform: translateY(-2px);
}

.category-tag.active {
  background: #4338ca;
  color: white;
  border-color: #4338ca;
  box-shadow: 0 4px 12px rgba(67, 56, 202, 0.3);
}

/* View Toggle Buttons */
.view-toggle-btn {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #64748b;
  padding: 0.5rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.view-toggle-btn:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.view-toggle-btn.active {
  background: #4338ca;
  color: white;
  border-color: #4338ca;
}

/* Resources List View */
.resources-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.resources-list .resource-item.enhanced {
  display: flex;
  max-width: none;
}

.resources-list .resource-category {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  width: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.resources-list .resource-content {
  flex: 1;
}

/* Search Input Enhancement */
.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 1rem;
  transition: all 0.3s ease;
  outline: none;
}

.form-input:focus {
  border-color: #4338ca;
  box-shadow: 0 0 0 3px rgba(67, 56, 202, 0.1);
  transform: translateY(-1px);
}

/* Enhanced Select Dropdown */
select.form-input {
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 1rem;
  padding-right: 2.5rem;
  appearance: none;
}

/* Enhanced Button Styles */
.btn-primary, .btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  border-radius: 8px;
  transition: all 0.3s ease;
  cursor: pointer;
  text-decoration: none;
  border: 2px solid transparent;
}

.btn-primary {
  background: linear-gradient(135deg, #4338ca, #6366f1);
  color: white;
  padding: 0.75rem 1.5rem;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(67, 56, 202, 0.3);
}

.btn-secondary {
  background: white;
  color: #4338ca;
  border-color: #4338ca;
  padding: 0.75rem 1.5rem;
}

.btn-secondary:hover {
  background: #4338ca;
  color: white;
  transform: translateY(-2px);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

/* Flex Utilities */
.flex { display: flex; }
.items-center { align-items: center; }
.items-end { align-items: flex-end; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.space-x-2 > * + * { margin-left: 0.5rem; }
.space-x-4 > * + * { margin-left: 1rem; }
.flex-wrap { flex-wrap: wrap; }

/* Enhanced Animation for Resource Cards */
.resources-grid .resource-item.enhanced:nth-child(1) { animation-delay: 0.1s; }
.resources-grid .resource-item.enhanced:nth-child(2) { animation-delay: 0.2s; }
.resources-grid .resource-item.enhanced:nth-child(3) { animation-delay: 0.3s; }
.resources-grid .resource-item.enhanced:nth-child(4) { animation-delay: 0.4s; }
.resources-grid .resource-item.enhanced:nth-child(5) { animation-delay: 0.5s; }
.resources-grid .resource-item.enhanced:nth-child(6) { animation-delay: 0.6s; }

/* Loading State for Search */
.search-loading {
  position: relative;
}

.search-loading::after {
  content: '';
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  border: 2px solid #e5e7eb;
  border-top: 2px solid #4338ca;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

/* Responsive Enhancements */
@media (max-width: 768px) {
  .resources-grid {
    grid-template-columns: 1fr;
  }
  
  .resource-item.enhanced {
    margin-bottom: 1rem;
  }
  
  .category-tag {
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
  }
  
  .grid.md\\:grid-cols-4 {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .flex.flex-wrap {
    justify-content: center;
  }
}

/* Mobile Responsiveness for Dashboard */
@media (max-width: 768px) {
  .dashboard-header {
    padding: 1.5rem;
    text-align: center;
  }
  
  .dashboard-nav {
    justify-content: center;
  }
  
  .nav-btn {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
  }
  
  .dashboard-content {
    padding: 0 1rem 2rem;
  }
  
  .dashboard-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .section-title {
    font-size: 1.5rem;
  }
  
  .mood-buttons {
    justify-content: center;
  }
  
  .mood-btn {
    padding: 0.75rem 1rem;
    font-size: 1.25rem;
  }
  
  .resources-grid {
    grid-template-columns: 1fr;
  }
  
  /* Mobile List Styles */
  .mobile-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
  }
  
  .mobile-list-item {
    display: flex;
    align-items: center;
    padding: 1rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f1f5f9;
    transition: all 0.3s ease;
  }
  
  .mobile-list-item:active {
    transform: scale(0.98);
    background: #f8fafc;
  }
  
  .mobile-list-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    margin-right: 1rem;
    flex-shrink: 0;
  }
  
  .mobile-list-content {
    flex: 1;
    min-width: 0;
  }
  
  .mobile-list-title {
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.25rem;
    font-size: 1rem;
  }
  
  .mobile-list-subtitle {
    color: #64748b;
    font-size: 0.875rem;
    line-height: 1.4;
  }
  
  .mobile-list-action {
    color: #94a3b8;
    font-size: 1rem;
    margin-left: 0.5rem;
  }
  
  .mobile-dashboard-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
  }
  
  .mobile-card {
    border-radius: 16px;
    overflow: hidden;
  }
  
  .mobile-card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
  }
  
  .mobile-card-title {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
  }
  
  .mobile-stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #1e293b;
    line-height: 1;
    margin-bottom: 0.25rem;
  }
  
  .mobile-stat-label {
    color: #64748b;
    font-size: 0.875rem;
    margin: 0;
  }
  
  /* Touch-friendly elements */
  .touch-friendly {
    min-height: 44px;
    cursor: pointer;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
  }
  
  .mobile-touch-item:active {
    transform: scale(0.98);
    transition: transform 0.1s ease;
  }
}

/* Print styles */
@media print {
  .no-print {
    display: none !important;
  }
  
  .card, .room-card, .resource-card {
    box-shadow: none !important;
    border: 1px solid #ccc;
  }
  
  .floating-shapes,
  .floating-element,
  .illustration-container {
    display: none !important;
  }
}

/* ===================================
   ADMIN PANEL STYLES
   =================================== */

/* Admin Dashboard Layout */
.admin-container {
  min-height: 100vh;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.admin-header {
  background: linear-gradient(135deg, #4338ca 0%, #6366f1 100%);
  color: white;
  box-shadow: 0 4px 20px rgba(67, 56, 202, 0.15);
}

.admin-nav {
  background: linear-gradient(135deg, #4338ca 0%, #6366f1 100%);
}

.admin-nav .nav-btn {
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 500;
  transition: all 0.3s ease;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.admin-nav .nav-btn:hover,
.admin-nav .nav-btn.active {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Admin Dashboard Cards */
.dashboard-card {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  border: 1px solid #f1f5f9;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.dashboard-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(135deg, #4338ca, #6366f1);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.dashboard-card:hover::before {
  transform: scaleX(1);
}

.dashboard-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

/* Card Components */
.card-header {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 1rem;
  font-size: 1.25rem;
  color: white;
}

.card-title {
  color: #1e293b;
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0;
}

.card-content {
  color: #64748b;
  line-height: 1.5;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: #4338ca;
  margin-bottom: 0.5rem;
  animation: countUp 1.5s ease-out;
}

@keyframes countUp {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Admin Tables */
.admin-table {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.admin-table table {
  width: 100%;
  border-collapse: collapse;
}

.admin-table th {
  background: #f8fafc;
  color: #374151;
  font-weight: 600;
  padding: 1rem;
  text-align: left;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  border-bottom: 1px solid #e5e7eb;
}

.admin-table td {
  padding: 1rem;
  border-bottom: 1px solid #f3f4f6;
  vertical-align: middle;
}

.admin-table tbody tr {
  transition: background-color 0.15s ease;
}

.admin-table tbody tr:hover {
  background: #f9fafb;
}

/* Admin Buttons */
.admin-btn {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.2s ease;
  cursor: pointer;
  border: 1px solid transparent;
  text-decoration: none;
}

.admin-btn-primary {
  background: linear-gradient(135deg, #4338ca, #6366f1);
  color: white;
}

.admin-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(67, 56, 202, 0.3);
}

.admin-btn-secondary {
  background: #f8fafc;
  color: #4b5563;
  border-color: #d1d5db;
}

.admin-btn-secondary:hover {
  background: #f3f4f6;
  border-color: #9ca3af;
}

.admin-btn-success {
  background: #10b981;
  color: white;
}

.admin-btn-success:hover {
  background: #059669;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.admin-btn-danger {
  background: #ef4444;
  color: white;
}

.admin-btn-danger:hover {
  background: #dc2626;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.admin-btn-warning {
  background: #f59e0b;
  color: white;
}

.admin-btn-warning:hover {
  background: #d97706;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

/* Status Badges */
.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

.status-badge.active {
  background: #dcfce7;
  color: #166534;
}

.status-badge.banned {
  background: #fecaca;
  color: #dc2626;
}

.status-badge.pending {
  background: #fef3c7;
  color: #92400e;
}

.status-badge.approved {
  background: #dcfce7;
  color: #166534;
}

.status-badge.rejected {
  background: #fecaca;
  color: #dc2626;
}

/* Role Badges */
.role-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.role-badge.admin {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
}

.role-badge.moderator {
  background: #f0f9ff;
  color: #0369a1;
  border: 1px solid #bae6fd;
}

.role-badge.user {
  background: #f9fafb;
  color: #374151;
  border: 1px solid #e5e7eb;
}

/* Admin Forms */
.admin-form {
  background: white;
  border-radius: 8px;
  padding: 2rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.admin-form-group {
  margin-bottom: 1.5rem;
}

.admin-form-label {
  display: block;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.admin-form-input,
.admin-form-select,
.admin-form-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 0.875rem;
  transition: all 0.2s ease;
  background: white;
}

.admin-form-input:focus,
.admin-form-select:focus,
.admin-form-textarea:focus {
  outline: none;
  border-color: #4338ca;
  box-shadow: 0 0 0 3px rgba(67, 56, 202, 0.1);
}

.admin-form-checkbox {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-form-checkbox input[type="checkbox"] {
  width: 1rem;
  height: 1rem;
  border-radius: 0.25rem;
  border: 1px solid #d1d5db;
}

/* Loading States */
.admin-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  color: #6b7280;
}

.admin-spinner {
  width: 2rem;
  height: 2rem;
  border: 3px solid #f3f4f6;
  border-top: 3px solid #4338ca;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 0.75rem;
}

/* Grid Layouts */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

/* Notification Styles */
.admin-notification {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 50;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
  animation: notificationSlide 0.3s ease-out;
  max-width: 320px;
}

@keyframes notificationSlide {
  from {
    opacity: 0;
    transform: translateX(100px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.admin-notification.success {
  background: rgba(16, 185, 129, 0.95);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.admin-notification.error {
  background: rgba(239, 68, 68, 0.95);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Art Submission Cards in Admin */
.art-admin-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  border: 1px solid #f1f5f9;
}

.art-admin-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.art-admin-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.art-admin-content {
  padding: 1rem;
}

.art-admin-title {
  font-weight: 600;
  color: #1e293b;
  margin: 0 0 0.5rem 0;
  font-size: 1rem;
}

.art-admin-description {
  color: #64748b;
  font-size: 0.875rem;
  line-height: 1.4;
  margin: 0 0 1rem 0;
}

.art-admin-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  color: #94a3b8;
  margin-bottom: 1rem;
}

.art-admin-actions {
  display: flex;
  gap: 0.5rem;
}

/* Responsive Admin Layout */
@media (max-width: 1024px) {
  .admin-nav {
    padding: 1rem;
  }
  
  .admin-nav .nav-btn {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
  }
  
  .dashboard-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
  }
}

@media (max-width: 768px) {
  .admin-nav {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .admin-nav .nav-btn {
    margin: 0.25rem;
    padding: 0.5rem 0.75rem;
    font-size: 0.8rem;
  }
  
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  
  .admin-table {
    overflow-x: auto;
  }
  
  .admin-table table {
    min-width: 600px;
  }
  
  .admin-form {
    padding: 1rem;
  }
  
  .admin-notification {
    top: 1rem;
    left: 1rem;
    right: 1rem;
    max-width: none;
  }
}

/* Section Headers */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.section-title {
  color: #1e293b;
  font-size: 1.75rem;
  font-weight: 700;
  margin: 0;
}

.section-description {
  color: #64748b;
  margin-top: 0.25rem;
}

/* Dashboard Sections */
.dashboard-section {
  display: none;
  animation: sectionFadeIn 0.4s ease-out;
}

.dashboard-section.active {
  display: block;
}

@keyframes sectionFadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Empty States */
.admin-empty-state {
  text-align: center;
  padding: 3rem 1rem;
  color: #6b7280;
}

.admin-empty-icon {
  font-size: 3rem;
  color: #d1d5db;
  margin-bottom: 1rem;
}

.admin-empty-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #374151;
  margin: 0 0 0.5rem 0;
}

.admin-empty-description {
  color: #6b7280;
  margin: 0;
}

/* Action Button Groups */
.admin-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.admin-actions .admin-btn {
  font-size: 0.75rem;
  padding: 0.375rem 0.75rem;
}

/* Filter and Search Bar */
.admin-filters {
  background: white;
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.admin-search {
  flex: 1;
  min-width: 200px;
}

.admin-filter-select {
  min-width: 150px;
}

/* Pagination */
.admin-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.admin-pagination button {
  padding: 0.5rem 0.75rem;
  border: 1px solid #d1d5db;
  background: white;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.admin-pagination button:hover:not(:disabled) {
  background: #f3f4f6;
  border-color: #9ca3af;
}

.admin-pagination button.active {
  background: #4338ca;
  color: white;
  border-color: #4338ca;
}

.admin-pagination button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Statistics Cards Enhancement */
.dashboard-card .stat-number {
  display: block;
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.dashboard-card .stat-label {
  color: #6b7280;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.dashboard-card .stat-change {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  font-weight: 500;
}

.dashboard-card .stat-change.positive {
  color: #10b981;
}

.dashboard-card .stat-change.negative {
  color: #ef4444;
}

.dashboard-card .stat-change.neutral {
  color: #6b7280;
}

/* Admin Settings Enhancements */
.settings-section {
  background: white;
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.settings-section h3 {
  color: #1e293b;
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #f1f5f9;
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
}

/* Enhanced Loading Animation */
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading-spinner {
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 2px solid #f3f3f3;
  border-top: 2px solid #4338ca;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 0.5rem;
}

/* =================================================================== */
/* MOBILE RESPONSIVE STYLES FOR DASHBOARD AND ARTWALL */
/* =================================================================== */

/* Mobile Dashboard Styles */
@media (max-width: 640px) {
  .dashboard-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
    margin-bottom: 1rem !important;
  }
  
  .dashboard-card {
    border-radius: 12px !important;
    padding: 1rem !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
  }
  
  .card-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0.5rem !important;
  }
  
  .card-icon {
    width: 2rem !important;
    height: 2rem !important;
  }
  
  .card-title {
    font-size: 1rem !important;
  }
  
  .section-title {
    font-size: 1.5rem !important;
  }
  
  /* Hide navigation text on mobile, show only icons */
  .nav-btn span {
    display: none;
  }
  
  .nav-btn {
    min-width: 40px;
    padding: 0.5rem;
    border-radius: 8px;
  }
  
  .dashboard-nav {
    justify-content: center;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
  }
  
  .dashboard-nav::-webkit-scrollbar {
    height: 2px;
  }
  
  .dashboard-nav::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
  }
  
  .dashboard-nav::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
  }
}

/* Tablet Dashboard Styles */
@media (min-width: 641px) and (max-width: 1023px) {
  .dashboard-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
    gap: 1.25rem !important;
  }
  
  .dashboard-card {
    padding: 1.25rem !important;
  }
  
  /* Show abbreviated text on tablets */
  .nav-btn span {
    display: inline;
  }
}

/* Mobile Art Gallery Styles */
@media (max-width: 640px) {
  .art-gallery {
    padding: 0 0.5rem !important;
    margin-top: 1rem !important;
  }
  
  .art-item {
    margin-bottom: 1rem !important;
    border-radius: 8px !important;
  }
  
  .art-item img {
    border-radius: 8px !important;
  }
  
  .art-overlay {
    padding: 0.75rem !important;
  }
  
  .art-title {
    font-size: 0.875rem !important;
    line-height: 1.2 !important;
  }
  
  .art-author {
    font-size: 0.75rem !important;
  }
  
  .art-description {
    font-size: 0.75rem !important;
    line-height: 1.3 !important;
    max-height: 2.6rem !important;
    overflow: hidden !important;
  }
  
  .like-btn {
    padding: 0.25rem 0.5rem !important;
    font-size: 0.75rem !important;
  }
}

/* Mobile Modal Styles */
@media (max-width: 640px) {
  .modal-content {
    width: 95% !important;
    margin: 1rem auto !important;
    max-height: 90vh !important;
    overflow-y: auto !important;
  }
  
  .modal h3 {
    font-size: 1.125rem !important;
  }
  
  .form-group label {
    font-size: 0.875rem !important;
  }
  
  .form-group input,
  .form-group textarea,
  .form-group select {
    font-size: 1rem !important;
    padding: 0.75rem !important;
    min-height: 44px !important; /* Touch-friendly minimum size */
  }
  
  .btn {
    width: 100% !important;
    margin: 0.25rem 0 !important;
    min-height: 44px !important; /* Touch-friendly minimum size */
  }
  
  /* Improved touch targets */
  button, .nav-btn, .art-card button {
    min-height: 44px !important;
    min-width: 44px !important;
  }
  
  /* Better text readability on mobile */
  body {
    font-size: 16px !important; /* Prevents zoom on iOS */
  }
  
  /* Improved form inputs */
  input, textarea, select {
    font-size: 16px !important; /* Prevents zoom on iOS */
  }
}

/* Mobile Room Cards */
@media (max-width: 640px) {
  .room-card {
    padding: 1rem !important;
    margin-bottom: 1rem !important;
  }
  
  .room-title {
    font-size: 1rem !important;
  }
  
  .room-description {
    font-size: 0.875rem !important;
    line-height: 1.4 !important;
  }
  
  .room-stats {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0.5rem !important;
  }
  
  .room-stat {
    font-size: 0.75rem !important;
  }
}

/* Mobile Profile Section */
@media (max-width: 640px) {
  .profile-form .form-group {
    margin-bottom: 1rem !important;
  }
  
  .profile-stats {
    flex-direction: column !important;
    gap: 0.5rem !important;
  }
  
  .stat-item {
    text-align: left !important;
    padding: 0.75rem !important;
  }
}

/* Mobile Mood Tracker */
@media (max-width: 640px) {
  .mood-selector {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 0.5rem !important;
  }
  
  .mood-option {
    padding: 0.75rem 0.5rem !important;
    font-size: 0.875rem !important;
  }
  
  .mood-history {
    overflow-x: auto !important;
  }
  
  .mood-entry {
    min-width: 250px !important;
  }
}

/* Header Improvements */
.scrollbar-hide {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.scrollbar-hide::-webkit-scrollbar {
  display: none;
}

/* Consistent button styles across headers */
header button,
nav button,
.nav-btn {
  min-height: 40px;
  transition: all 0.2s ease-in-out;
}

header button:hover,
nav button:hover {
  transform: translateY(-1px);
}

/* Better alignment for navigation items */
.nav-btn {
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-weight: 500;
}

/* Pulse animation for status indicators */
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.pulse-animation {
  animation: pulse 2s infinite;
}

/* Admin Panel Mobile Styles */
@media (max-width: 640px) {
  
  /* Admin dashboard cards */
  .admin-card {
    padding: 1rem !important;
    margin-bottom: 1rem !important;
  }
  
  .admin-stat {
    text-align: center !important;
    padding: 1rem !important;
  }
  
  .admin-stat-number {
    font-size: 1.5rem !important;
  }
  
  .admin-stat-label {
    font-size: 0.75rem !important;
  }
  
  /* Admin tables */
  .admin-table {
    font-size: 0.875rem !important;
  }
  
  .admin-table th,
  .admin-table td {
    padding: 0.5rem 0.25rem !important;
  }
  
  /* Admin buttons */
  .admin-btn {
    padding: 0.5rem 1rem !important;
    font-size: 0.875rem !important;
  }
  
  /* Admin modal */
  .admin-modal {
    margin: 0.5rem !important;
    max-height: 95vh !important;
  }
}

/* Enhanced Error Handling & Loading States */

/* Loading States */
.loading-overlay-global {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.loading-overlay-local {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(2px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  border-radius: inherit;
}

.loading-content {
  text-align: center;
  padding: 2rem;
}

.loading-text {
  color: #6b7280;
  font-size: 0.875rem;
  font-weight: 500;
}

/* Alert Animations */
.animate-slide-in {
  animation: slideInRight 0.3s ease-out;
}

.animate-slide-out {
  animation: slideOutRight 0.3s ease-in;
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideOutRight {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(100%);
    opacity: 0;
  }
}

/* Field Error States */
.field-error {
  animation: shakeError 0.3s ease-in-out;
}

@keyframes shakeError {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

/* Form Validation States */
.form-input.is-invalid {
  border-color: #ef4444 !important;
  background-color: #fef2f2 !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.form-input.is-valid {
  border-color: #10b981 !important;
  background-color: #f0fdf4 !important;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1) !important;
}

/* Error Boundary */
.error-boundary {
  background: linear-gradient(135deg, #fee2e2, #fecaca);
  border: 2px solid #f87171;
  border-radius: 0.75rem;
  padding: 2rem;
  text-align: center;
  margin: 2rem auto;
  max-width: 600px;
}

.error-boundary h2 {
  color: #dc2626;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.error-boundary p {
  color: #7f1d1d;
  margin-bottom: 1.5rem;
}

.error-boundary .error-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.error-boundary button {
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  transition: all 0.2s;
  cursor: pointer;
}

.error-boundary .btn-retry {
  background: #dc2626;
  color: white;
  border: none;
}

.error-boundary .btn-retry:hover {
  background: #b91c1c;
}

/* Skeleton Loading */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

.skeleton-text {
  height: 1rem;
  border-radius: 0.25rem;
  margin-bottom: 0.5rem;
}

.skeleton-title {
  height: 1.5rem;
  border-radius: 0.25rem;
  margin-bottom: 1rem;
  width: 70%;
}

.skeleton-avatar {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
}

@keyframes loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Enhanced Alerts */
.alert {
  min-width: 300px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  border-left: 4px solid;
}

.alert.bg-green-100 { border-left-color: #10b981; }
.alert.bg-red-100 { border-left-color: #ef4444; }
.alert.bg-yellow-100 { border-left-color: #f59e0b; }
.alert.bg-blue-100 { border-left-color: #3b82f6; }

/* Enhanced Skeleton Loading Styles */
.art-item-skeleton {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  animation: skeleton-pulse 2s infinite;
}

@keyframes skeleton-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

.upload-skeleton {
  padding: 2rem;
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

/* Action Loading Overlay */
.action-loading-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  border-radius: inherit;
  backdrop-filter: blur(1px);
}

/* Connection Lost Banner */
.connection-lost-banner {
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-100%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Progressive Loading */
.progressive-loading {
  position: relative;
  overflow: hidden;
}

.progressive-loading::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.6),
    transparent
  );
  animation: progressiveShimmer 2s infinite;
}

@keyframes progressiveShimmer {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* Message States */
.message-sending {
  opacity: 0.7;
  position: relative;
}

.message-sending::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(59, 130, 246, 0.1),
    transparent
  );
  animation: messageSending 1.5s infinite;
}

@keyframes messageSending {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.message-error {
  background-color: #fef2f2;
  border-left: 4px solid #ef4444;
}

.message-error-info {
  display: flex;
  align-items: center;
  margin-top: 0.5rem;
  font-size: 0.75rem;
}

/* Enhanced Loading Text */
.loading-text::after {
  content: '';
  animation: loadingDots 1.5s infinite;
}

@keyframes loadingDots {
  0%, 20% { content: ''; }
  40% { content: '.'; }
  60% { content: '..'; }
  80%, 100% { content: '...'; }
}

/* Responsive Error Handling */
@media (max-width: 640px) {
  .alert {
    left: 1rem;
    right: 1rem;
    min-width: auto;
  }
  
  .loading-content {
    padding: 1rem;
  }
  
  .error-boundary {
    margin: 1rem;
    padding: 1.5rem;
  }
  
  .art-item-skeleton {
    margin-bottom: 1rem;
  }
  
  .action-loading-overlay {
    border-radius: 8px;
  }
}