/* ===================================================================
   VERITA STUDIO - ESTILOS PRINCIPALES (CSS3 MODERNO)
   Identidad: Honestidad, Rigor Técnico, Transparencia y Fluidez.
   =================================================================== */

:root {
  /* Paleta de Colores Primaria - Verita Studio */
  --bg-main: #070a12;
  --bg-surface: #0d121f;
  --bg-surface-elevated: #131b2e;
  --bg-surface-glass: rgba(13, 18, 31, 0.8);
  
  /* Acentos y Gradientes Distintivos de Marca */
  --primary-accent: #00f5b8;
  --primary-hover: #00d69e;
  --secondary-accent: #00d2ff;
  --tertiary-accent: #4361ee;
  --emerald-accent: #00f5b8;
  --warm-accent: #f59e0b;
  --gradient-brand: linear-gradient(135deg, #00f5b8 0%, #00d2ff 45%, #4361ee 100%);
  --gradient-glow: radial-gradient(circle, rgba(0, 245, 184, 0.18) 0%, rgba(7, 10, 18, 0) 70%);
  
  /* Textos y Contraste */
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-inverse: #070a12;
  
  /* Bordes y Sombras */
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-medium: rgba(255, 255, 255, 0.14);
  --border-focus: rgba(0, 245, 184, 0.5);
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 10px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 20px 40px -15px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 0 35px -5px rgba(0, 245, 184, 0.25);

  /* Tipografías */
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Espaciado & Layout */
  --container-max: 1200px;
  --header-height: 80px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  /* Transiciones */
  --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ===================================================================
   RESET Y BASE
   =================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-main);
  color: var(--text-primary);
  line-height: 1.65;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

ul {
  list-style: none;
}

button {
  font-family: inherit;
  border: none;
  background: none;
  cursor: pointer;
}

/* ===================================================================
   ELEMENTOS DECORATIVOS DE FONDO (AMBIENT GLOWS & GRID)
   =================================================================== */
.ambient-glow {
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  pointer-events: none;
  z-index: -1;
  filter: blur(140px);
  opacity: 0.45;
}

.glow-top-left {
  top: -150px;
  left: -150px;
  background: radial-gradient(circle, rgba(0, 245, 184, 0.22) 0%, transparent 70%);
}

.glow-top-right {
  top: 100px;
  right: -200px;
  background: radial-gradient(circle, rgba(0, 210, 255, 0.2) 0%, transparent 70%);
}

.grid-overlay {
  position: fixed;
  inset: 0;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: -1;
}

/* ===================================================================
   LAYOUT GENERAL & CONTENEDORES
   =================================================================== */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

.section {
  padding-block: 6.5rem;
  position: relative;
}

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

.section-header {
  max-width: 700px;
  margin-inline: auto;
  margin-bottom: 4rem;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--secondary-accent);
  margin-bottom: 0.85rem;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.2);
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-full);
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.2rem;
  letter-spacing: -0.02em;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Gradiente de texto */
.gradient-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

/* ===================================================================
   BOTONES Y ELEMENTOS DE ACCIÓN
   =================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-heading);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-full);
  transition: all var(--transition-smooth);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-accent) 0%, #00d2ff 100%);
  color: #070a12;
  font-weight: 700;
  box-shadow: 0 4px 18px rgba(0, 245, 184, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 245, 184, 0.5);
  background: linear-gradient(135deg, #33f8c5 0%, #38bdf8 100%);
  color: #070a12;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
  border: 1px solid var(--border-medium);
  backdrop-filter: blur(8px);
}

.btn-secondary:hover {
  background: rgba(0, 245, 184, 0.08);
  border-color: rgba(0, 245, 184, 0.4);
  color: var(--primary-accent);
  transform: translateY(-2px);
}

.btn-sm {
  padding: 0.55rem 1.25rem;
  font-size: 0.9rem;
}

.btn-lg {
  padding: 0.9rem 1.9rem;
  font-size: 1.05rem;
}

.btn-xl {
  padding: 1.1rem 2.2rem;
  font-size: 1.15rem;
}

.btn-block {
  width: 100%;
}

/* ===================================================================
   1. HEADER / NAVEGACIÓN
   =================================================================== */
