:root {
  --bg: #020617;
  --bg-alt: #050816;
  --glass: rgba(15, 23, 42, 0.82);
  --primary: #ff0033;
  --primary-soft: rgba(255, 0, 51, 0.2);
  --primary-deep: #cc0029;
  --accent: #00b8d4;
  --accent-soft: rgba(0, 184, 212, 0.16);
  --accent-yellow: #facc15;
  --accent-purple: #a855f7;
  --text: #f9fafb;
  --text-muted: #9ca3af;
  --border-soft: rgba(148, 163, 184, 0.35);
  --radius-lg: 26px;
  --radius-md: 18px;
  --radius-sm: 999px;
  --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.9);
}

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

html,
body {
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: radial-gradient(circle at top, #020617 0, #020617 50%, #000 100%);
  overflow-x: hidden;
  scroll-behavior: smooth;
}

/* Fondo con glows */
.particles {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 10% 0%, rgba(255, 0, 51, 0.23), transparent 60%),
    radial-gradient(circle at 85% 10%, rgba(0, 184, 212, 0.24), transparent 60%),
    radial-gradient(circle at 15% 90%, rgba(168, 85, 247, 0.2), transparent 60%);
  opacity: 0.9;
  pointer-events: none;
  z-index: -2;
}

/* Layout base */
.layout {
  max-width: 1180px;
  margin: 0 auto;
  padding: 80px 24px;
}

/* HEADER */
.site-header {
  position: fixed;
  top: 0;
  inset-inline: 0;
  z-index: 40;
  backdrop-filter: blur(18px);
  background: linear-gradient(to bottom, rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0.6), transparent);
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
}

.logo {
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: none;
  text-decoration: none;
  font-size: 0.98rem;
  color: #ffffff;
}

.bimio-logo-ai{
  width: 25px;
  vertical-align: bottom;
  position: relative;
  top: 2px;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 26px;
  margin: 0;
  padding: 0;
}

nav a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.92rem;
  position: relative;
  padding-bottom: 4px;
  transition: color 0.2s ease-out;
}

nav a::after {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transition: width 0.2s ease-out;
}

nav a:hover::after,
nav a:focus-visible::after {
  width: 100%;
}

nav a.active {
  color: #fff;
}

nav a.active::after {
  width: 100%;
}

.menu-toggle {
  display: none;
  background: transparent;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-soft);
  color: var(--text);
  padding: 6px 10px;
  cursor: pointer;
}

/* MENÚ MÓVIL */
.mobile-menu {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at top, #020617 0, #020617 60%, #000 100%);
  transform: translateY(-100%);
  transition: transform 0.25s ease-out;
  z-index: 35;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-menu nav {
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: center;
}

.mobile-menu a {
  text-decoration: none;
  color: #e5e7eb;
  font-size: 1.05rem;
}

.mobile-menu.open {
  transform: translateY(0);
}

/* HERO VIDEO */
.hero {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 120px 24px 96px;
  overflow: hidden;
}

.hero-full {
  min-height: 100vh;
}

.hero-bg-carousel {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
  background: #010513;
}

.hero-bg-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.08) contrast(1.05) brightness(0.65);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 12% 10%, rgba(255, 0, 51, 0.25), transparent 50%),
    radial-gradient(circle at 85% 8%, rgba(0, 184, 212, 0.22), transparent 52%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.8), rgba(2, 6, 23, 0.94));
  pointer-events: none;
  z-index: 1;
}

.cursor-glow {
  position: absolute;
  width: 360px;
  height: 360px;
  background: radial-gradient(circle, rgba(255, 0, 51, 0.35), rgba(0, 184, 212, 0.08) 65%, transparent 70%);
  filter: blur(40px);
  opacity: 0;
  transform: translate(-50%, -50%);
  transition: opacity 0.25s ease-out;
  pointer-events: none;
  z-index: 1;
}

.cursor-glow-global {
  position: fixed;
  width: 420px;
  height: 420px;
  z-index: 5;
  mix-blend-mode: screen;
  filter: blur(52px);
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1100px;
  display: flex;
  justify-content: center;
}

.hero-copy {
  max-width: 760px;
  text-align: center;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}

.hero-title-stack {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 18px 26px;
}

.title-video {
  position: absolute;
  inset: -12px -20px;
  overflow: hidden;
  border-radius: 28px;
  opacity: 0.55;
  filter: blur(6px) saturate(1.25);
  mix-blend-mode: screen;
  pointer-events: none;
}

