/* Google Fonts loaded via <link> in HTML — no @import needed here */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #0B0B0D;
  --bg-2: #111114;
  --bg-3: #18181c;
  --text: #FFFFFF;
  --text-muted: #888898;
  --accent: #C8102E;
  --accent-2: #ff1f40;
  --accent-dim: rgba(200, 16, 46, 0.12);
  --border: rgba(255, 255, 255, 0.08);
  --border-2: rgba(255, 255, 255, 0.14);
  --font-ui: 'Inter', system-ui, sans-serif;
  --font-serif: 'Crimson Pro', Georgia, serif;
  --radius: 12px;
  --radius-sm: 6px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --max-w: 1200px;
  --header-h: 64px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in: cubic-bezier(0.64, 0, 0.78, 0);
  --header-scrolled-bg: rgba(11, 11, 13, 0.85);
}

html.light-mode {
  --bg: #EBEBEF;
  --bg-2: #FFFFFF;
  --bg-3: #D8D8E2;
  --text: #0B0B0D;
  --text-muted: #52526A;
  --border: rgba(0, 0, 0, 0.09);
  --border-2: rgba(0, 0, 0, 0.16);
  --header-scrolled-bg: rgba(235, 235, 239, 0.94);
}

html {
  scroll-behavior: auto;
}

body {
  font-family: var(--font-ui);
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

button {
  cursor: pointer;
  font-family: var(--font-ui);
}

a {
  color: inherit;
  text-decoration: none;
}

/* ─── Focus visibility (WCAG 2.1 AA) ───────────────────────── */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

/* Suppress outline for mouse/touch users, keep for keyboard */
:focus:not(:focus-visible) {
  outline: none;
}

#site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--gutter);
  background: transparent;
  transition: background 0.4s var(--ease-out), backdrop-filter 0.4s;
}

#site-header.scrolled {
  background: var(--header-scrolled-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.header-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
}

.header-logo svg {
  height: 2.8rem;
  width: auto;
}

.logo-phrase {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.logo-phrase .line-top {
  font-family: 'Inter', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  text-transform: none;
}

.logo-phrase .line-bottom {
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: 0.02em;
  text-transform: none;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.header-nav a {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s;
}

.header-nav a:hover {
  color: var(--text);
}

.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1.3rem;
  background: var(--accent);
  color: #fff;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  border: none;
  transition: background 0.2s, transform 0.15s;
}

.btn-pill:hover {
  background: var(--accent-2);
  transform: translateY(-1px);
}

.btn-pill:active {
  transform: translateY(0);
}

.btn-outline {
  padding: 0.5rem 1.2rem;
  border: 1px solid var(--border-2);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text);
  background: transparent;
  transition: border-color 0.2s, background 0.2s;
}

.btn-outline:hover {
  border-color: var(--accent);
  background: rgba(200, 16, 46, 0.08);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-2);
  border-radius: 100px;
  background: transparent;
  color: var(--text-muted);
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.theme-toggle:hover {
  color: var(--text);
  border-color: var(--accent);
  background: rgba(200, 16, 46, 0.08);
}

.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
  display: none;
  width: 16px;
  height: 16px;
}

html:not(.light-mode) .theme-toggle .icon-sun {
  display: block;
}

html.light-mode .theme-toggle .icon-moon {
  display: block;
}

#hero {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

.hero-ambient-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

/* Large red radial below-center */
.hero-ambient-glow::before {
  content: '';
  position: absolute;
  bottom: -10%;
  left: 20%;
  width: 70vw;
  height: 70vh;
  background: radial-gradient(ellipse, rgba(200, 16, 46, 0.18) 0%, rgba(11, 11, 13, 0) 68%);
  filter: blur(60px);
}

/* Cooler top-right accent */
.hero-ambient-glow::after {
  content: '';
  position: absolute;
  top: -5%;
  right: 5%;
  width: 50vw;
  height: 60vh;
  background: radial-gradient(ellipse, rgba(80, 60, 200, 0.09) 0%, rgba(11, 11, 13, 0) 70%);
  filter: blur(80px);
}

/* Hero grid overlay */
#hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 60%, black 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 60%, black 30%, transparent 80%);
  pointer-events: none;
  z-index: 0;
}

.ide-wrapper {
  position: absolute;
  inset: 0;
  perspective: 1200px;

  z-index: 1;
  pointer-events: none;
}

.ide-window {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 75vw;
  max-width: 1100px;
  height: 72vh;
  max-height: 800px;
  background: rgba(18, 18, 24, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.03) inset;
  display: flex;
  flex-direction: column;
  overflow: hidden;

  transform-origin: center center;
  opacity: 1;
}

