@import url('./variables.css');
@import url('./carousel.css');

/* Reset Básico */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: var(--font-main); color: var(--color-text); background-color: var(--color-bg); line-height: 1.6; }
a { text-decoration: none; color: inherit; }

/* Utilidades */
.container { max-width: var(--container-width); margin: 0 auto; padding: 0 var(--spacing-sm); }
.section { padding: var(--spacing-lg) 0; }
.btn { display: inline-block; padding: 0.75rem 1.5rem; border-radius: var(--radius); font-weight: 600; cursor: pointer; transition: opacity 0.3s; }
.btn-primary { background-color: var(--color-accent); color: var(--color-white); border: none; }
.btn-primary:hover { opacity: 0.9; }

/* Grid Layouts Generales */
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--spacing-md); }

/* --- Estilos de Componentes Específicos --- */

/* Hero */
.hero { background-color: var(--color-primary); color: var(--color-white); padding: 6rem 0; text-align: center; }
.hero h1 { font-size: 3.5rem; margin-bottom: var(--spacing-sm); letter-spacing: -1px; }
.hero p { font-size: 1.25rem; color: #94a3b8; max-width: 600px; margin: 0 auto var(--spacing-md); }

/* Services Card */
/* ===== Services (FRADA) – Pro Carousel (CSS puro) ===== */
.services{
  background: var(--color-bg);
  color: var(--color-text);
}

.services-header{
  text-align: center;
  margin-bottom: 1.25rem;
}

.services-header h2{
  margin: 0 0 .75rem 0;
  color: var(--color-primary);
}

.services-lead{
  margin: 0 auto;
  max-width: 980px;
  line-height: 1.7;
  color: var(--color-text);
  opacity: .92;
}

/* Contenedor del carrusel (para fades laterales) */
.services-stage{
  position: relative;
  margin-top: 1.25rem;
}

/* Fades laterales */
.services-fade{
  position: absolute;
  top: 0;
  bottom: 0;
  width: 70px;
  pointer-events: none;
  z-index: 2;
}

.services-fade-left{
  left: 0;
  background: linear-gradient(to right, var(--color-bg), rgba(248,250,252,0));
}

.services-fade-right{
  right: 0;
  background: linear-gradient(to left, var(--color-bg), rgba(248,250,252,0));
}

/* Carrusel */
.services-carousel{
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: .5rem .25rem 1rem;
  -webkit-overflow-scrolling: touch;

  /* “espacio” para que se note el fade */
  padding-left: 10px;
  padding-right: 10px;

  /* esconder scrollbar sin romper scroll */
  scrollbar-width: none;
}
.services-carousel::-webkit-scrollbar{ display: none; }

/* Tarjeta */
.service-card{
  scroll-snap-align: center;
  flex: 0 0 min(560px, 86vw);
  background: var(--color-white);
  border: 1px solid rgba(15,23,42,0.08);
  border-radius: calc(var(--radius) + 8px);
  box-shadow: 0 14px 30px rgba(15,23,42,0.08);
  padding: 1.35rem 1.35rem 1.1rem;
  position: relative;

  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, opacity .18s ease;
  outline: none;

  /* “no centrada” un poco más suave */
  opacity: .88;
}

/* Hover elevación */
.service-card:hover{
  transform: translateY(-4px);
  box-shadow: 0 18px 44px rgba(15,23,42,0.14);
  border-color: rgba(59,130,246,0.25);
  opacity: 1;
}

/* Efecto enfoque: si se navega con teclado o se hace click (focus) */
.service-card:focus,
.service-card:focus-within{
  transform: translateY(-4px);
  box-shadow: 0 20px 52px rgba(15,23,42,0.16);
  border-color: rgba(59,130,246,0.35);
  opacity: 1;
}

/* “Tarjeta centrada más grande” (sin JS) usando :target */
.service-card:target{
  transform: scale(1.03);
  box-shadow: 0 24px 62px rgba(15,23,42,0.18);
  border-color: rgba(59,130,246,0.45);
  opacity: 1;
}

/* Detalle pro: borde superior sutil */
.service-card::before{
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  top: 12px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(59,130,246,0.0), rgba(59,130,246,0.6), rgba(59,130,246,0.0));
  opacity: .55;
}

