

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Merriweather:ital,wght@0,300;0,400;0,700;0,900;1,300;1,400&display=swap');

:root {
  
  --color-primary-900: #0d1f33;
  --color-primary-800: #1a3a5c;
  --color-primary-700: #1e4976;
  --color-primary-600: #2360a0;
  --color-primary-500: #2e6da4;
  --color-primary-400: #4a8fc5;
  --color-primary-300: #7ab5dc;
  --color-primary-200: #b3d5ef;
  --color-primary-100: #deeef9;
  --color-primary-50:  #f0f7fd;

  
  --color-accent-gold:      #c9a227;
  --color-accent-gold-light:#f0d87b;
  --color-accent-gold-dark: #a07d12;

  
  --color-accent-red:       #c0392b;
  --color-accent-red-light: #e8716a;

  
  --color-white:   #ffffff;
  --color-gray-50: #f8fafc;
  --color-gray-100:#f1f5f9;
  --color-gray-200:#e2e8f0;
  --color-gray-300:#cbd5e1;
  --color-gray-400:#94a3b8;
  --color-gray-500:#64748b;
  --color-gray-600:#475569;
  --color-gray-700:#334155;
  --color-gray-800:#1e293b;
  --color-gray-900:#0f172a;

  
  --color-success: #16a34a;
  --color-success-light: #dcfce7;
  --color-warning: #d97706;
  --color-warning-light: #fef3c7;
  --color-error:   #dc2626;
  --color-error-light: #fee2e2;
  --color-info:    #2563eb;
  --color-info-light: #dbeafe;

  
  --font-heading: 'Merriweather', Georgia, serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;
  --font-mono:    'Courier New', monospace;

  
  --text-xs:   0.75rem;    
  --text-sm:   0.875rem;   
  --text-base: 1rem;       
  --text-lg:   1.125rem;   
  --text-xl:   1.25rem;    
  --text-2xl:  1.5rem;     
  --text-3xl:  1.875rem;   
  --text-4xl:  2.25rem;    
  --text-5xl:  3rem;       
  --text-6xl:  3.75rem;    

  
  --fw-light:    300;
  --fw-regular:  400;
  --fw-medium:   500;
  --fw-semibold: 600;
  --fw-bold:     700;
  --fw-extrabold:800;

  
  --space-1:  0.25rem;   
  --space-2:  0.5rem;    
  --space-3:  0.75rem;   
  --space-4:  1rem;      
  --space-5:  1.25rem;   
  --space-6:  1.5rem;    
  --space-8:  2rem;      
  --space-10: 2.5rem;    
  --space-12: 3rem;      
  --space-16: 4rem;      
  --space-20: 5rem;      
  --space-24: 6rem;      

  
  --radius-sm:  4px;
  --radius-md:  8px;
  --radius-lg:  12px;
  --radius-xl:  16px;
  --radius-2xl: 24px;
  --radius-full:9999px;

  
  --shadow-sm:  0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md:  0 4px 6px rgba(0,0,0,.07), 0 2px 4px rgba(0,0,0,.06);
  --shadow-lg:  0 10px 15px rgba(0,0,0,.08), 0 4px 6px rgba(0,0,0,.05);
  --shadow-xl:  0 20px 25px rgba(0,0,0,.10), 0 10px 10px rgba(0,0,0,.04);
  --shadow-2xl: 0 25px 50px rgba(0,0,0,.15);
  --shadow-blue: 0 8px 30px rgba(30, 73, 118, 0.25);

  
  --transition-fast:   150ms ease;
  --transition-base:   250ms ease;
  --transition-slow:   400ms ease;
  --transition-spring: 300ms cubic-bezier(0.34, 1.56, 0.64, 1);

  
  --container-max: 1280px;
  --navbar-height: 72px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: var(--fw-regular);
  line-height: 1.6;
  color: var(--color-gray-800);
  background-color: var(--color-gray-50);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: var(--fw-bold);
  line-height: 1.2;
  color: var(--color-primary-800);
}

h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-base); }

p {
  color: var(--color-gray-600);
  line-height: 1.75;
}

strong { font-weight: var(--fw-semibold); color: var(--color-gray-800); }
em     { font-style: italic; }