.title-video::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255, 0, 51, 0.3), rgba(0, 184, 212, 0.2));
  mix-blend-mode: soft-light;
}

.title-video-el {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-eyebrow {
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  color: #f9fafb;
}

.hero-copy h1 {
  font-size: clamp(2.8rem, 5vw, 4.3rem);
  margin: 0;
  letter-spacing: -0.04em;
  color: #f9fafb;
  text-shadow: 0 22px 60px rgba(0, 0, 0, 0.55);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-top: 10px;
}

.hero-actions .btn {
  min-width: 190px;
  padding: 14px 24px;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35);
}

.btn::after {
  content: "";
  position: absolute;
  width: 160px;
  height: 160px;
  inset: 0;
  margin: auto;
  translate: calc(var(--mx, 50%) - 50%) calc(var(--my, 50%) - 50%);
  background: radial-gradient(circle, rgba(255, 255, 255, 0.28), transparent 55%);
  opacity: 0;
  transition: opacity 0.2s ease-out;
  pointer-events: none;
  filter: blur(12px);
}

.btn:hover::after,
.btn:focus-visible::after {
  opacity: 0.5;
}

.btn:active::after,
.btn.btn-ignite::after {
  opacity: 0.9;
  filter: blur(16px);
}

.btn:active,
.btn.btn-ignite {
  box-shadow: 0 18px 50px rgba(255, 0, 51, 0.5), 0 12px 30px rgba(0, 0, 0, 0.28);
  transform: translateY(1px) scale(0.995);
}

/* BOTONES */
.btn {
  border-radius: 999px;
  padding: 10px 20px;
  font-size: 0.95rem;
  border: none;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  text-decoration: none;
}

.btn span {
  pointer-events: none;
}

.btn-primary {
  color: #f9fafb;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.22), transparent 60%),
    linear-gradient(120deg, var(--primary), #ff3366);
  box-shadow: 0 18px 40px rgba(255, 0, 51, 0.6);
}

.btn-primary::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 10% 0, rgba(255, 255, 255, 0.28), transparent 55%);
  opacity: 0;
  transition: opacity 0.18s ease-out;
}

.btn-primary:hover::before {
  opacity: 1;
}

.btn-ghost {
  color: #e5e7eb;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(148, 163, 184, 0.7);
}

.btn-outline {
  color: #e5e7eb;
  background: transparent;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.8);
  padding: 8px 16px;
  font-size: 0.9rem;
  cursor: pointer;
}

.btn-inline {
  color: var(--accent);
  text-decoration: none;
  font-size: 0.86rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
}

.btn-inline::after {
  content: "↗";
  font-size: 0.82rem;
  transition: transform 0.15s ease-out;
}

.btn-inline:hover::after {
  transform: translate(2px, -2px);
}

.btn-sub {
  font-size: 0.78rem;
  opacity: 0.78;
}

/* SECCIONES GENERALES */
.section-panel {
  position: relative;
  z-index: 1;
}

.section-header {
  margin-bottom: 32px;
}

.section-header h2 {
  font-size: 1.9rem;
  margin: 4px 0 6px;
}

.section-header p {
  margin: 0;
  color: var(--text-muted);
  max-width: 580px;
  font-size: 0.95rem;
}

.section-tag {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: rgba(148, 163, 184, 0.9);
}

/* Glass cards */
.glass {
  background:
    radial-gradient(circle at top left, rgba(255, 0, 51, 0.16), transparent 60%),
    radial-gradient(circle at bottom right, rgba(0, 184, 212, 0.16), transparent 60%),
    rgba(15, 23, 42, 0.92);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
}

/* AI CAROUSEL */
.ai-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
}

.ai-btn {
  border: 1px solid rgba(255, 255, 255, 0.32);
  background:
    linear-gradient(120deg, rgba(255, 0, 51, 0.14), rgba(0, 184, 212, 0.12)),
    rgba(15, 23, 42, 0.9);
  color: #fff9fb;
  border-radius: 999px;
  padding: 10px 18px;
  font-size: 0.95rem;
  cursor: pointer;
  transition:
    background 0.2s ease-out,
    border-color 0.2s ease-out,
    transform 0.15s ease-out,
    box-shadow 0.2s ease-out;
  position: relative;
  overflow: hidden;
}

