:root {
  --header-height: 90px;
  --bg: #ffffff;
  --main-bg: #f4f6f9;
  --text-primary: rgb(30, 41, 59);
  --text-muted: #6c7d95;
  --accent: #e9320e;
  --accent-strong: #e9320e;
  --border: #e2e8f0;
  --shadow: 0 4px 12px rgba(15,23,42,0.08);

  --logo-size: 85px;
}

body {
  margin: 0;
  padding-top: var(--header-height);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-image: url('/Images/fondounidad20tgj.png');
  background-size: cover;
  background-position: center center;
  background-attachment: fixed;
  background-repeat: no-repeat;
  background-color: var(--main-bg);
  font-family: 'Arial', 'Helvetica Neue', Helvetica, sans-serif;
  overflow-x: hidden;
}

h1 {
  display: none;
}

main {
  flex-grow: 1;
  padding-top: 2rem;
  padding-bottom: 2rem;
  background-color: rgba(200, 200, 200, 0.80);
  position: relative;
  z-index: 1;
}

header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  height: var(--header-height);
  background: var(--bg);
  border-bottom: 2px solid var(--accent);
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}

header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
  height: 100%;
}

/* Logo más a la izquierda y más grande */
header .logo-container {
  display: flex;
  align-items: center;
  padding-bottom: 5px;
  margin-left: -10px;
}

header .logo-container img {
  width: var(--logo-size);
  height: var(--logo-size);
  transition: transform 0.3s ease;
}

header .logo-container img:hover {
  transform: scale(1.05);
}

/* Menú de navegación */
header nav .nav {
  display: flex;
  gap: 1.5rem;
  list-style-type: none;
  padding-left: 0;
  margin: 0;
}

header nav .nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 600;
  padding: 0.5rem 0;
  transition: color 160ms ease, border-bottom 160ms ease;
  border-bottom: 3px solid transparent;
}

header nav .nav-link:hover,
header nav .nav-link.active {
  color: var(--accent-strong);
  border-bottom: 3px solid var(--accent-strong);
}

/* --- Listados sin viñetas --- */
ul, ol {
  list-style-type: none;
  padding-left: 0;
  margin: 0;
}

/* Títulos */
h2 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-primary);
  border-bottom: 2px solid var(--border);
  padding-bottom: 0.5rem;
  margin-bottom: 1.5rem;
}

h2#acerca-de {
  text-align: left;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent-strong);
  margin-left: 1rem;
  margin-top: 2rem;
  font-family: 'Arial Black', Arial, sans-serif;
  transform: translateY(-2px);
  transition: transform 0.3s ease;
}

h2#acerca-de:hover {
  transform: translateY(-5px);
}

/* Párrafos */
p {
  text-align: left;
  line-height: 1.8;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  font-weight: 400;
  font-size: 1.1rem;
}

/* Imágenes en contenido */
main img {
  display: block;
  margin: 1.5rem auto;
  max-width: 95%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.25);
  transition: transform 0.3s ease;
}

main img:hover {
  transform: scale(1.05);
}

/* Tarjeta de contacto */
.contact-card {
  max-width: 320px;
  margin: 3rem auto;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

.contact-card .btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  font-weight: 700;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.contact-card .btn-primary:hover {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  transform: translateY(-1px);
}

/* Footer */
footer {
  background-color: #1e293b !important;
  color: #f1f5f9;
  padding-top: 3rem !important;
  padding-bottom: 1rem !important;
  font-size: 0.95rem;
  margin-top: auto !important;
  position: relative;
  z-index: 1;
}

footer h5 {
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 1rem;
  border-bottom: 2px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 0.5rem;
}

footer p {
  color: #cbd5e1;
  text-align: left;
  line-height: 1.5;
  margin-bottom: 0.5rem;
  padding: 0;
}

footer .border-top {
  border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* Estilos para el diseño de cuadros de texto alternados */
.content-grid {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  margin-top: 2rem;
}

.text-card {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 12px;
  padding: 2.5rem;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border-left: 6px solid var(--accent);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  max-width: 85%;
  margin: 0 auto;
}

.text-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.2);
}

.text-card-left {
  align-self: flex-start;
  margin-right: auto;
  border-left: 6px solid var(--accent);
  border-right: none;
}

.text-card-right {
  align-self: flex-end;
  margin-left: auto;
  border-left: none;
  border-right: 6px solid var(--accent);
}

.text-card-center {
  align-self: center;
  margin-left: auto;
  margin-right: auto;
  border-left: 6px solid var(--accent);
  border-right: 6px solid var(--accent);
}

.card-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent-strong);
  margin-bottom: 1.2rem;
  font-family: 'Arial Black', Arial, sans-serif;
  border-bottom: 2px solid var(--border);
  padding-bottom: 0.5rem;
}

.text-card p {
  text-align: left;
  line-height: 1.7;
  color: var(--text-primary);
  margin-bottom: 0;
  font-size: 1.1rem;
}

/* Estilos para la grid de valores - MODIFICADO */
.valores-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-top: 1rem;
}

