/* CSS Variables */
:root {
  --font-size: 14px;
  --background: #ffffff;
  --foreground: #374151;
  --card: #ffffff;
  --card-foreground: #374151;
  --popover: #ffffff;
  --popover-foreground: #374151;
  --primary: #374151;
  --primary-foreground: #ffffff;
  --secondary: #f3f4f6;
  --secondary-foreground: #374151;
  --muted: #ececf0;
  --muted-foreground: #717182;
  --accent: #e9ebef;
  --accent-foreground: #374151;
  --destructive: #d4183d;
  --destructive-foreground: #ffffff;
  --border: rgba(0, 0, 0, 0.1);
  --input: transparent;
  --input-background: #f3f3f5;
  --switch-background: #cbced4;
  --font-weight-medium: 500;
  --font-weight-normal: 400;
  --ring: #9ca3af;
  --radius: 0.625rem;
  --spacing: 0.25rem;
}

/* Base Styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: var(--font-size);
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  tab-size: 4;
  font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  -webkit-tap-highlight-color: transparent;
}

body {
  background-color: var(--background);
  color: var(--foreground);
  line-height: inherit;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-size: inherit;
  font-weight: inherit;
}

h1 {
  font-size: 1.5rem;
  font-weight: var(--font-weight-medium);
  line-height: 1.5;
}

h2 {
  font-size: 1.25rem;
  font-weight: var(--font-weight-medium);
  line-height: 1.5;
}

h3 {
  font-size: 1.125rem;
  font-weight: var(--font-weight-medium);
  line-height: 1.5;
}

h4 {
  font-size: 1rem;
  font-weight: var(--font-weight-medium);
  line-height: 1.5;
}

p {
  font-size: 1rem;
  font-weight: var(--font-weight-normal);
  line-height: 1.5;
}

label, button {
  font-size: 1rem;
  font-weight: var(--font-weight-medium);
  line-height: 1.5;
}

input {
  font-size: 1rem;
  font-weight: var(--font-weight-normal);
  line-height: 1.5;
}

/* Layout Utilities */
.min-h-screen {
  min-height: 100vh;
}

.container {
  width: 100%;
  max-width: 80rem;
  margin: 0 auto;
}

@media (min-width: 40rem) {
  .container {
    max-width: 40rem;
  }
}

@media (min-width: 48rem) {
  .container {
    max-width: 48rem;
  }
}

@media (min-width: 64rem) {
  .container {
    max-width: 64rem;
  }
}

@media (min-width: 80rem) {
  .container {
    max-width: 80rem;
  }
}

@media (min-width: 96rem) {
  .container {
    max-width: 96rem;
  }
}

/* Flexbox */
.flex {
  display: flex;
}

.flex-col {
  flex-direction: column;
}

.flex-wrap {
  flex-wrap: wrap;
}

.items-center {
  align-items: center;
}

.items-start {
  align-items: flex-start;
}

.justify-between {
  justify-content: space-between;
}

.justify-center {
  justify-content: center;
}

.justify-end {
  justify-content: flex-end;
}

.flex-1 {
  flex: 1;
}

.flex-shrink-0 {
  flex-shrink: 0;
}

/* Grid */
.grid {
  display: grid;
}

.grid-cols-1 {
  grid-template-columns: repeat(1, minmax(0, 1fr));
}

