/* ==============================================
   CSR-Online | components.css
   Estilos de componentes extraídos del HTML.
   No editar estilos de layout aquí — usar main2-2.css
================================================ */

/* ===========================
   Accesibilidad: Skip Link
=========================== */
.skip-to-content {
  position: absolute;
  top: -48px;
  left: 16px;
  background: #ec733b;
  color: #fff;
  padding: 10px 18px;
  border-radius: 0 0 8px 8px;
  z-index: 100000;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: top 0.2s ease;
}
.skip-to-content:focus {
  top: 0;
}

/* ===========================
   Header: Colores Corporativos
=========================== */
header .nav-item a,
header .nav-item span,
header .nav-item-link-border {
  color: #ec733b;
  transition: color 0.3s ease;
}

header .nav-item a:hover,
header .nav-item-link-border:hover {
  color: #4f4f4f;
}

.dropdown-menu a {
  color: #ec733b;
}

.dropdown-menu a:hover {
  color: #4f4f4f;
}

/* ===========================
   Botón Flotante WhatsApp
=========================== */
.whatsapp-float {
  position: fixed;
  width: 60px;
  height: 60px;
  bottom: 25px;
  left: 25px;
  background-color: #25D366;
  color: #fff;
  border-radius: 50%;
  text-align: center;
  box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease-in-out, background-color 0.3s;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  background-color: #20b358;
}

.whatsapp-icon {
  width: 35px;
  height: 35px;
  filter: invert(1);
}

/* ===========================
   Sección Soporte: Botones
=========================== */
.botones-soporte {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 30px;
}

@media (min-width: 1280px) {
  .botones-soporte {
    justify-content: flex-start;
  }
}

.btn-blanco {
  background-color: #ffffff;
  color: #000000;
  border: 2px solid #000000;
  border-radius: 8px;
  padding: 10px 20px;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  display: inline-block;
  transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

.btn-blanco:hover {
  background-color: #000000;
  color: #ffffff;
  transform: translateY(-2px);
}

/* ===========================
   Banner de Cookies
=========================== */
.cookie-banner {
  position: fixed;
  inset: auto 0 0 0;
  background: #ffffff;
  border-top: 1px solid #e5e7eb;
  box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.08);
  padding: 12px 16px;
  z-index: 99999;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Inter, Arial, sans-serif;
}

.cookie-content {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
}

.cookie-text {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
  color: #111827;
}

.cookie-text a {
  text-decoration: underline;
  color: #0d6efd;
}

.cookie-actions {
  display: flex;
  gap: 8px;
}

.btn-cookie {
  cursor: pointer;
  border-radius: 8px;
  padding: 8px 16px;
  border: 1px solid transparent;
  font-size: 14px;
  font-family: inherit;
  transition: background-color 0.2s ease, transform 0.1s ease;
}

.btn-cookie-primary {
  background: #4f4f4f;
  color: #fff;
}

.btn-cookie-primary:hover {
  background: #333;
}

.btn-cookie-primary:active {
  transform: translateY(1px);
}

.btn-cookie-secondary {
  background: #f3f4f6;
  color: #111827;
  border-color: #e5e7eb;
}

.btn-cookie-secondary:hover {
  background: #e5e7eb;
}

@media (max-width: 640px) {
  .cookie-content {
    grid-template-columns: 1fr;
  }
  .cookie-actions {
    justify-content: flex-end;
  }
}

/* ===========================
   SEO Scroll Banner (footer)
=========================== */
.seo-scroll-container {
  width: 100%;
  overflow: hidden;
  background: #f8f9fa;
  border-top: 1px solid #e0e0e0;
  padding: 6px 0;
}

.seo-scroll-track {
  white-space: nowrap;
  animation: seo-scroll 140s linear infinite;
  color: #ec733b;
  font-size: 0.65rem;
  line-height: 1.3;
}

@keyframes seo-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-220%); }
}

/* ===========================
   Página 404 Personalizada
=========================== */
.error-404-section {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 20px 60px;
  text-align: center;
}

.error-404-inner {
  max-width: 600px;
}

.error-404-code {
  font-size: clamp(6rem, 20vw, 10rem);
  font-weight: 900;
  color: #ec733b;
  line-height: 1;
  margin: 0 0 0.25rem;
  letter-spacing: -4px;
}

.error-404-title {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 1rem;
}

.error-404-text {
  color: #666;
  font-size: 1rem;
  line-height: 1.6;
  margin: 0 auto 2rem;
}

.error-404-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===========================
   Utilidad: Focus visible accesible
=========================== */
:focus-visible {
  outline: 3px solid #ec733b;
  outline-offset: 3px;
}

/* ===========================
   Contacto: tarjetas blancas sobre fondo oscuro
   Reemplaza los style="color:white" inline.
=========================== */
.contact-card-text,
.contact-card-text a {
  color: #fff;
}

.required-asterisk {
  color: #dc2626;
}

/* ===========================
   Footer: ancho 0 inicial del divisor (lo anima JS / GSAP)
=========================== */
.footer-divider-init {
  width: 0;
}

