/* ============================================================
   ABI INFORMÁTICA — Stylesheet
   Paleta: blancos, grises, negros + acento rojo
   ============================================================ */

/* ── Variables ─────────────────────────────────────────────── */
:root {
  /* Dark theme (default) */
  --bg:          #111111;
  --bg-alt:      #181818;
  --surface:     #1f1f1f;
  --surface-2:   #272727;
  --border:      #333333;
  --text:        #f0f0f0;
  --text-muted:  #909090;
  --accent:      #e63030;   /* rojo — elemento destacado */
  --accent-dark: #b91c1c;
  --accent-glow: rgba(230, 48, 48, 0.15);
  --white:       #ffffff;
  --shadow:      0 4px 32px rgba(0,0,0,0.5);
  --radius:      12px;
  --radius-lg:   20px;
  --nav-h:       68px;
  --transition:  0.25s ease;
}

[data-theme="light"] {
  --bg:          #ffffff;
  --bg-alt:      #f5f5f5;
  --surface:     #ffffff;
  --surface-2:   #fafafa;
  --border:      #e0e0e0;
  --text:        #111111;
  --text-muted:  #666666;
  --accent:      #dc2020;
  --accent-dark: #b91c1c;
  --accent-glow: rgba(220, 32, 32, 0.10);
  --shadow:      0 4px 24px rgba(0,0,0,0.10);
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 19.2px; }
body {
  font-family: 'DM Sans', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  transition: background var(--transition), color var(--transition);
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
ul { list-style: none; }

/* ── Utilities ─────────────────────────────────────────────── */
.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
}
.accent { color: var(--accent); }
.accent-link { color: var(--accent); text-decoration: underline; }
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); }

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 64px;
}
.section-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-glow);
  border: 1px solid var(--accent);
  border-radius: 99px;
  padding: 4px 14px;
  margin-bottom: 16px;
}
.section-header h2 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 16px;
}
.section-header p { color: var(--text-muted); font-size: 1.05rem; }

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn-primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px var(--accent-glow);
}
.btn-outline {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}
.btn-full { width: 100%; }

/* ── Navbar ────────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: rgba(10, 15, 30, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  z-index: 1000;
  transition: background var(--transition);
}
[data-theme="light"] .navbar {
  background: rgba(244, 247, 251, 0.90);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
}
.logo-icon {
  color: var(--accent);
  font-size: 1.1rem;
}
.logo-text { color: var(--text); }
.logo-img {
  height: 40px;
  width: auto;
  display: block;
}
.footer-logo {
  height: 36px;
  opacity: 0.9;
}
.nav-links {
  display: flex;
  gap: 36px;
}
.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition);
}
.nav-links a:hover { color: var(--accent); }
.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Theme toggle */
.theme-toggle {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 99px;
  width: 44px;
  height: 26px;
  cursor: pointer;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  transition: all var(--transition);
  overflow: hidden;
}
.theme-toggle:hover { border-color: var(--accent); }
.icon-sun, .icon-moon {
  position: absolute;
  transition: opacity 0.2s, transform 0.3s;
}
[data-theme="dark"] .icon-sun  { opacity: 0; transform: translateY(-10px); }
[data-theme="dark"] .icon-moon { opacity: 1; transform: translateY(0); }
[data-theme="light"] .icon-sun  { opacity: 1; transform: translateY(0); }
[data-theme="light"] .icon-moon { opacity: 0; transform: translateY(10px); }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all var(--transition);
}
.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ── Hero ──────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: var(--nav-h);
  overflow: hidden;
}
.hero-bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 60px 60px;
  opacity: 0.3;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black, transparent);
}
.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 760px;
  padding: 80px 24px;
}
.hero-badge {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-glow);
  border: 1px solid var(--accent);
  border-radius: 99px;
  padding: 5px 16px;
  margin-bottom: 28px;
}
.hero-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(2.4rem, 5.5vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 24px;
}
.hero-sub {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 560px;
  margin-bottom: 40px;
}
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; }

