/* ==========================================================================
   MAIN.CSS
   Sistema visual compartido para la plataforma de herramientas creativas
   ========================================================================== */

/* ==========================================================================
   1. VARIABLES GLOBALES
   ========================================================================== */

:root {
  /* Colores principales */
  --color-primary: #66ff8f;
  --color-primary-strong: #2dff70;
  --color-primary-soft: #b8ffc9;
  --color-secondary: #0da85a;
  --color-secondary-dark: #08713f;
  --color-fluorescent: #78ff4f;
  --color-lime: #b7ff38;

  /* Fondos */
  --color-background: #040c07;
  --color-background-soft: #07150d;
  --color-surface: rgba(11, 31, 19, 0.88);
  --color-surface-strong: #0d2116;
  --color-surface-light: rgba(24, 58, 37, 0.72);
  --color-overlay: rgba(0, 0, 0, 0.58);

  /* Textos */
  --color-text: #f4fff7;
  --color-text-soft: #c9ded0;
  --color-text-muted: #8eaa97;
  --color-text-dark: #07140c;

  /* Estados */
  --color-success: #4df58a;
  --color-warning: #ffd666;
  --color-error: #ff6f79;
  --color-info: #73d7ff;

  /* Bordes */
  --color-border: rgba(116, 255, 157, 0.18);
  --color-border-strong: rgba(116, 255, 157, 0.42);
  --color-border-fluorescent: rgba(120, 255, 79, 0.72);

  /* Gradientes */
  --gradient-primary: linear-gradient(
    135deg,
    #2dff70 0%,
    #6eff91 48%,
    #b7ff38 100%
  );
  --gradient-surface: linear-gradient(
    145deg,
    rgba(14, 42, 25, 0.96),
    rgba(6, 22, 13, 0.9)
  );
  --gradient-glow: radial-gradient(
    circle,
    rgba(102, 255, 143, 0.24),
    transparent 68%
  );
  --gradient-space: linear-gradient(
    135deg,
    rgba(102, 255, 143, 0.16),
    rgba(11, 168, 90, 0.04),
    rgba(183, 255, 56, 0.12)
  );

  /* Sombras */
  --shadow-small: 0 8px 22px rgba(0, 0, 0, 0.26);
  --shadow-medium: 0 20px 50px rgba(0, 0, 0, 0.38);
  --shadow-large: 0 30px 90px rgba(0, 0, 0, 0.48);
  --shadow-glow: 0 0 28px rgba(102, 255, 143, 0.28);
  --shadow-glow-strong: 0 0 46px rgba(120, 255, 79, 0.42);

  /* Tipografía */
  --font-primary:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  --font-display:
    "Segoe UI",
    Inter,
    ui-sans-serif,
    system-ui,
    sans-serif;

  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-md: 1.125rem;
  --font-size-lg: 1.375rem;
  --font-size-xl: 1.75rem;
  --font-size-2xl: 2.35rem;
  --font-size-3xl: clamp(2.8rem, 7vw, 5.8rem);

  /* Espaciado */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* Bordes redondeados */
  --radius-xs: 0.5rem;
  --radius-sm: 0.75rem;
  --radius-md: 1rem;
  --radius-lg: 1.5rem;
  --radius-xl: 2rem;
  --radius-pill: 999px;

  /* Contenedores */
  --content-width: 1240px;
  --content-width-small: 820px;
  --header-height: 78px;

  /* Transiciones */
  --transition-fast: 160ms ease;
  --transition-normal: 280ms ease;
  --transition-slow: 520ms cubic-bezier(0.2, 0.75, 0.25, 1);

  /* Capas */
  --z-background: -1;
  --z-base: 1;
  --z-header: 50;
  --z-dropdown: 80;
  --z-modal: 100;

  /* Publicidad */
  --ad-min-height: 90px;
  --ad-background: rgba(255, 255, 255, 0.025);
  --ad-border: rgba(255, 255, 255, 0.08);
}

/* ==========================================================================
   2. REINICIO Y BASE
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  color: var(--color-text);
  background:
    radial-gradient(
      circle at 20% 10%,
      rgba(40, 255, 104, 0.08),
      transparent 28rem
    ),
    radial-gradient(
      circle at 88% 30%,
      rgba(183, 255, 56, 0.08),
      transparent 32rem
    ),
    var(--color-background);
  font-family: var(--font-primary);
  font-size: var(--font-size-base);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: var(--z-background);
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.014) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.014) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: linear-gradient(to bottom, black, transparent 90%);
}

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

button,
input,
select,
textarea {
  font: inherit;
}

button,
select,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  border: 0;
}

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

p,
h1,
h2,
h3,
h4,
ul {
  margin-top: 0;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  line-height: 1.08;
  letter-spacing: -0.035em;
}

h1 {
  font-size: var(--font-size-3xl);
}

h2 {
  font-size: clamp(2rem, 5vw, 3.7rem);
}

h3 {
  font-size: clamp(1.4rem, 3vw, 2rem);
}

h4 {
  font-size: var(--font-size-lg);
}

::selection {
  color: var(--color-text-dark);
  background: var(--color-primary);
}

:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 4px;
}

/* ==========================================================================
   3. UTILIDADES GENERALES
   ========================================================================== */

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

.skip-link {
  position: fixed;
  top: var(--space-4);
  left: var(--space-4);
  z-index: calc(var(--z-modal) + 1);
  padding: var(--space-3) var(--space-5);
  color: var(--color-text-dark);
  background: var(--color-primary);
  border-radius: var(--radius-pill);
  font-weight: 800;
  transform: translateY(-160%);
  transition: transform var(--transition-fast);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-shell {
  position: relative;
  z-index: var(--z-base);
  min-height: 100vh;
}

.particle-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.95;
}

.section-heading {
  max-width: 850px;
  margin-bottom: var(--space-12);
}

