@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

html {
  overflow-x: hidden;
  width: 100%;
  box-sizing: border-box;
}

*, *:before, *:after {
  box-sizing: inherit;
}

body {
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  width: 100%;
  position: relative;
}

/* Transición suave para cambio de tema */
html.theme-transition,
html.theme-transition *,
html.theme-transition *:before,
html.theme-transition *:after {
  transition: background-color 0.35s ease, border-color 0.35s ease, color 0.25s ease, fill 0.25s ease, stroke 0.25s ease, box-shadow 0.35s ease !important;
}

/* Efectos de Cristal / Glassmorphism Estilo Apple */
.glass-nav {
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.glass-card {
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

/* Gradientes sutiles de texto Apple */
.text-gradient-apple {
  background: linear-gradient(180deg, #FFFFFF 0%, #A1A1AA 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-gradient-apple-light {
  background: linear-gradient(180deg, #18181B 0%, #71717A 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-gradient-blue {
  background: linear-gradient(135deg, #38BDF8 0%, #6366F1 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Animaciones del switch de Sol y Luna */
.theme-switch-ray {
  transform-origin: center;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
}

.theme-switch-center {
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), r 0.4s ease;
}

.dark .theme-switch-center {
  transform: rotate(-20deg);
}

/* Ambient glow */
.ambient-glow {
  position: absolute;
  filter: blur(100px);
  pointer-events: none;
  opacity: 0.45;
  border-radius: 9999px;
  z-index: 0;
}

/* Estilo para Scrollbar sutil estilo Mac */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: rgba(150, 150, 150, 0.25);
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(150, 150, 150, 0.45);
}