.hero-scroll-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  animation: fadeInUp 1s 0.8s both;
}
.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%, 100% { opacity: 1; transform: scaleY(1); }
  50% { opacity: 0.4; transform: scaleY(0.6); }
}

/* ── Services ──────────────────────────────────────────────── */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}
.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}
.card.featured {
  border-color: var(--accent);
  background: var(--surface-2);
}
.card-badge {
  position: absolute;
  top: -12px;
  left: 24px;
  background: var(--accent);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 99px;
}
.card-icon {
  font-size: 2rem;
  margin-bottom: 20px;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  background: var(--accent-glow);
}
.card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 10px;
}
.card p { color: var(--text-muted); font-size: 0.93rem; margin-bottom: 20px; }
.card-list li {
  font-size: 0.88rem;
  color: var(--text-muted);
  padding: 5px 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-list li::before {
  content: '›';
  color: var(--accent);
  font-weight: 700;
  font-size: 1rem;
}

/* ── Highlight box ─────────────────────────────────────────── */
.highlight-box {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  margin-top: 36px;
  background: linear-gradient(135deg, var(--surface-2), var(--surface));
  border: 1px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 32px 36px;
  box-shadow: 0 0 32px var(--accent-glow);
}
.highlight-icon {
  font-size: 2.2rem;
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-glow);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
}
.highlight-content h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 14px;
  color: var(--accent);
}
.highlight-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.highlight-list li {
  font-size: 0.93rem;
  color: var(--text-muted);
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.highlight-list li::before {
  content: '✓';
  color: var(--accent);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}
.highlight-list strong { color: var(--text); }
.highlight-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 14px;
}

@media (max-width: 540px) {
  .highlight-box { flex-direction: column; gap: 16px; padding: 24px 20px; }
}

/* ── Steps ─────────────────────────────────────────────────── */
.steps {
  display: flex;
  align-items: flex-start;
  gap: 0;
  flex-wrap: wrap;
}
.step {
  flex: 1;
  min-width: 200px;
  padding: 32px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.step-connector {
  width: 32px;
  height: 2px;
  background: var(--accent);
  align-self: center;
  flex-shrink: 0;
  position: relative;
}
.step-connector::after {
  content: '';
  position: absolute;
  right: -6px;
  top: -4px;
  border: 5px solid transparent;
  border-left-color: var(--accent);
}
.step-num {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--accent);
  opacity: 0.4;
  line-height: 1;
  margin-bottom: 12px;
}
.step h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; }
.step p { font-size: 0.88rem; color: var(--text-muted); }

/* ── Technologies ──────────────────────────────────────────── */
.tech-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}
.tech-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 24px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: default;
  transition: all var(--transition);
}
.tech-item:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

/* ── Why us ────────────────────────────────────────────────── */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 28px;
}
.why-item {
  text-align: center;
  padding: 36px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: transform var(--transition);
}
.why-item:hover { transform: translateY(-4px); }
.why-icon {
  font-size: 2rem;
  margin-bottom: 16px;
}
.why-item h4 { font-size: 1rem; font-weight: 700; margin-bottom: 8px; }
.why-item p { font-size: 0.88rem; color: var(--text-muted); }

