/* Trazio Studio - Master Stylesheet (Premium Geometric B2B Identity) */

/* --- CARRUSEL INFINITO DE LOGOS (MARQUEE PREMIUM) --- */
.logos-marquee-container {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.logos-track {
  display: flex;
  width: max-content;
  animation: marquee-scroll 28s linear infinite; /* keyframe en animations.css */
}

.logos-item {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 2.5rem;
  color: var(--text-primary);
  opacity: 0.55;
  filter: grayscale(1);
  transition: opacity 0.3s ease, filter 0.3s ease, color 0.3s ease, transform 0.3s ease;
  cursor: default;
  white-space: nowrap;
}

.logos-item:hover {
  opacity: 1;
  filter: grayscale(0);
  color: var(--accent);
  transform: translateY(-2px) scale(1.05);
}

/* [EXTRAÍDO -> animations.css]: @keyframes marquee-scroll */

/* [EXTRAÍDO -> animations.css]: .logos-marquee-container:hover .logos-track (pause) */

/* Fades laterales adicionales (refuerzo visual sobre el mask) */
.logos-fade-left,
.logos-fade-right {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 60px;
  z-index: 2;
  pointer-events: none;
}

.logos-fade-left {
  left: 0;
  background: linear-gradient(to right, var(--bg-primary), transparent);
}

.logos-fade-right {
  right: 0;
  background: linear-gradient(to left, var(--bg-primary), transparent);
}

/* En móvil, animación un poco más rápida para dinamismo sin perder legibilidad */
@media (max-width: 768px) {
  .logos-track {
    animation-duration: 18s;
  }
  .logos-item {
    padding: 0 1.75rem;
  }
}

:root {
  --bg-primary: #111118;     /* Carbono Absoluto */
  --bg-secondary: #1E1E2A;   /* Azul Cenizo */
  --text-primary: #F5F4EF;   /* Blanco Cálido */
  --text-muted: #8B7355;     /* Marrón Tierra */
  --accent: #C9A96E;         /* Oro Mineral */
  --accent-rgb: 201, 169, 110;
  --accent-muted: #8B7355;
}

body.light-theme {
  --bg-primary: #F5F4EF;     /* Blanco Cálido */
  --bg-secondary: #FFFFFF;   /* Blanco Puro */
  --text-primary: #111118;   /* Carbono Absoluto */
  --text-muted: #8B7355;     /* Marrón Tierra */
  --accent: #8B7355;         /* Marrón Tierra */
  --accent-muted: #C9A96E;   /* Oro Mineral */
}

/* --- ESTILOS BASE --- */
body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  transition: background-color 0.4s ease, color 0.4s ease;
  font-family: 'Inter', sans-serif;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* --- CONTROL DE VISIBILIDAD DE LOGO (EVITA DUPLICADOS) --- */
body.light-theme .logo-gold {
  display: none !important;
}
body.light-theme .logo-dark {
  display: block !important;
  margin-left: auto;
  margin-right: auto;
}
body:not(.light-theme) .logo-gold {
  display: block !important;
  margin-left: auto;
  margin-right: auto;
}
body:not(.light-theme) .logo-dark {
  display: none !important;
}

/* --- CLASES DE UTILIDAD PERSONALIZADAS (TRAZIO SYSTEM) --- */
.bg-custom-main {
  background-color: var(--bg-primary);
}

.bg-custom-card {
  background-color: var(--bg-secondary);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.bg-custom-accent {
  background-color: var(--accent);
}

.bg-custom-accent-hover:hover {
  background-color: var(--accent-muted);
}

.text-custom-main {
  color: var(--text-primary);
}

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

.text-custom-muted {
  color: var(--text-muted);
}

.border-custom {
  border-color: rgba(139, 115, 85, 0.1);
}

/* --- ESTÉTICA GEOMÉTRICA (MÁXIMO 4PX RADIUS SEGÚN COREL) --- */
.rounded-lg, .rounded-xl, .rounded-2xl, button, select, input {
  border-radius: 8px !important;
}

/* --- PREMIUM SVG PATTERN 1: Diagonal Tech Blueprint --- */
.bg-pattern-diagonal {
  background-color: var(--bg-primary);
  background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 40L40 0H20L0 20M40 40V20L20 40' stroke='%23C9A96E' stroke-width='0.8' fill='none' stroke-opacity='0.12'/%3E%3C/svg%3E");
}

/* --- PREMIUM SVG PATTERN 2: Node Matrix / Crosses --- */
.bg-pattern-nodes {
  background-color: var(--bg-primary);
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M30 25v10m-5-5h10' stroke='%23C9A96E' stroke-width='1.2' fill='none' stroke-opacity='0.20'/%3E%3C/svg%3E");
}

/* --- SUBRAYADO EXPANSIVO PREMIUM PARA MENÚS --- */
.nav-link-premium {
  position: relative;
  transition: color 0.3s ease;
}

.nav-link-premium::after {
  content: '';
  position: absolute;
  width: 100%;
  transform: scaleX(0);
  height: 1.5px;
  bottom: -4px;
  left: 0;
  background-color: var(--accent);
  transform-origin: bottom right;
  transition: transform 0.25s ease-out;
}

.nav-link-premium:hover::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

/* --- INTERACTIVIDAD DEL ISOTIPO "T" EN CABECERA --- */
header a img {
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), filter 0.3s ease;
}

header a:hover img {
  transform: scale(1.1);
  filter: drop-shadow(0 0 8px rgba(201, 169, 110, 0.4));
}

header a:active img {
  transform: scale(0.95);
}

/* [EXTRAÍDO -> animations.css]: @keyframes fadeInUp */

/* [EXTRAÍDO -> animations.css]: .animate-fade-in-up */

/* [EXTRAÍDO -> animations.css]: @keyframes float */

/* [EXTRAÍDO -> animations.css]: .animate-float */

/* Custom Double Fine Gold Border Card (CorelDRAW Style) */
.border-double-gold {
  border: 1px solid rgba(201, 169, 110, 0.4);
  outline: 1px solid rgba(201, 169, 110, 0.2);
  outline-offset: 4px;
  border-radius: 8px !important;
}
.border-double-gold > div {
  border-radius: 6px !important; /* Slightly tighter radius for nested child container */
}

@media (max-width: 639px) {
  .ecosystem-scroll {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 1rem;
    padding-bottom: 0.5rem;
    margin: 0 -1.5rem;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
    scrollbar-width: none;
  }

  .ecosystem-scroll::-webkit-scrollbar {
    display: none;
  }

  .ecosystem-card {
    flex: 0 0 82%;
    scroll-snap-align: center;
  }

  .scroll-hint {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    z-index: 10;
    pointer-events: none;
    color: var(--accent);
    opacity: 0.6;
    transition: opacity 0.3s ease;
  }

  .scroll-hint-left {
    left: 0;
    background: linear-gradient(to right, var(--bg-primary) 30%, transparent 100%);
  }

  .scroll-hint-right {
    right: 0;
    background: linear-gradient(to left, var(--bg-primary) 30%, transparent 100%);
  }

  .scroll-hint svg {
    filter: drop-shadow(0 0 3px rgba(var(--accent-rgb), 0.3));
  }
}

@media (max-width: 767px) {
  .mockup-form-card.border-double-gold {
    outline-offset: 2px;
    margin: 2px;
  }

  /* --- ANIMACIÓN DE CONFIANZA (SÓLO MÓVIL) --- */
  .trust-marquee-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    display: flex;
    justify-content: center;
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    scrollbar-width: none;
  }

  .trust-marquee-container::-webkit-scrollbar {
    display: none;
  }

  .trust-marquee-track {
    display: flex;
    width: max-content;
    animation: trust-slide-mobile 10s linear infinite; /* keyframe en animations.css */
    gap: 1.5rem !important;
  }

  .trust-marquee-item {
    flex-shrink: 0;
    scroll-snap-align: center;
  }

  /* [EXTRAÍDO -> animations.css]: pause rule .trust-marquee-container:hover/:active */
}