/* Ajuste para que el :target no tape con header fijo */
.service-card{ scroll-margin-top: 90px; }

.service-top{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  margin-bottom: .8rem;
}

.service-chip{
  font-weight: 800;
  font-size: .92rem;
  letter-spacing: .10em;
  color: rgba(51,65,85,0.85);
}

.service-icon{
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(59,130,246,0.10);
  border: 1px solid rgba(59,130,246,0.18);
  font-size: 20px;
}

.service-card h3{
  margin: 0 0 .55rem 0;
  color: var(--color-primary);
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.service-card p{
  margin: 0 0 .9rem 0;
  line-height: 1.7;
  color: var(--color-text);
  opacity: .92;
}

.service-card h4{
  margin: .85rem 0 .5rem 0;
  font-size: .95rem;
  color: var(--color-primary);
}

.service-card ul{
  margin: 0;
  padding-left: 1.1rem;
  line-height: 1.7;
  color: var(--color-text);
}
.service-card li{ margin: .35rem 0; }

/* Flechas */
.service-nav{
  display: flex;
  gap: .65rem;
  justify-content: flex-end;
  margin-top: 1.05rem;
}

.nav-btn{
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  text-decoration: none;
  border: 1px solid rgba(59,130,246,0.22);
  background: var(--color-accent);
  color: var(--color-white);
  font-weight: 900;
  transition: transform .15s ease, filter .15s ease, background .15s ease, border-color .15s ease;
}

.nav-btn:hover{
  transform: translateY(-1px);
  filter: brightness(0.98);
  border-color: rgba(59,130,246,0.35);
}

.nav-btn.ghost{
  background: rgba(15,23,42,0.04);
  border-color: rgba(15,23,42,0.10);
  color: var(--color-primary);
}

.nav-btn.ghost:hover{
  background: rgba(15,23,42,0.06);
}

/* Dots nav */
.services-dots{
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: .85rem;
}

.services-dots a{
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(15,23,42,0.18);
  border: 1px solid rgba(15,23,42,0.08);
  display: inline-block;
  transition: transform .15s ease, background .15s ease;
}

.services-dots a:hover{
  transform: scale(1.15);
  background: rgba(59,130,246,0.55);
}

/* Resalta dot cuando hay :target (sin JS) */
#svc-1:target ~ .services-dots a[href="#svc-1"],
#svc-2:target ~ .services-dots a[href="#svc-2"],
#svc-3:target ~ .services-dots a[href="#svc-3"],
#svc-4:target ~ .services-dots a[href="#svc-4"],
#svc-5:target ~ .services-dots a[href="#svc-5"]{
  background: rgba(59,130,246,0.85);
  transform: scale(1.25);
}

/* Responsive */
@media (max-width: 520px){
  .services-fade{ width: 44px; }
  .service-card{ padding: 1.2rem 1.1rem 1rem; }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce){
  .services-carousel{ scroll-behavior: auto; }
  .service-card, .nav-btn, .services-dots a{ transition: none; }
}


/* Process */
/* ===== FRADA | Metodología "process" ===== */
.frada-section{
  padding: clamp(56px, 6vw, 96px) 0;
  background: #0b1220; /* puedes cambiarlo */
  color: #eaf0ff;
}

.frada-container{
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}

.frada-header{
  text-align: left;
  max-width: 720px;
  margin-bottom: 28px;
}

.frada-title{
  font-size: clamp(28px, 3.2vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 10px 0;
}

.frada-subtitle{
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.6;
  color: rgba(234,240,255,0.78);
}

/* Grid responsive */
.frada-grid{
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 18px;
  margin-top: 22px;
}

/* Card: 2 columnas en desktop, 1 en mobile */
.frada-card{
  grid-column: span 6;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 18px;
  padding: 22px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.25);
  backdrop-filter: blur(8px);
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.frada-card:hover{
  transform: translateY(-3px);
  border-color: rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.075);
}

.frada-cardTop{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.frada-step{
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  color: rgba(234,240,255,0.70);
}

.frada-icon{
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.10);
  font-size: 20px;
}