.section-heading--center {
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.section-heading__eyebrow,
.hero__eyebrow {
  margin-bottom: var(--space-4);
  color: var(--color-primary);
  font-size: var(--font-size-sm);
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.section-heading p:not(.section-heading__eyebrow) {
  max-width: 720px;
  color: var(--color-text-soft);
}

.section-heading--center p:not(.section-heading__eyebrow) {
  margin-right: auto;
  margin-left: auto;
}

/* ==========================================================================
   4. CABECERA
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  min-height: var(--header-height);
  border-bottom: 1px solid var(--color-border);
  background: rgba(4, 12, 7, 0.78);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(calc(100% - 2rem), var(--content-width));
  min-height: var(--header-height);
  margin: 0 auto;
  gap: var(--space-6);
}

.site-brand {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  gap: var(--space-3);
}

.site-brand__logo {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  object-fit: contain;
  filter: drop-shadow(0 0 14px rgba(102, 255, 143, 0.32));
}

.site-brand__name {
  overflow: hidden;
  font-size: var(--font-size-md);
  font-weight: 900;
  letter-spacing: -0.035em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.site-nav a {
  position: relative;
  color: var(--color-text-soft);
  font-size: var(--font-size-sm);
  font-weight: 700;
  transition:
    color var(--transition-fast),
    transform var(--transition-fast);
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: -0.55rem;
  left: 0;
  height: 2px;
  content: "";
  background: var(--gradient-primary);
  border-radius: var(--radius-pill);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform var(--transition-normal);
}

.site-nav a:hover {
  color: var(--color-primary);
  transform: translateY(-2px);
}

.site-nav a:hover::after {
  transform: scaleX(1);
}

.site-header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.language-control select {
  min-height: 42px;
  padding: 0 var(--space-4);
  color: var(--color-text);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  cursor: pointer;
}

.language-control select:hover {
  border-color: var(--color-border-strong);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 0;
  cursor: pointer;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}

.menu-toggle span {
  display: block;
  width: 19px;
  height: 2px;
  margin: 4px auto;
  background: var(--color-primary);
  border-radius: var(--radius-pill);
}

.mobile-navigation {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto var(--space-4);
  padding: var(--space-4);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.mobile-navigation a {
  display: block;
  padding: var(--space-3) var(--space-4);
  color: var(--color-text-soft);
  border-radius: var(--radius-sm);
}

.mobile-navigation a:hover {
  color: var(--color-text-dark);
  background: var(--color-primary);
}

/* ==========================================================================
   5. BOTONES
   ========================================================================== */

.button {
  position: relative;
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  padding: 0 var(--space-6);
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  cursor: pointer;
  font-weight: 850;
  isolation: isolate;
  transition:
    transform var(--transition-normal),
    box-shadow var(--transition-normal),
    border-color var(--transition-normal),
    background var(--transition-normal);
}

.button::before {
  position: absolute;
  inset: -2px;
  z-index: -1;
  content: "";
  opacity: 0;
  background: var(--gradient-primary);
  filter: blur(18px);
  transition: opacity var(--transition-normal);
}

.button:hover {
  transform: translateY(-4px) scale(1.035);
}

.button:hover::before {
  opacity: 0.42;
}

.button--primary {
  color: var(--color-text-dark);
  background: var(--gradient-primary);
  box-shadow: var(--shadow-glow);
}

.button--primary:hover {
  box-shadow: var(--shadow-glow-strong);
}

.button--secondary {
  color: var(--color-text);
  background: rgba(255, 255, 255, 0.035);
  border-color: var(--color-border);
}

.button--secondary:hover {
  border-color: var(--color-border-strong);
  background: rgba(102, 255, 143, 0.07);
}

.button--space::after {
  position: absolute;
  inset: 0;
  content: "";
  background:
    radial-gradient(
      circle at 50% 130%,
      rgba(255, 255, 255, 0.72),
      transparent 40%
    );
  opacity: 0;
  transform: scale(0.75);
  transition:
    opacity var(--transition-normal),
    transform var(--transition-slow);
}

.button--space:hover::after {
  opacity: 0.36;
  transform: scale(1.35);
}

/* ==========================================================================
   6. HERO
   ========================================================================== */

.hero {
  display: grid;
  width: min(calc(100% - 2rem), var(--content-width));
  min-height: calc(100vh - var(--header-height));
  align-items: center;
  margin: 0 auto;
  padding: var(--space-16) 0 var(--space-20);
  grid-template-columns: minmax(0, 1.12fr) minmax(340px, 0.88fr);
  gap: var(--space-16);
}

.hero__content {
  position: relative;
  z-index: 2;
}

.hero h1 {
  max-width: 900px;
  margin-bottom: var(--space-6);
  background: linear-gradient(
    115deg,
    #ffffff 0%,
    #dffff0 45%,
    #7cff9d 72%,
    #b7ff38 100%
  );
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  text-wrap: balance;
}

.hero__description {
  max-width: 690px;
  margin-bottom: var(--space-8);
  color: var(--color-text-soft);
  font-size: clamp(1.05rem, 2vw, 1.3rem);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: var(--space-8);
  gap: var(--space-4);
}

.hero__features {
  display: flex;
  flex-wrap: wrap;
  padding: 0;
  margin-bottom: 0;
  list-style: none;
  gap: var(--space-3);
}

.hero__features li {
  padding: var(--space-2) var(--space-4);
  color: var(--color-primary-soft);
  background: rgba(102, 255, 143, 0.055);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  font-size: var(--font-size-sm);
  font-weight: 700;
}

.hero__visual {
  position: relative;
  display: grid;
  min-height: 520px;
  place-items: center;
}

.hero__visual::before {
  position: absolute;
  width: 440px;
  max-width: 100%;
  aspect-ratio: 1;
  content: "";
  background: var(--gradient-glow);
  border-radius: 50%;
  filter: blur(4px);
  animation: pulse-glow 6s ease-in-out infinite;
}

.hero-tool-preview {
  position: relative;
  display: grid;
  width: min(360px, 78vw);
  aspect-ratio: 1;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(
      135deg,
      rgba(102, 255, 143, 0.14),
      rgba(6, 18, 10, 0.88)
    );
  border: 1px solid var(--color-border-strong);
  border-radius: 38% 62% 64% 36% / 44% 32% 68% 56%;
  box-shadow:
    var(--shadow-large),
    inset 0 0 50px rgba(102, 255, 143, 0.06);
  animation:
    float-preview 7s ease-in-out infinite,
    morph-preview 12s ease-in-out infinite;
}

.hero-tool-preview::before,
.hero-tool-preview::after {
  position: absolute;
  content: "";
  border: 1px solid rgba(102, 255, 143, 0.24);
  border-radius: 50%;
}

.hero-tool-preview::before {
  width: 72%;
  height: 72%;
  animation: rotate-slow 15s linear infinite;
}

.hero-tool-preview::after {
  width: 45%;
  height: 45%;
  border-style: dashed;
  animation: rotate-reverse 10s linear infinite;
}

.hero-tool-preview__glow {
  position: absolute;
  width: 110px;
  height: 110px;
  background: var(--color-primary);
  border-radius: 50%;
  box-shadow:
    0 0 80px rgba(102, 255, 143, 0.58),
    0 0 130px rgba(183, 255, 56, 0.28);
  filter: blur(6px);
  opacity: 0.62;
}

.hero-tool-preview__label {
  position: relative;
  z-index: 2;
  font-weight: 900;
  letter-spacing: 0.22em;
  text-shadow: 0 0 18px rgba(102, 255, 143, 0.72);
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(1px);
}

.orb--one {
  top: 8%;
  left: 4%;
  width: 72px;
  height: 72px;
  background: rgba(102, 255, 143, 0.32);
  box-shadow: 0 0 48px rgba(102, 255, 143, 0.35);
  animation: orbit-one 9s ease-in-out infinite;
}

.orb--two {
  right: 6%;
  bottom: 14%;
  width: 44px;
  height: 44px;
  background: rgba(183, 255, 56, 0.42);
  box-shadow: 0 0 42px rgba(183, 255, 56, 0.4);
  animation: orbit-two 7s ease-in-out infinite;
}

.orb--three {
  top: 20%;
  right: 18%;
  width: 20px;
  height: 20px;
  background: var(--color-primary);
  box-shadow: 0 0 28px rgba(102, 255, 143, 0.72);
  animation: pulse-orb 4s ease-in-out infinite;
}

/* ==========================================================================
   7. PUBLICIDAD
   ========================================================================== */

.ad-slot {
  display: grid;
  width: min(calc(100% - 2rem), var(--content-width));
  min-height: var(--ad-min-height);
  place-items: center;
  margin: var(--space-6) auto;
  color: var(--color-text-muted);
  background: var(--ad-background);
  border: 1px dashed var(--ad-border);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-xs);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ad-slot--between-tools {
  margin-top: var(--space-16);
  margin-bottom: var(--space-16);
}

.ad-slot--bottom {
  margin-top: var(--space-20);
  margin-bottom: var(--space-20);
}

/* ==========================================================================
   8. CATEGORÍAS
   ========================================================================== */

.categories-section,
.tools-section,
.about-section {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto;
  padding: var(--space-20) 0;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-5);
}

.category-card {
  position: relative;
  min-height: 260px;
  padding: var(--space-8);
  overflow: hidden;
  background: var(--gradient-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-small);
  isolation: isolate;
  transition:
    transform var(--transition-slow),
    border-color var(--transition-normal),
    box-shadow var(--transition-normal);
}

.category-card::before {
  position: absolute;
  inset: auto -20% -55% auto;
  z-index: -1;
  width: 190px;
  height: 190px;
  content: "";
  background: var(--gradient-glow);
  border-radius: 50%;
  transition: transform var(--transition-slow);
}

.category-card::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  opacity: 0;
  background: var(--gradient-space);
  transition: opacity var(--transition-normal);
}

.category-card:hover {
  border-color: var(--color-border-fluorescent);
  box-shadow: var(--shadow-medium), var(--shadow-glow);
  transform: translateY(-10px) scale(1.025);
}

.category-card:hover::before {
  transform: scale(1.45);
}

.category-card:hover::after {
  opacity: 1;
}

.category-card__icon {
  display: grid;
  width: 62px;
  height: 62px;
  place-items: center;
  margin-bottom: var(--space-8);
  color: var(--color-text-dark);
  background: var(--gradient-primary);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-glow);
  font-size: var(--font-size-xl);
  font-weight: 900;
}

.category-card h3 {
  margin-bottom: var(--space-4);
}

.category-card p {
  color: var(--color-text-soft);
}

/* ==========================================================================
   9. HERRAMIENTAS
   ========================================================================== */

.tool-group + .tool-group {
  margin-top: var(--space-20);
}

.tool-group__heading {
  display: flex;
  align-items: center;
  margin-bottom: var(--space-8);
  gap: var(--space-4);
}