.ide-header {
  height: 38px;
  background: rgba(30, 30, 40, 0.5);
  display: flex;
  align-items: center;
  padding: 0 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.ide-controls {
  display: flex;
  gap: 8px;
}

.ide-controls .ctrl {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.ctrl.close {
  background: #ff5f56;
}

.ctrl.min {
  background: #ffbd2e;
}

.ctrl.max {
  background: #27c93f;
}

.ide-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-family: system-ui, sans-serif;
  font-size: 0.75rem;
  color: #8b8b99;
}

.ide-body {
  display: flex;
  flex: 1;
  overflow: hidden;
  position: relative;
}

.ide-source {
  display: flex;
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
}

.ide-sidebar {
  width: 240px;
  background: rgba(20, 20, 26, 0.6);
  border-right: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.sidebar-title {
  font-family: system-ui, sans-serif;
  font-size: 0.65rem;
  font-weight: 600;
  color: #8b8b99;
  padding: 1rem 1.25rem;
  letter-spacing: 0.05em;
}

.tree-item {
  padding: 0.35rem 1.25rem;
  font-size: 0.85rem;
  color: #8b8b99;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: default;
}

.tree-item.folder {
  font-weight: 600;
  color: #fff;
}

.tree-item.file.active {
  background: rgba(255, 255, 255, 0.06);
  color: var(--accent);
}

.ide-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.ide-tabs {
  display: flex;
  height: 40px;
  background: rgba(20, 20, 26, 0.3);
}

.ide-tabs .tab {
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  font-size: 0.85rem;
  color: #8b8b99;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(20, 20, 26, 0.5);
}

.ide-tabs .tab.active {
  background: transparent;
  color: #fff;
  border-top: 2px solid var(--accent);
}

.ide-code {
  flex: 1;
  position: relative;
  overflow: hidden;
  padding: 1rem 0;
  display: flex;
}

.code-lines {
  flex: 1;
  font-family: 'Fira Code', 'Courier New', monospace;
  font-size: 0.95rem;
  line-height: 1.6;
  padding-left: 1rem;
}

.code-line {
  display: flex;
  opacity: 0.3;

  transition: opacity 0.2s;
}

.code-line.visible {
  opacity: 1;
}

.line-num {
  width: 40px;
  color: #4b4b5c;
  text-align: right;
  padding-right: 1rem;
  user-select: none;
}

.token-keyword {
  color: #c678dd;
}

.token-var {
  color: #e5c07b;
}

.token-string {
  color: #98c379;
}

.token-function {
  color: #61afef;
}

.token-comment {
  color: #5c6370;
  font-style: italic;
}

.cursor {
  display: inline-block;
  width: 8px;
  height: 1.1em;
  background-color: #528bff;
  vertical-align: middle;
  margin-left: 2px;
  opacity: 1;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

.ide-minimap {
  width: 60px;
  border-left: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(0, 0, 0, 0.2);
  position: relative;
}

.minimap-slider {
  position: absolute;
  top: 10%;
  left: 0;
  width: 100%;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  cursor: pointer;
}

.ide-terminal {
  height: 200px;
  background: rgba(14, 14, 18, 0.9);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
}

.terminal-tabs {
  display: flex;
  height: 36px;
  padding-left: 1.5rem;
}

.terminal-tabs .ttab {
  padding: 0 1rem;
  display: flex;
  align-items: center;
  font-size: 0.75rem;
  font-family: system-ui, sans-serif;
  color: #8b8b99;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.terminal-tabs .ttab.active {
  color: #fff;
  border-bottom: 1px solid #fff;
}

.terminal-body {
  flex: 1;
  padding: 0.5rem 1.5rem;
  font-family: 'Fira Code', 'Courier New', monospace;
  font-size: 0.85rem;
  line-height: 1.5;
  color: #a0a0b0;
  overflow: hidden;
}

.t-line.t-success {
  color: #98c379;
}

.t-line.t-info {
  color: #56b6c2;
}

.t-line.t-cmd {
  color: #fff;
}

.ide-gui {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background: #0b0b0e;
  z-index: 10;
  opacity: 0;

  pointer-events: none;

}

.ide-gui .gui-nav {
  height: 60px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  background: rgba(255, 255, 255, 0.02);
}

.ide-gui .gui-logo {
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.ide-gui .gui-logo .accent {
  color: var(--accent);
}

.ide-gui .gui-links {
  display: flex;
  gap: 2rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: #8b8b99;
}

.ide-gui .gui-links span:first-child {
  color: #fff;
}

.ide-gui .avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg-3);
  border: 1px solid rgba(200, 16, 46, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
}

.ide-gui .gui-content {
  flex: 1;
  padding: 3rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.ide-gui .gui-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.ide-gui .gui-header h2 {
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.ide-gui .gui-header p {
  color: #8b8b99;
  font-size: 0.95rem;
}

.ide-gui .gui-btn.primary {
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 0.85rem;
  border: none;
  cursor: pointer;
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out);
  box-shadow: 0 4px 16px rgba(200, 16, 46, 0.35);
}

.ide-gui .gui-btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(200, 16, 46, 0.5);
}

.ide-gui .gui-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.ide-gui .gui-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  transition: background 0.3s, border-color 0.3s;
}

.ide-gui .gui-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.15);
}

.ide-gui .gui-card.metric .icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.ide-gui .gui-card.metric .icon.bg-blue {
  background: rgba(200, 16, 46, 0.12);
}

.ide-gui .gui-card.metric .icon.bg-green {
  background: rgba(39, 201, 63, 0.15);
}

.ide-gui .gui-card.metric .icon.bg-purple {
  background: rgba(198, 120, 221, 0.15);
}

.ide-gui .metric-data {
  display: flex;
  flex-direction: column;
}

.ide-gui .metric-data .val {
  font-size: 1.5rem;
  font-weight: 700;
}

.ide-gui .metric-data .lbl {
  font-size: 0.8rem;
  color: #8b8b99;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.ide-gui .chart-card {
  grid-column: 1 / -1;
  flex-direction: column;
  align-items: stretch;
  padding: 2rem;
}

.ide-gui .chart-card .card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.ide-gui .chart-card .status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #27c93f;
  box-shadow: 0 0 8px rgba(39, 201, 63, 0.6);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    opacity: 0.5;
  }

  50% {
    opacity: 1;
  }

  100% {
    opacity: 0.5;
  }
}

.ide-gui .chart-mockup {
  height: 140px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.ide-gui .chart-mockup .bar {
  flex: 1;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 4px 4px 0 0;
  transition: height 1s ease-out, background 0.3s;
}

.ide-gui .chart-mockup .bar.highlight {
  background: var(--accent);
  box-shadow: 0 0 16px rgba(200, 16, 46, 0.35);
}

.ide-gui .chart-mockup .bar:hover {
  background: rgba(200, 16, 46, 0.5);
}

.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: calc(var(--header-h) + 2rem) var(--gutter) 7rem;
  pointer-events: none;
  z-index: 2;
  max-width: calc(var(--max-w) + var(--gutter) * 2);
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 1.25rem;
  opacity: 1;
}

.hero-eyebrow::before {
  content: '';
  display: block;
  width: 24px;
  height: 1px;
  background: var(--accent);
  flex-shrink: 0;
}

.hero-title {
  font-size: clamp(3rem, 7.5vw, 8rem);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: 1.5rem;
  opacity: 1;
  /* Prevent layout shift during GSAP split animation */
  will-change: transform, opacity;
}

/* Word-level split animation targets — set by JS */
.hero-title .word {
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
}

.hero-title .word-inner {
  display: inline-block;
}

.hero-title .accent-word {
  color: var(--accent);
}

.hero-gestionafacil {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.45);
  margin-top: -1.5rem;
  margin-bottom: 2rem;
  text-transform: uppercase;
}

.hero-gestionafacil strong {
  color: var(--accent);
  font-weight: 600;
}

.hero-gestionafacil-link {
  text-decoration: none;
  border-bottom: 1px solid rgba(200, 16, 46, 0.4);
  transition: border-color 0.2s;
}

.hero-gestionafacil-link:hover {
  border-color: var(--accent);
}

.hero-subtitle {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.1rem, 2.2vw, 1.75rem);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.65);
  margin-bottom: 2.5rem;
  opacity: 1;
}

.hero-services {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 860px;
  pointer-events: auto;
  background: rgba(11, 11, 13, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.hero-service-item {
  padding: 1.1rem 1.4rem;
  background: transparent;
  border-right: 1px solid var(--border);
  transition: background 0.3s var(--ease-out);
  position: relative;
}

.hero-service-item:last-child {
  border-right: none;
}

.hero-service-item::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease-out);
}

.hero-service-item:hover {
  background: rgba(200, 16, 46, 0.07);
}

.hero-service-item:hover::after {
  transform: scaleX(1);
}

.hero-service-item .label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.3rem;
  opacity: 0.8;
}

.hero-service-item .name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
}

#hero-loader {
  position: absolute;
  inset: 0;
  z-index: 10;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  transition: opacity 0.6s var(--ease-out);
}

#hero-loader.hidden {
  opacity: 0;
  pointer-events: none;
}

