/* -----------------------------------------------------------
   Itranser — Landing Page
   Autor: Jaime (Itranser) + Asistencia IA
   Tecnologías: HTML5 + CSS3 (sin frameworks, sin JS)
   Tipografía: Google Fonts (Inter + Sora)
   ----------------------------------------------------------- */

/* Import de fuentes desde Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&family=Sora:wght@500;700&display=swap');

/* -----------------------------------------------------------
   Variables de diseño
   ----------------------------------------------------------- */
:root{
  --bg: #0a2540;           /* Azul oscuro base */
  --bg-2: #0f3155;         /* Azul intermedio */
  --text: #e6eef6;         /* Texto claro */
  --muted: #b8c7d6;        /* Texto secundario */
  --card: #0f2b48;         /* Fondo tarjetas */
  --border: #1b3f66;       /* Bordes suaves */
  --accent: #17bebb;       /* Verde azulado (acento) */
  --accent-2: #ff7a59;     /* Naranja alternativo */
  --white: #ffffff;
  --shadow: 0 10px 30px rgba(0,0,0,.25);
  --radius: 16px;
  --radius-lg: 24px;
  --container: 1100px;
  --header-h: 64px;
}

/* -----------------------------------------------------------
   Reset + Base
   ----------------------------------------------------------- */