.grid-cols-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-cols-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (min-width: 48rem) {
  .md\:grid-cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 64rem) {
  .lg\:grid-cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  
  .lg\:grid-cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* Spacing */
.gap-1 {
  gap: calc(var(--spacing) * 1);
}

.gap-2 {
  gap: calc(var(--spacing) * 2);
}

.gap-4 {
  gap: calc(var(--spacing) * 4);
}

.gap-6 {
  gap: calc(var(--spacing) * 6);
}

.gap-8 {
  gap: calc(var(--spacing) * 8);
}

.space-x-2 > :not(:last-child) {
  margin-left: calc(var(--spacing) * 2);
}

.space-x-3 > :not(:last-child) {
  margin-left: calc(var(--spacing) * 3);
}

.space-x-4 > :not(:last-child) {
  margin-left: calc(var(--spacing) * 4);
}

.space-x-6 > :not(:last-child) {
  margin-left: calc(var(--spacing) * 6);
}

.space-y-1 > :not(:last-child) {
  margin-top: calc(var(--spacing) * 1);
}

.space-y-2 > :not(:last-child) {
  margin-top: calc(var(--spacing) * 2);
}

.space-y-3 > :not(:last-child) {
  margin-top: calc(var(--spacing) * 3);
}

.space-y-4 > :not(:last-child) {
  margin-top: calc(var(--spacing) * 4);
}

.space-y-6 > :not(:last-child) {
  margin-top: calc(var(--spacing) * 6);
}

.space-y-8 > :not(:last-child) {
  margin-top: calc(var(--spacing) * 8);
}

/* Padding */
.p-1 {
  padding: calc(var(--spacing) * 1);
}

.p-2 {
  padding: calc(var(--spacing) * 2);
}

.p-3 {
  padding: calc(var(--spacing) * 3);
}

.p-4 {
  padding: calc(var(--spacing) * 4);
}

.p-6 {
  padding: calc(var(--spacing) * 6);
}

.p-8 {
  padding: calc(var(--spacing) * 8);
}

.px-2 {
  padding-left: calc(var(--spacing) * 2);
  padding-right: calc(var(--spacing) * 2);
}

.px-3 {
  padding-left: calc(var(--spacing) * 3);
  padding-right: calc(var(--spacing) * 3);
}

.px-4 {
  padding-left: calc(var(--spacing) * 4);
  padding-right: calc(var(--spacing) * 4);
}

.px-6 {
  padding-left: calc(var(--spacing) * 6);
  padding-right: calc(var(--spacing) * 6);
}

.py-1 {
  padding-top: calc(var(--spacing) * 1);
  padding-bottom: calc(var(--spacing) * 1);
}

.py-2 {
  padding-top: calc(var(--spacing) * 2);
  padding-bottom: calc(var(--spacing) * 2);
}

.py-3 {
  padding-top: calc(var(--spacing) * 3);
  padding-bottom: calc(var(--spacing) * 3);
}

.py-4 {
  padding-top: calc(var(--spacing) * 4);
  padding-bottom: calc(var(--spacing) * 4);
}

.py-8 {
  padding-top: calc(var(--spacing) * 8);
  padding-bottom: calc(var(--spacing) * 8);
}

.pt-4 {
  padding-top: calc(var(--spacing) * 4);
}

.pt-6 {
  padding-top: calc(var(--spacing) * 6);
}

.pt-8 {
  padding-top: calc(var(--spacing) * 8);
}

.pb-2 {
  padding-bottom: calc(var(--spacing) * 2);
}

.pb-6 {
  padding-bottom: calc(var(--spacing) * 6);
}

/* Margin */
.mx-auto {
  margin-left: auto;
  margin-right: auto;
}

.mb-1 {
  margin-bottom: calc(var(--spacing) * 1);
}

.mb-2 {
  margin-bottom: calc(var(--spacing) * 2);
}

.mb-4 {
  margin-bottom: calc(var(--spacing) * 4);
}

.mb-6 {
  margin-bottom: calc(var(--spacing) * 6);
}

.mb-12 {
  margin-bottom: calc(var(--spacing) * 12);
}

.mt-2 {
  margin-top: calc(var(--spacing) * 2);
}

.mt-4 {
  margin-top: calc(var(--spacing) * 4);
}

.mt-6 {
  margin-top: calc(var(--spacing) * 6);
}

.mt-8 {
  margin-top: calc(var(--spacing) * 8);
}

.-mt-1 {
  margin-top: calc(var(--spacing) * -1);
}

/* Positioning */
.sticky {
  position: sticky;
}

.top-0 {
  top: 0;
}

.right-3 {
  right: calc(var(--spacing) * 3);
}

.z-10 {
  z-index: 10;
}

.z-50 {
  z-index: 50;
}

.relative {
  position: relative;
}

.absolute {
  position: absolute;
}

/* Sizing */
.w-1\/4 {
  width: 25%;
}

.w-3 {
  width: calc(var(--spacing) * 3);
}

.w-4 {
  width: calc(var(--spacing) * 4);
}

.w-6 {
  width: calc(var(--spacing) * 6);
}

.w-8 {
  width: calc(var(--spacing) * 8);
}

.w-10 {
  width: calc(var(--spacing) * 10);
}

.w-56 {
  width: calc(var(--spacing) * 56);
}

.w-full {
  width: 100%;
}

.w-fit {
  width: fit-content;
}

.h-2 {
  height: calc(var(--spacing) * 2);
}

.h-4 {
  height: calc(var(--spacing) * 4);
}

.h-5 {
  height: calc(var(--spacing) * 5);
}

.h-6 {
  height: calc(var(--spacing) * 6);
}

.h-8 {
  height: calc(var(--spacing) * 8);
}

.h-10 {
  height: calc(var(--spacing) * 10);
}

.h-12 {
  height: calc(var(--spacing) * 12);
}

.h-80 {
  height: calc(var(--spacing) * 80);
}

.h-full {
  height: 100%;
}

.min-w-24 {
  min-width: calc(var(--spacing) * 24);
}

.max-w-xs {
  max-width: 20rem;
}

.max-w-lg {
  max-width: 32rem;
}

.max-w-2xl {
  max-width: 42rem;
}

/* Text */
.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.text-xs {
  font-size: 0.75rem;
  line-height: calc(1 / 0.75);
}

.text-sm {
  font-size: 0.875rem;
  line-height: calc(1.25 / 0.875);
}

.text-base {
  font-size: 1rem;
  line-height: calc(1.5 / 1);
}

.text-lg {
  font-size: 1.125rem;
  line-height: calc(1.25 / 1.125);
}

.text-xl {
  font-size: 1.25rem;
  line-height: calc(1.75 / 1.25);
}

.text-2xl {
  font-size: 1.5rem;
  line-height: calc(2 / 1.5);
}

.text-3xl {
  font-size: 1.875rem;
  line-height: calc(2.25 / 1.875);
}

.text-4xl {
  font-size: 2.25rem;
  line-height: calc(2.5 / 2.25);
}

@media (min-width: 64rem) {
  .lg\:text-4xl {
    font-size: 2.25rem;
    line-height: calc(2.5 / 2.25);
  }
}

.font-bold {
  font-weight: 700;
}

.font-medium {
  font-weight: var(--font-weight-medium);
}

.font-semibold {
  font-weight: 600;
}

.leading-tight {
  line-height: 1.25;
}

.leading-relaxed {
  line-height: 1.625;
}

/* Colors */
.text-white {
  color: #ffffff;
}

.text-white\/70 {
  color: rgba(255, 255, 255, 0.7);
}

.text-white\/80 {
  color: rgba(255, 255, 255, 0.8);
}

.text-white\/90 {
  color: rgba(255, 255, 255, 0.9);
}

.text-gray-600 {
  color: #4b5563;
}

.text-gray-700 {
  color: #374151;
}

.text-gray-800 {
  color: #1f2937;
}

.text-gray-900 {
  color: #111827;
}

.text-green-600 {
  color: #059669;
}

.text-green-700 {
  color: #047857;
}

.text-blue-700 {
  color: #1d4ed8;
}

.text-orange-700 {
  color: #c2410c;
}

.text-purple-700 {
  color: #7c3aed;
}

.text-primary {
  color: var(--primary);
}

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

.text-\[rgba\(34\,113\,194\,1\)\] {
  color: rgba(34, 113, 194, 1);
}

/* Background Colors */
.bg-background {
  background-color: var(--background);
}

.bg-white {
  background-color: #ffffff;
}

.bg-white\/10 {
  background-color: rgba(255, 255, 255, 0.1);
}

.bg-white\/20 {
  background-color: rgba(255, 255, 255, 0.2);
}

.bg-gray-100 {
  background-color: #f3f4f6;
}

.bg-gray-200 {
  background-color: #e5e7eb;
}

.bg-gray-700 {
  background-color: #374151;
}

.bg-green-50 {
  background-color: #f0fdf4;
}

.bg-green-100 {
  background-color: #dcfce7;
}

.bg-green-500 {
  background-color: #22c55e;
}

.bg-blue-50 {
  background-color: #eff6ff;
}

.bg-blue-100 {
  background-color: #dbeafe;
}

.bg-orange-50 {
  background-color: #fff7ed;
}

.bg-orange-100 {
  background-color: #fed7aa;
}

.bg-orange-500 {
  background-color: #f97316;
}

.bg-purple-50 {
  background-color: #faf5ff;
}

.bg-purple-100 {
  background-color: #f3e8ff;
}

.bg-red-500 {
  background-color: #ef4444;
}

.bg-yellow-500 {
  background-color: #eab308;
}

.bg-card {
  background-color: var(--card);
}

.bg-muted {
  background-color: var(--muted);
}

.bg-muted\/50 {
  background-color: rgba(236, 236, 240, 0.5);
}

.bg-primary {
  background-color: var(--primary);
}

.bg-primary\/5 {
  background-color: rgba(55, 65, 81, 0.05);
}

.bg-primary\/10 {
  background-color: rgba(55, 65, 81, 0.1);
}

.bg-destructive {
  background-color: var(--destructive);
}

/* Border */
.border {
  border: 1px solid var(--border);
}

.border-2 {
  border: 2px solid var(--border);
}

.border-t {
  border-top: 1px solid var(--border);
}

.border-b {
  border-bottom: 1px solid var(--border);
}

.border-gray-200 {
  border-color: #e5e7eb;
}

.border-gray-300 {
  border-color: #d1d5db;
}

.border-green-200 {
  border-color: #bbf7d0;
}

.border-green-300 {
  border-color: #86efac;
}

.border-green-600 {
  border-color: #16a34a;
}

.border-blue-200 {
  border-color: #bfdbfe;
}

.border-blue-300 {
  border-color: #93c5fd;
}

.border-orange-200 {
  border-color: #fed7aa;
}

.border-orange-300 {
  border-color: #fdba74;
}

.border-purple-200 {
  border-color: #e9d5ff;
}

.border-purple-300 {
  border-color: #d8b4fe;
}

.border-primary\/20 {
  border-color: rgba(55, 65, 81, 0.2);
}

.border-white\/30 {
  border-color: rgba(255, 255, 255, 0.3);
}

.border-white\/50 {
  border-color: rgba(255, 255, 255, 0.5);
}

.border-transparent {
  border-color: transparent;
}

/* Border Radius */
.rounded {
  border-radius: 0.25rem;
}

.rounded-full {
  border-radius: 9999px;
}

.rounded-lg {
  border-radius: var(--radius);
}

.rounded-md {
  border-radius: calc(var(--radius) - 2px);
}

.rounded-sm {
  border-radius: calc(var(--radius) - 4px);
}

.rounded-xl {
  border-radius: calc(var(--radius) + 4px);
}

.rounded-t-\[10px\] {
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
}

.rounded-b-\[0px\] {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}

/* Shadows */
.shadow-sm {
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
}

.shadow-md {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
}

.shadow-lg {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
}

.shadow-blue-100 {
  box-shadow: 0 10px 15px -3px rgba(219, 234, 254, 0.1), 0 4px 6px -4px rgba(219, 234, 254, 0.1);
}

.shadow-green-100 {
  box-shadow: 0 10px 15px -3px rgba(220, 252, 231, 0.1), 0 4px 6px -4px rgba(220, 252, 231, 0.1);
}

.shadow-orange-100 {
  box-shadow: 0 10px 15px -3px rgba(255, 237, 213, 0.1), 0 4px 6px -4px rgba(255, 237, 213, 0.1);
}

.shadow-purple-100 {
  box-shadow: 0 10px 15px -3px rgba(243, 232, 255, 0.1), 0 4px 6px -4px rgba(243, 232, 255, 0.1);
}

/* Transitions */
.transition-all {
  transition-property: all;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 0.15s;
}

.transition-colors {
  transition-property: color, background-color, border-color, outline-color, text-decoration-color, fill, stroke;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 0.15s;
}

.transition-shadow {
  transition-property: box-shadow;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 0.15s;
}

.duration-200 {
  transition-duration: 0.2s;
}

.duration-300 {
  transition-duration: 0.3s;
}

/* Hover Effects */
.hover\:bg-white\/10:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.hover\:bg-gray-200:hover {
  background-color: #e5e7eb;
}

.hover\:bg-gray-300:hover {
  background-color: #d1d5db;
}

.hover\:border-gray-300:hover {
  border-color: #d1d5db;
}

.hover\:border-green-700:hover {
  border-color: #15803d;
}

.hover\:text-white:hover {
  color: #ffffff;
}

.hover\:text-gray-700:hover {
  color: #374151;
}

.hover\:text-gray-900:hover {
  color: #111827;
}

.hover\:shadow-lg:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
}