.loader-text {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.loader-bar-track {
  width: 200px;
  height: 2px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

.loader-bar-fill {
  height: 100%;
  background: var(--accent);
  width: 0%;
  border-radius: 2px;
  transition: width 0.1s linear;
}

.hero-scroll-hint {
  position: absolute;
  bottom: 2rem;
  right: var(--gutter);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.scroll-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, transparent, var(--text-muted));
  animation: scrollPulse 2s ease-in-out infinite;
}

.scroll-label {
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  writing-mode: vertical-rl;
}

.section-padding {
  padding: clamp(4rem, 8vh, 8rem) 0;
}

#problems {
  background: var(--bg);
  position: relative;
  z-index: 1;
}

.problems-container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  flex-direction: column;
  gap: 4rem;
}

.problems-header-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 900px) {
  .problems-header-container {
    grid-template-columns: 1fr 1fr;
  }
}

.problems-header-text {
  max-width: 600px;
}

.problems-image-wrapper {
  position: relative;
  width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.problems-hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  aspect-ratio: 16/9;
}

.problems-image-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, var(--bg) 0%, transparent 20%, transparent 80%, var(--bg) 100%),
    linear-gradient(to top, var(--bg) 0%, transparent 20%);
  pointer-events: none;
}

.problems-header {
  max-width: 800px;
  margin-bottom: 4rem;
}

.problems-intro {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 600px;
  line-height: 1.6;
  margin-top: 1.5rem;
}

.highlight-red {
  color: #ff4d4d;

  position: relative;
  display: inline-block;
  text-shadow: 0 0 20px rgba(255, 77, 77, 0.2);
}

.highlight-red::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 3px;
  background: #ff4d4d;
  opacity: 0.6;
  border-radius: 2px;
  transform: rotate(-1.5deg);
}

.problems-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
}

@media (max-width: 700px) {
  .problems-grid {
    grid-template-columns: 1fr;
  }
}

.problem-card {
  background: transparent;
  padding: 2.75rem 2.5rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transition: background 0.4s var(--ease-out);
  position: relative;
  overflow: hidden;
}

/* Remove right border on even (2nd column), bottom border on last row */
.problem-card:nth-child(2n) {
  border-right: none;
}

.problem-card:nth-child(3),
.problem-card:nth-child(4) {
  border-bottom: none;
}

@media (max-width: 700px) {
  .problem-card {
    border-right: none;
  }
  .problem-card:last-child {
    border-bottom: none;
  }
  .problem-card:nth-child(3) {
    border-bottom: 1px solid var(--border);
  }
}

.problem-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 0% 100%, rgba(200, 16, 46, 0.07) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.5s var(--ease-out);
}

.problem-card:hover {
  background: rgba(255, 255, 255, 0.02);
}

.problem-card:hover::before {
  opacity: 1;
}

/* Big background number */
.problem-num {
  font-size: 6rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
  color: rgba(200, 16, 46, 0.08);
  margin-bottom: -1.5rem;
  display: block;
  font-variant-numeric: tabular-nums;
  transition: color 0.4s;
}

.problem-card:hover .problem-num {
  color: rgba(200, 16, 46, 0.14);
}

.problem-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  position: relative;
}

.problem-icon svg {
  width: 24px;
  height: 24px;
}

.problem-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text);
  letter-spacing: -0.01em;
}

.problem-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.65;
  max-width: 34ch;
}

@media (max-width: 768px) {
  .problems-header {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
  }
}

#promo {
  background: var(--bg-2);
  padding: clamp(4rem, 8vh, 7rem) var(--gutter);
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--border);
}

/* Subtle horizontal accent lines on promo */
#promo::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(200,16,46,0.35) 50%, transparent 100%);
}

.promo-container {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 4rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .promo-container {
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
  }
}

.promo-content {
  max-width: 540px;
}

.promo-content .section-title {
  font-size: clamp(2rem, 4.5vw, 3.75rem);
  letter-spacing: -0.03em;
  line-height: 1.0;
}

.promo-description {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--text-muted);
  margin-top: 1.5rem;
  margin-bottom: 2.5rem;
  max-width: 44ch;
}

.promo-cards-wrapper {
  position: relative;
  width: 100%;
  height: 500px;
  flex-shrink: 0;
  align-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
}

.promo-card-stack {
  position: relative;
  width: 500px;
  height: 420px;
}

.promo-card {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #0d0d10;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow:
    0 20px 60px -15px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  overflow: hidden;
  transition: transform 0.4s var(--ease-out), opacity 0.4s;
  will-change: transform, opacity;
  cursor: grab;
}

.promo-card:nth-child(1) {
  z-index: 4;
}

.promo-card:nth-child(2) {
  z-index: 3;
  transform: translateX(20px) translateY(12px) scale(0.96);
  opacity: 0.8;
}

.promo-card:nth-child(3) {
  z-index: 2;
  transform: translateX(40px) translateY(24px) scale(0.92);
  opacity: 0.5;
}

.promo-card:nth-child(4) {
  z-index: 1;
  transform: translateX(60px) translateY(36px) scale(0.88);
  opacity: 0.25;
}

.promo-card-stack:hover .promo-card:nth-child(2) {
  transform: translateX(35px) translateY(20px) scale(0.96);
}

.promo-card-stack:hover .promo-card:nth-child(3) {
  transform: translateX(70px) translateY(40px) scale(0.92);
}

.promo-card-stack:hover .promo-card:nth-child(4) {
  transform: translateX(105px) translateY(60px) scale(0.88);
}

.promo-card:nth-child(n+5) {
  opacity: 0;
  pointer-events: none;
}

.promo-card__label {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 100px;
  padding: 0.35rem 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  white-space: nowrap;
  color: #fff;
}

.promo-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

#why-section {
  background: var(--bg-2);
  padding: clamp(5rem, 10vh, 10rem) var(--gutter);
  display: flex;
  flex-direction: column;
  gap: 6rem;
}

/* Big stat display in why intro */
.why-stat-row {
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.why-stat-number {
  font-size: clamp(5rem, 10vw, 9rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--text);
}

.why-stat-unit {
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.02em;
}

.why-intro {
  max-width: 900px;
}

.why-intro .section-title {
  font-size: clamp(2rem, 4vw, 3.25rem);
}

.why-intro .section-title em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.65);
}

.why-intro-desc {
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  color: var(--text-muted);
  line-height: 1.75;
  margin-top: 1.5rem;
  max-width: 60ch;
}

.why-compare-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0;
  align-items: stretch;
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  max-width: var(--max-w);
}

.compare-col {
  padding: 3rem 2.75rem;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.compare-col--without {
  background: rgba(255, 255, 255, 0.015);
}

.compare-col--with {
  background: rgba(200, 16, 46, 0.04);
  border-left: 1px solid rgba(200, 16, 46, 0.18);
  position: relative;
  overflow: hidden;
}

.compare-col--with::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent);
}