/* [EXTRAÍDO -> animations.css]: @keyframes trust-slide-mobile */

/* --- ECOSYSTEM MARQUEE (SÓLO MÓVIL) --- */
@media (max-width: 639px) {
  .ecosystem-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    display: flex;
    justify-content: center;
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    scrollbar-width: none;
  }
  .ecosystem-scroll::-webkit-scrollbar {
    display: none;
  }
  .ecosystem-track {
    display: flex;
    width: max-content;
    animation: ecosystem-slide 15s linear infinite; /* keyframe en animations.css */
    gap: 1rem;
  }
  .ecosystem-card {
    flex: 0 0 82%;
    scroll-snap-align: center;
  }
  /* [EXTRAÍDO -> animations.css]: pause rule .ecosystem-scroll:hover/:active */
}

/* [EXTRAÍDO -> animations.css]: @keyframes ecosystem-slide */

/* Custom Double Fine Gold Border Card (CorelDRAW Style) */
.border-double-gold {
  border: 1px solid rgba(201, 169, 110, 0.4);
  outline: 1px solid rgba(201, 169, 110, 0.2);
  outline-offset: 4px;
  border-radius: 8px !important;
}
.border-double-gold > div {
  border-radius: 6px !important; /* Slightly tighter radius for nested child container */
}