.valor-item {
  background: rgba(233, 50, 14, 0.1);
  border: 2px solid var(--accent);
  border-radius: 8px;
  padding: 0.8rem 1rem;
  text-align: center;
  font-weight: 600;
  color: var(--text-primary);
  transition: all 0.3s ease;
  font-size: 1rem;
}

.valor-item:hover {
  background: var(--accent);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(233, 50, 14, 0.3);
}

/* NUEVO: Puntualidad ocupa todo el ancho */
.valor-item:last-child {
  grid-column: 1 / -1;
  width: 100%;
}

/* Estilos para la página de Servicios */

/* Filtros */
.filter-buttons {
  margin-bottom: 2rem;
}

.btn-filter {
  background: rgba(255, 255, 255, 0.8);
  border: 2px solid var(--accent);
  color: var(--text-primary);
  margin: 0 0.5rem;
  padding: 0.5rem 1.5rem;
  border-radius: 25px;
  transition: all 0.3s ease;
}

.btn-filter:hover,
.btn-filter.active {
  background: var(--accent);
  color: white;
  transform: translateY(-2px);
}

/* Acordeón de Servicios */
.services-accordion {
  max-width: 1000px;
  margin: 0 auto;
}

.service-card {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 12px;
  margin-bottom: 1rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.service-card:hover {
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border-color: var(--accent);
}

.service-card.active {
  border-color: var(--accent);
  box-shadow: 0 8px 25px rgba(233, 50, 14, 0.2);
}

.service-header {
  padding: 1.5rem;
  background: white;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}

.service-header:hover {
  background: rgba(233, 50, 14, 0.05);
}

.service-header h3 {
  margin: 0;
  color: var(--accent);
  font-size: 1.3rem;
  font-weight: 700;
}

.service-icon {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--accent);
  transition: all 0.3s ease;
  min-width: 20px;
  text-align: center;
}

.service-card.active .service-icon {
  transform: rotate(45deg);
  color: var(--accent-strong);
}

.service-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s ease;
  background: rgba(248, 250, 252, 0.9);
}

.service-content-inner {
  padding: 1.5rem;
}

.service-card.active .service-content {
  max-height: 1000px;
}

/* Mejoras para los tipos de vehículos */
.vehicle-types {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.vehicle-item {
  background: white;
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  border-left: 4px solid var(--accent);
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.vehicle-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.vehicle-item strong {
  display: block;
  color: var(--accent);
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.vehicle-item span {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Galería - TEXTO EN BLANCO */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.gallery-item {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.8));
  color: white;
  padding: 2rem 1rem 1rem;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

/* TEXTO EN BLANCO PARA LA GALERÍA */
.gallery-overlay h5 {
  color: white !important;
  font-weight: 700;
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.7);
}

.gallery-overlay p {
  color: white !important;
  margin-bottom: 0;
  font-size: 0.95rem;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.7);
  opacity: 0.9;
}

.gallery-item:hover .gallery-overlay {
  transform: translateY(0);
}

.gallery-item:hover img {
  transform: scale(1.1);
}

/* ===== ESTILOS PARA LA PÁGINA ABOUT ===== */

/* Timeline */
.timeline-section {
  position: relative;
  max-width: 1000px;
  margin: 0 auto 3rem;
  padding: 0 1rem;
}

.timeline {
  position: relative;
  padding: 2rem 0;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--accent);
  transform: translateX(-50%);
}

.timeline-item {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 3rem;
  position: relative;
}

.timeline-item:nth-child(odd) {
  flex-direction: row;
}

.timeline-item:nth-child(even) {
  flex-direction: row-reverse;
}

.timeline-date {
  flex: 0 0 120px;
  text-align: center;
  background: var(--accent);
  color: white;
  padding: 1rem;
  border-radius: 25px;
  font-weight: bold;
  font-size: 1.1rem;
  margin: 0 2rem;
  position: relative;
  z-index: 2;
}

.timeline-content {
  flex: 0 0 400px;
  background: rgba(255, 255, 255, 0.95);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  border-left: 4px solid var(--accent);
}

.timeline-content h4 {
  color: var(--accent);
  margin-bottom: 1rem;
}

/* Información del Equipo (sin fotos) */
.team-info-section {
  margin: 3rem auto;
  max-width: 1000px;
  padding: 0 1rem;
}

.team-feature {
  background: rgba(255, 255, 255, 0.95);
  padding: 2rem;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  border-left: 4px solid var(--accent);
  transition: all 0.3s ease;
  height: 100%;
}

.team-feature:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.feature-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.team-feature h4 {
  color: var(--accent);
  margin-bottom: 1rem;
}

/* ===== MAPA SIMPLIFICADO - CORREGIDO ===== */
.coverage-section {
  margin: 3rem auto;
  max-width: 1000px;
  padding: 0 1rem;
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
}

.coverage-info-simple {
  background: rgba(255, 255, 255, 0.95);
  padding: 2rem;
  border-radius: 12px;
  border-left: 5px solid var(--accent);
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  width: 100%;
  max-width: 800px;
  text-align: center;
}