.hover\:shadow-md:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
}

.hover\:-translate-y-1:hover {
  transform: translateY(calc(var(--spacing) * -1));
}

/* Focus Effects */
.focus\:border-primary:focus {
  border-color: var(--primary);
}

/* Cursor */
.cursor-pointer {
  cursor: pointer;
}

.cursor-help {
  cursor: help;
}

.cursor-default {
  cursor: default;
}

/* Overflow */
.overflow-hidden {
  overflow: hidden;
}

.overflow-x-hidden {
  overflow-x: hidden;
}

.overflow-y-auto {
  overflow-y: auto;
}

/* Display */
.inline-block {
  display: inline-block;
}

.inline-flex {
  display: inline-flex;
}

/* Transform */
.transform {
  transform: translate3d(0, 0, 0);
}

.-translate-y-1 {
  transform: translateY(calc(var(--spacing) * -1));
}

/* Card Components */
.card {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
}

.card-content {
  padding: calc(var(--spacing) * 6);
}

/* Button Components */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: calc(var(--radius) - 2px);
  font-size: 0.875rem;
  font-weight: var(--font-weight-medium);
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  border: 1px solid transparent;
  padding: 0.5rem 1rem;
  height: 2.25rem;
}

.btn:focus {
  outline: 2px solid transparent;
  outline-offset: 2px;
}