.ai-btn:hover {
  border-color: rgba(255, 0, 51, 0.8);
  box-shadow:
    0 0 0 6px rgba(255, 0, 51, 0.08),
    0 18px 38px rgba(255, 0, 51, 0.28);
  transform: translateY(-1px);
}

.ai-btn.active {
  background: linear-gradient(120deg, #ff0033, #ff4d6d);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.9);
  box-shadow:
    0 0 0 10px rgba(255, 0, 51, 0.12),
    0 20px 46px rgba(255, 0, 51, 0.38);
}

.ai-video {
  margin-top: 18px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.ai-video iframe {
  width: 100%;
  height: min(70vh, 520px);
  display: block;
  border: 0;
  background: #000;
}

/* USE CASES */
/* 4 PASOS */
.steps-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px;
  align-items: flex-start;
  width: fit-content;
  max-width: 620px;
}

.step-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.5);
  color: #f9fafb;
  cursor: pointer;
  text-align: left;
  width: auto;
  max-width: 520px;
  align-self: flex-start;
  transition:
    border-color 0.2s ease-out,
    box-shadow 0.2s ease-out,
    transform 0.15s ease-out,
    background 0.2s ease-out;
}

.step-item:hover {
  border-color: rgba(255, 0, 51, 0.6);
  box-shadow: 0 16px 30px rgba(255, 0, 51, 0.2);
  transform: translateY(-1px);
}

.step-item.active {
  background: linear-gradient(120deg, rgba(255, 0, 51, 0.16), rgba(0, 184, 212, 0.12));
  border-color: rgba(255, 255, 255, 0.85);
  box-shadow: 0 20px 50px rgba(255, 0, 51, 0.22);
}

.step-item h4 {
  margin: 0 0 4px;
  font-size: 1rem;
}

.step-item p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.step-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(120deg, #ff0033, #ff4d6d);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 12px 30px rgba(255, 0, 51, 0.3);
}

/* Overlay video */
.video-overlay {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 80;
}

.video-overlay.open {
  display: flex;
}

.video-overlay-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
}

.video-overlay-content {
  position: relative;
  width: min(960px, 92vw);
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
  z-index: 1;
}

.video-overlay-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.5);
  background: rgba(15, 23, 42, 0.9);
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 2;
}

.video-overlay iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.section-hidden {
  display: none !important;
}

.section-slide-in {
  animation: slideInFromLeft 0.5s ease-out;
}

@keyframes slideInFromLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* OPEN TECH */
#open .section-header h2 {
  font-size: 2.8rem;
  letter-spacing: -0.02em;
  background: linear-gradient(120deg, #ff0033, #ff4d6d, #ff7aa2);
  -webkit-background-clip: text;
  color: transparent;
}

#open .section-header .section-tag {
  display: block;
  font-size: 2.2rem;
  letter-spacing: -0.01em;
  margin-bottom: 4px;
  background: linear-gradient(120deg, #ff7aa2, #ff0033);
  -webkit-background-clip: text;
  color: transparent;
   font-weight: 800;
}

#steps .section-tag,
#ai .section-tag,
#blog .section-tag,
#team .section-tag {
  display: inline-block;
  font-size: 1.6rem;
  letter-spacing: -0.01em;
  margin-bottom: 6px;
  background: linear-gradient(120deg, #ff7aa2, #ff0033);
  -webkit-background-clip: text;
  color: transparent;
  font-weight: 800;
}

#steps .section-header,
#ai .section-header,
#blog .section-header,
#team .section-header {
  text-align: center;
}

#steps .section-header h2,
#ai .section-header h2,
#blog .section-header h2,
#team .section-header h2 {
  display: inline-block;
  background: linear-gradient(120deg, #ff0033, #ff4d6d, #ff7aa2);
  -webkit-background-clip: text;
  color: transparent;
}

#blog .section-header h2 {
  font-size: 2.4rem;
  letter-spacing: -0.02em;
}

#blog .section-tag {
  font-size: 2rem;
}

#open .section-header {
  text-align: center;
}

#open .section-header p {
  margin-left: auto;
  margin-right: auto;
}

.open-carousel {
  position: relative;
  overflow: hidden;
  padding: 12px;
}
.open-carousel {
  position: relative;
  overflow: hidden;
  padding: 12px;
}

.open-carousel-track {
  display: flex;
  transition: transform 0.35s ease;
  width: 100%;
}

.open-card {
  min-width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 14px;
  align-items: flex-start;
}