.frada-cardTitle{
  margin: 0 0 8px 0;
  font-size: 1.15rem;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.frada-microcopy{
  margin: 0 0 14px 0;
  color: rgba(234,240,255,0.78);
  line-height: 1.55;
}

.frada-list{
  margin: 0;
  padding-left: 18px;
  color: rgba(234,240,255,0.82);
  line-height: 1.6;
}

.frada-list li{
  margin: 8px 0;
}

/* CTA */
.frada-ctaRow{
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.frada-btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.14);
  text-decoration: none;
  color: #eaf0ff;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
  min-height: 44px;
}

.frada-btn:hover{
  transform: translateY(-1px);
  border-color: rgba(255,255,255,0.22);
}

.frada-btnPrimary{
  background: #3b82f6; /* primario */
  border-color: rgba(59,130,246,0.55);
}

.frada-btnPrimary:hover{
  background: #2f74e3;
}

.frada-btnGhost{
  background: rgba(255,255,255,0.06);
}

.frada-btnGhost:hover{
  background: rgba(255,255,255,0.09);
}

/* Responsive */
@media (max-width: 900px){
  .frada-card{ grid-column: span 12; }
  .frada-header{ margin-bottom: 18px; }
}

@media (prefers-reduced-motion: reduce){
  .frada-card, .frada-btn{ transition: none; }
  .frada-card:hover, .frada-btn:hover{ transform: none; }
}


/* Contact Form */
.form-group { margin-bottom: var(--spacing-sm); }
.form-input { width: 100%; padding: 0.8rem; border: 1px solid #cbd5e1; border-radius: var(--radius); font-family: inherit; }
.form-input:focus { outline: 2px solid var(--color-accent); border-color: transparent; }

/* Responsive */
@media (max-width: 768px) {
    .hero h1 { font-size: 2.5rem; }
}

/* --- 1. NAVBAR & HAMBURGER --- */
.navbar {
    background-color: var(--color-primary);
    border-bottom: 1px solid rgba(255,255,255,0.1);
    position: sticky; /* Sticky header para producción */
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
}

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

.logo {
    color: var(--color-white);
    font-weight: bold;
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    color: #cbd5e1;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-link:hover { color: var(--color-white); }

/* Estilos del botón Hamburguesa (oculto en desktop) */
.hamburger {
    display: none;
    cursor: pointer;
    background: none;
    border: none;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: white;
    transition: all 0.3s ease-in-out;
}

/* --- 2. ESTILOS MISION/VISION (ABOUT) --- */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* 2 Columnas iguales */
    gap: 4rem;
    align-items: center;
}

.overline {
    text-transform: uppercase;
    color: var(--color-accent);
    font-size: 0.875rem;
    font-weight: bold;
    letter-spacing: 1px;
}

.mission-box {
    margin-top: 2rem;
    padding-left: 1.5rem;
    border-left: 4px solid var(--color-accent);
}

.vision-card {
    background: var(--color-primary);
    color: white;
    padding: 3rem;
    border-radius: var(--radius);
    position: relative;
    overflow: hidden;
}

.vision-decoration {
    position: absolute;
    top: -50px;
    right: -50px;
    width: 150px;
    height: 150px;
    background: var(--color-accent);
    opacity: 0.2;
    border-radius: 50%;
}

/* --- 3. RESPONSIVE (MÓVIL) --- */
@media (max-width: 768px) {
    /* Navbar Móvil */
    .hamburger { display: block; }

    .nav-menu {
        position: fixed;
        left: -100%; /* Oculto a la izquierda */
        top: 70px; /* Debajo del navbar */
        gap: 0;
        flex-direction: column;
        background-color: var(--color-primary);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 10px rgba(0,0,0,0.1);
        padding-bottom: 2rem;
    }

    .nav-menu.active {
        left: 0; /* Mostrar menú */
    }

    .nav-item { margin: 1.5rem 0; }

    /* Animación del icono hamburguesa al abrir */
    .hamburger.active .bar:nth-child(2) { opacity: 0; }
    .hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

    /* Stackear Grid en móvil */
    .about-grid { grid-template-columns: 1fr; gap: 2rem; }
    .hero h1 { font-size: 2.5rem; }
}