.btn:disabled {
  pointer-events: none;
  opacity: 0.5;
}

.btn-default {
  background-color: var(--primary);
  color: var(--primary-foreground);
}

.btn-default:hover {
  background-color: rgba(55, 65, 81, 0.9);
}

.btn-outline {
  background-color: transparent;
  color: var(--foreground);
  border-color: var(--border);
}

.btn-outline:hover {
  background-color: var(--accent);
  color: var(--accent-foreground);
}

.btn-sm {
  height: 2rem;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
}

.btn-ghost {
  background-color: transparent;
  color: var(--foreground);
}

.btn-ghost:hover {
  background-color: var(--accent);
  color: var(--accent-foreground);
}

.btn-primary {
  background-color: #2271C2;
  color: #ffffff;
  border-color: #1b5a9c;
}

.btn-primary:hover {
  background-color: #1b5a9c;
  border-color: #164a7f;
}

.placeholder-card,
.info-card {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: calc(var(--spacing) * 6);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
}

.placeholder-card {
  border-style: dashed;
  color: var(--muted-foreground);
  text-align: center;
}

.code-block {
  background-color: var(--input-background);
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid var(--border);
  padding: calc(var(--spacing) * 4);
  font-size: 0.85rem;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}

/* Input Components */
.input {
  display: flex;
  height: 2.5rem;
  width: 100%;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid var(--border);
  background-color: var(--input-background);
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.input:focus {
  outline: 2px solid transparent;
  outline-offset: 2px;
  border-color: var(--primary);
}

.input::placeholder {
  color: var(--muted-foreground);
}

/* Select Components */
.select {
  position: relative;
}

.select-trigger {
  display: flex;
  height: 2.5rem;
  width: 100%;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid var(--border);
  background-color: var(--input-background);
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  cursor: pointer;
  align-items: center;
  justify-content: space-between;
}

.select-trigger:focus {
  outline: 2px solid transparent;
  outline-offset: 2px;
  border-color: var(--primary);
}

.select-content {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 50;
  background-color: var(--popover);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) - 2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  max-height: 15rem;
  overflow-y: auto;
  margin-top: 0.25rem;
}