.compare-col__header {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.compare-col__header h3 {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.2;
}

.compare-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}

.compare-col--with .compare-icon {
  background: rgba(200, 16, 46, 0.1);
  border-color: rgba(200, 16, 46, 0.2);
}

.compare-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.compare-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.92rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.65);
}

.compare-col--with .compare-list li {
  color: rgba(255, 255, 255, 0.82);
}

.compare-x {
  color: rgba(255, 77, 109, 0.7);
  font-size: 1rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 0.1rem;
  line-height: 1;
}

.compare-check {
  color: #4ade80;
  font-size: 1rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 0.1rem;
  line-height: 1;
}

.compare-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1rem;
  background: var(--bg-2);
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
}

.compare-vs {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: var(--bg-3);
  border: 1px solid var(--border-2);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

.why-process {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.process-header {
  text-align: left;
  max-width: 700px;
}

.why-process-title {
  font-size: clamp(2rem, 4vw, 3.25rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0.5rem 0 1rem;
  line-height: 1.05;
}

.process-subtitle {
  color: var(--text-muted);
  font-size: 1rem;
}

/* New horizontal-numbered layout */
.process-timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  width: 100%;
}

@media (min-width: 900px) {
  .process-timeline {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
  }
}

/* Horizontal connector line behind the number row — desktop only */
.process-line {
  display: none;
}

.process-step {
  background: transparent;
  border: none;
  border-top: 1px solid var(--border);
  border-right: 1px solid var(--border);
  padding: 2.5rem 2.25rem 2.75rem;
  display: flex;
  flex-direction: column;
  gap: 0;
  transition: background 0.35s var(--ease-out);
  position: relative;
  z-index: 1;
  text-align: left;
}

.process-step:last-child {
  border-right: none;
}

.process-step::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: transparent;
  transition: background 0.35s var(--ease-out);
}

.process-step:hover {
  background: rgba(255, 255, 255, 0.02);
}

.process-step:hover::before {
  background: var(--accent);
}

/* Large display number */
.process-step__num {
  display: block;
  font-size: 4rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
  color: rgba(255, 255, 255, 0.07);
  margin-bottom: 1.5rem;
  transition: color 0.35s;
  font-variant-numeric: tabular-nums;
}

.process-step:hover .process-step__num {
  color: rgba(200, 16, 46, 0.25);
}

.process-step__icon-wrapper {
  width: 48px;
  height: 48px;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-dim);
  border-radius: 10px;
  transition: background 0.35s, box-shadow 0.35s;
}

.process-step:hover .process-step__icon-wrapper {
  background: rgba(200, 16, 46, 0.18);
  box-shadow: 0 0 24px rgba(200, 16, 46, 0.2);
}

.process-step__icon {
  color: var(--accent);
  transition: transform 0.35s var(--ease-out);
}

.process-step__icon svg {
  width: 22px;
  height: 22px;
}

.process-step:hover .process-step__icon {
  transform: scale(1.1);
}

.process-step__content h4 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  color: var(--text);
  letter-spacing: -0.01em;
}

.process-step__content p {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.65;
  max-width: 32ch;
}

@media (max-width: 899px) {
  .process-step {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .process-step:first-child {
    border-top: 1px solid var(--border);
  }
  .process-step:last-child {
    border-bottom: none;
  }
  .process-step__num {
    font-size: 3rem;
  }
}

.why-cta {
  display: flex;
  justify-content: flex-start;
}

.why-cta-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
  width: 100%;
  padding: 2.5rem 3rem;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.02);
}

.why-cta-text {
  font-size: clamp(1.2rem, 2vw, 1.6rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  max-width: 44ch;
}

@media (max-width: 700px) {
  .why-cta-content {
    flex-direction: column;
    align-items: flex-start;
    padding: 2rem 1.75rem;
  }
}

@media (max-width: 900px) {
  .why-compare-grid {
    grid-template-columns: 1fr;
    border-radius: 16px;
  }

  .compare-divider {
    display: none;
  }

  .compare-col--with {
    border-left: none;
    border-top: 1px solid rgba(200, 16, 46, 0.18);
  }

  .compare-col {
    padding: 2rem 1.75rem;
  }
}

#work {
  background: var(--bg);
  padding: clamp(4rem, 8vh, 8rem) var(--gutter);
}

/* Work section intro row — number + title inline */
#work .section-header {
  display: flex;
  align-items: flex-end;
  gap: 2rem;
  margin-bottom: clamp(2.5rem, 5vh, 4rem);
}

#work .section-eyebrow {
  margin-bottom: 0.75rem;
}

/* Premium framing for case image */
.case-img-wrap {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 16/10;
  background: var(--bg-2);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255,255,255,0.05);
}

.case-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.88) saturate(0.9);
  transition: filter 0.5s var(--ease-out), transform 0.5s var(--ease-out);
}

.case-slide:hover .case-img-wrap img {
  filter: brightness(0.96) saturate(1.05);
  transform: scale(1.015);
}

/* Larger, more authoritative case title */
.case-title {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--text);
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: clamp(2.5rem, 5vh, 4rem);
  gap: 1rem;
  flex-wrap: wrap;
}

.section-eyebrow {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.6rem;
}