.tool-group__heading::after {
  height: 1px;
  flex: 1;
  content: "";
  background: linear-gradient(
    to right,
    var(--color-border-strong),
    transparent
  );
}

.tool-group__heading h3 {
  margin-bottom: 0;
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-5);
}

.tool-card {
  position: relative;
  display: flex;
  min-height: 280px;
  flex-direction: column;
  padding: var(--space-6);
  overflow: hidden;
  background:
    linear-gradient(
      145deg,
      rgba(12, 35, 21, 0.94),
      rgba(5, 17, 10, 0.88)
    );
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-small);
  isolation: isolate;
  transition:
    transform var(--transition-slow),
    border-color var(--transition-normal),
    box-shadow var(--transition-normal);
}

.tool-card::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  opacity: 0;
  background:
    radial-gradient(
      circle at 30% 20%,
      rgba(102, 255, 143, 0.15),
      transparent 48%
    ),
    linear-gradient(
      135deg,
      rgba(102, 255, 143, 0.09),
      transparent 55%
    );
  transition: opacity var(--transition-normal);
}

.tool-card::after {
  position: absolute;
  right: -50px;
  bottom: -70px;
  z-index: -1;
  width: 160px;
  height: 160px;
  content: "";
  background: var(--gradient-glow);
  border-radius: 50%;
  transition: transform var(--transition-slow);
}

.tool-card:hover {
  z-index: 2;
  border-color: var(--color-border-fluorescent);
  box-shadow:
    var(--shadow-large),
    0 0 35px rgba(102, 255, 143, 0.17);
  transform: translateY(-12px) scale(1.045);
}

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

.tool-card:hover::after {
  transform: scale(1.65);
}

.tool-card--featured {
  border-color: rgba(102, 255, 143, 0.48);
  box-shadow:
    var(--shadow-medium),
    0 0 30px rgba(102, 255, 143, 0.1);
}

.tool-card__badge {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  padding: var(--space-1) var(--space-3);
  color: var(--color-text-dark);
  background: var(--gradient-primary);
  border-radius: var(--radius-pill);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tool-card__icon {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  margin-bottom: var(--space-8);
  color: var(--color-primary);
  background: rgba(102, 255, 143, 0.07);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-sm);
  font-weight: 900;
  box-shadow: inset 0 0 24px rgba(102, 255, 143, 0.04);
}

.tool-card h4 {
  margin-bottom: var(--space-4);
}

.tool-card p {
  flex: 1;
  color: var(--color-text-soft);
}

.tool-card__action {
  display: inline-flex;
  align-items: center;
  margin-top: var(--space-5);
  color: var(--color-primary);
  font-size: var(--font-size-sm);
  font-weight: 850;
  gap: var(--space-2);
}

.tool-card__action::after {
  content: "→";
  transition: transform var(--transition-fast);
}

.tool-card:hover .tool-card__action::after {
  transform: translateX(6px);
}

/* ==========================================================================
   10. SECCIÓN ACERCA DE
   ========================================================================== */

.about-section__content {
  padding: clamp(2rem, 5vw, 4rem);
  background: var(--gradient-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-medium);
}

.about-section__content > p:not(.section-heading__eyebrow) {
  max-width: 800px;
  color: var(--color-text-soft);
  font-size: var(--font-size-md);
}

.trust-grid {
  display: grid;
  margin-top: var(--space-10);
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-5);
}

.trust-card {
  padding: var(--space-6);
  background: rgba(102, 255, 143, 0.035);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.trust-card h3 {
  margin-bottom: var(--space-3);
  color: var(--color-primary);
  font-size: var(--font-size-lg);
}

.trust-card p {
  margin-bottom: 0;
  color: var(--color-text-soft);
}

/* ==========================================================================
   11. FOOTER
   ========================================================================== */

.site-footer {
  position: relative;
  margin-top: var(--space-16);
  padding: var(--space-16) 0 var(--space-6);
  background:
    linear-gradient(
      to bottom,
      rgba(6, 19, 11, 0.7),
      rgba(3, 9, 5, 0.98)
    );
  border-top: 1px solid var(--color-border);
}

.site-footer__grid,
.site-footer__bottom {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1.45fr repeat(3, 1fr);
  gap: var(--space-10);
}

.site-footer__brand p {
  max-width: 360px;
  margin-top: var(--space-5);
  color: var(--color-text-muted);
}

.site-footer__column {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-3);
}

.site-footer__column h2 {
  margin-bottom: var(--space-2);
  font-size: var(--font-size-base);
  letter-spacing: 0;
}

.site-footer__column a {
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
  transition:
    color var(--transition-fast),
    transform var(--transition-fast);
}

.site-footer__column a:hover {
  color: var(--color-primary);
  transform: translateX(4px);
}

.site-footer__bottom {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-top: var(--space-12);
  padding-top: var(--space-6);
  color: var(--color-text-muted);
  border-top: 1px solid var(--color-border);
  font-size: var(--font-size-xs);
  gap: var(--space-6);
}

.site-footer__bottom p {
  margin-bottom: 0;
}

.site-footer__monetization-note {
  max-width: 420px;
  text-align: right;
}

.noscript-message {
  position: fixed;
  right: var(--space-4);
  bottom: var(--space-4);
  z-index: var(--z-modal);
  max-width: 420px;
  padding: var(--space-4);
  color: var(--color-text-dark);
  background: var(--color-warning);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-medium);
  font-weight: 800;
}

/* ==========================================================================
   12. COMPONENTES COMPARTIDOS PARA PRODUCTOS
   ========================================================================== */

.product-page {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto;
  padding: var(--space-12) 0 var(--space-20);
}

.product-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: var(--space-10);
  gap: var(--space-6);
}

.product-header__content {
  max-width: 800px;
}

.product-header__description {
  color: var(--color-text-soft);
  font-size: var(--font-size-md);
}

.back-to-portfolio {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0 var(--space-5);
  color: var(--color-primary);
  background: rgba(102, 255, 143, 0.045);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  font-size: var(--font-size-sm);
  font-weight: 800;
  white-space: nowrap;
  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast),
    background var(--transition-fast);
}

.back-to-portfolio:hover {
  background: rgba(102, 255, 143, 0.1);
  border-color: var(--color-border-strong);
  transform: translateY(-2px);
}

.tool-interface {
  display: grid;
  padding: clamp(1.25rem, 4vw, 2.5rem);
  background: var(--gradient-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-medium);
  gap: var(--space-8);
}

.upload-zone {
  display: grid;
  min-height: 260px;
  place-items: center;
  padding: var(--space-8);
  color: var(--color-text-soft);
  background:
    linear-gradient(
      135deg,
      rgba(102, 255, 143, 0.045),
      rgba(102, 255, 143, 0.015)
    );
  border: 2px dashed var(--color-border-strong);
  border-radius: var(--radius-xl);
  cursor: pointer;
  text-align: center;
  transition:
    border-color var(--transition-normal),
    background var(--transition-normal),
    transform var(--transition-normal);
}

.upload-zone:hover,
.upload-zone.is-dragging {
  color: var(--color-text);
  background: rgba(102, 255, 143, 0.075);
  border-color: var(--color-primary);
  transform: translateY(-3px);
}

.control-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-5);
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.form-field label {
  color: var(--color-text-soft);
  font-size: var(--font-size-sm);
  font-weight: 800;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 48px;
  padding: 0 var(--space-4);
  color: var(--color-text);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition:
    border-color var(--transition-fast),
    box-shadow var(--transition-fast);
}

.form-field textarea {
  min-height: 140px;
  padding-top: var(--space-4);
  resize: vertical;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(102, 255, 143, 0.08);
  outline: none;
}

.result-panel {
  padding: var(--space-6);
  background: rgba(0, 0, 0, 0.16);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.result-panel__preview {
  display: grid;
  min-height: 280px;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(
      45deg,
      rgba(255, 255, 255, 0.025) 25%,
      transparent 25%,
      transparent 75%,
      rgba(255, 255, 255, 0.025) 75%
    );
  background-position: 0 0, 12px 12px;
  background-size: 24px 24px;
  border-radius: var(--radius-md);
}

.status-message {
  padding: var(--space-4);
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
}

.status-message--success {
  color: var(--color-success);
  background: rgba(77, 245, 138, 0.08);
  border: 1px solid rgba(77, 245, 138, 0.22);
}

.status-message--error {
  color: var(--color-error);
  background: rgba(255, 111, 121, 0.08);
  border: 1px solid rgba(255, 111, 121, 0.22);
}

.status-message--info {
  color: var(--color-info);
  background: rgba(115, 215, 255, 0.08);
  border: 1px solid rgba(115, 215, 255, 0.22);
}

.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: grid;
  place-items: center;
  background: rgba(2, 8, 4, 0.74);
  backdrop-filter: blur(12px);
}

