/* Base Styles */
:root {
  --primary-color: #4569fc;
  --secondary-color: #18319a;
  --accent-color: #ffaa00;
  --text-color: #0f0f0f;
  --light-bg: #f9f9f9;
  --white: #ffffff;
  --gray: #6c757d;
  --light-gray: #e9ecef;
  --border-radius: 8px;
  --box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  --transition: all 0.1s ease;
}

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

body {
  font-family: 'DM Sans', sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--light-bg);
  margin: 0;
  padding: 0;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--secondary-color);
}

.button {
  display: inline-block;
  background-color: var(--primary-color);
  color: var(--white);
  padding: 12px 24px;
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition);
  margin-top: 20px;
}

.button:hover {
  background-color: var(--secondary-color);
  color: var(--white);
  transform: translateY(-2px);
}

/* Header Styles - MODIFIED */
.header-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
}

.logo-container {
  display: flex;
  align-items: center;
}

.company-logo {
  height: 24px;
  width: auto;
}

nav {
  margin-top: 0;
}

nav ul {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
  justify-content: flex-end;
}

nav li {
  margin: 0 15px;
}

nav a {
  font-weight: 500;
  padding: 8px 12px;
  position: relative;
  color: var(--gray);
}

nav a:hover {
  color: var(--primary-color);
}

/* SIMPLIFIED ACTIVE STYLE */
nav a.active {
  color: var(--primary-color);
  font-weight: 600;
}

nav a.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1px;
}

/* Main Content Styles */
main {
  padding: 40px 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Hedvig Letters Serif', serif;
  margin-bottom: 20px;
  line-height: 1.2;
  color: var(--primary-color);
}

h1 {
  font-size: 2.5rem;
  margin-bottom: 30px;
  text-align: center;
  color: var(--text-color);
}

h2 {
  font-size: 2rem;
  color: var(--text-color);
}

h3 {
  font-size: 1.5rem;
  margin-top: 30px;
}

p {
  margin-bottom: 20px;
}

/* Hero Section - IMPROVED */
.hero {
  text-align: center;
  padding: 50px 0;
  margin-bottom: 60px;
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
}

.hero h1 {
  color: var(--text-color);
  font-size: 2.8rem;
  margin-bottom: 20px;
}

.hero p {
  font-size: 1.2rem;
  max-width: 800px;
  margin: 0 auto 30px;
  color: var(--gray);
}

.government-logos {
  width: 100%;
  height: auto;
  margin: 30px 0;
}

/* Services Overview Section */
.services-overview {
  background-color: var(--white);
  padding: 40px;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  margin-bottom: 60px;
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
}

.services-overview h2 {
  text-align: center;
  margin-bottom: 30px;
}

.services-overview ul {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-bottom: 30px;
  padding: 0;
  list-style: none;
  justify-content: center;
}

.services-overview li {
  flex: 0 0 calc(33.333% - 10px);
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100px;
  background-color: var(--light-bg);
  padding: 15px;
  border-radius: var(--border-radius);
  border: 1px solid var(--light-gray);
  text-align: center;
  box-shadow: var(--box-shadow);
  transition: var(--transition);
}

.services-overview li a {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
  color: var(--secondary-color);
  font-weight: 500;
}

.services-overview li:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
  border-color: var(--primary-color);
}

.services-overview a.button {
  display: block;
  max-width: 250px;
  text-align: center;
  margin: 30px auto 0;
}

/* Service Sections */
.service {
  background-color: var(--white);
  border-radius: var(--border-radius);
  margin-bottom: 40px;
  box-shadow: var(--box-shadow);
  overflow: hidden;
}

.service-header {
  background-color: var(--primary-color);
  color: var(--white);
  padding: 20px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.service-header h2 {
  color: var(--white);
  margin-bottom: 0;
  font-size: 1.6rem;
}

.service-badge {
  background-color: var(--accent-color);
  padding: 8px 16px;
  border-radius: 20px;
  font-weight: bold;
  font-size: 0.9rem;
}

.service-content {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  align-items: flex-start;
  padding: 30px 40px 40px;
}

.service-description,
.service-features {
  flex: 1 1 45%;
  min-width: 300px;
}

.service-description h3 {
  color: var(--primary-color);
}

.service-description ul {
  margin-left: 20px;
}

.service-description li {
  margin-bottom: 8px;
}

.service-pricing {
  flex: 1 1 100%;
  margin-top: 10px;
  border-top: 1px solid var(--light-gray);
}

/* Table Styles */
.service-pricing table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  background-color: var(--white);
}