.coverage-features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.feature-item {
  text-align: center;
  padding: 1.5rem 1rem;
  background: rgba(233, 50, 14, 0.05);
  border-radius: 10px;
  border: 1px solid rgba(233, 50, 14, 0.2);
  transition: all 0.3s ease;
}

.feature-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
  background: rgba(233, 50, 14, 0.1);
}

.feature-item .feature-icon {
  font-size: 2.5rem;
  display: block;
  margin-bottom: 1rem;
}

.feature-item strong {
  display: block;
  color: var(--accent);
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.feature-item span {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.text-accent {
  color: var(--accent) !important;
}

/* ===== ESTILOS PARA GOOGLE MAPS RESPONSIVE ===== */
.map-section {
  margin: 3rem auto;
  max-width: 1000px;
  padding: 0 1rem;
}

.map-container {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* Proporción 16:9 */
  height: 0;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  margin: 0 auto;
  border: 3px solid var(--accent);
}

.map-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  :root {
    --header-height: 70px;
    --logo-size: 50px;
  }

  body {
    padding-top: 70px;
  }

  header {
    height: 70px;
    min-height: 70px;
    padding: 0.5rem 0;
  }

  header .container {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 0 1rem;
    gap: 0.5rem;
  }

  header .logo-container {
    margin-left: 0;
    padding-bottom: 0;
    flex-shrink: 0;
  }

  header .logo-container img {
    width: 50px;
    height: 50px;
  }

  header nav {
    width: auto;
    flex-grow: 1;
  }

  header nav .nav {
    justify-content: flex-end;
    gap: 0.5rem;
    flex-wrap: nowrap;
  }

  header nav .nav-link {
    font-size: 0.85rem;
    padding: 0.3rem 0.5rem;
    white-space: nowrap;
  }

  h2 {
    font-size: 1.5rem;
    padding-top: 1rem;
    text-align: left;
  }

  .contact-card {
    max-width: 90%;
    margin: 2rem auto !important;
    padding: 1.5rem !important;
    background: rgba(255, 255, 255, 0.7);
  }

  footer h5 {
    margin-top: 1.5rem;
  }

  /* Responsive para cuadros de texto */
  .content-grid {
    gap: 2rem;
  }
  
  .text-card {
    max-width: 95%;
    padding: 2rem;
    margin-left: auto !important;
    margin-right: auto !important;
  }
  
  .text-card-left,
  .text-card-right {
    border-left: 6px solid var(--accent);
    border-right: none;
  }
  
  .card-title {
    font-size: 1.5rem;
  }
  
  .text-card p {
    font-size: 1rem;
  }

  /* Responsive para servicios */
  .service-header {
    padding: 1rem;
  }
  
  .service-header h3 {
    font-size: 1.1rem;
  }
  
  .vehicle-types {
    grid-template-columns: 1fr;
  }
  
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  
  .btn-filter {
    margin: 0.25rem;
    padding: 0.5rem 1rem;
  }

  /* Responsive para about */
  .timeline::before {
    left: 30px;
  }
  
  .timeline-item {
    flex-direction: row !important;
    justify-content: flex-start;
    margin-left: 60px;
  }
  
  .timeline-date {
    position: absolute;
    left: -90px;
    margin: 0;
  }
  
  .timeline-content {
    flex: 1;
  }

  /* Responsive para mapa simple */
  .coverage-features {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .feature-item {
    padding: 1rem 0.5rem;
  }
  
  .feature-item .feature-icon {
    font-size: 2rem;
  }

  .valores-grid {
    grid-template-columns: 1fr;
    gap: 0.8rem;
  }
  
  .valor-item {
    padding: 0.7rem 0.9rem;
    font-size: 0.95rem;
  }

  /* Responsive para puntualidad en móvil */
  .valor-item:last-child {
    grid-column: 1;
  }

  /* Responsive para cobertura */
  .coverage-info-simple {
    padding: 1.5rem;
    max-width: 95%;
  }

  /* Responsive para el mapa */
  .map-section {
    padding: 0 0.5rem;
    max-width: 95%;
  }
  
  .map-container {
    padding-bottom: 75%;
    border-radius: 8px;
  }
}

@media (max-width: 576px) {
  :root {
    --header-height: 65px;
    --logo-size: 45px;
  }

  body {
    padding-top: 65px;
  }

  header {
    height: 65px;
    min-height: 65px;
  }

  header .logo-container img {
    width: 45px;
    height: 45px;
  }

  header nav .nav-link {
    font-size: 0.8rem;
    padding: 0.25rem 0.4rem;
  }

  .text-card {
    padding: 1.5rem;
    max-width: 100%;
  }
  
  .card-title {
    font-size: 1.3rem;
  }

  .gallery-grid {
    gap: 1rem;
  }

  .team-feature {
    padding: 1.5rem;
  }
  
  .feature-icon {
    font-size: 2.5rem;
  }

  /* Responsive para mapa simple */
  .coverage-features {
    grid-template-columns: 1fr;
  }
  
  .coverage-info-simple {
    padding: 1.5rem;
  }
  
  .feature-item .feature-icon {
    font-size: 1.8rem;
  }

  .map-container {
    padding-bottom: 100%;
  }
}