.loading-spinner {
  width: 54px;
  height: 54px;
  border: 4px solid rgba(102, 255, 143, 0.15);
  border-top-color: var(--color-primary);
  border-radius: 50%;
  animation: spin 0.85s linear infinite;
}

/* ==========================================================================
   13. ANIMACIONES
   ========================================================================== */

@keyframes float-preview {
  0%,
  100% {
    transform: translateY(0) rotate(-1deg);
  }

  50% {
    transform: translateY(-18px) rotate(1deg);
  }
}

@keyframes morph-preview {
  0%,
  100% {
    border-radius: 38% 62% 64% 36% / 44% 32% 68% 56%;
  }

  50% {
    border-radius: 59% 41% 38% 62% / 35% 62% 38% 65%;
  }
}

@keyframes pulse-glow {
  0%,
  100% {
    opacity: 0.7;
    transform: scale(0.94);
  }

  50% {
    opacity: 1;
    transform: scale(1.08);
  }
}

@keyframes rotate-slow {
  to {
    transform: rotate(360deg);
  }
}

@keyframes rotate-reverse {
  to {
    transform: rotate(-360deg);
  }
}

@keyframes orbit-one {
  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(42px, 30px);
  }
}

@keyframes orbit-two {
  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(-36px, -24px);
  }
}