.service-pricing th,
.service-pricing td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid var(--light-gray);
}

.service-pricing th {
  background-color: var(--light-bg);
  font-weight: 600;
  color: var(--secondary-color);
}

.service-pricing tr:last-child td {
  border-bottom: none;
}

.service-pricing tr:hover {
  background-color: var(--light-bg);
}

.service-features ul {
  margin-left: 20px;
}

.service-features li {
  margin-bottom: 8px;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

th,
td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid var(--light-gray);
}

th {
  background-color: var(--light-bg);
  font-weight: 600;
}

tr:last-child td {
  border-bottom: none;
}

tr:hover {
  background-color: var(--light-bg);
}

/* Legal Sections */
.legal-section {
  background-color: var(--white);
  padding: 30px;
  border-radius: var(--border-radius);
  margin-bottom: 30px;
  box-shadow: var(--box-shadow);
}

.legal-section h2 {
  color: var(--primary-color);
  border-bottom: 2px solid var(--light-gray);
  padding-bottom: 10px;
  margin-bottom: 20px;
}

.legal-section ul {
  margin-left: 20px;
}

.legal-section li {
  margin-bottom: 10px;
}

/* Footer Styles - NEW */
footer {
  background-color: var(--secondary-color);
  color: var(--white);
  padding: 50px 0 20px;
  margin-top: 60px;
}

.footer-content {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 15px;
}

.footer-primary {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 40px;
}

.contact-info,
.about-company {
  flex: 1 1 300px;
}

.contact-info h3,
.about-company h3 {
  color: var(--white);
  margin-bottom: 20px;
  font-size: 1.3rem;
}

.contact-info p,
.about-company p {
  margin-bottom: 12px;
}

.footer-link {
  color: var(--white);
  text-decoration: underline;
  font-weight: 500;
  transition: var(--transition);
}

.footer-link:hover {
  color: rgba(255, 255, 255, 0.7);
}

.footer-secondary {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
}

/* Animations - FIXED */
.fade-in {
  animation: fadeIn 0.2s ease-in; /* REDUCED from 0.8s to 0.2s */
}

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

/* Enhanced color usage for UI elements */
.button {
  background-color: var(--primary-color);
}

.button:hover {
  background-color: var(--secondary-color);
}

.service-header {
  background-color: var(--secondary-color);
}

nav a.active {
  color: var(--primary-color);
  border-bottom: 3px solid var(--primary-color);
}

.services-overview li:hover {
  border-color: var(--primary-color);
}

footer {
  background-color: var(--secondary-color);
}

.legal-section h2 {
  color: var(--secondary-color);
}

/* Responsive Styles */
@media (max-width: 768px) {
  .header-wrapper {
    justify-content: center;
  }

  nav {
    display: none;
  }

  .logo-container {
    flex-direction: column;
    gap: 15px;
  }

  .program-logos {
    position: relative;
    top: 0;
    right: 0;
    margin-top: 15px;
  }

  .service-content {
    flex-direction: column;
    padding: 20px;
  }

  .service-description,
  .service-features,
  .service-pricing {
    flex-basis: 100%;
  }

  .service-pricing {
    overflow-x: auto; /* Para tablas responsivas en móvil */
  }

  .hero {
    padding: 30px 15px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.6rem;
  }

  .service-header {
    flex-direction: column;
    padding: 20px;
    gap: 10px;
    align-items: flex-start;
  }

  .footer-primary {
    flex-direction: column;
    gap: 30px;
  }

  .contact-info,
  .about-company {
    text-align: center;
  }
}

@media (max-width: 480px) {
  .services-overview li {
    flex: 0 0 100%;
  }
}

.contact-link {
  color: var(--white);
  text-decoration: underline;
  transition: var(--transition);
}

.contact-link:hover {
  color: rgba(255, 255, 255, 0.7);
}

/* Pricing Toggle Styles */
.pricing-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 10px 0;
}

.toggle-pricing {
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

.toggle-pricing svg {
  fill: var(--primary-color);
}

.toggle-pricing.active {
  transform: rotate(45deg);
}

.pricing-content {
  transition: max-height 0.3s ease-out;
  overflow: hidden;
}

.pricing-content.hidden {
  display: none;
}