/* ===========================
   Badges: mejora de legibilidad global
   Aplica a todos los .badge (cyan, primary, etc.) sin tocar layout.
=========================== */
.badge {
  font-size: 0.9375rem;          /* ~15px, antes ~14px */
  font-weight: 500;              /* medium en vez de normal */
  letter-spacing: 0.01em;
  padding-block: 0.5rem;
  padding-inline: 1.125rem;
  border: 1px solid rgba(236, 115, 59, 0.25);
  color: #1a1a1c;
}

.badge-cyan,
.badge-cyan-v2 {
  background-color: #ffe2d1;     /* tono cálido coherente con la marca */
}

/* ===========================
   Hero: subtítulo y badge sobre fondo decorativo
=========================== */
.hero p {
  font-weight: 500;
  color: #2a2a2c;
  position: relative;
  z-index: 2;
}

.hero .badge {
  position: relative;
  z-index: 2;
}

.hero figure[aria-hidden="true"] {
  opacity: 0.85;
}

/* ===========================
   Botón de play del vídeo hero (circular)
=========================== */
#playButton {
  background: transparent !important;
  color: transparent;
  font-size: 0;
}

#playButton::before {
  content: "";
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.28);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ec733b'><path d='M8 5v14l11-7z'/></svg>");
  background-repeat: no-repeat;
  background-position: 54% center;
  background-size: 38px 38px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

#playButton:hover::before,
#playButton:focus-visible::before {
  transform: scale(1.08);
  background-color: #ec733b;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffffff'><path d='M8 5v14l11-7z'/></svg>");
  box-shadow: 0 12px 32px rgba(236, 115, 59, 0.45);
}

@media (max-width: 768px) {
  #playButton::before {
    width: 72px;
    height: 72px;
    background-size: 30px 30px;
  }
}

/* ===========================
   Footer: logo CSR-Online
=========================== */
.footer-logo {
  display: block;
  text-align: center;
  margin-bottom: 24px;
}

.footer-logo img {
  display: inline-block;
  height: auto;
  max-height: 56px;
  width: auto;
}

@media (min-width: 1024px) {
  .footer-logo {
    text-align: left;
  }
}

/* ===========================
   Menú móvil — botón hamburguesa
=========================== */
.mobile-menu-toggle {
  position: relative;
  width: 44px;
  height: 44px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: 1px solid rgba(236, 115, 59, 0.3);
  border-radius: 10px;
  cursor: pointer;
  padding: 0;
  transition: border-color 0.2s ease, background-color 0.2s ease;
  display: inline-flex;
}

@media (min-width: 1280px) {
  .mobile-menu-toggle,
  .mobile-menu,
  .mobile-menu-backdrop {
    display: none !important;
  }
}

.mobile-menu-toggle:hover {
  border-color: #ec733b;
  background-color: rgba(236, 115, 59, 0.06);
}

.mobile-menu-toggle-bar {
  display: block;
  width: 22px;
  height: 2px;
  background-color: #ec733b;
  border-radius: 2px;
  transform-origin: center;
  transition: transform 0.3s ease, opacity 0.2s ease;
}

.mobile-menu-toggle.is-open .mobile-menu-toggle-bar:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.mobile-menu-toggle.is-open .mobile-menu-toggle-bar:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.is-open .mobile-menu-toggle-bar:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* ===========================
   Menú móvil — panel
=========================== */
.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: min(86vw, 380px);
  height: 100dvh;
  background-color: #ffffff;
  box-shadow: -8px 0 32px rgba(0, 0, 0, 0.12);
  z-index: 9999;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
  padding: 100px 28px 32px;
  visibility: hidden;
}

.mobile-menu.is-open {
  transform: translateX(0);
  visibility: visible;
}

.mobile-menu-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.4);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}

.mobile-menu-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.mobile-menu-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 14px 16px;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 500;
  color: #1a1a1c;
  text-decoration: none;
  background: transparent;
  border: none;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
  font-family: inherit;
}

.mobile-menu-link:hover,
.mobile-menu-link:focus-visible {
  background-color: #fff3ec;
  color: #ec733b;
}

.mobile-menu-link[aria-current="page"] {
  color: #ec733b;
  background-color: #fff3ec;
}

.mobile-menu-link-cta {
  margin-top: 12px;
  background-color: #ec733b;
  color: #ffffff;
  justify-content: center;
}

.mobile-menu-link-cta:hover,
.mobile-menu-link-cta:focus-visible {
  background-color: #d8632f;
  color: #ffffff;
}

.mobile-menu-chevron {
  transition: transform 0.25s ease;
}

.mobile-menu-accordion-trigger[aria-expanded="true"] .mobile-menu-chevron {
  transform: rotate(180deg);
}

.mobile-menu-sublist {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

.mobile-menu-sublist.is-open {
  max-height: 600px;
}

.mobile-menu-sublink {
  display: block;
  padding: 11px 16px 11px 32px;
  font-size: 0.9375rem;
  color: #4f4f4f;
  text-decoration: none;
  border-radius: 8px;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.mobile-menu-sublink:hover,
.mobile-menu-sublink:focus-visible {
  background-color: #fff3ec;
  color: #ec733b;
}