@keyframes pulse-orb {
  0%,
  100% {
    opacity: 0.6;
    transform: scale(0.85);
  }

  50% {
    opacity: 1;
    transform: scale(1.25);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ==========================================================================
   14. RESPONSIVE BÁSICO
   ========================================================================== */

@media (max-width: 1100px) {
  .site-nav {
    gap: var(--space-5);
  }

  .hero {
    grid-template-columns: 1fr 0.75fr;
    gap: var(--space-10);
  }

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

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

@media (max-width: 820px) {
  :root {
    --header-height: 70px;
  }

  .site-nav {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .hero {
    min-height: auto;
    padding-top: var(--space-12);
    grid-template-columns: 1fr;
  }

  .hero__content {
    text-align: center;
  }

  .hero__description {
    margin-right: auto;
    margin-left: auto;
  }

  .hero__actions,
  .hero__features {
    justify-content: center;
  }

  .hero__visual {
    min-height: 390px;
  }

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

  .trust-grid {
    grid-template-columns: 1fr;
  }

  .product-header {
    flex-direction: column;
  }

  .control-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  :root {
    --space-20: 4rem;
    --space-16: 3rem;
  }

  .site-header__inner {
    gap: var(--space-3);
  }

  .site-brand__name {
    max-width: 150px;
    font-size: var(--font-size-base);
  }

  .site-brand__logo {
    width: 42px;
    height: 42px;
  }

  .language-control select {
    min-height: 40px;
    padding: 0 var(--space-3);
  }

  .hero {
    width: min(calc(100% - 1.25rem), var(--content-width));
    padding-top: var(--space-10);
  }

  .hero__actions {
    flex-direction: column;
  }

  .hero__actions .button {
    width: 100%;
  }

  .hero__visual {
    min-height: 330px;
  }

  .hero-tool-preview {
    width: min(290px, 82vw);
  }

  .categories-section,
  .tools-section,
  .about-section,
  .product-page {
    width: min(calc(100% - 1.25rem), var(--content-width));
  }

  .category-grid,
  .tools-grid,
  .site-footer__grid {
    grid-template-columns: 1fr;
  }

  .category-card {
    min-height: 220px;
  }

  .tool-card {
    min-height: 250px;
  }

  .site-footer__bottom {
    flex-direction: column;
  }

  .site-footer__monetization-note {
    text-align: left;
  }

  .ad-slot {
    width: min(calc(100% - 1.25rem), var(--content-width));
    min-height: 72px;
  }

  .about-section__content,
  .tool-interface {
    border-radius: var(--radius-lg);
  }
}

/* ==========================================================================
   15. ACCESIBILIDAD Y REDUCCIÓN DE MOVIMIENTO
   ========================================================================== */

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

  .particle-canvas {
    display: none;
  }
}

/* ==========================================================================
   16. IMPRESIÓN
   ========================================================================== */

@media print {
  .particle-canvas,
  .site-header,
  .ad-slot,
  .site-footer,
  .button,
  .back-to-portfolio {
    display: none !important;
  }

  body {
    color: #000;
    background: #fff;
  }

  .tool-interface,
  .result-panel,
  .about-section__content {
    color: #000;
    background: #fff;
    border: 1px solid #ccc;
    box-shadow: none;
  }
}

/* ==========================================================================
   SELECTORES: OPCIONES VISIBLES
   ========================================================================== */

.form-field select,
.language-control select {
  color: var(--color-text);
  background-color: var(--color-surface-strong);
}

.form-field select option,
.language-control select option {
  color: var(--color-text);
  background-color: var(--color-surface-strong);
}



/* ==========================================================================
   MAIN.CSS
   Sistema visual compartido para la plataforma de herramientas creativas
   ========================================================================== */

/* ==========================================================================
   1. VARIABLES GLOBALES
   ========================================================================== */

:root {
  /* Colores principales */
  --color-primary: #66ff8f;
  --color-primary-strong: #2dff70;
  --color-primary-soft: #b8ffc9;
  --color-secondary: #0da85a;
  --color-secondary-dark: #08713f;
  --color-fluorescent: #78ff4f;
  --color-lime: #b7ff38;

  /* Fondos */
  --color-background: #040c07;
  --color-background-soft: #07150d;
  --color-surface: rgba(11, 31, 19, 0.88);
  --color-surface-strong: #0d2116;
  --color-surface-light: rgba(24, 58, 37, 0.72);
  --color-overlay: rgba(0, 0, 0, 0.58);

  /* Textos */
  --color-text: #f4fff7;
  --color-text-soft: #c9ded0;
  --color-text-muted: #8eaa97;
  --color-text-dark: #07140c;

  /* Estados */
  --color-success: #4df58a;
  --color-warning: #ffd666;
  --color-error: #ff6f79;
  --color-info: #73d7ff;

  /* Bordes */
  --color-border: rgba(116, 255, 157, 0.18);
  --color-border-strong: rgba(116, 255, 157, 0.42);
  --color-border-fluorescent: rgba(120, 255, 79, 0.72);

  /* Gradientes */
  --gradient-primary: linear-gradient(
    135deg,
    #2dff70 0%,
    #6eff91 48%,
    #b7ff38 100%
  );
  --gradient-surface: linear-gradient(
    145deg,
    rgba(14, 42, 25, 0.96),
    rgba(6, 22, 13, 0.9)
  );
  --gradient-glow: radial-gradient(
    circle,
    rgba(102, 255, 143, 0.24),
    transparent 68%
  );
  --gradient-space: linear-gradient(
    135deg,
    rgba(102, 255, 143, 0.16),
    rgba(11, 168, 90, 0.04),
    rgba(183, 255, 56, 0.12)
  );

  /* Sombras */
  --shadow-small: 0 8px 22px rgba(0, 0, 0, 0.26);
  --shadow-medium: 0 20px 50px rgba(0, 0, 0, 0.38);
  --shadow-large: 0 30px 90px rgba(0, 0, 0, 0.48);
  --shadow-glow: 0 0 28px rgba(102, 255, 143, 0.28);
  --shadow-glow-strong: 0 0 46px rgba(120, 255, 79, 0.42);

  /* Tipografía */
  --font-primary:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  --font-display:
    "Segoe UI",
    Inter,
    ui-sans-serif,
    system-ui,
    sans-serif;

  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-md: 1.125rem;
  --font-size-lg: 1.375rem;
  --font-size-xl: 1.75rem;
  --font-size-2xl: 2.35rem;
  --font-size-3xl: clamp(2.8rem, 7vw, 5.8rem);

  /* Espaciado */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* Bordes redondeados */
  --radius-xs: 0.5rem;
  --radius-sm: 0.75rem;
  --radius-md: 1rem;
  --radius-lg: 1.5rem;
  --radius-xl: 2rem;
  --radius-pill: 999px;

  /* Contenedores */
  --content-width: 1240px;
  --content-width-small: 820px;
  --header-height: 78px;

  /* Transiciones */
  --transition-fast: 160ms ease;
  --transition-normal: 280ms ease;
  --transition-slow: 520ms cubic-bezier(0.2, 0.75, 0.25, 1);

  /* Capas */
  --z-background: -1;
  --z-base: 1;
  --z-header: 50;
  --z-dropdown: 80;
  --z-modal: 100;

  /* Publicidad */
  --ad-min-height: 90px;
  --ad-background: rgba(255, 255, 255, 0.025);
  --ad-border: rgba(255, 255, 255, 0.08);
}

/* ==========================================================================
   2. REINICIO Y BASE
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  color: var(--color-text);
  background:
    radial-gradient(
      circle at 20% 10%,
      rgba(40, 255, 104, 0.08),
      transparent 28rem
    ),
    radial-gradient(
      circle at 88% 30%,
      rgba(183, 255, 56, 0.08),
      transparent 32rem
    ),
    var(--color-background);
  font-family: var(--font-primary);
  font-size: var(--font-size-base);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: var(--z-background);
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.014) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.014) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: linear-gradient(to bottom, black, transparent 90%);
}

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

button,
input,
select,
textarea {
  font: inherit;
}

button,
select,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  border: 0;
}

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

p,
h1,
h2,
h3,
h4,
ul {
  margin-top: 0;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  line-height: 1.08;
  letter-spacing: -0.035em;
}

h1 {
  font-size: var(--font-size-3xl);
}

h2 {
  font-size: clamp(2rem, 5vw, 3.7rem);
}

h3 {
  font-size: clamp(1.4rem, 3vw, 2rem);
}

h4 {
  font-size: var(--font-size-lg);
}

::selection {
  color: var(--color-text-dark);
  background: var(--color-primary);
}

:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 4px;
}

/* ==========================================================================
   3. UTILIDADES GENERALES
   ========================================================================== */

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

.skip-link {
  position: fixed;
  top: var(--space-4);
  left: var(--space-4);
  z-index: calc(var(--z-modal) + 1);
  padding: var(--space-3) var(--space-5);
  color: var(--color-text-dark);
  background: var(--color-primary);
  border-radius: var(--radius-pill);
  font-weight: 800;
  transform: translateY(-160%);
  transition: transform var(--transition-fast);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-shell {
  position: relative;
  z-index: var(--z-base);
  min-height: 100vh;
}

.particle-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.95;
}

.section-heading {
  max-width: 850px;
  margin-bottom: var(--space-12);
}

.section-heading--center {
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.section-heading__eyebrow,
.hero__eyebrow {
  margin-bottom: var(--space-4);
  color: var(--color-primary);
  font-size: var(--font-size-sm);
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.section-heading p:not(.section-heading__eyebrow) {
  max-width: 720px;
  color: var(--color-text-soft);
}

.section-heading--center p:not(.section-heading__eyebrow) {
  margin-right: auto;
  margin-left: auto;
}

/* ==========================================================================
   4. CABECERA
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  min-height: var(--header-height);
  border-bottom: 1px solid var(--color-border);
  background: rgba(4, 12, 7, 0.78);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(calc(100% - 2rem), var(--content-width));
  min-height: var(--header-height);
  margin: 0 auto;
  gap: var(--space-6);
}

.site-brand {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  gap: var(--space-3);
}

.site-brand__logo {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  object-fit: contain;
  filter: drop-shadow(0 0 14px rgba(102, 255, 143, 0.32));
}

.site-brand__name {
  overflow: hidden;
  font-size: var(--font-size-md);
  font-weight: 900;
  letter-spacing: -0.035em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.site-nav a {
  position: relative;
  color: var(--color-text-soft);
  font-size: var(--font-size-sm);
  font-weight: 700;
  transition:
    color var(--transition-fast),
    transform var(--transition-fast);
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: -0.55rem;
  left: 0;
  height: 2px;
  content: "";
  background: var(--gradient-primary);
  border-radius: var(--radius-pill);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform var(--transition-normal);
}

.site-nav a:hover {
  color: var(--color-primary);
  transform: translateY(-2px);
}

.site-nav a:hover::after {
  transform: scaleX(1);
}

.site-header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.language-control select {
  min-height: 42px;
  padding: 0 var(--space-4);
  color: var(--color-text);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  cursor: pointer;
}

.language-control select:hover {
  border-color: var(--color-border-strong);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 0;
  cursor: pointer;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}

.menu-toggle span {
  display: block;
  width: 19px;
  height: 2px;
  margin: 4px auto;
  background: var(--color-primary);
  border-radius: var(--radius-pill);
}

.mobile-navigation {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto var(--space-4);
  padding: var(--space-4);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.mobile-navigation a {
  display: block;
  padding: var(--space-3) var(--space-4);
  color: var(--color-text-soft);
  border-radius: var(--radius-sm);
}

.mobile-navigation a:hover {
  color: var(--color-text-dark);
  background: var(--color-primary);
}

/* ==========================================================================
   5. BOTONES
   ========================================================================== */

.button {
  position: relative;
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  padding: 0 var(--space-6);
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  cursor: pointer;
  font-weight: 850;
  isolation: isolate;
  transition:
    transform var(--transition-normal),
    box-shadow var(--transition-normal),
    border-color var(--transition-normal),
    background var(--transition-normal);
}

.button::before {
  position: absolute;
  inset: -2px;
  z-index: -1;
  content: "";
  opacity: 0;
  background: var(--gradient-primary);
  filter: blur(18px);
  transition: opacity var(--transition-normal);
}

.button:hover {
  transform: translateY(-4px) scale(1.035);
}

.button:hover::before {
  opacity: 0.42;
}

.button--primary {
  color: var(--color-text-dark);
  background: var(--gradient-primary);
  box-shadow: var(--shadow-glow);
}

.button--primary:hover {
  box-shadow: var(--shadow-glow-strong);
}

.button--secondary {
  color: var(--color-text);
  background: rgba(255, 255, 255, 0.035);
  border-color: var(--color-border);
}

.button--secondary:hover {
  border-color: var(--color-border-strong);
  background: rgba(102, 255, 143, 0.07);
}

.button--space::after {
  position: absolute;
  inset: 0;
  content: "";
  background:
    radial-gradient(
      circle at 50% 130%,
      rgba(255, 255, 255, 0.72),
      transparent 40%
    );
  opacity: 0;
  transform: scale(0.75);
  transition:
    opacity var(--transition-normal),
    transform var(--transition-slow);
}

.button--space:hover::after {
  opacity: 0.36;
  transform: scale(1.35);
}

/* ==========================================================================
   6. HERO
   ========================================================================== */

.hero {
  display: grid;
  width: min(calc(100% - 2rem), var(--content-width));
  min-height: calc(100vh - var(--header-height));
  align-items: center;
  margin: 0 auto;
  padding: var(--space-16) 0 var(--space-20);
  grid-template-columns: minmax(0, 1.12fr) minmax(340px, 0.88fr);
  gap: var(--space-16);
}

.hero__content {
  position: relative;
  z-index: 2;
}

.hero h1 {
  max-width: 900px;
  margin-bottom: var(--space-6);
  background: linear-gradient(
    115deg,
    #ffffff 0%,
    #dffff0 45%,
    #7cff9d 72%,
    #b7ff38 100%
  );
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  text-wrap: balance;
}

.hero__description {
  max-width: 690px;
  margin-bottom: var(--space-8);
  color: var(--color-text-soft);
  font-size: clamp(1.05rem, 2vw, 1.3rem);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: var(--space-8);
  gap: var(--space-4);
}

.hero__features {
  display: flex;
  flex-wrap: wrap;
  padding: 0;
  margin-bottom: 0;
  list-style: none;
  gap: var(--space-3);
}

.hero__features li {
  padding: var(--space-2) var(--space-4);
  color: var(--color-primary-soft);
  background: rgba(102, 255, 143, 0.055);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  font-size: var(--font-size-sm);
  font-weight: 700;
}

.hero__visual {
  position: relative;
  display: grid;
  min-height: 520px;
  place-items: center;
}

.hero__visual::before {
  position: absolute;
  width: 440px;
  max-width: 100%;
  aspect-ratio: 1;
  content: "";
  background: var(--gradient-glow);
  border-radius: 50%;
  filter: blur(4px);
  animation: pulse-glow 6s ease-in-out infinite;
}

.hero-tool-preview {
  position: relative;
  display: grid;
  width: min(360px, 78vw);
  aspect-ratio: 1;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(
      135deg,
      rgba(102, 255, 143, 0.14),
      rgba(6, 18, 10, 0.88)
    );
  border: 1px solid var(--color-border-strong);
  border-radius: 38% 62% 64% 36% / 44% 32% 68% 56%;
  box-shadow:
    var(--shadow-large),
    inset 0 0 50px rgba(102, 255, 143, 0.06);
  animation:
    float-preview 7s ease-in-out infinite,
    morph-preview 12s ease-in-out infinite;
}

.hero-tool-preview::before,
.hero-tool-preview::after {
  position: absolute;
  content: "";
  border: 1px solid rgba(102, 255, 143, 0.24);
  border-radius: 50%;
}

.hero-tool-preview::before {
  width: 72%;
  height: 72%;
  animation: rotate-slow 15s linear infinite;
}

.hero-tool-preview::after {
  width: 45%;
  height: 45%;
  border-style: dashed;
  animation: rotate-reverse 10s linear infinite;
}

.hero-tool-preview__glow {
  position: absolute;
  width: 110px;
  height: 110px;
  background: var(--color-primary);
  border-radius: 50%;
  box-shadow:
    0 0 80px rgba(102, 255, 143, 0.58),
    0 0 130px rgba(183, 255, 56, 0.28);
  filter: blur(6px);
  opacity: 0.62;
}

.hero-tool-preview__label {
  position: relative;
  z-index: 2;
  font-weight: 900;
  letter-spacing: 0.22em;
  text-shadow: 0 0 18px rgba(102, 255, 143, 0.72);
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(1px);
}

.orb--one {
  top: 8%;
  left: 4%;
  width: 72px;
  height: 72px;
  background: rgba(102, 255, 143, 0.32);
  box-shadow: 0 0 48px rgba(102, 255, 143, 0.35);
  animation: orbit-one 9s ease-in-out infinite;
}

.orb--two {
  right: 6%;
  bottom: 14%;
  width: 44px;
  height: 44px;
  background: rgba(183, 255, 56, 0.42);
  box-shadow: 0 0 42px rgba(183, 255, 56, 0.4);
  animation: orbit-two 7s ease-in-out infinite;
}

.orb--three {
  top: 20%;
  right: 18%;
  width: 20px;
  height: 20px;
  background: var(--color-primary);
  box-shadow: 0 0 28px rgba(102, 255, 143, 0.72);
  animation: pulse-orb 4s ease-in-out infinite;
}

/* ==========================================================================
   7. PUBLICIDAD
   ========================================================================== */

.ad-slot {
  display: grid;
  width: min(calc(100% - 2rem), var(--content-width));
  min-height: var(--ad-min-height);
  place-items: center;
  margin: var(--space-6) auto;
  color: var(--color-text-muted);
  background: var(--ad-background);
  border: 1px dashed var(--ad-border);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-xs);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ad-slot--between-tools {
  margin-top: var(--space-16);
  margin-bottom: var(--space-16);
}

.ad-slot--bottom {
  margin-top: var(--space-20);
  margin-bottom: var(--space-20);
}

/* ==========================================================================
   8. CATEGORÍAS
   ========================================================================== */

.categories-section,
.tools-section,
.about-section {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto;
  padding: var(--space-20) 0;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-5);
}

.category-card {
  position: relative;
  min-height: 260px;
  padding: var(--space-8);
  overflow: hidden;
  background: var(--gradient-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-small);
  isolation: isolate;
  transition:
    transform var(--transition-slow),
    border-color var(--transition-normal),
    box-shadow var(--transition-normal);
}

.category-card::before {
  position: absolute;
  inset: auto -20% -55% auto;
  z-index: -1;
  width: 190px;
  height: 190px;
  content: "";
  background: var(--gradient-glow);
  border-radius: 50%;
  transition: transform var(--transition-slow);
}

.category-card::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  opacity: 0;
  background: var(--gradient-space);
  transition: opacity var(--transition-normal);
}

.category-card:hover {
  border-color: var(--color-border-fluorescent);
  box-shadow: var(--shadow-medium), var(--shadow-glow);
  transform: translateY(-10px) scale(1.025);
}

.category-card:hover::before {
  transform: scale(1.45);
}

.category-card:hover::after {
  opacity: 1;
}

.category-card__icon {
  display: grid;
  width: 62px;
  height: 62px;
  place-items: center;
  margin-bottom: var(--space-8);
  color: var(--color-text-dark);
  background: var(--gradient-primary);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-glow);
  font-size: var(--font-size-xl);
  font-weight: 900;
}

.category-card h3 {
  margin-bottom: var(--space-4);
}

.category-card p {
  color: var(--color-text-soft);
}

/* ==========================================================================
   9. HERRAMIENTAS
   ========================================================================== */

.tool-group + .tool-group {
  margin-top: var(--space-20);
}

.tool-group__heading {
  display: flex;
  align-items: center;
  margin-bottom: var(--space-8);
  gap: var(--space-4);
}

.tool-group__heading::after {
  height: 1px;
  flex: 1;
  content: "";
  background: linear-gradient(
    to right,
    var(--color-border-strong),
    transparent
  );
}

.tool-group__heading h3 {
  margin-bottom: 0;
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-5);
}

.tool-card {
  position: relative;
  display: flex;
  min-height: 280px;
  flex-direction: column;
  padding: var(--space-6);
  overflow: hidden;
  background:
    linear-gradient(
      145deg,
      rgba(12, 35, 21, 0.94),
      rgba(5, 17, 10, 0.88)
    );
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-small);
  isolation: isolate;
  transition:
    transform var(--transition-slow),
    border-color var(--transition-normal),
    box-shadow var(--transition-normal);
}