.select-item {
  display: flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  cursor: pointer;
  transition: background-color 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.select-item:hover {
  background-color: var(--accent);
  color: var(--accent-foreground);
}

/* Checkbox Components */
.checkbox {
  display: flex;
  align-items: center;
  cursor: pointer;
}

.checkbox-input {
  width: 1rem;
  height: 1rem;
  border: 1px solid var(--border);
  border-radius: 0.25rem;
  background-color: var(--background);
  cursor: pointer;
}

.checkbox-input:checked {
  background-color: var(--primary);
  border-color: var(--primary);
}

.checkbox-input:checked::after {
  content: "✓";
  color: var(--primary-foreground);
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

/* Badge Components */
.badge {
  display: inline-flex;
  align-items: center;
  border-radius: calc(var(--radius) - 4px);
  font-size: 0.75rem;
  font-weight: var(--font-weight-medium);
  padding: 0.25rem 0.5rem;
  border: 1px solid transparent;
}

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

.badge-outline {
  background-color: transparent;
  color: var(--foreground);
  border-color: var(--border);
}

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

/* Dropdown Menu */
.dropdown-menu {
  position: relative;
}

.dropdown-trigger {
  display: flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  border-radius: calc(var(--radius) - 2px);
  background-color: transparent;
  border: none;
  cursor: pointer;
  transition: background-color 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.dropdown-content {
  position: absolute;
  top: 100%;
  right: 0;
  z-index: 50;
  background-color: var(--popover);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) - 2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  min-width: 14rem;
  margin-top: 0.25rem;
  display: none;
}

.dropdown-content.show {
  display: block;
}

.dropdown-item {
  display: flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  cursor: pointer;
  transition: background-color 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.dropdown-item:hover {
  background-color: var(--accent);
  color: var(--accent-foreground);
}

/* Tooltip */
.tooltip {
  position: relative;
}

.tooltip-trigger {
  cursor: help;
}

.tooltip-content {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  background-color: var(--popover);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) - 2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  white-space: nowrap;
  margin-bottom: 0.5rem;
  display: none;
}

.tooltip:hover .tooltip-content {
  display: block;
}

/* Avatar */
.avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background-color: var(--muted);
  color: var(--muted-foreground);
  font-size: 0.875rem;
  font-weight: var(--font-weight-medium);
}

/* Role Selector Styles */
.role-card {
  background-color: var(--card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: calc(var(--spacing) * 6);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  height: 100%;
  position: relative;
  overflow: hidden;
}

.role-card:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  transform: translateY(calc(var(--spacing) * -1));
  border-color: var(--border);
}

.role-card.selected {
  transform: translateY(calc(var(--spacing) * -1));
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
}

.role-card.selected.national {
  background-color: rgba(59, 130, 246, 0.1);
  border-color: rgba(59, 130, 246, 0.3);
  box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.1), 0 4px 6px -4px rgba(59, 130, 246, 0.1);
}