.section-title {
  font-size: clamp(2rem, 4.5vw, 3.5rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.025em;
}

.section-link {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.2s;
  white-space: nowrap;
}

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

.section-link::after {
  content: '→';
  transition: transform 0.2s;
}

.section-link:hover::after {
  transform: translateX(4px);
}

.cases-slider {
  position: relative;
}

.case-slide {
  display: none;
  grid-template-columns: 55% 1fr;
  gap: 3.5rem;
  align-items: center;
  opacity: 0;
}

.case-slide.active {
  display: grid;
  animation: caseFadeInSoft 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes caseFadeInSoft {
  0% {
    opacity: 0;
    transform: translateX(30px) scale(0.98);
    filter: blur(4px);
  }

  100% {
    opacity: 1;
    transform: translateX(0) scale(1);
    filter: blur(0);
  }
}

@media (max-width: 860px) {
  .case-slide {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* .case-img-wrap and img styles above, near #work section */

.case-img-label {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(11, 11, 13, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  border-radius: 100px;
  padding: 0.3rem 0.8rem;
}

.case-img-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #fff;
  background: var(--accent);
  border-radius: 100px;
  padding: 0.25rem 0.7rem;
}

.case-info {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  justify-content: center;
}

.case-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.case-badge {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(200, 16, 46, 0.1);
  border: 1px solid rgba(200, 16, 46, 0.25);
  border-radius: 100px;
  padding: 0.18rem 0.6rem;
}

.case-year {
  font-size: 0.65rem;
  color: var(--text-muted);
}

.case-client {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-left: auto;
}

/* .case-title styles above, near #work section */

.case-psr {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
}

@media (max-width: 580px) {
  .case-psr {
    grid-template-columns: 1fr;
  }
}

.psr-card {
  background: rgba(25, 25, 30, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: border-color 0.25s, background 0.25s;
}

.psr-card:hover {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(30, 30, 38, 0.6);
}

.psr-card__head {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.psr-card__icon {
  font-size: 0.85rem;
  line-height: 1;
}

.psr-card__label {
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.psr-card__text {
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text);
  font-weight: 500;
}

.psr-card--problema {
  border-top: 2px solid rgba(200, 16, 46, 0.5);
}

.psr-card--solucion {
  border-top: 2px solid rgba(59, 130, 246, 0.5);
}

.psr-card--resultado {
  border-top: 2px solid rgba(34, 197, 94, 0.5);
}

.psr-card--problema .psr-card__label {
  color: rgba(200, 16, 46, 0.8);
}

.psr-card--solucion .psr-card__label {
  color: rgba(96, 165, 250, 0.9);
}

.psr-card--resultado .psr-card__label {
  color: rgba(74, 222, 128, 0.9);
}

.case-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.25rem;
}

.case-link {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  border-bottom: 1px solid var(--border-2);
  padding-bottom: 2px;
  transition: color 0.2s, border-color 0.2s;
}

.case-link:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.cases-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.cases-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border-2);
  border: none;
  cursor: pointer;
  padding: 0;
  position: relative;
  transition: background 0.2s, transform 0.2s, width 0.3s;
}

/* Expand touch/click target to WCAG 44×44px minimum */
.cases-dot::before {
  content: '';
  position: absolute;
  inset: -19px;
}

.cases-dot.active {
  background: var(--accent);
  width: 20px;
  border-radius: 3px;
}

.cases-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(25, 25, 30, 0.8);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 1rem;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  z-index: 2;
}

.cases-arrow:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.cases-arrow--prev {
  left: -18px;
}

.cases-arrow--next {
  right: -18px;
}

@media (max-width: 860px) {
  .cases-arrow {
    display: none;
  }
}

#services-section {
  background: var(--bg-2);
  padding: clamp(4rem, 8vh, 8rem) var(--gutter);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

/* Services — compact 2x2 card grid */
.services-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: clamp(2rem, 4vh, 3rem);
}

.svc-card {
  padding: 1.5rem 1.75rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg-2);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  transition: border-color 0.2s, background 0.2s;
}

.svc-card:hover {
  border-color: rgba(200, 16, 46, 0.35);
  background: rgba(255, 255, 255, 0.025);
}

.svc-card__icon {
  width: 36px;
  height: 36px;
  color: var(--accent);
  margin-bottom: 0.25rem;
}

.svc-card__icon svg {
  width: 100%;
  height: 100%;
}

.svc-card__title {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.svc-card__desc {
  font-size: 0.82rem;
  line-height: 1.6;
  color: var(--text-muted);
  flex: 1;
}

.svc-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.25rem;
}

.svc-card__tags span {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.2rem 0.5rem;
}

@media (max-width: 640px) {
  .services-cards {
    grid-template-columns: 1fr;
  }
}

html.light-mode .svc-card {
  background: var(--bg-2);
  border-color: var(--border);
}

html.light-mode .svc-card:hover {
  background: rgba(0, 0, 0, 0.02);
}

/* Services (legacy list — kept for admin dynamic rendering) — NOT a uniform card grid.
   Layout: 2-column on desktop, first service is large (featured row),
   rest are alternating numbered list items */
.services-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  margin-top: clamp(2rem, 4vh, 3.5rem);
}

.service-item {
  display: grid;
  grid-template-columns: 80px 1fr auto;
  gap: 0;
  align-items: center;
  border-bottom: 1px solid var(--border);
  transition: background 0.3s var(--ease-out);
  cursor: default;
  min-height: 100px;
  position: relative;
}

.service-item:last-child {
  border-bottom: none;
}

.service-item:hover {
  background: rgba(255, 255, 255, 0.02);
}

/* Left: large index number */
.service-item__num {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  border-right: 1px solid var(--border);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--accent);
  padding: 1.5rem 0;
  transition: background 0.3s;
}

.service-item:hover .service-item__num {
  background: var(--accent-dim);
}

/* Center: title + desc */
.service-item__body {
  padding: 1.75rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.service-item__title {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.service-item__desc {
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 56ch;
}

/* Right: feature tags */
.service-item__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 1.75rem 1.5rem 1.75rem 0;
  justify-content: flex-end;
  max-width: 220px;
}

.service-item__tag {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.22rem 0.65rem;
  border: 1px solid var(--border-2);
  border-radius: 100px;
  color: var(--text-muted);
  white-space: nowrap;
  transition: border-color 0.25s, color 0.25s;
}

.service-item:hover .service-item__tag {
  border-color: rgba(200, 16, 46, 0.3);
  color: rgba(255, 255, 255, 0.7);
}

@media (max-width: 860px) {
  .service-item {
    grid-template-columns: 56px 1fr;
  }
  .service-item__tags {
    display: none;
  }
  .service-item__num {
    font-size: 0.65rem;
  }
}

/* Keep legacy .service-card + .services-grid for dynamic loading fallback */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
  margin-top: clamp(2rem, 4vh, 3rem);
}

.service-card {
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-3);
  transition: border-color 0.3s, transform 0.3s var(--ease-out);
}

.service-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
}

.service-card__icon {
  width: 42px;
  height: 42px;
  margin-bottom: 1.25rem;
  background: rgba(200, 16, 46, 0.12);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  color: var(--accent);
}

.service-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  letter-spacing: -0.01em;
}

.service-card__desc {
  font-size: 0.82rem;
  line-height: 1.65;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.service-card__features {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.service-card__features li {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.2rem 0.6rem;
  border: 1px solid var(--border-2);
  border-radius: 100px;
  color: var(--text-muted);
}

#contact-strip {
  padding: clamp(5rem, 10vh, 9rem) var(--gutter);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0;
  position: relative;
  overflow: hidden;
  background: var(--bg);
}

/* Full-bleed red radial behind the CTA */
#contact-strip::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 120%, rgba(200, 16, 46, 0.22) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* Horizontal rule above */
#contact-strip::after {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(200, 16, 46, 0.4) 50%, transparent);
}

#contact-strip > * {
  position: relative;
  z-index: 1;
}

.cta-eyebrow {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.75rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.cta-eyebrow::before,
.cta-eyebrow::after {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: var(--accent);
  opacity: 0.5;
}

.cta-title {
  font-size: clamp(3rem, 7vw, 6rem);
  font-weight: 900;
  line-height: 0.95;
  letter-spacing: -0.04em;
  max-width: 12ch;
  margin-bottom: 1.75rem;
}

.cta-title em {
  font-style: italic;
  font-family: var(--font-serif);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.7);
}

.cta-sub {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 40ch;
  line-height: 1.65;
  margin-bottom: 3rem;
}