@media (max-width: 767px) {
  .mockup-form-card.border-double-gold {
    outline-offset: 2px;
    margin: 2px;
  }

  /* --- ANIMACIÓN DE CONFIANZA (SÓLO MÓVIL) --- */
  .trust-marquee-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    display: flex;
    justify-content: center;
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    scrollbar-width: none;
  }

  .trust-marquee-container::-webkit-scrollbar {
    display: none;
  }

  .trust-marquee-track {
    display: flex;
    width: max-content;
    animation: trust-slide-mobile 10s linear infinite; /* keyframe en animations.css */
    gap: 1.5rem !important;
  }

  .trust-marquee-item {
    flex-shrink: 0;
    scroll-snap-align: center;
  }
}

/* ============================================
   PORTFOLIO COVERFLOW 3D — Solo mobile
   ============================================ */

/* ============================================
   PORTFOLIO COVERFLOW 3D — Solo mobile
   ============================================ */

.pf-coverflow {
  display: flex;
  gap: 1rem;
  padding: 3rem 20vw;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  perspective: 1200px;
  scrollbar-width: none;
}
.pf-coverflow::-webkit-scrollbar { display: none; }

.pf-card {
  flex: 0 0 68vw;
  max-width: 320px;
  height: 420px;
  scroll-snap-align: center;
  transform-style: preserve-3d;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), filter 0.4s ease, opacity 0.4s ease;
  transform: scale(0.82) rotateY(18deg);
  opacity: 0.55;
  filter: blur(1.5px) brightness(0.7);
}

.pf-card-inner {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid var(--custom-border, rgba(255,255,255,0.1));
  box-shadow: 0 20px 40px -10px rgba(0,0,0,0.5);
}
.pf-card-inner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Tarjeta activa: se detecta por scroll-driven animation (fallback: todas iguales si no soportado) */
@supports (animation-timeline: view()) {
  .pf-card {
    animation: pf-focus linear both; /* keyframe en animations.css */
    animation-timeline: view(x);
    animation-range: entry 25% cover 50% exit 75%;
  }

  /* [EXTRAÍDO -> animations.css]: @keyframes pf-focus */
}

/* Fallback sin scroll-timeline: efecto estático más simple pero elegante */
@supports not (animation-timeline: view()) {
  .pf-card {
    scroll-snap-align: center;
  }
  .pf-card:nth-child(1) { transform: scale(0.95) rotateY(0deg); opacity: 0.9; filter: none; }
}

/* Hint de swipe — aparece al entrar en viewport, invita a interactuar */
.pf-swipe-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: var(--custom-accent, #d4af37);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  animation: pf-hint-pulse 1.8s ease-in-out infinite; /* keyframe en animations.css */
}

/* [EXTRAÍDO -> animations.css]: @keyframes pf-hint-pulse */

/* Dots indicadores (decorativos, sin JS de sincronía real) */
.pf-dots {
  display: flex;
  justify-content: center;
  gap: 0.4rem;
  margin-top: 0.5rem;
}
.pf-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--custom-muted, rgba(255,255,255,0.25));
  transition: background 0.3s ease;
}

/* [EXTRAÍDO -> animations.css]: @media (prefers-reduced-motion: reduce) */

/* --- INDICADOR DE SWIPE (ICONO ANIMADO) --- */
@media (min-width: 640px) {
  [data-i18n="infra-swipe-hint"],
  [data-i18n="infra-swipe-hint"] + svg {
    display: none;
  }
}

/* --- TRAMAS DE FONDO PARA SECCIONES (BAJO CONTRASTE) --- */
.bg-mesh-dots {
  background-image: radial-gradient(circle, #C9A96E 1px, transparent 1px);
  background-size: 20px 20px;
  background-color: transparent;
  opacity: 0.04;
}

.bg-mesh-lines {
  background-image: linear-gradient(45deg, #C9A96E 25%, transparent 25%, transparent 75%, #C9A96E 75%, #C9A96E),
                    linear-gradient(45deg, #C9A96E 25%, transparent 25%, transparent 75%, #C9A96E 75%, #C9A96E);
  background-size: 20px 20px;
  background-position: 0 0, 10px 10px;
  background-color: transparent;
  opacity: 0.04;
}

@media print {
  header, footer, nav, .hide-on-print, .no-print, button, .animate-fade-in-up {
    display: none !important;
  }

  body {
    background-color: #ffffff !important;
    color: #000000 !important;
    margin: 0;
    padding: 0;
    box-shadow: none !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  @page {
    size: A4;
    margin: 1cm;
  }

  * {
    box-shadow: none !important;
    text-shadow: none !important;
    -webkit-box-shadow: none !important;
    -moz-box-shadow: none !important;
  }

  .text-custom-main, .text-custom-muted, h1, h2, h3, h4, h5, h6, p, span, div {
    color: #000000 !important;
  }

  a {
    color: #000000 !important;
    text-decoration: none !important;
  }
}