.role-card.selected.regional {
  background-color: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.3);
  box-shadow: 0 10px 15px -3px rgba(34, 197, 94, 0.1), 0 4px 6px -4px rgba(34, 197, 94, 0.1);
}

.role-card.selected.district {
  background-color: rgba(168, 85, 247, 0.1);
  border-color: rgba(168, 85, 247, 0.3);
  box-shadow: 0 10px 15px -3px rgba(168, 85, 247, 0.1), 0 4px 6px -4px rgba(168, 85, 247, 0.1);
}

.role-card.selected.school {
  background-color: rgba(249, 115, 22, 0.1);
  border-color: rgba(249, 115, 22, 0.3);
  box-shadow: 0 10px 15px -3px rgba(249, 115, 22, 0.1), 0 4px 6px -4px rgba(249, 115, 22, 0.1);
}

.role-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: calc(var(--radius) + 4px);
  background-color: var(--muted);
  margin-right: 1rem;
  flex-shrink: 0;
  transition: background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.role-card.selected .role-icon.national {
  background-color: rgba(59, 130, 246, 0.2);
}

.role-card.selected .role-icon.regional {
  background-color: rgba(34, 197, 94, 0.2);
}

.role-card.selected .role-icon.district {
  background-color: rgba(168, 85, 247, 0.2);
}

.role-card.selected .role-icon.school {
  background-color: rgba(249, 115, 22, 0.2);
}

.role-selection-indicator {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 10;
}