.site-header {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  z-index: 1000;
  background-color: rgba(7, 10, 18, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  transition: all var(--transition-smooth);
}

.site-header.scrolled {
  background-color: rgba(7, 10, 18, 0.92);
  box-shadow: var(--shadow-sm);
  border-bottom-color: rgba(0, 245, 184, 0.15);
}

.nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

/* Logo */
.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.logo-symbol {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(0, 245, 184, 0.18) 0%, rgba(0, 210, 255, 0.18) 100%);
  border: 1px solid rgba(0, 245, 184, 0.45);
  border-radius: var(--radius-sm);
  color: var(--primary-accent);
  box-shadow: 0 0 15px rgba(0, 245, 184, 0.2);
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.brand-logo:hover .logo-symbol {
  transform: rotate(5deg) scale(1.05);
  border-color: var(--primary-accent);
  box-shadow: 0 0 20px rgba(0, 245, 184, 0.4);
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.logo-accent {
  font-weight: 400;
  color: var(--text-secondary);
}

/* Desktop Menu Links */
.nav-menu {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 2.2rem;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
  position: relative;
  padding-block: 0.25rem;
}

.nav-link:hover, .nav-link.active {
  color: #ffffff;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--gradient-brand);
  transition: width var(--transition-fast);
  border-radius: var(--radius-full);
}

.nav-link:hover::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Botón Hamburguesa Móvil */
.mobile-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 40px;
  height: 40px;
  padding: 8px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  z-index: 1010;
}

.hamburger-line {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
  border-radius: 2px;
  transition: transform var(--transition-smooth), opacity var(--transition-smooth);
}

.mobile-toggle.active .hamburger-line:nth-child(1) {
  transform: translateY(4px) rotate(45deg);
}

.mobile-toggle.active .hamburger-line:nth-child(2) {
  transform: translateY(-4px) rotate(-45deg);
}

/* Mobile Drawer */
.mobile-drawer {
  position: fixed;
  top: var(--header-height);
  left: 0;
  width: 100%;
  height: calc(100vh - var(--header-height));
  background-color: rgba(11, 15, 25, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 2.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
  transition: transform var(--transition-smooth), opacity var(--transition-smooth);
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-drawer.open {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.mobile-nav-link {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-secondary);
  display: block;
}

.mobile-nav-link:hover {
  color: var(--primary-accent);
}

.mobile-drawer-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.mobile-drawer-contact {
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.mobile-drawer-contact a {
  color: var(--secondary-accent);
  text-decoration: underline;
}

/* ===================================================================
   2. HERO SECTION
   =================================================================== */
.hero-section {
  padding-top: 4.5rem;
  padding-bottom: 6rem;
  position: relative;
  overflow: hidden;
}

.hero-container {
  display: grid;
  grid-template-columns: 1.2fr 0.9fr;
  align-items: center;
  gap: 3.5rem;
}

.pill-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.25);
  padding: 0.4rem 1rem;
  border-radius: var(--radius-full);
  margin-bottom: 1.5rem;
}

.pill-center {
  margin-inline: auto;
}

.pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--emerald-accent);
  box-shadow: 0 0 10px var(--emerald-accent);
  animation: pulse-dot 2s infinite ease-in-out;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.pill-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: #c7d2fe;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 4.8vw, 3.8rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: clamp(1.05rem, 1.8vw, 1.2rem);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2.2rem;
  max-width: 580px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.2rem;
  margin-bottom: 3.5rem;
}

/* Metrics Strip */
.hero-metrics {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-subtle);
}

.metric-item {
  display: flex;
  flex-direction: column;
}

.metric-value {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.02em;
}

.metric-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  max-width: 140px;
  line-height: 1.35;
}

.metric-divider {
  width: 1px;
  height: 40px;
  background: var(--border-subtle);
}