.open-card-copy h3 {
  margin: 0 0 6px;
  color: #ffdee9;
}

.open-card-copy p {
  margin: 0;
  color: var(--text-muted);
}

.open-card-video {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: #000;
  width: 100%;
  aspect-ratio: 16 / 9;
  min-height: 420px;
}

.open-card-video iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.open-carousel-controls {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
}

.open-nav {
  pointer-events: all;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.9);
  color: #f9fafb;
  font-size: 1.4rem;
  cursor: pointer;
  box-shadow: var(--shadow-soft);
  transition: transform 0.15s ease, border-color 0.2s ease;
}

.open-nav:hover {
  transform: scale(1.05);
  border-color: rgba(255, 0, 51, 0.6);
}

/* BLOG */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 26px;
}

.blog-card {
  position: relative;
  border-radius: 18px;
  padding: 18px;
  background:
    radial-gradient(circle at top left, rgba(255, 0, 51, 0.18), transparent 60%),
    radial-gradient(circle at bottom right, rgba(0, 184, 212, 0.18), transparent 60%),
    rgba(15, 23, 42, 0.95);
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.blog-thumb-wrap {
  position: relative;
  margin: -18px -18px 12px;
  border-radius: 18px 18px 12px 12px;
  overflow: hidden;
  background: #0f172a;
}

.blog-thumb {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

.badge {
  position: absolute;
  top: 10px;
  left: 10px;
  display: inline-block;
  font-size: 0.76rem;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.blog-card h4 {
  margin: 4px 0 6px;
}

.blog-card span {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.blog-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.blog-readmore {
  margin-top: 6px;
}

/* TEAM */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.team-card {
  padding: 18px;
}

.team-card h3 {
  margin: 0 0 4px;
}

.team-card p {
  margin: 0;
  font-size: 0.9rem;
}

.team-bio {
  margin-top: 8px;
  color: var(--text-muted);
}

.team-avatar {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 10px;
  border: 2px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 16px 30px rgba(255, 0, 51, 0.2);
}

.team-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* CTA */
.cta-final {
  padding: 24px 22px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 18px;
}

.cta-text h2 {
  margin: 0 0 6px;
  font-size: 1.6rem;
}

.cta-text p {
  margin: 0;
  color: var(--text-muted);
  max-width: 460px;
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

/* FOOTER */
footer {
  border-top: 1px solid rgba(15, 23, 42, 0.7);
  background: radial-gradient(circle at top, #020617 0, #020617 60%, #000 100%);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1.1fr 1.1fr 1.1fr;
  gap: 24px;
  padding-top: 28px;
  padding-bottom: 24px;
}

.footer-grid h4 {
  margin: 0 0 6px;
  font-size: 0.9rem;
}

.footer-text {
  margin: 6px 0 0;
  color: var(--text-muted);
  font-size: 0.86rem;
}

.footer-grid a {
  font-size: 0.84rem;
  color: var(--text-muted);
  text-decoration: none;
}

/* REVEAL ANIMATION */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition:
    opacity 0.6s cubic-bezier(0.19, 1, 0.22, 1),
    transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* BLOG fade extra cuando vienes desde el menú */
.blog-fade {
  animation: blogFadeIn 0.6s ease forwards;
}

@keyframes blogFadeIn {
  from {
    opacity: 0;
    transform: translateY(34px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* RESPONSIVE */
@media (max-width: 960px) {
  .hero {
    padding: 110px 18px 90px;
  }

  .hero-copy h1 {
    font-size: clamp(2.4rem, 6.8vw, 3.6rem);
  }

  .giant-frame {
    grid-template-columns: minmax(0, 1fr);
  }

  .open-card {
    min-width: 100%;
  }
}

@media (max-width: 768px) {
  nav ul {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .layout {
    padding: 72px 16px;
  }

  .site-header .nav {
    padding-inline: 16px;
  }

  .hero {
    padding: 96px 16px 80px;
  }

  .hero-actions .btn {
    width: 100%;
    max-width: 320px;
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cta-final {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .layout {
    padding: 64px 16px;
  }

  .hero {
    padding: 86px 14px 72px;
  }

  .hero-eyebrow {
    font-size: 0.82rem;
    letter-spacing: 0.2em;
  }

  .hero-copy h1 {
    font-size: clamp(2.1rem, 9vw, 3rem);
  }

  .footer-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}