.tool-card::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  opacity: 0;
  background:
    radial-gradient(
      circle at 30% 20%,
      rgba(102, 255, 143, 0.15),
      transparent 48%
    ),
    linear-gradient(
      135deg,
      rgba(102, 255, 143, 0.09),
      transparent 55%
    );
  transition: opacity var(--transition-normal);
}

.tool-card::after {
  position: absolute;
  right: -50px;
  bottom: -70px;
  z-index: -1;
  width: 160px;
  height: 160px;
  content: "";
  background: var(--gradient-glow);
  border-radius: 50%;
  transition: transform var(--transition-slow);
}

.tool-card:hover {
  z-index: 2;
  border-color: var(--color-border-fluorescent);
  box-shadow:
    var(--shadow-large),
    0 0 35px rgba(102, 255, 143, 0.17);
  transform: translateY(-12px) scale(1.045);
}

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

.tool-card:hover::after {
  transform: scale(1.65);
}

.tool-card--featured {
  border-color: rgba(102, 255, 143, 0.48);
  box-shadow:
    var(--shadow-medium),
    0 0 30px rgba(102, 255, 143, 0.1);
}

.tool-card__badge {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  padding: var(--space-1) var(--space-3);
  color: var(--color-text-dark);
  background: var(--gradient-primary);
  border-radius: var(--radius-pill);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tool-card__icon {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  margin-bottom: var(--space-8);
  color: var(--color-primary);
  background: rgba(102, 255, 143, 0.07);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-sm);
  font-weight: 900;
  box-shadow: inset 0 0 24px rgba(102, 255, 143, 0.04);
}

.tool-card h4 {
  margin-bottom: var(--space-4);
}

.tool-card p {
  flex: 1;
  color: var(--color-text-soft);
}

.tool-card__action {
  display: inline-flex;
  align-items: center;
  margin-top: var(--space-5);
  color: var(--color-primary);
  font-size: var(--font-size-sm);
  font-weight: 850;
  gap: var(--space-2);
}

.tool-card__action::after {
  content: "→";
  transition: transform var(--transition-fast);
}

.tool-card:hover .tool-card__action::after {
  transform: translateX(6px);
}

/* ==========================================================================
   10. SECCIÓN ACERCA DE
   ========================================================================== */

