/* CSS Variables for Light and Dark Themes */
:root {
  /* Light theme colors */
  --background: 0 0% 100%;
  --foreground: 222.2 84% 4.9%;
  --card: 0 0% 100%;
  --card-foreground: 222.2 84% 4.9%;
  --popover: 0 0% 100%;
  --popover-foreground: 222.2 84% 4.9%;
  --primary: 210 79% 46%;
  --primary-foreground: 210 40% 98%;
  --secondary: 210 40% 96.1%;
  --secondary-foreground: 222.2 47.4% 11.2%;
  --muted: 210 40% 96.1%;
  --muted-foreground: 215.4 16.3% 46.9%;
  --accent: 210 40% 96.1%;
  --accent-foreground: 222.2 47.4% 11.2%;
  --destructive: 0 84.2% 60.2%;
  --destructive-foreground: 210 40% 98%;
  --border: 214.3 31.8% 91.4%;
  --input: 214.3 31.8% 91.4%;
  --ring: 210 79% 46%;
  --radius: 0.5rem;
}

/* Dark theme colors */
.dark {
  --background: 222.2 84% 4.9%;
  --foreground: 210 40% 98%;
  --card: 222.2 84% 4.9%;
  --card-foreground: 210 40% 98%;
  --popover: 222.2 84% 4.9%;
  --popover-foreground: 210 40% 98%;
  --primary: 210 79% 46%;
  --primary-foreground: 210 40% 98%;
  --secondary: 217.2 32.6% 17.5%;
  --secondary-foreground: 210 40% 98%;
  --muted: 217.2 32.6% 17.5%;
  --muted-foreground: 215 20.2% 65.1%;
  --accent: 217.2 32.6% 17.5%;
  --accent-foreground: 210 40% 98%;
  --destructive: 0 62.8% 30.6%;
  --destructive-foreground: 210 40% 98%;
  --border: 217.2 32.6% 17.5%;
  --input: 217.2 32.6% 17.5%;
  --ring: 210 79% 46%;
}

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

body {
  font-family: "Lora", serif; /* Updated font-family quotes */
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  line-height: 1.6; /* Added line-height */
  -webkit-font-smoothing: antialiased; /* Added antialiased font smoothing */
  -moz-osx-font-smoothing: grayscale; /* Added grayscale font smoothing */
  transition: background-color 0.3s ease, color 0.3s ease; /* Retained from original */
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Cormorant Garamond", serif; /* Updated font-family quotes */
  font-weight: 700; /* Updated font-weight */
  line-height: 1.2;
}

/* Custom Utilities */
.font-heading {
  font-family: "Cormorant Garamond", serif;
}

.font-body {
  font-family: "Lora", serif;
}

.text-balance {
  text-wrap: balance;
}

.text-pretty {
  text-wrap: pretty;
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Smooth Scrolling */
html {
  scroll-behavior: smooth;
}

/* Focus Styles */
*:focus-visible {
  outline: 2px solid hsl(var(--ring));
  outline-offset: 2px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px; /* Updated width */
  height: 10px; /* Updated height */
}

::-webkit-scrollbar-track {
  background: hsl(var(--muted)); /* Updated background color */
}

::-webkit-scrollbar-thumb {
  background: hsl(var(--muted-foreground) / 0.3); /* Updated background color */
  border-radius: 5px; /* Updated border-radius */
}

::-webkit-scrollbar-thumb:hover {
  background: hsl(var(--muted-foreground) / 0.5); /* Updated background color */
}

/* Link Styles */
a {
  color: inherit; /* Updated color */
  text-decoration: none; /* Updated text-decoration */
  transition: color 0.2s ease; /* Retained from original */
}

a:hover {
  color: hsl(var(--primary) / 0.8); /* Retained from original */
}

/* Button Reset */
button {
  background: none; /* Added background reset */
  border: none; /* Added border reset */
  cursor: pointer;
  font-family: inherit; /* Added font-family inherit */
  transition: all 0.2s ease; /* Retained from original */
}

button:hover {
  opacity: 0.9; /* Retained from original */
}

/* Image Styles */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Form Elements */
input, textarea, select {
  font-family: inherit;
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  padding: 0.5rem;
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
}

input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: hsl(var(--primary));
  box-shadow: 0 0 0 3px hsl(var(--ring) / 0.1);
}

/* Cards */
.card {
  background-color: hsl(var(--card));
  color: hsl(var(--card-foreground));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  padding: 1.5rem;
}

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

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

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

.animate-slide-down {
  animation: slideDown 0.2s ease-out;
}

/* Backdrop Blur Support */
@supports (backdrop-filter: blur(10px)) {
  .backdrop-blur {
    backdrop-filter: blur(10px);
  }
}

/* Print Styles */
@media print {
  body { /* Retained from original, though some print rules moved to general print */
    background: white;
    color: black;
  }
  header,
  footer,
  nav,
  .no-print {
    display: none;
  }
  a {
    text-decoration: underline; /* Retained from original */
  }
  button {
    display: none; /* Retained from original */
  }
}

/* Accessibility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Loading State */
.loading {
  opacity: 0.6;
  pointer-events: none;
}

/* Transition Classes */
.transition-colors {
  transition-property: color, background-color, border-color;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

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

.transition-all {
  transition-property: all;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}