/* Visual Engineering Card */
.hero-visual {
  position: relative;
  perspective: 1000px;
}

.code-card {
  background: rgba(17, 24, 39, 0.85);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  position: relative;
  overflow: visible;
  transition: transform var(--transition-smooth);
}

.code-card:hover {
  transform: translateY(-4px) rotateX(2deg);
}

.card-glass-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.25rem;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.mac-buttons {
  display: flex;
  gap: 6px;
}

.mac-btn {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.mac-btn.red { background-color: #ef4444; }
.mac-btn.yellow { background-color: #f59e0b; }
.mac-btn.green { background-color: #10b981; }

.card-title-file {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  color: var(--emerald-accent);
  font-weight: 500;
}

.status-dot {
  width: 6px;
  height: 6px;
  background-color: var(--emerald-accent);
  border-radius: 50%;
}

.card-code-body {
  padding: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.7;
  overflow-x: auto;
}

.code-keyword { color: #f43f5e; }
.code-var { color: #38bdf8; }
.code-prop { color: #a5b4fc; }
.code-str { color: #34d399; }
.code-num { color: #fbbf24; }
.code-func { color: #c084fc; }

/* Micro Floating Cards */
.floating-badge {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: rgba(22, 32, 50, 0.95);
  border: 1px solid var(--border-medium);
  padding: 0.75rem 1.1rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(10px);
  z-index: 10;
  animation: float-badge 6s ease-in-out infinite alternate;
}

.badge-speed {
  top: -24px;
  right: -20px;
}

.badge-trust {
  bottom: -24px;
  left: -20px;
  animation-delay: -3s;
}

@keyframes float-badge {
  0% { transform: translateY(0px); }
  100% { transform: translateY(-8px); }
}

.badge-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
}

.green-icon {
  background: rgba(16, 185, 129, 0.15);
  color: var(--emerald-accent);
}

.blue-icon {
  background: rgba(56, 189, 248, 0.15);
  color: var(--secondary-accent);
}

.badge-details {
  display: flex;
  flex-direction: column;
}

.badge-number {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  color: #ffffff;
}

.badge-tag {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ===================================================================
   3. SECCIÓN DE VALORES / FILOSOFÍA
   =================================================================== */
.philosophy-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.philosophy-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all var(--transition-smooth);
}

.philosophy-card:hover {
  transform: translateY(-6px);
  border-color: rgba(99, 102, 241, 0.35);
  box-shadow: 0 15px 35px -10px rgba(0, 0, 0, 0.5), 0 0 25px rgba(99, 102, 241, 0.15);
}

.philosophy-card.featured-card {
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.7) 0%, rgba(17, 24, 39, 0.95) 100%);
  border-color: rgba(99, 102, 241, 0.3);
}

.card-badge {
  position: absolute;
  top: 1.25rem;
  right: 1.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--primary-accent);
  background: rgba(99, 102, 241, 0.15);
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
}

.card-icon-wrapper {
  width: 58px;
  height: 58px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  display: grid;
  place-items: center;
  color: var(--secondary-accent);
  margin-bottom: 1.75rem;
  transition: transform var(--transition-fast), background var(--transition-fast);
}

.card-icon-wrapper.accent-icon {
  background: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.3);
  color: #a5b4fc;
}

.philosophy-card:hover .card-icon-wrapper {
  transform: scale(1.08);
}

.card-meta {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.card-title {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #ffffff;
}

.card-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1.8rem;
}

.card-highlights {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-subtle);
}

.card-highlights li {
  font-size: 0.875rem;
  color: var(--text-secondary);
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  line-height: 1.45;
}

.bullet-check {
  color: var(--emerald-accent);
  font-weight: 700;
}

/* ===================================================================
   4. SECCIÓN DE SERVICIOS
   =================================================================== */
.services-section {
  background-color: rgba(11, 15, 25, 0.5);
  position: relative;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.service-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2.2rem;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.service-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--gradient-brand);
  opacity: 0;
  transition: opacity var(--transition-smooth);
}

.service-box:hover {
  transform: translateY(-8px);
  border-color: rgba(56, 189, 248, 0.3);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
}

.service-box:hover::before {
  opacity: 1;
}

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

.service-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.2);
  display: grid;
  place-items: center;
  color: var(--secondary-accent);
  transition: all var(--transition-fast);
}

.service-icon.accent-glow {
  background: rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.3);
  color: #a5b4fc;
}