.cta-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.btn-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1.1rem 3rem;
  background: var(--accent);
  color: #fff;
  border-radius: 100px;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
  border: none;
  box-shadow: 0 8px 30px rgba(200, 16, 46, 0.4);
}

.btn-cta:hover {
  background: var(--accent-2);
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(200, 16, 46, 0.55);
}

.btn-cta:active {
  transform: translateY(0);
}

#site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

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

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--text);
}

#admin-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.5s var(--ease-out);
}

#admin-overlay.open {
  transform: translateX(0);
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--gutter);
  height: var(--header-h);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.admin-topbar-title {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
}

.admin-topbar-title span {
  color: var(--accent);
}

.admin-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--border);
  border: none;
  color: var(--text);
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.admin-close:hover {
  background: var(--accent);
}

.admin-body {
  display: flex;
  flex: 1;
  overflow: hidden;
}

.admin-sidebar {
  width: 220px;
  border-right: 1px solid var(--border);
  padding: 1.5rem 0;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  overflow-y: auto;
}

.admin-nav-label {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0 1.25rem;
  margin-bottom: 0.5rem;
  margin-top: 1.5rem;
}

.admin-nav-label:first-child {
  margin-top: 0;
}

.admin-nav-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.7rem 1.25rem;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 500;
  text-align: left;
  border-left: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.admin-nav-btn:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
}

.admin-nav-btn.active {
  color: var(--text);
  border-left-color: var(--accent);
  background: rgba(200, 16, 46, 0.06);
}

.admin-nav-icon {
  font-size: 1rem;
  min-width: 18px;
}

.admin-content {
  flex: 1;
  overflow-y: auto;
  padding: 2rem var(--gutter);
}

.admin-panel {
  display: none;
}

.admin-panel.active {
  display: block;
}

#auth-gate {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 400px;
}

.auth-card {
  width: 100%;
  max-width: 400px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem;
}

.auth-card h2 {
  font-size: 1.4rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}

.auth-card p {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 0.7rem 1rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 0.88rem;
  outline: none;
  transition: border-color 0.2s;
  appearance: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--accent);
}

.form-input:focus-visible,
.form-select:focus-visible,
.form-textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 0;
}

.form-textarea {
  min-height: 100px;
  resize: vertical;
}

.form-error {
  margin-top: 0.4rem;
  font-size: 0.72rem;
  color: var(--accent);
}

.auth-switch {
  margin-top: 1.25rem;
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.auth-switch span {
  color: var(--accent);
  cursor: pointer;
  font-weight: 600;
}

.auth-switch span:hover {
  text-decoration: underline;
}

.admin-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}

.admin-table th {
  background: var(--bg-3);
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}

.admin-table td {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  vertical-align: middle;
}

.admin-table tr:last-child td {
  border-bottom: none;
}

.admin-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.admin-table td:first-child {
  color: var(--text);
  font-weight: 500;
}

.table-actions {
  display: flex;
  gap: 0.5rem;
}

.btn-sm {
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  border: 1px solid transparent;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
  cursor: pointer;
}

.btn-sm.edit {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border-2);
  color: var(--text);
}

.btn-sm.edit:hover {
  border-color: #fff;
}

.btn-sm.delete {
  background: rgba(200, 16, 46, 0.1);
  border-color: rgba(200, 16, 46, 0.3);
  color: var(--accent);
}

.btn-sm.delete:hover {
  background: var(--accent);
  color: #fff;
}

.admin-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.75rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.admin-panel-title {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.role-badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 100px;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.role-badge.admin,
.role-badge.superadmin {
  background: rgba(200, 16, 46, 0.15);
  color: var(--accent);
  border: 1px solid rgba(200, 16, 46, 0.3);
}

.role-badge.user {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.role-badge.invitado {
  background: rgba(136, 136, 152, 0.1);
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.admin-modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.admin-modal-mask.open {
  opacity: 1;
  pointer-events: auto;
}

.admin-modal {
  background: var(--bg-2);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  padding: 2rem;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.95);
  transition: transform 0.25s var(--ease-out);
}

.admin-modal-mask.open .admin-modal {
  transform: scale(1);
}

.admin-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.admin-modal-title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.admin-user-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: rgba(200, 16, 46, 0.06);
  border: 1px solid rgba(200, 16, 46, 0.2);
  border-radius: var(--radius-sm);
  margin-bottom: 1.5rem;
}

.admin-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.admin-user-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
}