.hidden    { display: none !important; }
.sr-only   { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.text-center { text-align: center; }
.text-left   { text-align: left; }
.text-right  { text-align: right; }

.mt-auto   { margin-top: auto; }
.ml-auto   { margin-left: auto; }

.flex      { display: flex; }
.flex-col  { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2     { gap: var(--space-2); }
.gap-4     { gap: var(--space-4); }
.gap-6     { gap: var(--space-6); }

.icon-sm   { width: 16px; height: 16px; display: inline-block; vertical-align: middle; }
.icon-md   { width: 20px; height: 20px; display: inline-block; vertical-align: middle; }
.icon-lg   { width: 24px; height: 24px; display: inline-block; vertical-align: middle; }
.icon-xl   { width: 32px; height: 32px; display: inline-block; vertical-align: middle; }

.section-header {
  text-align: center;
  margin-bottom: var(--space-12);
}
.section-header__eyebrow {
  display: inline-block;
  font-size: var(--text-sm);
  font-weight: var(--fw-semibold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-primary-500);
  background: var(--color-primary-50);
  border: 1px solid var(--color-primary-200);
  padding: var(--space-1) var(--space-4);
  border-radius: var(--radius-full);
  margin-bottom: var(--space-4);
}
.section-header__title {
  font-size: var(--text-3xl);
  color: var(--color-primary-800);
  margin-bottom: var(--space-4);
}
.section-header__subtitle {
  font-size: var(--text-lg);
  color: var(--color-gray-500);
  max-width: 600px;
  margin: 0 auto;
}
.section-header__divider {
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--color-primary-500), var(--color-accent-gold));
  border-radius: var(--radius-full);
  margin: var(--space-4) auto 0;
}

.page-loader {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
}
.loader-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid var(--color-primary-100);
  border-top-color: var(--color-primary-500);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

.offline-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: var(--color-warning);
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
  font-weight: var(--fw-medium);
}

.toast-container {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  pointer-events: none;
}

.toast {
  pointer-events: all;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-lg);
  background: var(--color-white);
  box-shadow: var(--shadow-xl);
  min-width: 280px;
  max-width: 380px;
  border-left: 4px solid var(--color-primary-500);
  animation: toastIn 0.35s var(--transition-spring) forwards;
  font-size: var(--text-sm);
  font-weight: var(--fw-medium);
}
.toast--success { border-left-color: var(--color-success); }
.toast--error   { border-left-color: var(--color-error); }
.toast--warning { border-left-color: var(--color-warning); }
.toast--info    { border-left-color: var(--color-info); }
.toast__icon    { flex-shrink: 0; }
.toast__msg     { flex: 1; color: var(--color-gray-700); }
.toast__close   { flex-shrink: 0; color: var(--color-gray-400); cursor: pointer; padding: 2px; }
.toast__close:hover { color: var(--color-gray-700); }

@keyframes toastIn {
  from { opacity: 0; transform: translateX(100%); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes toastOut {
  to { opacity: 0; transform: translateX(120%); }
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-xs);
  font-weight: var(--fw-semibold);
  padding: 2px var(--space-2);
  border-radius: var(--radius-full);
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.badge--cultural  { background: #e0e7ff; color: #3730a3; }
.badge--deportivo { background: #dcfce7; color: #166534; }
.badge--academico { background: #fef3c7; color: #92400e; }
.badge--social    { background: #fce7f3; color: #9d174d; }
.badge--cientifico{ background: #cffafe; color: #164e63; }
.badge--general   { background: var(--color-primary-100); color: var(--color-primary-700); }

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--color-gray-100); }
::-webkit-scrollbar-thumb { background: var(--color-primary-300); border-radius: var(--radius-full); }
::-webkit-scrollbar-thumb:hover { background: var(--color-primary-400); }

:focus-visible {
  outline: 2px solid var(--color-primary-400);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

::selection {
  background: var(--color-primary-200);
  color: var(--color-primary-900);
}

@media (max-width: 768px) {
  h1 { font-size: var(--text-3xl); }
  h2 { font-size: var(--text-2xl); }
  h3 { font-size: var(--text-xl); }
  .section-header__title { font-size: var(--text-2xl); }
}