.role-selection-indicator .check-circle {
  width: 1.5rem;
  height: 1.5rem;
  background-color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

/* Chart Container */
.chart-container {
  position: relative;
  height: 20rem;
  width: 100%;
}

/* Data Preferences */
.preferences-card {
  background-color: var(--gray-700);
  color: white;
  border-radius: var(--radius);
  padding: calc(var(--spacing) * 6);
}

.preferences-header {
  display: flex;
  align-items: center;
  margin-bottom: 1.25rem;
}

.preferences-section {
  margin-bottom: 1.5rem;
}

.preferences-section:last-child {
  margin-bottom: 0;
}

.section-title {
  display: flex;
  align-items: center;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
  margin-bottom: 1.5rem;
  font-weight: var(--font-weight-medium);
  color: white;
}

/* Responsive Design */
@media (max-width: 768px) {
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  
  .grid-cols-4 {
    grid-template-columns: repeat(1, minmax(0, 1fr));
  }
  
  .lg\:grid-cols-4 {
    grid-template-columns: repeat(1, minmax(0, 1fr));
  }
  
  .text-3xl {
    font-size: 1.5rem;
  }
  
  .lg\:text-4xl {
    font-size: 1.875rem;
  }
}

@media (max-width: 640px) {
  .px-6 {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  
  .py-4 {
    padding-top: 1rem;
    padding-bottom: 1rem;
  }
  
  .space-x-3 > :not(:last-child) {
    margin-left: 0.5rem;
  }
  
  .text-xl {
    font-size: 1.125rem;
  }
  
  .text-2xl {
    font-size: 1.25rem;
  }
}

/* Sidebar Styles */
.sidebar {
  width: 280px;
  background-color: var(--secondary);
  border-right: 1px solid var(--border);
  transition: transform 0.3s ease, width 0.3s ease;
  overflow-y: auto;
  overflow-x: hidden;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  position: sticky;
  top: 0;
}

.sidebar.collapsed {
  width: 60px;
}

.sidebar.collapsed .sidebar-menu-title {
  opacity: 0;
  width: 0;
  overflow: hidden;
}

.sidebar.collapsed .sidebar-menu-content {
  display: none;
}

.sidebar-header {
  padding: 1rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-height: 64px;
}

.sidebar-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: calc(var(--radius) - 2px);
  color: var(--foreground);
  transition: background-color 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sidebar-toggle:hover {
  background-color: var(--accent);
}

.sidebar-nav {
  flex: 1;
  padding: 0.5rem;
  overflow-y: auto;
}

.sidebar-menu-section {
  margin-bottom: 0.5rem;
}

.sidebar-menu-header {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--foreground);
  font-size: 0.875rem;
  font-weight: var(--font-weight-medium);
  text-align: left;
  border-radius: calc(var(--radius) - 2px);
  transition: background-color 0.2s;
  position: relative;
}

.sidebar-menu-header:hover {
  background-color: var(--accent);
}

.sidebar-menu-header.active {
  background-color: var(--accent);
}

.sidebar-menu-header .sidebar-chevron {
  margin-left: auto;
  transition: transform 0.3s ease;
}

.sidebar-menu-header.active .sidebar-chevron {
  transform: rotate(180deg);
}

.sidebar-menu-title {
  flex: 1;
  transition: opacity 0.3s ease, width 0.3s ease;
  white-space: nowrap;
}

.sidebar-menu-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  padding-left: 0;
}

.sidebar-menu-content.expanded {
  max-height: 500px;
  padding-left: 0.5rem;
  padding-top: 0.25rem;
}

.sidebar-menu-item {
  display: flex;
  align-items: center;
  padding: 0.625rem 1rem;
  padding-left: 2.75rem;
  color: var(--muted-foreground);
  text-decoration: none;
  font-size: 0.875rem;
  border-radius: calc(var(--radius) - 2px);
  transition: background-color 0.2s, color 0.2s;
  margin-bottom: 0.25rem;
}

.sidebar-menu-item:hover {
  background-color: var(--accent);
  color: var(--foreground);
}

.sidebar-menu-item.active {
  background-color: var(--accent);
  color: var(--foreground);
  font-weight: var(--font-weight-medium);
}

/* Responsive sidebar */
@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 40;
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .sidebar-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 30;
    display: none;
  }

  .sidebar-overlay.active {
    display: block;
  }
}