.about-section__content {
  padding: clamp(2rem, 5vw, 4rem);
  background: var(--gradient-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-medium);
}

.about-section__content > p:not(.section-heading__eyebrow) {
  max-width: 800px;
  color: var(--color-text-soft);
  font-size: var(--font-size-md);
}

.trust-grid {
  display: grid;
  margin-top: var(--space-10);
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-5);
}

.trust-card {
  padding: var(--space-6);
  background: rgba(102, 255, 143, 0.035);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.trust-card h3 {
  margin-bottom: var(--space-3);
  color: var(--color-primary);
  font-size: var(--font-size-lg);
}

.trust-card p {
  margin-bottom: 0;
  color: var(--color-text-soft);
}

/* ==========================================================================
   11. FOOTER
   ========================================================================== */

.site-footer {
  position: relative;
  margin-top: var(--space-16);
  padding: var(--space-16) 0 var(--space-6);
  background:
    linear-gradient(
      to bottom,
      rgba(6, 19, 11, 0.7),
      rgba(3, 9, 5, 0.98)
    );
  border-top: 1px solid var(--color-border);
}

.site-footer__grid,
.site-footer__bottom {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1.45fr repeat(3, 1fr);
  gap: var(--space-10);
}

.site-footer__brand p {
  max-width: 360px;
  margin-top: var(--space-5);
  color: var(--color-text-muted);
}

.site-footer__column {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-3);
}

.site-footer__column h2 {
  margin-bottom: var(--space-2);
  font-size: var(--font-size-base);
  letter-spacing: 0;
}

.site-footer__column a {
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
  transition:
    color var(--transition-fast),
    transform var(--transition-fast);
}

.site-footer__column a:hover {
  color: var(--color-primary);
  transform: translateX(4px);
}

.site-footer__bottom {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-top: var(--space-12);
  padding-top: var(--space-6);
  color: var(--color-text-muted);
  border-top: 1px solid var(--color-border);
  font-size: var(--font-size-xs);
  gap: var(--space-6);
}

.site-footer__bottom p {
  margin-bottom: 0;
}

.site-footer__monetization-note {
  max-width: 420px;
  text-align: right;
}

.noscript-message {
  position: fixed;
  right: var(--space-4);
  bottom: var(--space-4);
  z-index: var(--z-modal);
  max-width: 420px;
  padding: var(--space-4);
  color: var(--color-text-dark);
  background: var(--color-warning);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-medium);
  font-weight: 800;
}

/* ==========================================================================
   12. COMPONENTES COMPARTIDOS PARA PRODUCTOS
   ========================================================================== */

.product-page {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto;
  padding: var(--space-12) 0 var(--space-20);
}

.product-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: var(--space-10);
  gap: var(--space-6);
}

.product-header__content {
  max-width: 800px;
}

.product-header__description {
  color: var(--color-text-soft);
  font-size: var(--font-size-md);
}

.back-to-portfolio {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0 var(--space-5);
  color: var(--color-primary);
  background: rgba(102, 255, 143, 0.045);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  font-size: var(--font-size-sm);
  font-weight: 800;
  white-space: nowrap;
  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast),
    background var(--transition-fast);
}

.back-to-portfolio:hover {
  background: rgba(102, 255, 143, 0.1);
  border-color: var(--color-border-strong);
  transform: translateY(-2px);
}

.tool-interface {
  display: grid;
  padding: clamp(1.25rem, 4vw, 2.5rem);
  background: var(--gradient-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-medium);
  gap: var(--space-8);
}

.upload-zone {
  display: grid;
  min-height: 260px;
  place-items: center;
  padding: var(--space-8);
  color: var(--color-text-soft);
  background:
    linear-gradient(
      135deg,
      rgba(102, 255, 143, 0.045),
      rgba(102, 255, 143, 0.015)
    );
  border: 2px dashed var(--color-border-strong);
  border-radius: var(--radius-xl);
  cursor: pointer;
  text-align: center;
  transition:
    border-color var(--transition-normal),
    background var(--transition-normal),
    transform var(--transition-normal);
}

.upload-zone:hover,
.upload-zone.is-dragging {
  color: var(--color-text);
  background: rgba(102, 255, 143, 0.075);
  border-color: var(--color-primary);
  transform: translateY(-3px);
}

.control-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-5);
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.form-field label {
  color: var(--color-text-soft);
  font-size: var(--font-size-sm);
  font-weight: 800;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 48px;
  padding: 0 var(--space-4);
  color: var(--color-text);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition:
    border-color var(--transition-fast),
    box-shadow var(--transition-fast);
}

.form-field textarea {
  min-height: 140px;
  padding-top: var(--space-4);
  resize: vertical;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(102, 255, 143, 0.08);
  outline: none;
}

.result-panel {
  padding: var(--space-6);
  background: rgba(0, 0, 0, 0.16);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.result-panel__preview {
  display: grid;
  min-height: 280px;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(
      45deg,
      rgba(255, 255, 255, 0.025) 25%,
      transparent 25%,
      transparent 75%,
      rgba(255, 255, 255, 0.025) 75%
    );
  background-position: 0 0, 12px 12px;
  background-size: 24px 24px;
  border-radius: var(--radius-md);
}

.status-message {
  padding: var(--space-4);
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
}

.status-message--success {
  color: var(--color-success);
  background: rgba(77, 245, 138, 0.08);
  border: 1px solid rgba(77, 245, 138, 0.22);
}

.status-message--error {
  color: var(--color-error);
  background: rgba(255, 111, 121, 0.08);
  border: 1px solid rgba(255, 111, 121, 0.22);
}

.status-message--info {
  color: var(--color-info);
  background: rgba(115, 215, 255, 0.08);
  border: 1px solid rgba(115, 215, 255, 0.22);
}

.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: grid;
  place-items: center;
  background: rgba(2, 8, 4, 0.74);
  backdrop-filter: blur(12px);
}

.loading-spinner {
  width: 54px;
  height: 54px;
  border: 4px solid rgba(102, 255, 143, 0.15);
  border-top-color: var(--color-primary);
  border-radius: 50%;
  animation: spin 0.85s linear infinite;
}

/* ==========================================================================
   13. ANIMACIONES
   ========================================================================== */

@keyframes float-preview {
  0%,
  100% {
    transform: translateY(0) rotate(-1deg);
  }

  50% {
    transform: translateY(-18px) rotate(1deg);
  }
}

@keyframes morph-preview {
  0%,
  100% {
    border-radius: 38% 62% 64% 36% / 44% 32% 68% 56%;
  }

  50% {
    border-radius: 59% 41% 38% 62% / 35% 62% 38% 65%;
  }
}

@keyframes pulse-glow {
  0%,
  100% {
    opacity: 0.7;
    transform: scale(0.94);
  }

  50% {
    opacity: 1;
    transform: scale(1.08);
  }
}

@keyframes rotate-slow {
  to {
    transform: rotate(360deg);
  }
}

@keyframes rotate-reverse {
  to {
    transform: rotate(-360deg);
  }
}

@keyframes orbit-one {
  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(42px, 30px);
  }
}

@keyframes orbit-two {
  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(-36px, -24px);
  }
}