.service-box:hover .service-icon {
  transform: scale(1.05);
}

.service-number {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.15);
}

.service-heading {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 700;
  margin-bottom: 1.1rem;
  color: #ffffff;
  line-height: 1.3;
}

.service-paragraph {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2rem;
}

.service-features {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2.5rem;
}

.feature-tag {
  font-size: 0.78rem;
  font-weight: 500;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-sm);
}

.service-link {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--secondary-accent);
  transition: gap var(--transition-fast), color var(--transition-fast);
}

.service-link:hover {
  color: #ffffff;
  gap: 0.75rem;
}

/* ===================================================================
   SECCIÓN DE CASOS DE ÉXITO & PORTFOLIO DE DEMOS INTERACTIVAS
   =================================================================== */
.portfolio-filter-tabs {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.portfolio-tab-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.portfolio-tab-btn:hover {
  background: rgba(0, 245, 184, 0.08);
  border-color: rgba(0, 245, 184, 0.3);
  color: #ffffff;
}

.portfolio-tab-btn.active {
  background: linear-gradient(135deg, rgba(0, 245, 184, 0.15) 0%, rgba(0, 210, 255, 0.15) 100%);
  border-color: var(--primary-accent);
  color: var(--primary-accent);
  box-shadow: 0 0 15px rgba(0, 245, 184, 0.2);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 2.2rem;
}

.project-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition-smooth);
  display: flex;
  flex-direction: column;
  position: relative;
}

.project-card:hover {
  transform: translateY(-8px);
  border-color: rgba(0, 245, 184, 0.35);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.7), 0 0 30px rgba(0, 245, 184, 0.15);
}

.project-preview {
  height: 220px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  overflow: hidden;
}

.preview-barber {
  background: radial-gradient(circle at 70% 30%, rgba(197, 160, 89, 0.25) 0%, transparent 60%),
              linear-gradient(135deg, #16181f 0%, #0d0e12 100%);
}

.preview-housing {
  background: radial-gradient(circle at 30% 70%, rgba(205, 163, 98, 0.2) 0%, transparent 60%),
              linear-gradient(135deg, #131a27 0%, #090c12 100%);
}

.preview-transport {
  background: radial-gradient(circle at 50% 50%, rgba(0, 210, 255, 0.22) 0%, transparent 65%),
              linear-gradient(135deg, #0e1524 0%, #06080d 100%);
}

.preview-badge-status {
  position: absolute;
  top: 1rem;
  left: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(7, 10, 18, 0.8);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-subtle);
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  color: #ffffff;
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary-accent);
  box-shadow: 0 0 8px var(--primary-accent);
  animation: pulse-dot 1.5s infinite;
}

.preview-tag-sector {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--secondary-accent);
  background: rgba(0, 210, 255, 0.1);
  border: 1px solid rgba(0, 210, 255, 0.25);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
}

.preview-visual-icon {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: grid;
  place-items: center;
  color: #ffffff;
  transition: transform 0.4s ease;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.project-card:hover .preview-visual-icon {
  transform: scale(1.1) rotate(4deg);
  border-color: var(--primary-accent);
  color: var(--primary-accent);
}

.project-info {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.project-category {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--primary-accent);
  letter-spacing: 0.08em;
  margin-bottom: 0.4rem;
}

.project-name {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.8rem;
  line-height: 1.3;
}

.project-desc {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.project-features-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-bottom: 1.5rem;
  font-size: 0.825rem;
  color: #cbd5e1;
}

.project-features-list span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.project-features-list span::before {
  content: '✓';
  color: var(--primary-accent);
  font-weight: 700;
}

.project-tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 1.75rem;
  margin-top: auto;
}

