:root {
  --color-primary: #3c0c7a;    /* Deep Purple */
  --color-secondary: #2a348e;  /* Blue */
  --color-accent: #f47e25;     /* Orange */
  --color-danger: #d90b16;     /* Red */
  --color-dark: #111111;       /* Black */
  --color-light: #f8f9fa;      /* Off-White */
  --color-white: #ffffff;
  
  --font-main: 'Inter', system-ui, -apple-system, sans-serif;
  --transition: all 0.3s ease;
}

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

body {
  font-family: var(--font-main);
  background-color: var(--color-light);
  color: var(--color-dark);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4 {
  font-weight: 700;
  line-height: 1.2;
}

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

/* Utilities */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.text-center {
  text-align: center;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
  font-size: 2.5rem;
  color: var(--color-primary);
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: var(--color-accent);
  margin: 10px auto 0;
  border-radius: 2px;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 30px;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  color: var(--color-white);
  box-shadow: 0 4px 15px rgba(60, 12, 122, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(60, 12, 122, 0.4);
}

.btn-accent {
  background: var(--color-accent);
  color: var(--color-white);
  box-shadow: 0 4px 15px rgba(244, 126, 37, 0.3);
}

.btn-accent:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(244, 126, 37, 0.4);
}

.btn-whatsapp {
  background: #25d366;
  color: var(--color-white);
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-whatsapp:hover {
  background: #1ebc5a;
  transform: scale(1.05);
}

/* Header */
.header {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  padding: 15px 0;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo img {
  height: 110px;
  transition: var(--transition);
  animation: spin 1.5s ease-in-out 3;
}

@keyframes spin {
  0% { transform: rotateY(0deg); }
  100% { transform: rotateY(360deg); }
}

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

.nav-links {
  display: flex;
  gap: 25px;
  align-items: center;
}

.nav-links a {
  font-weight: 500;
  color: var(--color-dark);
  transition: var(--transition);
}

.nav-links a:hover {
  color: var(--color-accent);
}

.lang-switch {
  cursor: pointer;
  background: transparent;
  border: 1px solid var(--color-secondary);
  color: var(--color-secondary);
  padding: 5px 10px;
  border-radius: 5px;
  font-weight: bold;
  transition: var(--transition);
}

.lang-switch:hover {
  background: var(--color-secondary);
  color: var(--color-white);
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: var(--color-primary);
  transition: var(--transition);
}

/* Hero Section */
.hero {
  padding: 150px 0 80px;
  background-color: var(--color-dark);
  text-align: center;
  min-height: 80vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.video-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  background-color: var(--color-dark);
}

.video-background video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5; /* Oscurece el video para que el texto resalte */
}

.hero-content {
  position: relative;
  z-index: 2;
  background: rgba(255, 255, 255, 0.85);
  padding: 50px 40px;
  border-radius: 20px;
  backdrop-filter: blur(10px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.2);
  max-width: 900px;
  margin: 0 auto;
}

.hero-content h1 {
  font-size: 3.5rem;
  color: var(--color-primary);
  margin-bottom: 20px;
}

.hero-content p {
  font-size: 1.25rem;
  color: var(--color-secondary);
  margin-bottom: 40px;
  max-width: 800px;
  margin-inline: auto;
}

.hero-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
}

/* Services Grid */
.section {
  padding: 80px 0;
}

.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.card {
  background: var(--color-white);
  padding: 40px 30px;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
  transition: var(--transition);
  text-align: center;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,0.02);
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-secondary));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.card:hover::before {
  transform: scaleX(1);
}

.card-icon {
  font-size: 3rem;
  color: var(--color-accent);
  margin-bottom: 20px;
}

.card h3 {
  margin-bottom: 15px;
  color: var(--color-primary);
}

.price {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--color-secondary);
  margin: 15px 0;
}

/* Courses Section */
.courses-bg {
  background: var(--color-primary);
  color: var(--color-white);
}

.courses-bg .section-title {
  color: var(--color-white);
}

.courses-bg .section-title::after {
  background: var(--color-accent);
}

.course-item {
  background: rgba(255,255,255,0.1);
  padding: 20px;
  border-radius: 10px;
  backdrop-filter: blur(5px);
  border: 1px solid rgba(255,255,255,0.1);
  transition: var(--transition);
}

.course-item:hover {
  background: rgba(255,255,255,0.2);
}

/* Footer */
.footer {
  background: var(--color-dark);
  color: var(--color-white);
  padding: 60px 0 20px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer h4 {
  margin-bottom: 20px;
  color: var(--color-accent);
}

.footer p, .footer a {
  color: rgba(255,255,255,0.7);
  margin-bottom: 10px;
  display: block;
}

.footer a:hover {
  color: var(--color-white);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.5);
}

/* Responsive */
@media (max-width: 768px) {
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: var(--color-white);
    flex-direction: column;
    padding: 20px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    transform: translateY(-150%);
    transition: transform 0.3s ease-in-out;
    opacity: 0;
  }
  
  .nav-links.active {
    transform: translateY(0);
    opacity: 1;
  }

  .menu-toggle {
    display: flex;
  }
  
  .hero-content h1 {
    font-size: 2.5rem;
  }
  
  .hero-buttons {
    flex-direction: column;
  }
}

/* Certifications Table */
.cert-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 2rem;
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.cert-table th, .cert-table td {
  padding: 15px 20px;
  text-align: left;
  border-bottom: 1px solid #eee;
}

.cert-table th {
  background: var(--color-primary);
  color: white;
}

.cert-table tr:hover {
  background: #f8f9fa;
}

@media (max-width: 600px) {
  .cert-table th, .cert-table td {
    padding: 10px;
    font-size: 0.9rem;
  }
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.5);
  backdrop-filter: blur(5px);
  align-items: center;
  justify-content: center;
}

.modal.show {
  display: flex;
}

.modal-content {
  background-color: var(--color-white);
  padding: 40px;
  border-radius: 20px;
  max-width: 400px;
  width: 90%;
  position: relative;
  text-align: center;
  box-shadow: 0 20px 40px rgba(0,0,0,0.2);
  animation: modalIn 0.3s ease-out;
}

@keyframes modalIn {
  from { transform: translateY(50px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.close-modal {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  color: #aaa;
  cursor: pointer;
  transition: var(--transition);
}

.close-modal:hover {
  color: var(--color-danger);
}

.clickable-card {
  cursor: pointer;
}
