:root {
  /* Tailwind Original Palette */
  --color-primary: #1e3a5f;
  --color-secondary: #64748b;
  --color-background-light: #f8fafc;
  --color-background-dark: #0f172a;

  --color-text-light: #1e293b;
  /* text-slate-800 */
  --color-text-dark: #f1f5f9;
  /* text-slate-100/200 */
  --color-muted-light: #475569;
  /* text-slate-600 */
  --color-muted-dark: #94a3b8;
  /* text-slate-400 */

  /* Bulma Overrides */
  --bulma-primary: #1e3a5f;
  --bulma-primary-h: 214;
  --bulma-primary-s: 52%;
  --bulma-primary-l: 25%;

  --bulma-link: #1e3a5f;
  --bulma-info: #137fec;

  --bulma-family-sans-serif: 'Inter', sans-serif;
  --bulma-title-family: 'Montserrat', sans-serif;
  --bulma-body-background-color: var(--color-background-light);
  --bulma-text: var(--color-text-light);
  --bulma-title-color: var(--color-primary);
}

/* Dark Mode Handling */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bulma-body-background-color: var(--color-background-dark);
    --bulma-text: var(--color-text-dark);
    --bulma-title-color: #ffffff;
    --color-muted-light: var(--color-muted-dark);
  }
}

[data-theme="dark"],
.dark {
  --bulma-body-background-color: var(--color-background-dark);
  --bulma-text: var(--color-text-dark);
  --bulma-title-color: #ffffff;
  --color-muted-light: var(--color-muted-dark);

  --bulma-card-background-color: #1e293b;
  /* slate-800 */
  --bulma-border: #334155;
  /* slate-700 */
}

/* Custom Utilities */
body {
  font-family: 'Inter', sans-serif;
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1,
h2,
h3,
.navbar-item {
  font-family: 'Montserrat', sans-serif;
}

/* Hero Gradient from original file */
.hero-gradient {
  background: linear-gradient(rgba(30, 58, 95, 0.8), rgba(30, 58, 95, 0.6)), url('/images/mateDeLuna.jpg');
  background-size: cover;
  background-position: center;
}

/* Additional Custom Styles to match Tailwind utils */
.navbar {
  backdrop-filter: blur(12px);
  background-color: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid #e2e8f0;
}

[data-theme="dark"] .navbar,
.dark .navbar {
  background-color: rgba(15, 23, 42, 0.9);
  border-bottom: 1px solid #334155;
}

.navbar-item.has-text-weight-semibold {
  font-size: 0.875rem;
  /* text-sm */
}

.card-feature {
  height: 100%;
  border: 1px solid #e2e8f0;
  transition: all 0.3s ease;
}

.feature-icon-wrapper {
  width: 3.5rem;
  height: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  margin-bottom: 1.5rem;
  background-color: #f1f5f9;
}

[data-theme="dark"] .feature-icon-wrapper,
.dark .feature-icon-wrapper {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(148, 163, 184, 0.12));
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.28), inset 0 0 0 1px rgba(226, 232, 240, 0.04);
}

[data-theme="dark"] .card-feature,
.dark .card-feature {
  background-color: #1e293b;
  border-color: #334155;
  margin-bottom: 0;
}

[data-theme="dark"] .icon.has-text-primary,
.dark .icon.has-text-primary,
[data-theme="dark"] .material-icons-outlined.has-text-primary,
.dark .material-icons-outlined.has-text-primary,
[data-theme="dark"] .feature-icon-wrapper .material-icons-outlined,
.dark .feature-icon-wrapper .material-icons-outlined {
  color: #e2e8f0 !important;
}

[data-theme="dark"] .feature-icon-wrapper,
.dark .feature-icon-wrapper,
[data-theme="dark"] .media .icon.has-background-white-ter,
.dark .media .icon.has-background-white-ter {
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.2);
}

[data-theme="dark"] .card-feature:hover .feature-icon-wrapper,
.dark .card-feature:hover .feature-icon-wrapper {
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.28), rgba(226, 232, 240, 0.14));
  border-color: rgba(191, 219, 254, 0.45);
}

.card-feature:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

/* Footer specific */
.footer {
  background-color: #0f172a;
  color: #94a3b8;
}

.footer a {
  color: #cbd5e1;
}

.footer a:hover {
  color: white;
}

.footer-title {
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.875rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

/* Dark mode overrides for light background sections and grey text */
.dark .has-background-white,
[data-theme="dark"] .has-background-white {
  background-color: var(--color-background-dark) !important;
}

.dark .has-background-white-ter,
[data-theme="dark"] .has-background-white-ter {
  background-color: #0b1220 !important;
  /* slightly lighter than body for contrast */
}

.dark .has-text-grey,
[data-theme="dark"] .has-text-grey {
  color: var(--color-muted-dark) !important;
}

.dark .title,
[data-theme="dark"] .title {
  color: var(--bulma-title-color) !important;
}