.project-tech-stack span {
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
}

.project-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-subtle);
}

.btn-project-live {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: linear-gradient(135deg, var(--primary-accent) 0%, #00d2ff 100%);
  color: #070a12;
  font-family: var(--font-heading);
  font-size: 0.825rem;
  font-weight: 700;
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-sm);
  text-align: center;
  transition: all var(--transition-fast);
}

.btn-project-live:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(0, 245, 184, 0.4);
  color: #070a12;
}

.btn-project-preview {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  color: #ffffff;
  font-family: var(--font-heading);
  font-size: 0.825rem;
  font-weight: 600;
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-project-preview:hover {
  background: rgba(0, 245, 184, 0.1);
  border-color: var(--primary-accent);
  color: var(--primary-accent);
}

/* ===================================================================
   MODAL INTERACTIVO DE PREVISUALIZACIÓN EN VIVO (DEVICE SIMULATOR)
   =================================================================== */
.live-preview-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 7, 12, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.live-preview-modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.live-preview-modal {
  background: #0d121f;
  border: 1px solid rgba(0, 245, 184, 0.35);
  border-radius: var(--radius-lg);
  width: 95vw;
  max-width: 1350px;
  height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.9), 0 0 50px rgba(0, 245, 184, 0.15);
  animation: modal-pop 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modal-pop {
  0% { transform: scale(0.96) translateY(10px); }
  100% { transform: scale(1) translateY(0); }
}

.modal-bar-header {
  padding: 0.9rem 1.5rem;
  background: #070a12;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.modal-info-col {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.modal-badge-live {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--primary-accent);
  background: rgba(0, 245, 184, 0.12);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
}

.modal-site-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
}

/* Device Switcher Controls */
.modal-device-controls {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.05);
  padding: 0.25rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.device-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all var(--transition-fast);
}

.device-btn.active, .device-btn:hover {
  background: rgba(0, 245, 184, 0.15);
  color: var(--primary-accent);
}

.modal-right-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.btn-open-fullscreen {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  color: #ffffff;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  transition: all var(--transition-fast);
}

.btn-open-fullscreen:hover {
  background: var(--primary-accent);
  color: #070a12;
  border-color: var(--primary-accent);
}

.modal-close-icon {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: #ffffff;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  display: grid;
  place-items: center;
  font-size: 1.3rem;
  transition: all var(--transition-fast);
}

.modal-close-icon:hover {
  background: #ef4444;
  color: #ffffff;
}

.modal-frame-viewport {
  flex-grow: 1;
  background: #040609;
  display: flex;
  justify-content: center;
  align-items: stretch;
  overflow: hidden;
  position: relative;
}

.preview-iframe-wrapper {
  width: 100%;
  height: 100%;
  transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.8);
  background: #000000;
}

.preview-iframe-wrapper.tablet {
  width: 768px;
  border-inline: 1px solid var(--border-subtle);
}

.preview-iframe-wrapper.mobile {
  width: 390px;
  border-inline: 1px solid var(--border-subtle);
}

.preview-iframe-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

/* ===================================================================
   5. SECCIÓN DE LLAMADA A LA ACCIÓN FINAL (CTA)
   =================================================================== */
.cta-section {
  padding-block: 7rem;
}

.cta-card {
  position: relative;
  background: linear-gradient(135deg, rgba(13, 18, 31, 0.95) 0%, rgba(7, 10, 18, 0.98) 100%);
  border: 1px solid rgba(0, 245, 184, 0.35);
  border-radius: 28px;
  padding: 4.5rem 2.5rem;
  text-align: center;
  overflow: hidden;
  box-shadow: var(--shadow-lg), 0 0 50px rgba(0, 245, 184, 0.15);
}

.cta-card-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(0, 245, 184, 0.2) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
}

.cta-content {
  position: relative;
  z-index: 2;
  max-width: 760px;
  margin-inline: auto;
}