@keyframes pulse-orb {
  0%,
  100% {
    opacity: 0.6;
    transform: scale(0.85);
  }

  50% {
    opacity: 1;
    transform: scale(1.25);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ==========================================================================
   14. RESPONSIVE BÁSICO
   ========================================================================== */

@media (max-width: 1100px) {
  .site-nav {
    gap: var(--space-5);
  }

  .hero {
    grid-template-columns: 1fr 0.75fr;
    gap: var(--space-10);
  }

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

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

@media (max-width: 820px) {
  :root {
    --header-height: 70px;
  }

  .site-nav {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .hero {
    min-height: auto;
    padding-top: var(--space-12);
    grid-template-columns: 1fr;
  }

  .hero__content {
    text-align: center;
  }

  .hero__description {
    margin-right: auto;
    margin-left: auto;
  }

  .hero__actions,
  .hero__features {
    justify-content: center;
  }

  .hero__visual {
    min-height: 390px;
  }

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

  .trust-grid {
    grid-template-columns: 1fr;
  }

  .product-header {
    flex-direction: column;
  }

  .control-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  :root {
    --space-20: 4rem;
    --space-16: 3rem;
  }

  .site-header__inner {
    gap: var(--space-3);
  }

  .site-brand__name {
    max-width: 150px;
    font-size: var(--font-size-base);
  }

  .site-brand__logo {
    width: 42px;
    height: 42px;
  }

  .language-control select {
    min-height: 40px;
    padding: 0 var(--space-3);
  }

  .hero {
    width: min(calc(100% - 1.25rem), var(--content-width));
    padding-top: var(--space-10);
  }

  .hero__actions {
    flex-direction: column;
  }

  .hero__actions .button {
    width: 100%;
  }

  .hero__visual {
    min-height: 330px;
  }

  .hero-tool-preview {
    width: min(290px, 82vw);
  }

  .categories-section,
  .tools-section,
  .about-section,
  .product-page {
    width: min(calc(100% - 1.25rem), var(--content-width));
  }

  .category-grid,
  .tools-grid,
  .site-footer__grid {
    grid-template-columns: 1fr;
  }

  .category-card {
    min-height: 220px;
  }

  .tool-card {
    min-height: 250px;
  }

  .site-footer__bottom {
    flex-direction: column;
  }

  .site-footer__monetization-note {
    text-align: left;
  }

  .ad-slot {
    width: min(calc(100% - 1.25rem), var(--content-width));
    min-height: 72px;
  }

  .about-section__content,
  .tool-interface {
    border-radius: var(--radius-lg);
  }
}

/* ==========================================================================
   15. ACCESIBILIDAD Y REDUCCIÓN DE MOVIMIENTO
   ========================================================================== */

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

  .particle-canvas {
    display: none;
  }
}

/* ==========================================================================
   16. IMPRESIÓN
   ========================================================================== */

@media print {
  .particle-canvas,
  .site-header,
  .ad-slot,
  .site-footer,
  .button,
  .back-to-portfolio {
    display: none !important;
  }

  body {
    color: #000;
    background: #fff;
  }

  .tool-interface,
  .result-panel,
  .about-section__content {
    color: #000;
    background: #fff;
    border: 1px solid #ccc;
    box-shadow: none;
  }
}

/* ==========================================================================
   SELECTORES: OPCIONES VISIBLES
   ========================================================================== */

.form-field select,
.language-control select {
  color: var(--color-text);
  background-color: var(--color-surface-strong);
}

.form-field select option,
.language-control select option {
  color: var(--color-text);
  background-color: var(--color-surface-strong);
}

/* ==========================================================================
   MARCA DEL HEADER: CREATIVE LAB
   ========================================================================== */

.site-brand__name {
  display: inline-block;
  overflow: visible;
  color: transparent;
  background:
    linear-gradient(
      90deg,
      #ffffff 0%,
      #ffffff 67%,
      #8cff22 67%,
      #62ff2f 82%,
      #18c96a 100%
    );
  background-clip: text;
  -webkit-background-clip: text;
  font-family: var(--font-primary);
  font-size: clamp(1rem, 1.7vw, 1.22rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.045em;
  text-shadow:
    0 0 18px rgba(102, 255, 143, 0.08);
  white-space: nowrap;
}

.site-brand:hover .site-brand__name {
  filter: brightness(1.08);
}

@supports not ((background-clip: text) or (-webkit-background-clip: text)) {
  .site-brand__name {
    color: var(--color-text);
    background: none;
  }
}

/* ==========================================================================
   HEADER DINÁMICO · REDUCCIÓN DE MOVIMIENTO
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  .header-drawer,
  .header-drawer-overlay {
    transition-duration: 1ms;
  }
}

/* ========================================================================== 
   ALFORA · HEADER DINÁMICO DESDE JSON
   ========================================================================== */

.site-header--index,
.site-header--tools {
  overflow: visible;
}

.header-desktop-nav {
  min-width: 0;
}

.header-language-control select {
  min-width: 78px;
  min-height: 42px;
  padding: 0 38px 0 18px;
  color: var(--color-text);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' fill='none' stroke='%23d7e4da' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 12px 8px;
}

.header-menu-toggle {
  display: inline-grid;
  place-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  cursor: pointer;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition:
    border-color var(--transition-fast),
    background var(--transition-fast),
    transform var(--transition-fast);
}

.header-menu-toggle[hidden] {
  display: none !important;
}

.header-menu-toggle:hover {
  border-color: var(--color-border-strong);
  background: var(--color-surface-strong);
}

.header-menu-toggle span {
  display: block;
  width: 19px;
  height: 2px;
  margin: 2.5px auto;
  background: var(--color-primary);
  border-radius: var(--radius-pill);
  transform-origin: center;
  transition:
    transform var(--transition-normal),
    opacity var(--transition-fast);
}

.header-menu-toggle.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header-menu-toggle.is-open span:nth-child(2) {
  opacity: 0;
}

.header-menu-toggle.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* En el index, la hamburguesa pertenece al modo responsive. */
.site-header--index .header-menu-toggle {
  display: none;
}

/* En herramientas aparece también en escritorio únicamente si JSON tiene extras. */
.site-header--tools .header-menu-toggle:not([hidden]) {
  display: inline-grid;
}

.header-drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: calc(var(--z-header) + 8);
  opacity: 0;
  pointer-events: none;
  background: rgba(0, 0, 0, 0.46);
  transition: opacity 200ms ease;
}

.header-drawer-overlay[hidden] {
  display: none !important;
}

.header-drawer-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

.header-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: calc(var(--z-header) + 10);
  display: flex;
  flex-direction: column;
  width: min(88vw, 360px);
  height: 100vh;
  height: 100dvh;
  padding: var(--space-5);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  color: var(--color-text);
  background: #07150d;
  border-left: 1px solid var(--color-border);
  box-shadow: -16px 0 42px rgba(0, 0, 0, 0.30);
  transform: translate3d(105%, 0, 0);
  transition: transform 220ms cubic-bezier(.22, .75, .2, 1);
  will-change: transform;
  scrollbar-width: thin;
  scrollbar-color: var(--color-primary) rgba(102, 255, 143, 0.06);
}

.header-drawer[hidden] {
  display: none !important;
}

.header-drawer.is-open {
  transform: translate3d(0, 0, 0);
}

.header-drawer::-webkit-scrollbar {
  width: 9px;
}

.header-drawer::-webkit-scrollbar-track {
  background: rgba(102, 255, 143, 0.05);
}

.header-drawer::-webkit-scrollbar-thumb {
  background: var(--color-primary);
  border: 2px solid var(--color-background);
  border-radius: var(--radius-pill);
}

.header-drawer__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding-bottom: var(--space-4);
  margin-bottom: var(--space-4);
  border-bottom: 1px solid var(--color-border);
}

.header-drawer__brand {
  color: var(--color-primary-soft);
  font-size: var(--font-size-lg);
  font-weight: 900;
}

.header-drawer__close {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  color: var(--color-primary);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  cursor: pointer;
  font-size: 1.7rem;
  line-height: 1;
}

.header-drawer__nav {
  display: grid;
  gap: var(--space-2);
}

.header-drawer__link {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: var(--space-3) var(--space-4);
  color: var(--color-text-soft);
  background: rgba(102, 255, 143, 0.025);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  font-weight: 800;
  transition:
    color var(--transition-fast),
    background var(--transition-fast),
    border-color var(--transition-fast),
    transform var(--transition-fast);
}

.header-drawer__link:hover {
  color: var(--color-text-dark);
  background: var(--color-primary);
  border-color: var(--color-primary);
  transform: translateX(-3px);
}

/* El drawer no bloquea el overflow de html/body.
   El overlay evita interacción accidental con el fondo y así no se rompe
   el scroll hacia anclas ni se congela Chrome móvil al cerrar el menú. */
html.header-drawer-open {
  scroll-behavior: smooth;
}

@media (max-width: 820px) {
  .site-header--index .header-desktop-nav {
    display: none;
  }

  .site-header--index .header-menu-toggle:not([hidden]) {
    display: inline-grid;
  }
}

@media (max-width: 620px) {
  .header-language-control select {
    min-width: 72px;
    min-height: 40px;
    padding-left: 14px;
    padding-right: 34px;
    background-position: right 13px center;
  }

  .site-header--tools .back-to-portfolio {
    min-height: 40px;
    padding-inline: var(--space-3);
  }

  .header-menu-toggle {
    width: 40px;
    height: 40px;
  }
}
