/* Tema inspirado en shadcn/ui */
:root {
  --background: 0 0% 100%;
  --foreground: 222.2 84% 4.9%;
  --muted: 210 40% 98%;
  --muted-foreground: 215.4 16.3% 46.9%;
  --popover: 0 0% 100%;
  --popover-foreground: 222.2 84% 4.9%;
  --border: 214.3 31.8% 91.4%;
  --input: 214.3 31.8% 91.4%;
  --card: 0 0% 100%;
  --card-foreground: 222.2 84% 4.9%;
  --primary: 221.2 83.2% 53.3%;
  --primary-foreground: 210 40% 98%;
  --secondary: 210 40% 96%;
  --secondary-foreground: 222.2 47.4% 11.2%;
  --accent: 210 40% 96%;
  --accent-foreground: 222.2 47.4% 11.2%;
  --destructive: 0 84.2% 60.2%;
  --destructive-foreground: 210 40% 98%;
  --ring: 221.2 83.2% 53.3%;
  --radius: 0.75rem;
}

.dark {
  --background: 222.2 84% 4.9%;
  --foreground: 210 40% 98%;
  --muted: 217.2 32.6% 17.5%;
  --muted-foreground: 215 20.2% 65.1%;
  --popover: 222.2 84% 4.9%;
  --popover-foreground: 210 40% 98%;
  --border: 217.2 32.6% 17.5%;
  --input: 217.2 32.6% 17.5%;
  --card: 222.2 84% 4.9%;
  --card-foreground: 210 40% 98%;
  --primary: 217.2 91.2% 59.8%;
  --primary-foreground: 222.2 47.4% 11.2%;
  --secondary: 217.2 32.6% 17.5%;
  --secondary-foreground: 210 40% 98%;
  --accent: 217.2 32.6% 17.5%;
  --accent-foreground: 210 40% 98%;
  --destructive: 0 62.8% 30.6%;
  --destructive-foreground: 210 40% 98%;
  --ring: 217.2 91.2% 59.8%;
}

* {
  border-color: hsl(var(--border));
}

body {
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  font-feature-settings: "rlig" 1, "calt" 1;
}

/* shadcn/ui inspired components */
.shadcn-card {
  background-color: hsl(var(--card));
  color: hsl(var(--card-foreground));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
}

.shadcn-card-header {
  padding: 1.5rem;
  border-bottom: 1px solid hsl(var(--border));
}

.shadcn-card-content {
  padding: 1.5rem;
}

.shadcn-button-primary {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  border: 1px solid hsl(var(--primary));
  border-radius: calc(var(--radius) - 2px);
  padding: 0.5rem 1rem;
  font-weight: 500;
  transition: all 0.2s;
}

.shadcn-button-primary:hover {
  background-color: hsl(var(--primary) / 0.9);
  color: hsl(var(--primary-foreground));
}

.shadcn-button-secondary {
  background-color: hsl(var(--secondary));
  color: hsl(var(--secondary-foreground));
  border: 1px solid hsl(var(--border));
  border-radius: calc(var(--radius) - 2px);
  padding: 0.5rem 1rem;
  font-weight: 500;
  transition: all 0.2s;
}

.shadcn-button-secondary:hover {
  background-color: hsl(var(--secondary) / 0.8);
}

.shadcn-input {
  background-color: hsl(var(--background));
  border: 1px solid hsl(var(--border));
  border-radius: calc(var(--radius) - 2px);
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  transition: all 0.2s;
}

.shadcn-input:focus {
  outline: none;
  border-color: hsl(var(--ring));
  box-shadow: 0 0 0 2px hsl(var(--ring) / 0.2);
}

.shadcn-badge {
  background-color: hsl(var(--secondary));
  color: hsl(var(--secondary-foreground));
  border-radius: calc(var(--radius) - 2px);
  padding: 0.25rem 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1;
}

.shadcn-badge-primary {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
}

.shadcn-badge-success {
  background-color: hsl(142.1 76.2% 36.3%);
  color: hsl(355.7 100% 97.3%);
}

.shadcn-badge-warning {
  background-color: hsl(47.9 95.8% 53.1%);
  color: hsl(26 83.3% 14.1%);
}

.shadcn-badge-destructive {
  background-color: hsl(var(--destructive));
  color: hsl(var(--destructive-foreground));
}

.shadcn-muted {
  color: hsl(var(--muted-foreground));
}

.shadcn-navbar {
  background-color: hsl(var(--card));
  border-bottom: 1px solid hsl(var(--border));
  backdrop-filter: blur(10px);
}

.shadcn-table {
  background-color: hsl(var(--card));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
}

.shadcn-table th {
  background-color: hsl(var(--muted));
  color: hsl(var(--muted-foreground));
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.75rem;
}

.shadcn-table td {
  padding: 0.75rem;
  border-top: 1px solid hsl(var(--border));
}

.shadcn-table tbody tr:hover {
  background-color: hsl(var(--muted) / 0.5);
}

.shadcn-metric-card {
  background: linear-gradient(135deg, hsl(var(--card)) 0%, hsl(var(--muted)) 100%);
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
}

.shadcn-metric-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, hsl(var(--primary)), hsl(var(--accent)));
}

/* Gradient variants for metric cards */
.metric-primary {
  background: linear-gradient(135deg, hsl(var(--primary) / 0.05) 0%, hsl(var(--primary) / 0.1) 100%);
}

.metric-success {
  background: linear-gradient(135deg, hsl(142.1 76.2% 36.3% / 0.05) 0%, hsl(142.1 76.2% 36.3% / 0.1) 100%);
}

.metric-warning {
  background: linear-gradient(135deg, hsl(47.9 95.8% 53.1% / 0.05) 0%, hsl(47.9 95.8% 53.1% / 0.1) 100%);
}

.metric-info {
  background: linear-gradient(135deg, hsl(199.4 89.1% 48.4% / 0.05) 0%, hsl(199.4 89.1% 48.4% / 0.1) 100%);
}

/* Login page specific styles */
.login-container {
  min-height: 100vh;
  background: linear-gradient(135deg, hsl(var(--background)) 0%, hsl(var(--muted)) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-card {
  width: 100%;
  max-width: 400px;
  background-color: hsl(var(--card));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  box-shadow: 0 10px 25px -3px rgb(0 0 0 / 0.1), 0 4px 6px -2px rgb(0 0 0 / 0.05);
  padding: 2rem;
}

.login-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.login-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: hsl(var(--foreground));
  margin-bottom: 0.5rem;
}

.login-subtitle {
  color: hsl(var(--muted-foreground));
  font-size: 0.875rem;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in {
  animation: fadeIn 0.5s ease-out;
}

.animate-fade-in-delay {
  animation: fadeIn 0.5s ease-out 0.2s both;
}