.cta-headline {
  font-family: var(--font-heading);
  font-size: clamp(2.3rem, 4.5vw, 3.4rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin-top: 1.25rem;
  margin-bottom: 1.5rem;
}

.cta-text {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2.8rem;
}

.cta-actions-cluster {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}

.btn-copy {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1.1rem 1.6rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.05rem;
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
}

.btn-copy:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.3);
}

.btn-copy.copied {
  background: rgba(16, 185, 129, 0.15);
  border-color: var(--emerald-accent);
  color: var(--emerald-accent);
}

.cta-guarantees {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* ===================================================================
   6. PIE DE PÁGINA (FOOTER)
   =================================================================== */
.site-footer {
  background-color: #070a12;
  border-top: 1px solid var(--border-subtle);
  padding-top: 5rem;
  padding-bottom: 2.5rem;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: 3.5rem;
  margin-bottom: 4rem;
}

.footer-brand-col {
  display: flex;
  flex-direction: column;
}

.footer-logo {
  margin-bottom: 1.25rem;
}

.footer-tagline {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1.5rem;
  max-width: 340px;
}

.footer-email-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--secondary-accent);
  font-weight: 500;
  font-size: 0.95rem;
}

.footer-email-link a:hover {
  text-decoration: underline;
  color: #ffffff;
}

.footer-heading {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.footer-nav a {
  font-size: 0.92rem;
  color: var(--text-secondary);
  transition: color var(--transition-fast), transform var(--transition-fast);
  display: inline-block;
}

.footer-nav a:hover {
  color: #ffffff;
  transform: translateX(4px);
}

/* Redes Sociales */
.social-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.92rem;
  color: var(--text-secondary);
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  transition: all var(--transition-fast);
}

.social-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateX(4px);
}

/* Footer Bottom */
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border-subtle);
  flex-wrap: wrap;
  gap: 1.25rem;
}

.copyright-text {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.legal-links {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.legal-link {
  font-size: 0.88rem;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.legal-link:hover {
  color: var(--text-primary);
}

.legal-separator {
  color: rgba(255, 255, 255, 0.15);
  font-size: 0.8rem;
}

/* ===================================================================
   RESPONSIVE DESIGN (MEDIA QUERIES)
   =================================================================== */

/* Tablet & Pantallas Medianas (<= 1024px) */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3.5rem;
  }

  .hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-subtitle {
    margin-inline: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-metrics {
    justify-content: center;
  }

  .hero-visual {
    max-width: 600px;
    margin-inline: auto;
  }

  .philosophy-grid,
  .services-grid {
    grid-template-columns: 1fr;
    max-width: 640px;
    margin-inline: auto;
  }

  .projects-grid {
    grid-template-columns: 1fr;
    max-width: 640px;
    margin-inline: auto;
  }

  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }
}

/* Móviles & Pantallas Pequeñas (<= 768px) */
@media (max-width: 768px) {
  .nav-menu,
  .nav-cta {
    display: none;
  }

  .mobile-toggle {
    display: flex;
  }

  .section {
    padding-block: 4.5rem;
  }

  .hero-metrics {
    flex-direction: column;
    gap: 1.25rem;
    align-items: center;
  }

  .metric-divider {
    display: none;
  }

  .metric-item {
    align-items: center;
    text-align: center;
  }

  .card-code-body {
    font-size: 0.75rem;
    padding: 1rem;
  }

  .floating-badge {
    position: static;
    margin-block: 0.75rem;
    width: 100%;
    justify-content: center;
  }

  .badge-speed, .badge-trust {
    animation: none;
  }

  .cta-card {
    padding: 3rem 1.5rem;
    border-radius: 20px;
  }

  .cta-actions-cluster {
    flex-direction: column;
    width: 100%;
  }

  .cta-actions-cluster .btn {
    width: 100%;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .legal-links {
    flex-wrap: wrap;
    justify-content: center;
  }
}

/* ===================================================================
   ACCESIBILIDAD & REDUCED MOTION
   =================================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

:focus-visible {
  outline: 2px solid var(--secondary-accent);
  outline-offset: 3px;
}