/* ── Contact ───────────────────────────────────────────────── */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 64px;
  align-items: start;
}
.contact-info .section-tag { margin-bottom: 16px; }
.contact-info h2 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.6rem, 2.8vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.2;
}
.contact-info > p { color: var(--text-muted); margin-bottom: 36px; }
.contact-details { display: flex; flex-direction: column; gap: 20px; }
.contact-detail {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.detail-icon {
  font-size: 1.2rem;
  background: var(--accent-glow);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.contact-detail strong { display: block; font-size: 0.8rem; color: var(--text-muted); margin-bottom: 2px; }
.contact-detail span { font-size: 0.95rem; }

/* ── Form ──────────────────────────────────────────────────── */
.contact-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}
.form-group input,
.form-group select,
.form-group textarea {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
  resize: vertical;
  width: 100%;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-muted); opacity: 0.6; }
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
.form-group input.error,
.form-group textarea.error { border-color: #f87171; }
select option { background: var(--bg); color: var(--text); }

.form-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.form-check input { width: 16px; height: 16px; margin-top: 2px; accent-color: var(--accent); flex-shrink: 0; }

.form-feedback {
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  text-align: center;
}
.form-feedback.success {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid #22c55e;
  color: #4ade80;
}
.form-feedback.error-msg {
  background: rgba(248, 113, 113, 0.1);
  border: 1px solid #f87171;
  color: #f87171;
}

/* ── Footer ────────────────────────────────────────────────── */
.footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 48px 0 32px;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  text-align: center;
}
.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.footer-brand .logo-icon { color: var(--accent); font-size: 1rem; }
.footer-brand .logo-text {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
}
.footer-brand p {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-top: 6px;
}
.footer-nav {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  justify-content: center;
}
.footer-nav a {
  font-size: 0.85rem;
  color: var(--text-muted);
  transition: color var(--transition);
}
.footer-nav a:hover { color: var(--accent); }
.footer-legal {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
  font-size: 0.78rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  padding-top: 24px;
  width: 100%;
}
.footer-legal a { color: var(--text-muted); transition: color var(--transition); }
.footer-legal a:hover { color: var(--accent); }

/* ── Animations ────────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero-badge, .hero-title, .hero-sub, .hero-cta {
  animation: fadeInUp 0.7s ease both;
}
.hero-badge  { animation-delay: 0.05s; }
.hero-title  { animation-delay: 0.15s; }
.hero-sub    { animation-delay: 0.25s; }
.hero-cta    { animation-delay: 0.35s; }

/* scroll-reveal */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 900px) {
  .steps { gap: 12px; }
  .step-connector { display: none; }
  .step { min-width: 180px; }
  .contact-layout { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: var(--nav-h);
    left: 0; right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 24px;
    gap: 20px;
    z-index: 999;
  }
  .hamburger { display: flex; }
  .form-row { grid-template-columns: 1fr; }
  .contact-form { padding: 28px 20px; }
  .section { padding: 64px 0; }
  .hero-inner { padding: 64px 24px; }
}

@media (max-width: 480px) {
  .services-grid { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: 1fr; }
  .hero-title { font-size: 2rem; }
  .btn { width: 100%; }
}

/* ── Language Selector ─────────────────────────────────────── */
.lang-select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%237a8db5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  border: 1px solid var(--border);
  border-radius: 99px;
  height: 32px;
  padding: 0 30px 0 12px;
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 600;
  font-family: inherit;
  color: var(--text);
  outline: none;
  transition: all var(--transition);
}
.lang-select:hover,
.lang-select:focus { border-color: var(--accent); color: var(--accent); }
.lang-select option { background: var(--bg); color: var(--text); }

/* ── Legal pages ───────────────────────────────────────────── */
.legal-hero {
  padding: calc(var(--nav-h) + 56px) 0 48px;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}
.legal-hero h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  margin-bottom: 10px;
}
.legal-hero .legal-date {
  font-size: 0.85rem;
  color: var(--text-muted);
}
.legal-body {
  padding: 64px 0 96px;
  max-width: 780px;
}
.legal-body h2 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.25rem;
  font-weight: 800;
  margin: 40px 0 12px;
  color: var(--accent);
}
.legal-body h2:first-child { margin-top: 0; }
.legal-body p { color: var(--text-muted); margin-bottom: 14px; line-height: 1.75; }
.legal-body ul { margin: 0 0 14px 20px; }
.legal-body ul li { color: var(--text-muted); margin-bottom: 6px; line-height: 1.7; list-style: disc; }
.legal-body a { color: var(--accent); text-decoration: underline; }
.legal-body strong { color: var(--text); }