.admin-user-role-label {
  font-size: 0.65rem;
  color: var(--text-muted);
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat-card {
  padding: 1.25rem;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.stat-value {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  margin-bottom: 0.25rem;
  color: var(--text);
}

.stat-label {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.toggle-wrap {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
}

.toggle-input {
  width: 36px;
  height: 20px;
  background: var(--border-2);
  border-radius: 20px;
  position: relative;
  transition: background 0.2s;
  flex-shrink: 0;
  cursor: pointer;
  border: none;
  appearance: none;
  -webkit-appearance: none;
}

.toggle-input::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.2s;
}

.toggle-input:checked {
  background: var(--accent);
}

.toggle-input:checked::after {
  transform: translateX(16px);
}

.toggle-label {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.admin-alert {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  margin-bottom: 1rem;
  display: none;
}

.admin-alert.show {
  display: block;
}

.admin-alert.success {
  background: rgba(34, 197, 94, 0.1);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.admin-alert.error {
  background: rgba(200, 16, 46, 0.1);
  color: var(--accent);
  border: 1px solid rgba(200, 16, 46, 0.2);
}

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  to {
    opacity: 0.6;
  }
}

@keyframes scrollPulse {

  0%,
  100% {
    opacity: 0.4;
  }

  50% {
    opacity: 1;
  }
}


@media (max-width: 768px) {
  .header-nav a:not(.btn-pill) {
    display: none;
  }

  .hero-services {
    grid-template-columns: 1fr 1fr;
  }

  .admin-sidebar {
    width: 100%;
    height: auto;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .admin-body {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .hero-services {
    grid-template-columns: 1fr;
  }

  .admin-stats {
    grid-template-columns: repeat(2, 1fr);
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.divider {
  width: 100%;
  height: 1px;
  background: var(--border);
}

.mt-1 {
  margin-top: 1rem;
}

.mt-2 {
  margin-top: 2rem;
}

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

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

.full-width {
  width: 100%;
}

.whatsapp-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  background-color: #25D366;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
  z-index: 9999;
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s;
  text-decoration: none;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
}

.whatsapp-btn::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  background-color: #25D366;
  border-radius: 50%;
  z-index: -1;
  animation: whatsapp-pulse 2s infinite;
}

@keyframes whatsapp-pulse {
  0% {
    transform: scale(1);
    opacity: 0.6;
  }

  100% {
    transform: scale(1.5);
    opacity: 0;
  }
}

.project-modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.94);
  backdrop-filter: blur(12px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s cubic-bezier(0.19, 1, 0.22, 1);
  padding: clamp(1rem, 5vw, 4rem);
}

.project-modal-mask.open {
  opacity: 1;
  pointer-events: auto;
}

.project-modal-container {
  background: var(--bg-2);
  width: 100%;
  max-width: 1300px;
  max-height: 90vh;
  border-radius: 24px;
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: translateY(40px) scale(0.96);
  transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
  box-shadow: 0 50px 100px -20px rgba(0, 0, 0, 0.5);
}

.project-modal-mask.open .project-modal-container {
  transform: translateY(0) scale(1);
}

.modal-close-btn {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--text);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s, transform 0.3s;
  font-size: 1.2rem;
}

.modal-close-btn:hover {
  background: var(--accent);
  transform: rotate(90deg);
}

.project-modal-content {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  height: 100%;
  overflow: hidden;
}

@media (max-width: 1100px) {
  .project-modal-content {
    grid-template-columns: 1fr;
    overflow-y: auto;
  }
}

.project-modal-gallery {
  padding: 3rem;
  background: #0b0b0d;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.gallery-main {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 16px;
  overflow: hidden;
  background: #111;
  margin-bottom: 2rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.gallery-thumbs {
  display: flex;
  gap: 1.25rem;
  overflow-x: auto;
  padding: 0.5rem 0 1.5rem;
  scrollbar-width: none;
}

.gallery-thumbs::-webkit-scrollbar {
  display: none;
}

.gallery-thumb {
  width: 100px;
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  cursor: pointer;
  opacity: 0.4;
  transition: opacity 0.3s, border-color 0.3s, transform 0.3s;
  border: 2px solid transparent;
  flex-shrink: 0;
}

.gallery-thumb:hover,
.gallery-thumb.active {
  opacity: 1;
  border-color: var(--accent);
  transform: translateY(-2px);
}

.project-modal-info {
  padding: clamp(2rem, 5vw, 4rem);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.modal-meta {
  display: flex;
  gap: 2rem;
  margin-bottom: 2rem;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.modal-meta .cat {
  color: var(--accent);
  font-weight: 700;
}

.modal-meta .year {
  color: var(--text-muted);
}

.modal-title {
  font-size: clamp(2.2rem, 5vw, 4rem);
  font-weight: 800;
  line-height: 1.05;
  margin-bottom: 2.5rem;
  letter-spacing: -0.03em;
}

.modal-desc {
  font-size: 1.05rem;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 3.5rem;
  white-space: pre-wrap;
}

.modal-details {
  border-top: 1px solid var(--border);
  padding-top: 2rem;
  margin-top: auto;
}

.detail-item .label {
  font-size: 0.65rem;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
  display: block;
}

.detail-item .val {
  font-size: 1.1rem;
  font-weight: 600;
}

#reviews {
  padding: clamp(4rem, 8vh, 7rem) var(--gutter);
  background: var(--bg);
}

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.5rem;
  margin-top: 2.5rem;
}

.review-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s var(--ease-out), border-color 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
}

.review-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: 0 24px 50px -15px rgba(0, 0, 0, 0.5);
}

/* Giant decorative quote mark */
.review-card::before {
  content: '\201C';
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  font-family: var(--font-serif);
  font-size: 8rem;
  line-height: 1;
  color: rgba(255, 255, 255, 0.03);
  pointer-events: none;
  user-select: none;
}

/* Star rating row */
.review-stars {
  display: flex;
  gap: 3px;
  margin-bottom: 1.25rem;
}

.review-star {
  color: #f59e0b;
  font-size: 0.75rem;
}

.review-content {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 2rem;
  flex-grow: 1;
  position: relative;
}

.review-author {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.review-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-3);
  overflow: hidden;
  border: 2px solid var(--border-2);
  flex-shrink: 0;
}

.review-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.author-info .name {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 0.2rem;
  letter-spacing: -0.01em;
}

.author-info .role {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.mobile-mockup-wrapper {
  display: none;

}

.mobile-mockup {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.mobile-mockup__frame {
  position: relative;
  width: 180px;
  height: 320px;
  background: #18181f;
  border-radius: 32px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 30px 60px -10px rgba(0, 0, 0, 0.7),
    0 0 40px rgba(200, 16, 46, 0.08);
  overflow: hidden;
  padding: 10px 8px;
}

.mobile-mockup__notch {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 100px;
  z-index: 5;
}

.mobile-mockup__screen {
  width: 100%;
  height: 100%;
  border-radius: 24px;
  overflow: hidden;
  position: relative;
  background: #0b0b0d;
}

.mobile-mockup__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  display: block;
}

.mobile-mockup__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 60%, rgba(11, 11, 13, 0.6) 100%);
  pointer-events: none;
}

.mobile-mockup__btn {
  position: absolute;
  right: -4px;
  top: 80px;
  width: 3px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
}

.mobile-mockup__badge {
  margin-top: 1rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 100px;
  padding: 0.3rem 0.8rem;
}

.mobile-mockup__badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 6px #22c55e;
  flex-shrink: 0;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.4;
  }
}

@media (max-width: 768px) {

  #hero {
    height: auto;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
  }

  .ide-wrapper {
    display: none;
  }

  .hero-ambient-glow::before {
    bottom: -20%;
    left: -10%;
    width: 120vw;
    background: radial-gradient(ellipse, rgba(200, 16, 46, 0.14) 0%, transparent 65%);
  }

  .hero-ambient-glow::after {
    display: none;
  }

  .hero-content {
    position: relative;
    inset: auto;
    justify-content: flex-start;
    align-items: flex-start;
    padding: calc(var(--header-h) + 1.5rem) var(--gutter) 1rem;
    z-index: 2;
  }

  .mobile-mockup-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    padding-bottom: 2rem;
    position: relative;
    z-index: 2;
  }

  .hero-title {
    font-size: clamp(2.6rem, 12vw, 4rem);
    line-height: 0.93;
    margin-bottom: 1rem;
  }

  .hero-subtitle {
    font-size: clamp(0.95rem, 3.5vw, 1.2rem);
    margin-bottom: 1.75rem;
  }

  .hero-services {
    grid-template-columns: 1fr 1fr;
    max-width: 100%;
  }

  .hero-service-item:nth-child(2) {
    border-right: none;
  }

  .hero-service-item:nth-child(3) {
    border-right: 1px solid var(--border);
    border-top: 1px solid var(--border);
  }

  .hero-service-item:nth-child(4) {
    border-right: none;
    border-top: 1px solid var(--border);
  }

  .promo-cards-wrapper {
    height: 320px;
  }

  .promo-card-stack {
    width: min(340px, 85vw);
    height: 260px;
  }

  .promo-card:nth-child(2) {
    transform: translateX(12px) translateY(8px) scale(0.96);
  }

  .promo-card:nth-child(3) {
    transform: translateX(24px) translateY(16px) scale(0.92);
  }

  .promo-card:nth-child(4) {
    transform: translateX(36px) translateY(24px) scale(0.88);
  }

  .promo-card-stack:hover .promo-card:nth-child(2) {
    transform: translateX(20px) translateY(12px) scale(0.96);
  }

  .promo-card-stack:hover .promo-card:nth-child(3) {
    transform: translateX(40px) translateY(24px) scale(0.92);
  }

  .promo-card-stack:hover .promo-card:nth-child(4) {
    transform: translateX(60px) translateY(36px) scale(0.88);
  }

  .promo-content {
    max-width: 100%;
  }

  .promo-description {
    font-size: 1rem;
    margin-bottom: 1.75rem;
  }

  #why-section {
    gap: 3.5rem;
    padding: clamp(3rem, 8vh, 6rem) var(--gutter);
  }

  .why-compare-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .compare-divider {
    display: none;
  }

  .process-timeline {
    grid-template-columns: 1fr !important;
  }

  .process-line {
    display: none !important;
  }

  .case-slide {
    grid-template-columns: 1fr !important;
    gap: 1.5rem;
  }

  .case-img-wrap {
    aspect-ratio: 16/9;
  }

  .case-psr {
    grid-template-columns: 1fr !important;
    gap: 0.5rem;
  }

  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: clamp(1.5rem, 4vh, 2.5rem);
  }

  .section-title {
    font-size: clamp(1.8rem, 8vw, 2.5rem);
  }
}