*,
*::before,
*::after{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

body{
  margin: 0;
  color: var(--text);
  background: linear-gradient(180deg, var(--bg) 0%, #071a2d 100%);
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

/* Accesibilidad: esconder solo visualmente */
.sr-only{
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

.container{
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 24px;
}

/* -----------------------------------------------------------
   Header fijo + navegación (hamburguesa sin JS)
   ----------------------------------------------------------- */
.site-header{
  position: sticky; top: 0; z-index: 1000;
  height: var(--header-h);
  background: rgba(10,37,64,.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.nav-wrap{
  height: 100%;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
}

.brand{
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--white); text-decoration: none;
}

.brand-mark{
  width: 36px; height: 36px; display: grid; place-items: center;
  border-radius: 12px;
  font-weight: 700; letter-spacing: .5px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  color: #062038;
}

.brand-name{
  font-family: 'Sora', sans-serif;
  font-weight: 700; font-size: 1.1rem; letter-spacing: .3px;
}

/* Toggle */
.nav-toggle{ display: none; }
.nav-toggle-label{
  display: none;
  width: 40px; height: 40px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.08);
  cursor: pointer;
  align-items: center; justify-content: center;
}
.nav-toggle-label span,
.nav-toggle-label span::before,
.nav-toggle-label span::after{
  content: ""; display: block; height: 2px; width: 20px;
  background: var(--white); border-radius: 2px;
  transition: .3s ease;
}
.nav-toggle-label span::before{ transform: translateY(-6px); }
.nav-toggle-label span::after{ transform: translateY(6px); }

.site-nav ul{
  list-style: none; margin: 0; padding: 0;
  display: flex; gap: 24px;
}
.site-nav a{
  color: var(--text); text-decoration: none;
  padding: 8px 10px; border-radius: 8px;
  border: 1px solid transparent;
  transition: background .2s ease, border-color .2s ease;
}
.site-nav a:hover{
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.08);
}

/* Responsive nav */
@media (max-width: 860px){
  .nav-toggle-label{ display: inline-flex; }
  .site-nav{
    position: fixed; inset: var(--header-h) 0 auto 0;
    background: rgba(7,26,45,.98);
    transform: translateY(-110%);
    transition: transform .3s ease;
    border-bottom: 1px solid rgba(255,255,255,.06);
  }
  .site-nav ul{
    padding: 16px 24px 24px;
    flex-direction: column; gap: 8px;
  }
  .site-nav a{ display: block; padding: 12px 10px; }

  /* Abre el menú cuando el checkbox está activo */
  .nav-toggle:checked ~ .site-nav{
    transform: translateY(0);
  }
  /* Cambia icono a "X" */
  .nav-toggle:checked + .nav-toggle-label span{
    transform: rotate(45deg);
  }
  .nav-toggle:checked + .nav-toggle-label span::before{
    transform: rotate(90deg) translateX(-0px);
  }
  .nav-toggle:checked + .nav-toggle-label span::after{
    opacity: 0;
  }
}

/* -----------------------------------------------------------
   HERO
   ----------------------------------------------------------- */
.hero{
  padding-top: clamp(48px, 4vw, 64px); /* despeje bajo header pegajoso */
  padding-bottom: 56px;
}

.hero-inner{
  display: grid;
  gap: 40px;
  align-items: center;
}

@media (min-width: 900px){
  .hero-inner{
    grid-template-columns: 1.1fr .9fr;
    min-height: calc(100vh - var(--header-h) - 80px);
  }
}

.overline{
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
  margin: 0 0 6px 0;
}

.hero-title{
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  line-height: 1.2;
  margin: 0 0 12px 0;
}

.hero-subtitle{
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.125rem);
  margin: 0 0 22px 0;
  max-width: 48ch;
}

.hero-cta{ display: flex; gap: 14px; flex-wrap: wrap; }

.btn{
  --btn-bg: rgba(255,255,255,.06);
  --btn-br: rgba(255,255,255,.10);
  display: inline-flex; align-items: center; justify-content: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: 12px;
  color: var(--white);
  text-decoration: none;
  font-weight: 600;
  border: 1px solid var(--btn-br);
  background: var(--btn-bg);
  transition: transform .08s ease, box-shadow .2s ease, background .2s ease;
  will-change: transform;
}
.btn:hover{ box-shadow: var(--shadow); transform: translateY(-1px); }
.btn:active{ transform: translateY(0); }

.btn-primary{
  --btn-bg: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  --btn-br: transparent;
  color: #072234;
}
.btn-ghost{
  --btn-bg: rgba(255,255,255,.02);
  --btn-br: rgba(255,255,255,.12);
}
.btn-secondary{
  --btn-bg: rgba(23,190,187,.12);
  --btn-br: rgba(23,190,187,.35);
}

/* Mockup “móvil” del hero */
.hero-visual{ margin: 0; }
.device-mockup{
  width: min(380px, 92%);
  margin-inline: auto;
  aspect-ratio: 9 / 19.5;
  background: linear-gradient(180deg, #0f3155 0%, #0c2846 100%);
  border-radius: 36px;
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 20px 60px rgba(0,0,0,.35), inset 0 0 0 12px #061a2f;
  position: relative;
  overflow: hidden;
}
.device-notch{
  position: absolute; top: 10px; left: 50%; transform: translateX(-50%);
  width: 40%; height: 22px; background: #061a2f; border-radius: 0 0 16px 16px;
}
.device-screen{
  position: absolute; inset: 48px 14px 14px 14px;
  display: grid; gap: 10px;
}
.screen-card{
  background: linear-gradient(135deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 16px;
  padding: 12px;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center;
  gap: 10px;
}
.screen-card .dot{
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent);
}
.screen-card .line{
  height: 8px; border-radius: 5px; background: rgba(255,255,255,.18);
}
.screen-card .line.w40{ width: 40%; }
.screen-card .line.w45{ width: 45%; }
.screen-card .line.w55{ width: 55%; }
.screen-card .line.w60{ width: 60%; }
.screen-card .line.w70{ width: 70%; }
.screen-card .line.w80{ width: 80%; }
.screen-card .pill{
  width: 48px; height: 22px; border-radius: 999px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  opacity: .9;
}

/* -----------------------------------------------------------
   Sections
   ----------------------------------------------------------- */
.section{
  padding: 72px 0;
  border-top: 1px solid rgba(255,255,255,.06);
}

.section-header{
  text-align: center;
  margin-bottom: 28px;
}
.section-header h2{
  font-family: 'Sora', sans-serif;
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  margin: 0 0 8px 0;
}
.section-lead{
  color: var(--muted);
  max-width: 60ch;
  margin: 0 auto;
}

/* Servicio principal */
.service-card{
  background: linear-gradient(180deg, var(--card), rgba(15,43,72,.6));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-top: 28px;
  box-shadow: 0 10px 30px rgba(0,0,0,.2);
}
.service-card__head{
  display: flex; gap: 14px; align-items: center; margin-bottom: 12px;
}
.service-icon{
  width: 36px; height: 36px; fill: var(--accent);
}
.service-card h3{
  margin: 0; font-size: 1.25rem; font-weight: 700; font-family: 'Sora', sans-serif;
}
.service-desc{ color: var(--text); margin: 8px 0 18px; }

.benefits{
  display: grid; gap: 14px;
}
@media (min-width: 720px){
  .benefits{ grid-template-columns: repeat(3, 1fr); }
}
.benefit{
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--radius);
  padding: 16px;
}
.benefit-icon{
  width: 24px; height: 24px; fill: var(--accent);
}
.benefit h4{
  margin: 8px 0 6px;
  font-size: 1.05rem; font-weight: 700;
}
.benefit p{ margin: 0; color: var(--muted); }

/* -----------------------------------------------------------
   Proyectos
   ----------------------------------------------------------- */
.projects-grid{
  display: grid; gap: 20px; margin-top: 28px;
}
@media (min-width: 780px){
  .projects-grid{ grid-template-columns: repeat(2, 1fr); }
}

.card{
  background: linear-gradient(180deg, var(--card), rgba(15,43,72,.6));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: grid;
  box-shadow: 0 10px 30px rgba(0,0,0,.2);
}
.card-media{
  aspect-ratio: 16/9;
  background: radial-gradient(1200px 300px at -20% -100%, rgba(23,190,187,.25), transparent),
              linear-gradient(180deg, #0e2b49 0%, #0b233d 100%);
  border-bottom: 1px solid var(--border);
  display: grid; place-items: center;
}
.media-placeholder{
  font-family: 'Sora', sans-serif;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.85);
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  font-size: clamp(1.2rem, 3vw, 1.6rem);
}

.card-body{ padding: 18px; }
.card-title{
  margin: 0 0 6px 0;
  font-family: 'Sora', sans-serif;
  font-weight: 700; font-size: 1.2rem;
}
.card-text{ margin: 0 0 14px 0; color: var(--muted); }

/* -----------------------------------------------------------
   Footer / Contacto
   ----------------------------------------------------------- */
.site-footer{
  padding: 40px 0 56px;
  border-top: 1px solid rgba(255,255,255,.06);
  background: linear-gradient(180deg, #081f36 0%, #071a2d 100%);
}
.footer-inner{
  display: grid; gap: 8px; justify-items: center; text-align: center;
}
.footer-brand{
  display: inline-flex; align-items: center; gap: 10px;
}
.footer-contact a{
  color: var(--white); text-decoration: none;
  padding: 6px 10px; border-radius: 8px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.03);
}
.footer-contact a:hover{ background: rgba(255,255,255,.06); }
.copyright{
  margin: 12px 0 0 0; color: var(--muted); font-size: .95rem;
}

/* -----------------------------------------------------------
   Utilidades
   ----------------------------------------------------------- */
img{ max-width: 100%; height: auto; display: block; }