/* ─── Light Mode Overrides ──────────────────────────────────────────── */

html.light-mode .problem-card {
  border-color: var(--border);
}

html.light-mode .problem-card:hover {
  background: var(--bg-2);
}

html.light-mode .problems-grid {
  border-color: var(--border);
}

html.light-mode .compare-col--without {
  background: var(--bg-2);
}

html.light-mode .compare-col--with {
  background: rgba(200, 16, 46, 0.03);
}

html.light-mode .compare-icon {
  background: var(--bg-3);
  border-color: var(--border);
}

html.light-mode .why-compare-grid {
  border-color: var(--border);
}

html.light-mode .services-list {
  border-color: var(--border);
}

html.light-mode .service-item {
  border-color: var(--border);
}

html.light-mode .service-item:hover {
  background: var(--bg-2);
}

html.light-mode .compare-list li {
  color: var(--text);
}

html.light-mode .process-step__icon-wrapper {
  background: var(--bg-2);
  border-color: var(--border-2);
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.04);
}

html.light-mode .psr-card {
  background: var(--bg-2);
  border-color: var(--border);
}

html.light-mode .psr-card:hover {
  background: var(--bg-3);
  border-color: var(--border-2);
}

html.light-mode .promo-card {
  background: var(--bg-3);
  border-color: var(--border);
  box-shadow: 0 20px 60px -15px rgba(0, 0, 0, 0.12);
}

html.light-mode .project-modal-gallery {
  background: var(--bg);
}

html.light-mode .btn-sm.edit {
  background: var(--bg-3);
}

html.light-mode .admin-table tr:hover td {
  background: var(--bg-3);
}

html.light-mode .admin-nav-btn:hover {
  background: var(--bg-3);
}

/* Hero always dark regardless of mode */
html.light-mode #hero {
  background: #0B0B0D;
}

/* Typography — hardcoded rgba(255,255,255,...) overrides */
html.light-mode .section-eyebrow {
  color: var(--text-muted);
}

html.light-mode .cta-title em {
  color: var(--text-muted);
}

html.light-mode .modal-desc {
  color: var(--text-muted);
}

html.light-mode .review-content {
  color: var(--text);
}

html.light-mode .process-step__num {
  color: rgba(0, 0, 0, 0.06);
}

html.light-mode .mobile-mockup__badge {
  color: var(--text-muted);
  background: rgba(0, 0, 0, 0.04);
  border-color: var(--border);
}

html.light-mode .btn-cta-secondary {
  border-color: var(--border-2);
}

html.light-mode .btn-cta-secondary:hover {
  border-color: rgba(0, 0, 0, 0.25);
}

/* Case slider / review cards */
html.light-mode .review-card {
  background: var(--bg-2);
  border-color: var(--border);
}

html.light-mode .review-card:hover {
  border-color: var(--border-2);
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.1);
}

/* ─── Hero CTA row ─────────────────────────────────────────── */
.hero-cta-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
  pointer-events: auto;
}

.hero-cta-primary {
  font-size: 1rem;
  padding: 0.85rem 1.75rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 9999px;
  padding: 0.7rem 1.4rem;
  transition: color 0.2s, border-color 0.2s;
  white-space: nowrap;
  pointer-events: auto;
}

.btn-ghost:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
}

/* Hero service items — now <a> tags */
.hero-service-item {
  display: block;
  text-decoration: none;
  cursor: pointer;
}

.btn-cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  border: 1px solid var(--border-2);
  border-radius: 9999px;
  padding: 0.6rem 1.4rem;
  transition: color 0.2s, border-color 0.2s;
}

.btn-cta-secondary:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.3);
}

/* ─── Skeleton loaders ──────────────────────────────────────── */
@keyframes shimmer {
  0%   { background-position: -600px 0; }
  100% { background-position: 600px 0; }
}

.skeleton {
  background: linear-gradient(
    90deg,
    rgba(255,255,255,0.04) 25%,
    rgba(255,255,255,0.09) 50%,
    rgba(255,255,255,0.04) 75%
  );
  background-size: 600px 100%;
  animation: shimmer 1.4s ease-in-out infinite;
  border-radius: 6px;
}

.skeleton-slide {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  padding: 2rem var(--gutter);
  width: 100%;
}

.skeleton-img {
  aspect-ratio: 4/3;
  border-radius: var(--radius);
}

.skeleton-info {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding-top: 1rem;
}

.skeleton-tag {
  height: 20px;
  width: 80px;
}

.skeleton-h {
  height: 36px;
  width: 70%;
}

.skeleton-p {
  height: 14px;
  width: 100%;
}

.skeleton-p.short {
  width: 60%;
}

.skeleton-review {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.skeleton-author-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.skeleton-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  flex-shrink: 0;
}

.skeleton-author-text {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
}

.skeleton-name {
  height: 12px;
  width: 120px;
}

.skeleton-role {
  height: 10px;
  width: 80px;
}

.skeleton-promo-card {
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
  z-index: 1;
}

/* ─── Promo stack fallback state ────────────────────────────── */
.promo-card-stack[data-empty="true"] {
  min-height: 260px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed var(--border-2);
  border-radius: var(--radius);
}

.promo-card-stack[data-empty="true"]::after {
  content: 'Proyectos próximamente';
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

/* ─── prefers-reduced-motion ────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .cursor {
    animation: none;
    opacity: 1;
  }

  .scroll-line {
    animation: none;
    opacity: 0.5;
  }

  .ide-gui .chart-card .status-dot {
    animation: none;
  }

  .skeleton {
    animation: none;
    background: rgba(255,255,255,0.06);
  }

  * {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
