/* ==========================================================================
   1. IMPORTS
   ========================================================================== */

@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Source+Serif+4:ital,wght@0,400;0,500;0,600;1,400;1,500;1,600&display=swap");


/* ==========================================================================
   2. VARIABLES + BASE
   ========================================================================== */

:root {
  --bg-main: #fffaef;
  --bg-tertiary: #eee7d6;
  --accent: #6d0303;
  --text-dark: #1c1410;
  --font-sans: "Inter", system-ui, -apple-system, sans-serif;
  --font-serif: "Source Serif 4", serif;
  --nav-h: 60px;
}

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

html {
  scroll-behavior: auto;
  scrollbar-gutter: stable;
}

html.lenis {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth body {
  overscroll-behavior: none;
}

body {
  width: 100%;
  margin: 0;
  overflow-x: hidden;
  background-color: var(--bg-main);
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
.section-title {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: 600;
  letter-spacing: -0.04em;
}

p,
.lead,
li {
  line-height: 1.3;
  letter-spacing: normal;
}

.accent-serif {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 500;
}

a,
button,
.nav-link,
.project-card img,
.accordion-icon::before,
.accordion-icon::after,
summary {
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

img {
  transition: opacity 0.5s ease;
}

section {
  padding-block: 6rem;
  scroll-margin-top: 100px;
}


/* ==========================================================================
   3. NAVBAR
   ========================================================================== */

.navbar-custom {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  width: 100%;
  max-width: 100vw;
  padding-top: 1rem;
  padding-bottom: 2rem;
  overflow-x: clip;
  background-color: transparent;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  mask-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 1) 55%,
    rgba(0, 0, 0, 0) 100%
  );
  -webkit-mask-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 1) 55%,
    rgba(0, 0, 0, 0) 100%
  );
}

.navbar-brand {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.navbar-nav .nav-link {
  position: relative;
  display: flex;
  align-items: center;
  padding-inline: 0.75rem;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.navbar-nav .nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0.15rem;
  width: 0;
  height: 1px;
  background-color: var(--accent);
  transition: width 0.25s ease;
}

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

.navbar-toggler {
  border: none;
}

.navbar-toggler:focus {
  outline: none;
  box-shadow: none;
}

.navbar-toggler-icon,
.navbar-toggler.collapsed .navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(28, 20, 16, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
  transform: rotate(0deg);
  transition: transform 0.3s ease-in-out, background-image 0.3s ease-in-out;
}

.navbar-toggler:not(.collapsed) .navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(28, 20, 16, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M6 6L24 24M24 6L6 24'/%3e%3c/svg%3e");
  transform: rotate(90deg);
}

.navbar-custom.menu-open {
  padding-bottom: 0.5rem;
  background-color: var(--bg-tertiary) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  mask-image: none !important;
  -webkit-mask-image: none !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: background-color 0.3s ease;
}

.btn-navbar-cta {
  display: inline-block;
  margin-left: 1.5rem;
  padding: 0.6rem 1.8rem !important;
  border: 2px solid var(--accent);
  border-radius: 50px;
  background-color: var(--accent);
  color: var(--bg-main) !important;
  font-weight: 700 !important;
  line-height: 1;
  letter-spacing: 0.05em;
  text-align: center;
  text-transform: uppercase;
  transition: all 0.3s ease;
}

.btn-navbar-cta:hover {
  background-color: transparent;
  color: var(--accent) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(109, 3, 3, 0.2);
}

.btn-navbar-cta::after {
  display: none !important;
}


/* ==========================================================================
   4. HERO + MASTER STAGE
   ========================================================================== */

#master-stage {
  position: relative;
  display: grid;
  place-items: start;
  width: 100%;
  min-height: 100vh;
  height: auto;
  padding: 0 !important;
  overflow: visible;
}

.stage-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
  width: 100%;
  height: 100%;
  margin-top: 0;
  transform: none;
}

.card-layer,
.text-layer {
  grid-column: 1 / -1;
  grid-row: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100vh;
  pointer-events: none;
}

.card-layer {
  z-index: 20;
}

.services-accordion,
.wave-badge {
  pointer-events: auto;
}

.hero-text {
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  column-gap: clamp(2rem, 4vw, 5rem);
  width: 100%;
  height: 100vh;
}

.hero-ghost-center {
  width: calc(clamp(350px, 65vh, 800px) * 0.68);
  height: 1px;
  min-height: 0;
  visibility: hidden;
}

.hero-ref-left,
.hero-ref-right {
  display: flex;
  flex-direction: column;
}

.hero-ref-left {
  justify-self: end;
  align-items: flex-start;
  text-align: left;
}

.hero-ref-right {
  justify-self: start;
  align-items: flex-end;
  padding-top: 3.7rem;
  text-align: right;
}

.hero-ref-name {
  margin: 0 0 0.5em 0.2em;
  font-family: var(--font-serif);
  font-size: clamp(1rem, 2vw, 1.5rem);
  font-style: italic;
  font-weight: 500;
}

.hero-ref-big {
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: clamp(3rem, 10vw, 9rem);
  font-weight: 600;
  line-height: 0.9;
  letter-spacing: -0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.hero-ref-sub {
  margin: 0.5em 0.2em 0 0;
  color: var(--text-dark);
  font-family: var(--font-serif);
  font-size: calc(0.9rem + 0.3vw);
  font-style: italic;
  font-weight: 500;
  letter-spacing: -0.04em;
  white-space: nowrap;
}

.tilt-stage {
  position: relative;
  overflow: visible;
  perspective: 1600px;
  perspective-origin: 50% 50%;
}

.tilt-card {
  position: relative;
  width: calc(clamp(350px, 65vh, 800px) * 0.68);
  height: clamp(350px, 65vh, 800px);
  border-radius: 40px;
  background: transparent;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.22);
  transform-style: preserve-3d;
  will-change: transform;
}

.card-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 40px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transform: translateZ(0);
}

.card-front {
  transform: rotateY(0deg) translateZ(1px);
}

.card-back {
  background-color: var(--text-dark);
  transform: rotateY(180deg) translateZ(1px);
}

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

.wave-badge {
  position: absolute;
  left: -25px;
  bottom: -25px;
  z-index: 30;
  display: grid;
  place-items: center;
  width: 110px;
  height: 110px;
  border: none;
  border-radius: 50%;
  background-color: var(--accent);
  cursor: pointer;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
  transform: translateZ(50px);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.wave-badge:hover {
  transform: translateZ(60px) scale(1.1);
}

.wave-icon {
  width: 40%;
  height: 40%;
  fill: var(--bg-main);
}

.wave-hand {
  transform-origin: 70% 90%;
  animation: wave-animation 2.5s infinite ease-in-out;
}

@keyframes wave-animation {
  0%,
  100% { transform: rotate(0deg); }
  10% { transform: rotate(14deg); }
  20% { transform: rotate(-8deg); }
  30% { transform: rotate(14deg); }
  40% { transform: rotate(-4deg); }
  50% { transform: rotate(10deg); }
  60% { transform: rotate(0deg); }
}


/* ==========================================================================
   5. SERVICIOS
   ========================================================================== */

.services-text {
  z-index: 15;
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  width: 100%;
  min-height: 100vh;
  height: auto !important;
  padding-top: calc(var(--nav-h) + 4rem);
  padding-bottom: 3rem;
  background-color: var(--bg-main);
  opacity: 0;
  transform: translateY(100px);
}

.services-accordion {
  width: 100%;
  margin-bottom: 5rem;
}

.services-accordion details {
  padding: 1rem 0;
  overflow: hidden;
  border-bottom: 1px solid rgba(28, 20, 16, 0.15);
}

.services-accordion summary {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 0;
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  list-style: none;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.3s ease;
}

.services-accordion summary:hover {
  color: var(--accent);
}

.services-accordion summary::-webkit-details-marker {
  display: none;
}

.service-number {
  flex-shrink: 0;
  margin-right: 1.5rem;
  color: var(--accent);
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 500;
  letter-spacing: -0.04em;
}

.accordion-icon {
  position: relative;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-left: auto;
  transition: transform 0.4s ease;
}

.accordion-icon::before,
.accordion-icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--text-dark);
  transform: translateY(-50%);
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1),
    background-color 0.3s ease;
}

.accordion-icon::after {
  transform: translateY(-50%) rotate(90deg);
}

.services-accordion summary:hover .accordion-icon::before,
.services-accordion summary:hover .accordion-icon::after {
  background-color: var(--accent);
}

details[open] .accordion-icon {
  transform: rotate(180deg);
}

details[open] .accordion-icon::after {
  transform: translateY(-50%) rotate(0deg);
}

.accordion-content {
  padding-top: 0;
  padding-left: 3.5rem;
}

.accordion-content ul {
  margin: 0;
  padding: 1rem 0 0;
  list-style: none;
}

.accordion-content li {
  position: relative;
  margin-bottom: 0.4rem;
  padding-left: 1.5rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 500;
}

.accordion-content li::before {
  content: "";
  position: absolute;
  top: 6px;
  left: 0;
  width: 6px;
  height: 10px;
  border: solid var(--accent);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}


/* ==========================================================================
   6. SOFTWARE
   ========================================================================== */

.software-badge {
  display: inline-block;
  margin-bottom: 3rem;
  padding: 0.7rem 1.2rem;
  border-radius: 10px;
  background-color: var(--bg-tertiary);
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: 1.1rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  text-transform: none;
}

.software-marquee {
  position: relative;
  width: 100%;
  max-width: 800px;
  margin-inline: auto;
  padding-block: 1rem;
  overflow: hidden;
  user-select: none;
  mask-image: linear-gradient(
    to right,
    transparent,
    black 15%,
    black 85%,
    transparent
  );
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    black 15%,
    black 85%,
    transparent
  );
}

.marquee-track {
  display: flex;
  width: fit-content;
  gap: 1.5rem;
  animation: scroll-loop 30s linear infinite;
}

.marquee-group {
  display: flex;
  align-items: center;
  justify-content: space-around;
  flex-shrink: 0;
  min-width: 100%;
  gap: 1.5rem;
}

.marquee-group img {
  width: auto;
  height: 50px;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.7;
  transition: all 0.3s ease;
}

.marquee-group img:hover {
  filter: grayscale(0%);
  opacity: 1;
  transform: scale(1.1);
}

.marquee-fade {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    var(--bg-main) 0%,
    rgba(255, 250, 239, 0) 15%,
    rgba(255, 250, 239, 0) 85%,
    var(--bg-main) 100%
  );
}

@keyframes scroll-loop {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-100% - 1.5rem)); }
}


/* ==========================================================================
   7. SOBRE MÍ
   ========================================================================== */

.hybrid-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1.3fr;
  grid-template-rows: auto auto auto;
  gap: 1.5rem;
  width: 100%;
}

.hybrid-card {
  position: relative;
  overflow: hidden;
  border-radius: 1.5rem;
  background-color: var(--bg-tertiary);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.02);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.hybrid-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.editorial-label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.5;
}

.bio-area {
  grid-column: 1 / 3;
  grid-row: 1 / 2;
}

.photo-area {
  grid-column: 3 / 4;
  grid-row: 1 / 3;
  height: 100%;
  max-height: 500px;
}

.photo-area img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  filter: none;
  transition: transform 0.6s ease;
}

.photo-area:hover img {
  transform: scale(1.05);
}

.info-area-1 {
  grid-column: 1 / 2;
  grid-row: 2 / 3;
}

.info-area-2 {
  grid-column: 2 / 3;
  grid-row: 2 / 3;
}

.cta-area {
  grid-column: 1 / -1;
  grid-row: 3 / 4;
  overflow: visible;
  border-radius: 1.5rem;
  background-color: transparent;
  color: var(--text-dark);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.4s ease;
}

.cta-link-rounded {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 100%;
  padding: 1.5rem 2.5rem;
  border: 2px solid var(--accent);
  border-radius: 1.5rem;
  background-color: var(--accent);
  color: var(--bg-main);
  box-shadow: 0 5px 18px rgba(109, 3, 3, 0.08);
  font-size: 1.2rem;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
  transition: background-color 0.35s ease,
    color 0.35s ease,
    border-color 0.35s ease,
    box-shadow 0.4s ease;
}

.cta-link-rounded:active {
  background-color: var(--bg-tertiary);
  color: var(--accent);
}

.cta-area:active {
  transform: scale(0.985);
}

.cta-link-rounded:focus-visible {
  background-color: var(--bg-tertiary);
  color: var(--accent);
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

@media (hover: hover) and (pointer: fine) {
  .cta-area:hover {
    transform: translateY(-3px) scale(1.015);
    box-shadow: 0 14px 35px rgba(28, 20, 16, 0.08);
  }

  .cta-link-rounded:hover {
    background-color: var(--bg-tertiary);
    color: var(--accent);
  }
}

/* ==========================================================================
   8. EXPERIENCIA
   ========================================================================== */

.experience-section {
  position: relative;

  padding-block:
    clamp(6rem, 10vw, 10rem);

  overflow: hidden;
}


/* ==========================================================================
   CABECERA
   ========================================================================== */

.experience-heading {
  display: grid;

  grid-template-columns:
    minmax(0, 1.2fr)
    minmax(280px, 0.8fr);

  align-items: end;

  gap:
    clamp(2rem, 6vw, 7rem);

  margin-bottom:
    clamp(3rem, 7vw, 6rem);
}


.experience-title {
  line-height: 0.95;

  letter-spacing: -0.075em;
}


/* ==========================================================================
   GRID
   ========================================================================== */

.experience-grid {
  display: grid;

  grid-template-columns:
    repeat(2, minmax(0, 1fr));

  gap: 1.5rem;
}


/* ==========================================================================
   TARJETA
   ========================================================================== */

.experience-card {
  --trail-x: 50%;
  --trail-y: 50%;

  --blob-angle: 0deg;

  --blob-stretch: 1;
  --blob-squash: 1;


  position: relative;

  min-height: 360px;

  padding:
    clamp(1.75rem, 3vw, 3rem);

  overflow: hidden;

  isolation: isolate;

  border:
    1px solid transparent;

  border-radius:
    2rem;

  background-color:
    var(--bg-tertiary);

  box-shadow:
    0 15px 50px
    rgba(28, 20, 16, 0.04);

  transition:
    transform
      0.45s
      cubic-bezier(0.22, 1, 0.36, 1),

    border-color
      0.35s
      ease,

    box-shadow
      0.45s
      ease;
}


/* ==========================================================================
   LUZ ELÁSTICA
   ========================================================================== */

.experience-card::before {
  content: "";

  position: absolute;

  left:
    var(--trail-x);

  top:
    var(--trail-y);

  z-index: -1;

  width: 170px;
  height: 170px;

  border-radius: 50%;

  pointer-events: none;

  background:
    radial-gradient(
      circle at center,

      rgba(109, 3, 3, 0.32) 0%,

      rgba(109, 3, 3, 0.15) 38%,

      rgba(109, 3, 3, 0.06) 58%,

      transparent 78%
    );

  filter:
    blur(8px);

  opacity: 0;

  transform:
    translate(-50%, -50%)
    rotate(var(--blob-angle))
    scaleX(var(--blob-stretch))
    scaleY(var(--blob-squash));

  transform-origin:
    center;

  transition:
    opacity 0.45s ease;

  will-change:
    left,
    top,
    transform,
    opacity;
}


/* ==========================================================================
   LÍNEA INFERIOR
   ========================================================================== */

.experience-card::after {
  content: "";

  position: absolute;

  left: 2rem;
  right: 2rem;

  bottom: 0;

  height: 3px;

  border-radius:
    999px 999px 0 0;

  background-color:
    var(--accent);

  transform:
    scaleX(0);

  transform-origin:
    left center;

  transition:
    transform
      0.8s
      cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   HOVER · RATÓN / TRACKPAD DISPONIBLE
   ========================================================================== */

@media (any-hover: hover) and (any-pointer: fine) {

  .experience-card:hover {
    transform:
      translateY(-8px);

    border-color:
      rgba(109, 3, 3, 0.18);

    box-shadow:
      0 28px 65px
      rgba(28, 20, 16, 0.1);
  }


  /*
   * La luz elástica aparece al entrar
   * con un dispositivo que permite hover.
   *
   * La posición, deformación y dirección
   * siguen controladas por JavaScript.
   */

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


  .experience-card:hover::after {
    transform:
      scaleX(1);
  }


  .experience-card:hover
  .experience-card-number {
    color:
      rgba(109, 3, 3, 0.075);

    transform:
      translateY(-0.05em)
      rotate(-3deg);
  }


  .experience-external-link:hover {
    color:
      var(--accent);
  }


  .experience-external-link:hover span {
    transform:
      translate(0.2em, -0.2em)
      rotate(8deg);
  }

}


/* ==========================================================================
   SELECCIÓN MEDIANTE SCROLL
   ========================================================================== */

.experience-card.is-scroll-active::after {
  transform: scaleX(1);
}


/* ==========================================================================
   TOUCH · SIN LUZ ELÁSTICA
   ========================================================================== */

@media (any-hover: none) {

  .experience-card::before {
    display: none;
  }

}


/* ==========================================================================
   TARJETA DESTACADA
   ========================================================================== */

.experience-card-featured {
  grid-column:
    1 / -1;

  min-height: auto;

  background:
    var(--bg-tertiary);
}


/* ==========================================================================
   NÚMERO DECORATIVO
   ========================================================================== */

.experience-card-number {
  position: absolute;

  right: 1.75rem;

  bottom: -0.12em;

  z-index: -1;

  color:
    rgba(109, 3, 3, 0.045);

  font-family:
    var(--font-serif);

  font-size:
    clamp(7rem, 15vw, 13rem);

  font-style: italic;

  font-weight: 500;

  line-height: 1;

  letter-spacing: -0.08em;

  pointer-events: none;

  transition:
    transform
      0.6s
      cubic-bezier(0.22, 1, 0.36, 1),

    color
      0.4s
      ease;
}


/* ==========================================================================
   CABECERA DE TARJETA
   ========================================================================== */

.experience-card-top {
  position: relative;

  z-index: 2;

  display: flex;

  align-items:
    flex-start;

  justify-content:
    space-between;

  gap: 2rem;

  margin-bottom: 2rem;
}


/* ==========================================================================
   FECHA
   ========================================================================== */

.experience-date {
  display: block;

  margin-bottom:
    0.75rem;

  color:
    var(--accent);

  font-family:
    var(--font-sans);

  font-size:
    0.72rem;

  font-weight:
    700;

  letter-spacing:
    0.12em;

  text-transform:
    uppercase;
}


/* ==========================================================================
   EMPRESA
   ========================================================================== */

.experience-company {
  margin: 0;

  font-family:
    var(--font-sans);

  font-size:
    clamp(2rem, 4vw, 4rem);

  font-weight:
    600;

  line-height:
    0.95;

  letter-spacing:
    -0.065em;
}


.experience-card:not(
  .experience-card-featured
)
.experience-company {
  font-size:
    clamp(1.8rem, 3vw, 2.8rem);
}


/* ==========================================================================
   PUESTO
   ========================================================================== */

.experience-role {
  margin:
    0.8rem 0 0;

  color:
    rgba(28, 20, 16, 0.65);

  font-family:
    var(--font-serif);

  font-size:
    1.15rem;

  font-style:
    italic;
}


/* ==========================================================================
   ETIQUETA
   ========================================================================== */

.experience-tag {
  flex-shrink: 0;

  padding:
    0.55rem 0.9rem;

  border:
    1px solid
    rgba(109, 3, 3, 0.16);

  border-radius:
    999px;

  background-color:
    rgba(255, 250, 239, 0.55);

  color:
    var(--accent);

  font-size:
    0.7rem;

  font-weight:
    700;

  letter-spacing:
    0.08em;

  text-transform:
    uppercase;
}


/* ==========================================================================
   ENLACE
   ========================================================================== */

.experience-external-link {
  display:
    inline-flex;

  align-items:
    center;

  gap:
    0.25em;

  color:
    var(--text-dark);

  text-decoration:
    none;
}


.experience-external-link span {
  display:
    inline-block;

  font-family:
    var(--font-sans);

  font-size:
    0.5em;

  transition:
    transform
      0.35s
      cubic-bezier(0.22, 1, 0.36, 1);
}


/* ==========================================================================
   ETAPAS
   ========================================================================== */

.experience-stages {
  position: relative;

  z-index: 2;

  display: grid;

  grid-template-columns:
    repeat(2, minmax(0, 1fr));

  gap:
    clamp(2rem, 5vw, 5rem);

  padding-top:
    1rem;
}


.experience-stage-date {
  display:
    block;

  margin-bottom:
    0.8rem;

  color:
    var(--text-dark);

  font-size:
    0.78rem;

  font-weight:
    700;

  letter-spacing:
    0.04em;
}


.experience-stage p,
.experience-description {
  position: relative;

  z-index: 2;

  max-width:
    630px;

  margin: 0;

  color:
    rgba(28, 20, 16, 0.72);

  font-size:
    1rem;

  line-height:
    1.55;
}

/* ==========================================================================
   9. PROYECTOS
   ========================================================================== */


   #projects {
  position: relative;

  overflow-x: clip;
  overflow-y: visible;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1rem, 2.5vw, 2rem);
  width: 100%;
}

.project-card {
  min-width: 0;
  cursor: pointer;
}

.project-card-media {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 1.5rem;
  background-color: #000;
}

.project-card-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(0%) brightness(1);
  transform: scale(1);
  transition: filter 0.75s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-category {
  display: block;
  margin-bottom: 0.6rem;
  color: rgba(255, 255, 255, 0.8);
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.project-title {
  margin: 0 0 1.25rem;
  color: #fff;
  font-family: var(--font-serif);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-style: italic;
  font-weight: 500;
}

.project-more {
  display: inline-block;
  margin: 0;
  padding: 0.55rem 1.35rem;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 999px;
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: background-color 0.3s ease,
    color 0.3s ease,
    border-color 0.3s ease,
    transform 0.3s ease;
}

.project-more:hover {
  border-color: #fff;
  background-color: #fff;
  color: var(--text-dark);
  transform: translateY(-2px);
}

.project-mobile-info {
  display: none;
}

@media (hover: hover) and (pointer: fine) {
  .project-card .project-card-media img {
    filter: grayscale(0%) brightness(1) !important;
    transform: scale(1) !important;
  }

  .project-card .project-overlay {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 2rem !important;
    background: linear-gradient(
      to top,
      rgba(12, 10, 8, 0.68) 0%,
      rgba(12, 10, 8, 0.28) 48%,
      rgba(12, 10, 8, 0.08) 100%
    ) !important;
    opacity: 0 !important;
    transform: translateY(14px) !important;
    transition: opacity 0.5s ease,
      transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .project-card:hover .project-card-media img {
    filter: grayscale(100%) brightness(0.58) !important;
    transform: scale(1.05) !important;
  }

  .project-card:hover .project-overlay {
    opacity: 1 !important;
    transform: translateY(0) !important;
  }

  .project-mobile-info {
    display: none !important;
  }
}

@media (hover: none) {
  .project-card .project-card-media img {
    filter: grayscale(0%) brightness(1) !important;
    transform: none !important;
  }

  .project-overlay {
    display: none !important;
  }

  .project-mobile-info {
    display: block !important;
  }
}


/* ==========================================================================
   10. MODALES + CARRUSELES
   ========================================================================== */

.project-modal-content {
  padding: clamp(0.5rem, 2vw, 1.5rem);
}

.project-modal-intro {
  max-width: 900px;
  margin: 0 auto clamp(2.5rem, 5vw, 4.5rem);
}

.project-modal-category {
  display: block;
  margin-bottom: 1rem;
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.project-modal-title {
  margin: 0;
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 600;
  line-height: 0.95;
  letter-spacing: -0.065em;
}

.project-modal-subtitle {
  margin: 0.8rem 0 2rem;
  color: var(--accent);
  font-family: var(--font-serif);
  font-size: clamp(1.3rem, 2vw, 1.8rem);
  font-style: italic;
}

.project-modal-description {
  max-width: 760px;
  margin: 0;
  color: rgba(28, 20, 16, 0.72);
  font-size: 1rem;
  line-height: 1.6;
}

.project-concept {
  max-width: 760px;
  margin-top: 2.5rem;
}

.project-modal-label {
  display: block;
  margin-bottom: 0.8rem;
  color: rgba(28, 20, 16, 0.5);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.project-concept p {
  margin: 0 0 0.8rem;
  color: rgba(28, 20, 16, 0.7);
  font-size: 0.95rem;
  line-height: 1.6;
}

.project-modal-software {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(28, 20, 16, 0.12);
}

.project-software-list {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
}

.project-software-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.project-software-item img {
  width: 34px;
  height: 34px;
  object-fit: contain;
}

.project-software-item img.cinema4d-icon {
  transform: scale(1.8);
  transform-origin: center;
}

.project-software-item div {
  display: flex;
  flex-direction: column;
}

.project-software-item span {
  color: var(--text-dark);
  font-size: 0.85rem;
  font-weight: 600;
}

.project-software-item small {
  margin-top: 0.1rem;
  color: rgba(28, 20, 16, 0.5);
  font-size: 0.7rem;
}

.project-modal-carousel {
  width: 100%;
  margin-top: 1.5rem;
}

.project-carousel-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 10 / 7;
  overflow: hidden;
  border-radius: 1.25rem;
}

.project-carousel-stage .carousel-inner,
.project-carousel-stage .carousel-item {
  width: 100%;
  height: 100%;
}

.project-slide-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  padding: 0.6rem;
}

.project-modal-carousel .project-slide-frame img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  margin: 0 !important;
  border-radius: 0;
  object-fit: contain !important;
}

.project-carousel-control {
  top: 50%;
  bottom: auto;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  background-color: rgba(35, 35, 35, 0.42);
  opacity: 1;
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
  box-shadow: 0 5px 18px rgba(0, 0, 0, 0.18);
  transform: translateY(-50%);
  transition: background-color 0.3s ease,
    border-color 0.3s ease,
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.project-carousel-control:hover {
  border-color: rgba(255, 255, 255, 0.34);
  background-color: rgba(25, 25, 25, 0.68);
  box-shadow: 0 7px 22px rgba(0, 0, 0, 0.25);
  transform: translateY(-50%) scale(1.07);
}

.project-modal-carousel .carousel-control-prev {
  left: 0.75rem;
}

.project-modal-carousel .carousel-control-next {
  right: 0.75rem;
}

.project-modal-carousel .carousel-control-prev-icon,
.project-modal-carousel .carousel-control-next-icon {
  width: 1.6rem;
  height: 1.6rem;
  background-size: 70%;
  filter: none;
}

.project-carousel-indicators {
  position: static;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin: 1.15rem 0 0;
  pointer-events: none;
}

.project-carousel-indicators [data-bs-target] {
  width: 8px;
  height: 8px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background-color: rgba(28, 20, 16, 0.2);
  opacity: 1;
  transition: background-color 0.35s ease,
    transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-carousel-indicators .active {
  background-color: var(--accent);
  transform: scale(1.35);
}

.modal-content {
  display: flex;
  flex-direction: column;
  max-height: 90vh;
  overflow: hidden;
  border: none;
  border-radius: 1.5rem;
  background-color: var(--bg-main);
}

body.modal-open {
  overflow: hidden !important;
  overscroll-behavior: none;
}

.modal {
  overscroll-behavior: contain;
}

.modal-body {
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
}

.project-video-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.project-carousel-video {
  display: block;
  width: 100%;
  height: 100%;
  margin: 0;
  border: 0;
  border-radius: 0;
  background-color: #000;
  object-fit: contain;
}

.project-video-toggle {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(64px, 7vw, 82px);
  height: clamp(64px, 7vw, 82px);
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background-color: rgba(35, 35, 35, 0.55);
  color: #fff;
  cursor: pointer;
  opacity: 1;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.22);
  transform: translate(-50%, -50%);
  transition: opacity 0.35s ease,
    transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    background-color 0.3s ease;
}

.project-video-toggle:not(.is-playing):hover {
  background-color: rgba(25, 25, 25, 0.72);
  transform: translate(-50%, -50%) scale(1.07);
}

.project-video-icon {
  width: 30%;
  height: 30%;
}

.project-video-icon-play {
  transform: translateX(2px);
}

.project-video-icon-pause {
  display: none;
}

.project-video-toggle.is-playing {
  opacity: 0;
  pointer-events: none;
}

.project-video-toggle.is-playing .project-video-icon-play {
  display: none;
}

.project-video-toggle.is-playing .project-video-icon-pause {
  display: block;
}

.project-external-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin-top: 1.75rem;
  padding: 0.8rem 1.15rem;
  border: 1px solid rgba(28, 20, 16, 0.18);
  border-radius: 999px;
  color: var(--text-dark);
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s ease,
    background-color 0.3s ease,
    border-color 0.3s ease,
    transform 0.3s ease;
}

.project-external-link:hover {
  border-color: var(--accent);
  background-color: var(--accent);
  color: var(--bg-main);
  transform: translateY(-2px);
}

.project-external-arrow {
  display: inline-block;
  font-size: 1rem;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-external-link:hover .project-external-arrow {
  transform: translate(2px, -2px);
}


/* ==========================================================================
   11. MOTION GRAPHICS
   ========================================================================== */

.featured-motion {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(280px, 0.8fr);
  align-items: center;
  gap: clamp(2.5rem, 6vw, 6rem);
  width: 100%;
  margin-bottom: clamp(4rem, 8vw, 7rem);
}

.featured-motion-secondary {
  margin-top: clamp(5rem, 9vw, 9rem);
}

.featured-motion-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 1.5rem;
  background-color: #000;
}

.inline-video-element {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.featured-motion-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.featured-motion-category {
  margin-bottom: 1rem;
  color: var(--accent);
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.featured-motion-title {
  margin: 0 0 1.5rem;
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: clamp(2rem, 3vw, 3.2rem);
  font-weight: 600;
  line-height: 0.95;
  letter-spacing: -0.06em;
}

.featured-motion-description {
  max-width: 430px;
  margin: 0;
  color: rgba(28, 20, 16, 0.72);
  font-size: 1rem;
  line-height: 1.55;
}

.featured-motion-tools {
  width: 100%;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(28, 20, 16, 0.12);
}

.featured-motion-tools-label {
  display: block;
  margin-bottom: 1rem;
  color: rgba(28, 20, 16, 0.5);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.featured-motion-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.featured-motion-tool {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.featured-motion-tool img {
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.featured-motion-tool span {
  color: rgba(28, 20, 16, 0.68);
  font-size: 0.78rem;
  font-weight: 500;
}
/* ==========================================================================
   11. FOTOGRAFÍA · CARRUSEL 3D
   ========================================================================== */

.photography-showcase {
  position: relative;
  width: 100%;
  margin-top: clamp(6rem, 11vw, 10rem);
  margin-bottom: clamp(4rem, 8vw, 7rem);
  overflow: visible;
}


/* ==========================================================================
   CABECERA
   ========================================================================== */

.photography-showcase-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;

  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}


.photography-kicker {
  display: block;

  margin-bottom: 0.8rem;

  color: var(--accent);

  font-size: 0.7rem;
  font-weight: 700;

  letter-spacing: 0.13em;
  text-transform: uppercase;
}


.photography-heading {
  max-width: 720px;
  margin: 0;

  font-family: var(--font-sans);

  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 600;

  line-height: 0.94;
  letter-spacing: -0.065em;

  color: var(--text-dark);
}


.photography-heading .accent-serif {
  font-size: 1.05em;
}
/* ==========================================================================
   CONTROLES
   ========================================================================== */

.photography-controls {
  display: flex;
  align-items: center;
  gap: 0.8rem;

  flex-shrink: 0;
}


.photography-arrow {
  display: grid;
  place-items: center;

  width: 48px;
  height: 48px;

  padding: 0;

  border: 1px solid rgba(28, 20, 16, 0.14);
  border-radius: 50%;

  background-color: var(--bg-tertiary);

  color: var(--text-dark);

  cursor: pointer;

  -webkit-tap-highlight-color: transparent;

  touch-action: manipulation;

  user-select: none;
  -webkit-user-select: none;

  transition:
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    background-color 0.3s ease,
    color 0.3s ease,
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}


.photography-arrow svg {
  width: 21px;
  height: 21px;

  pointer-events: none;
}


/* ==========================================================================
   HOVER · SOLO RATÓN / TRACKPAD
   ========================================================================== */

@media (hover: hover) and (pointer: fine) {

  .photography-arrow:hover {
    background-color: var(--accent);

    border-color: var(--accent);

    color: var(--bg-main);

    transform: scale(1.08);

    box-shadow:
      0 8px 20px
      rgba(109, 3, 3, 0.14);
  }

}


/* ==========================================================================
   PULSACIÓN
   ========================================================================== */

.photography-arrow:active {
  transform: scale(0.94);
}


/* ==========================================================================
   FOCO DE TECLADO
   ========================================================================== */

.photography-arrow:focus {
  outline: none;
}


.photography-arrow:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

/* ==========================================================================
   CONTADOR
   ========================================================================== */

.photography-counter {
  display: flex;
  align-items: center;
  justify-content: center;

  gap: 0.32rem;

  min-width: 62px;

  font-size: 0.7rem;
  font-weight: 600;

  line-height: 1;

  letter-spacing: 0.08em;

  color: rgba(28, 20, 16, 0.42);
}


.photography-current {
  color: var(--text-dark);
}


/*
 * Funciona también aunque el segundo número
 * todavía no tenga la clase photography-total.
 */

.photography-total,
.photography-counter span:last-child {
  color: rgba(28, 20, 16, 0.42);
}


/* ==========================================================================
   CARRUSEL
   ========================================================================== */

.photography-carousel {
  position: relative;

  width: 100%;

  overflow: visible;
}


/*
 * El escenario ocupa prácticamente todo el viewport.
 *
 * IMPORTANTE:
 * overflow queda en visible para que la sombra de la
 * fotografía central nunca se corte en la parte inferior.
 *
 * El body ya controla el desbordamiento horizontal del sitio.
 */

.photography-carousel-stage {
  position: relative;

  left: 50%;

  width: min(100vw, 1500px);

  height: clamp(470px, 52vw, 700px);

  margin-left: -50vw;

  overflow: visible;

  perspective: 1600px;
  perspective-origin: center center;

  transform-style: preserve-3d;

  isolation: isolate;

  touch-action: pan-y;

  user-select: none;
  -webkit-user-select: none;
}


/*
 * Cuando el monitor supera los 1500px,
 * mantenemos el escenario centrado.
 */

@media (min-width: 1500px) {

  .photography-carousel-stage {
    left: 50%;
    margin-left: -750px;
  }

}


/* ==========================================================================
   FOTOGRAFÍAS
   ========================================================================== */

.photography-slide {
  position: absolute;

  top: 50%;
  left: 50%;

  width: clamp(250px, 31vw, 430px);

  aspect-ratio: 4 / 5;

  margin: 0;

  overflow: hidden;

  border-radius: 1.6rem;

  background-color: var(--bg-tertiary);

  box-shadow:
    0 24px 55px
    rgba(28, 20, 16, 0.12);

  transform-origin: center center;
  transform-style: preserve-3d;

  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;

  cursor: pointer;

  will-change:
    transform,
    filter,
    opacity;

  /*
   * No añadimos transition aquí.
   * GSAP controla toda la interpolación para
   * evitar que CSS y JS compitan entre sí.
   */
}


.photography-slide img {
  display: block;

  width: 100%;
  height: 100%;

  object-fit: cover;
  object-position: center;

  pointer-events: none;

  transition: none;
}


/* ==========================================================================
   FOTOGRAFÍA CENTRAL
   ========================================================================== */

.photography-slide.is-active {
  cursor: default;

  box-shadow:
    0 38px 85px
    rgba(28, 20, 16, 0.2);
}


/*
 * El shadow se aplica sobre el propio slide.
 * Como el escenario tiene overflow visible,
 * puede expandirse libremente hacia abajo.
 */


/* ==========================================================================
   TABLET
   ========================================================================== */

@media (max-width: 1024px) {

  .photography-showcase {
    margin-top: 6rem;
    margin-bottom: 5rem;
  }


  .photography-showcase-header {
    margin-bottom: 2.5rem;
  }


  .photography-carousel-stage {
    height: clamp(450px, 65vw, 620px);
  }


  .photography-slide {
    width: clamp(245px, 37vw, 350px);

    border-radius: 1.45rem;
  }


  .photography-slide.is-active {
    box-shadow:
      0 30px 70px
      rgba(28, 20, 16, 0.18);
  }

}


/* ==========================================================================
   MÓVIL
   ========================================================================== */

@media (max-width: 767px) {

  .photography-showcase {
    margin-top: 5rem;
    margin-bottom: 4rem;
  }


  /* CABECERA */

  .photography-showcase-header {
    align-items: flex-end;

    gap: 1rem;

    margin-bottom: 1.75rem;
  }


  .photography-kicker {
    margin-bottom: 0.5rem;

    font-size: 0.6rem;
  }


  .photography-heading {
    max-width: 100%;

    font-size: clamp(2rem, 9vw, 2.75rem);

    line-height: 0.96;
  }


  /* CONTROLES */

  .photography-controls {
    gap: 0.4rem;
  }


  .photography-arrow {
    width: 42px;
    height: 42px;
  }


  .photography-arrow svg {
    width: 18px;
    height: 18px;
  }


  /*
   * En móvil dejamos solo las flechas.
   * El contador sigue funcionando internamente.
   */

  .photography-counter {
    display: none;
  }


  /* ESCENARIO */

  .photography-carousel-stage {
    left: 50%;

    width: 100vw;

    height: clamp(410px, 120vw, 535px);

    margin-left: -50vw;

    overflow: visible;

    perspective: 1200px;
  }


  /* FOTOGRAFÍAS */

  .photography-slide {
    width: min(70vw, 310px);

    border-radius: 1.25rem;

    box-shadow:
      0 18px 40px
      rgba(28, 20, 16, 0.1);
  }


  .photography-slide.is-active {
    box-shadow:
      0 28px 58px
      rgba(28, 20, 16, 0.18);
  }

}


/* ==========================================================================
   MÓVIL PEQUEÑO
   ========================================================================== */

@media (max-width: 480px) {

  .photography-showcase-header {
    gap: 0.75rem;
  }


  .photography-heading {
    font-size: clamp(1.85rem, 8.5vw, 2.35rem);
  }


  .photography-arrow {
    width: 39px;
    height: 39px;
  }


  .photography-carousel-stage {
    height: clamp(385px, 124vw, 485px);
  }


  .photography-slide {
    width: min(69vw, 285px);
  }

}


/* ==========================================================================
   ACCESIBILIDAD · REDUCIR MOVIMIENTO
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {

  .photography-arrow,
  .photography-slide {
    transition: none !important;
  }

}


/* ==========================================================================
   12. CONTACTO
   ========================================================================== */

/* ==========================================================================
   12. CONTACTO
   ========================================================================== */

#contact {
  position: relative;
}

.contact-card {
  position: relative;
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(4.5rem, 7vw, 6rem) clamp(2rem, 6vw, 5rem);
  overflow: visible;
  border-radius: 2rem;
  background-color: var(--bg-tertiary);
}

.icon-box-top {
  position: absolute;
  top: -32px;
  left: 50%;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background-color: var(--text-dark);
  color: var(--bg-main);
  box-shadow: 0 10px 25px rgba(28, 20, 16, 0.16);
  transform: translateX(-50%);
}

.contact-card-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, 0.85fr);
  align-items: center;
  gap: clamp(3rem, 7vw, 7rem);
}

.contact-card-intro {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.badge-editorial {
  display: inline-block;
  margin-bottom: clamp(2rem, 4vw, 3rem);
  padding: 0.6rem 1.2rem;
  border-radius: 10px;
  background-color: var(--bg-main);
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 600;
}

.contact-card-title {
  width: 100%;
  max-width: none;
  margin: 0;
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: clamp(2.2rem, 4.6vw, 4rem);
  font-weight: 600;
  line-height: 0.92;
  letter-spacing: -0.07em;
}

.contact-title-line,
.contact-card-title .accent-serif {
  display: block;
  white-space: nowrap;
}

.contact-card-title .accent-serif {
  margin-top: 0.16em;
  font-size: 1.05em;
}

.contact-card-description {
  max-width: 510px;
  margin: clamp(1.8rem, 4vw, 2.75rem) 0 0;
  color: rgba(28, 20, 16, 0.66);
  font-size: clamp(0.95rem, 1.3vw, 1.08rem);
  line-height: 1.55;
}

.contact-card-details {
  width: 100%;
  padding-left: clamp(2rem, 4vw, 4rem);
  border-left: 1px solid rgba(28, 20, 16, 0.12);
}

.contact-mini-profile {
  display: flex;
  align-items: center;
  gap: 1.15rem;
  margin-bottom: 2rem;
}

.contact-mini-photo {
  flex-shrink: 0;
  width: 92px;
  height: 108px;
  overflow: hidden;
  border-radius: 1.25rem;
  box-shadow: 0 10px 28px rgba(28, 20, 16, 0.12);
  transform: rotate(-2deg);
}

.contact-mini-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.contact-mini-photo:hover img {
  transform: scale(1.05);
}

.contact-mini-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.contact-mini-info span {
  margin-bottom: 0.35rem;
  color: rgba(28, 20, 16, 0.45);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.contact-mini-info strong {
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 600;
}

.contact-mini-info small {
  margin-top: 0.25rem;
  color: rgba(28, 20, 16, 0.55);
  font-size: 0.78rem;
}

.contact-card-actions {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  width: 100%;
}

.contact-card-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  min-height: 66px;
  padding: 0.75rem 1.25rem;
  border: 2px solid var(--accent);
  border-radius: 1.25rem;
  background-color: var(--accent);
  color: var(--bg-main);
  box-shadow: 0 5px 14px rgba(28, 20, 16, 0.07);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.35s ease,
    color 0.35s ease,
    transform 0.35s ease,
    box-shadow 0.35s ease;
}

.contact-action-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}

.contact-action-label {
  margin-bottom: 0.15rem;
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.65;
}

.contact-action-value {
  max-width: 100%;
  font-family: var(--font-sans);
  font-size: clamp(0.82rem, 1.3vw, 0.95rem);
  font-weight: 600;
  line-height: 1.2;
  text-transform: none;
  overflow-wrap: anywhere;
}

.contact-card-action .icon-copy,
.contact-action-arrow {
  flex-shrink: 0;
  font-size: 1.25rem;
  transition: transform 0.35s ease;
}

.contact-card-action:hover {
  background-color: transparent;
  color: var(--accent);
  box-shadow: 0 10px 24px rgba(109, 3, 3, 0.1);
  transform: translateY(-3px);
}

.contact-card-action:hover .icon-copy {
  transform: scale(1.08);
}

.contact-card-linkedin:hover .contact-action-arrow {
  transform: translate(3px, -3px);
}

.btn-contact-copy.copied {
  border-color: #27ae60;
  background-color: #27ae60;
  color: #fff;
  pointer-events: none;
}

.contact-card-hint {
  margin: 0.85rem 0 0;
  color: rgba(28, 20, 16, 0.42);
  font-size: 0.68rem;
}


/* ==========================================================================
   13. FOOTER
   ========================================================================== */

.footer-tagline-line {
  display: block;
  white-space: nowrap;
}

.minimal-footer {
  padding: 3rem 0 2rem;
  background-color: var(--bg-tertiary);
  color: var(--text-dark);
}

.footer-content-wrapper {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: clamp(3rem, 8vw, 10rem);
  margin-bottom: 3rem;
}

.footer-content-wrapper .footer-box:first-child {
  min-width: 360px;
}

.footer-box {
  min-width: 150px;
  text-align: left;
}

.footer-tagline-medium {
  margin-left: -20px;
  color: var(--text-dark);
  font-size: 1.8rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
}

.footer-label {
  display: block;
  margin-bottom: 1.2rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.5;
}

.footer-list {
  padding: 0;
  list-style: none;
}

.footer-list a {
  color: var(--text-dark);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
}

.footer-list a:hover {
  color: var(--accent);
}

.social-circles {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 1rem;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--accent);
  color: var(--bg-main);
  transition: all 0.3s ease;
}

.social-icon:hover {
  opacity: 0.8;
  transform: translateY(-4px);
}

.footer-email-link {
  color: var(--text-dark);
  font-size: 0.85rem;
  text-decoration: none;
  opacity: 0.7;
}

.footer-credits-centered {
  padding-top: 1.5rem;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  font-size: 0.75rem;
  text-align: center;
  opacity: 0.4;
}


/* ==========================================================================
   14. UTILIDADES
   ========================================================================== */

.gsap-reveal {
  opacity: 0;
  transform: translateY(30px);
}


/* ==========================================================================
   15. ERROR 404
   Se mantiene por seguridad si la hoja también se usa en la página 404.
   ========================================================================== */

.error-page {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100vh;
  overflow: hidden;
  background-color: var(--bg-main);
  text-align: center;
}

.error-container {
  max-width: 600px;
  padding: 2rem;
}

.error-code {
  margin-bottom: 1rem;
  color: var(--text-dark);
  font-family: var(--font-sans);
  font-size: clamp(6rem, 15vw, 10rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.05em;
}

.error-message {
  margin-bottom: 2.5rem;
  color: var(--text-dark);
  font-size: clamp(1.2rem, 4vw, 1.8rem);
  font-weight: 500;
  opacity: 0.8;
}

.btn-back-home {
  display: inline-block;
  padding: 1rem 2.5rem;
  border: 2px solid transparent;
  border-radius: 50px;
  background-color: var(--accent);
  color: var(--bg-main);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-decoration: none;
  text-transform: uppercase;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.btn-back-home:hover {
  border-color: var(--accent);
  background-color: transparent;
  color: var(--accent);
  transform: translateY(-5px);
}


/* ==========================================================================
   16. RESPONSIVE · TABLET + MÓVIL
   ========================================================================== */

@media (max-width: 1024px) {
  section {
    padding-block: 3rem !important;
  }

  .navbar-custom {
    backdrop-filter: blur(8px);
  }

  .marquee-group img,
  .photo-area img {
    filter: grayscale(0%) !important;
    opacity: 1 !important;
  }

  #master-stage {
    display: block;
    min-height: auto !important;
    height: auto !important;
    padding-top: 120px !important;
    padding-bottom: 60px !important;
    overflow: visible !important;
  }

  .stage-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    height: auto !important;
    margin-top: 0;
    gap: 30px;
  }

  .hero-text,
  .card-layer,
  .text-layer {
    position: relative !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
    min-height: auto !important;
    height: auto !important;
  }

  #heroText {
    visibility: visible !important;
    transform: none !important;
  }

  .hero-text {
    display: contents;
  }

  .hero-ref-left {
    order: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    margin-bottom: 0;
    padding-top: 0;
    text-align: center;
  }

  .hero-ref-name {
    width: 100%;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    text-align: center;
  }

  .hero-ref-left .hero-ref-big,
  .hero-ref-right .hero-ref-big {
    width: 100%;
    margin: 0;
    font-size: 15vw !important;
    line-height: 1;
    text-align: center;
  }

  .card-layer {
    order: 2;
    z-index: 5;
    width: 100%;
    margin: 0;
    padding: 0;
  }

  .tilt-stage {
    overflow: visible !important;
    perspective: none !important;
  }

  .tilt-card {
    width: 70vw !important;
    height: 85vw !important;
    max-width: 400px;
    max-height: 500px;
    margin: 0 auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    transform: none !important;
    visibility: visible !important;
  }

  .card-front {
    display: block !important;
    visibility: visible !important;
    transform: none !important;
  }

  .card-back {
    display: none !important;
  }

  .hero-ref-right {
    order: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    padding-top: 0 !important;
    text-align: center;
  }

  .hero-ref-sub {
    width: 100%;
    margin-top: 1rem;
    padding: 0 1rem;
    font-size: 1rem;
    text-align: center;
  }

  .services-text {
    position: relative !important;
    order: 6;
    z-index: 10 !important;
    display: block !important;
    width: 100% !important;
    min-height: auto !important;
    height: auto !important;
    padding-top: 3rem !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .services-text .col-lg-6 {
    width: 100% !important;
    padding-right: 0 !important;
  }

  .services-accordion {
    width: 100% !important;
  }

  .hero-ghost-center {
    display: none;
  }

  .wave-badge {
    left: -10px;
    bottom: -10px;
    z-index: 50 !important;
    width: 80px;
    height: 80px;
  }

  .project-card .project-card-media img {
    opacity: 1 !important;
  }

  #contact {
    margin-top: 0 !important;
  }

  /* Software: el espacio aumenta progresivamente con el ancho. */
  .software-marquee {
    --software-gap: clamp(1.6rem, 4.4vw, 2.8rem);
    --software-gap-half: clamp(0.8rem, 2.2vw, 1.4rem);
    width: 100%;
    padding-block: 0.7rem;
    overflow: hidden;
  }

  .marquee-track {
    display: flex;
    align-items: center;
    width: max-content;
    gap: var(--software-gap) !important;
    animation: software-responsive-loop 25s linear infinite !important;
    will-change: transform;
  }

  .marquee-group {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-shrink: 0;
    min-width: max-content;
    gap: var(--software-gap) !important;
  }

  .marquee-group img {
    flex-shrink: 0;
    width: auto;
    height: clamp(38px, 4.7vw, 44px) !important;
  }
}

@keyframes software-responsive-loop {
  from { transform: translateX(0); }
  to {
    transform: translateX(calc(-50% - var(--software-gap-half)));
  }
}


/* ==========================================================================
   17. RESPONSIVE · TABLET HORIZONTAL
   ========================================================================== */

@media (min-width: 768px) and (max-width: 1024px) and (orientation: landscape) {
  #master-stage {
    min-height: auto !important;
    height: auto !important;
    padding: 95px 0 3rem !important;
    overflow: visible !important;
  }

  .stage-inner {
    --tablet-card-width: clamp(200px, 25vw, 280px);
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) var(--tablet-card-width) minmax(0, 1fr) !important;
    grid-template-rows: auto auto !important;
    align-items: center !important;
    column-gap: clamp(0.8rem, 2vw, 1.5rem) !important;
    row-gap: 0 !important;
    height: auto !important;
    overflow: visible !important;
  }

  .card-layer {
    position: relative !important;
    grid-column: 2;
    grid-row: 1;
    order: initial !important;
    z-index: 30 !important;
    width: var(--tablet-card-width) !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  .tilt-stage {
    position: relative !important;
    width: 100% !important;
    height: auto !important;
    overflow: visible !important;
  }

  .tilt-card {
    width: 100% !important;
    height: clamp(300px, 36vw, 400px) !important;
    min-height: 0 !important;
    max-width: none !important;
    max-height: none !important;
    margin: 0 auto !important;
    overflow: visible !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
  }

  #heroText,
  .hero-text {
    position: relative !important;
    grid-column: 1 / -1;
    grid-row: 1;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) var(--tablet-card-width) minmax(0, 1fr) !important;
    align-items: center !important;
    width: 100% !important;
    min-width: 0;
    height: auto !important;
    overflow: visible !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    z-index: 11;
  }

  .hero-ghost-center {
    grid-column: 2 !important;
    grid-row: 1 !important;
    order: 0 !important;
    display: block !important;
    width: var(--tablet-card-width) !important;
    height: 1px !important;
    min-height: 0 !important;
    visibility: hidden !important;
  }

  .hero-ref-left,
  .hero-ref-right {
    position: relative;
    grid-row: 1 !important;
    order: 0 !important;
    z-index: 12;
    min-width: 0 !important;
    width: max-content !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
  }

  .hero-ref-left {
    grid-column: 1 !important;
    justify-self: end !important;
    align-items: flex-start !important;
    padding: 0 !important;
    text-align: left !important;
  }

  .hero-ref-right {
    grid-column: 3 !important;
    justify-self: start !important;
    align-items: flex-start !important;
    padding-top: 1.7rem !important;
    text-align: left !important;
  }

  .hero-ref-left .hero-ref-big,
  .hero-ref-right .hero-ref-big {
    width: auto !important;
    max-width: none !important;
    margin: 0 !important;
    font-size: clamp(2.5rem, 5.8vw, 4rem) !important;
    line-height: 0.9;
    text-align: left !important;
    white-space: nowrap;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
  }

  .hero-ref-name {
    width: 100% !important;
    margin: 0 0 0.45rem !important;
    padding: 0 !important;
    font-size: 0.92rem;
    text-align: left !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
  }

  .hero-ref-sub {
    width: auto !important;
    margin: 0.65rem 0 0 !important;
    padding: 0 !important;
    font-size: 0.86rem;
    text-align: left !important;
    white-space: nowrap;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
  }

  .services-text {
    position: relative !important;
    grid-column: 1 / -1;
    grid-row: 2;
    order: initial !important;
    z-index: 10 !important;
    display: block !important;
    width: 100% !important;
    min-height: auto !important;
    height: auto !important;
    padding-top: 4.5rem !important;
    padding-bottom: 1rem !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .services-text .col-lg-6 {
    width: 100% !important;
    max-width: 680px;
    padding-right: 0 !important;
  }
}


/* ==========================================================================
   18. RESPONSIVE · TABLET VERTICAL
   ========================================================================== */

@media (min-width: 768px) and (max-width: 1024px) and (orientation: portrait) {
  #master-stage {
    padding-top: 110px !important;
  }

  .hero-ref-left .hero-ref-big,
  .hero-ref-right .hero-ref-big {
    font-size: clamp(5rem, 13vw, 7rem) !important;
  }

  .tilt-card {
    width: min(52vw, 400px) !important;
    height: min(64vw, 500px) !important;
  }

  .services-text {
    padding-top: 4rem !important;
  }
}


/* ==========================================================================
   19. RESPONSIVE · PORTÁTIL / ESCRITORIO
   ========================================================================== */

@media (min-width: 768px) and (orientation: landscape) {
  .hero-ref-left {
    position: relative;
    left: calc(-1 * clamp(1.5rem, 3vw, 3rem));
    align-items: flex-start !important;
    text-align: left !important;
  }

  .hero-ref-name {
    width: 100% !important;
    margin: 0 0 0.45rem !important;
    padding: 0 !important;
    text-align: left !important;
  }

  .hero-ref-left .hero-ref-big {
    text-align: left !important;
  }
}

@media (min-width: 1025px) and (max-width: 1399px) {
  .hero-text {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) !important;
    column-gap: clamp(1.25rem, 2.5vw, 2.5rem) !important;
    overflow: visible !important;
  }

  .tilt-card {
    width: calc(clamp(430px, 60vh, 540px) * 0.68) !important;
    height: clamp(430px, 60vh, 540px) !important;
    min-height: 0 !important;
  }

  .hero-ghost-center {
    width: calc(clamp(430px, 60vh, 540px) * 0.68) !important;
    height: 1px !important;
    min-height: 0 !important;
  }

  .hero-ref-big {
    font-size: clamp(4.2rem, 6.5vw, 5.5rem) !important;
    line-height: 0.9;
    white-space: nowrap;
  }
}

@media (min-width: 1025px) and (max-height: 850px) {
  .tilt-card {
    width: calc(clamp(430px, 68vh, 590px) * 0.68) !important;
    height: clamp(430px, 68vh, 590px) !important;
    min-height: 0 !important;
  }

  .hero-ghost-center {
    width: calc(clamp(430px, 68vh, 590px) * 0.68) !important;
    height: 1px !important;
    min-height: 0 !important;
  }

  .hero-ref-name {
    font-size: clamp(1rem, 1.5vw, 1.25rem);
  }

  .hero-ref-sub {
    font-size: clamp(0.95rem, 1.3vw, 1.15rem);
  }
}

@media (min-width: 1400px) and (max-height: 850px) {
  .hero-ref-big {
    font-size: clamp(4.75rem, 8vw, 7rem) !important;
  }
}


/* ==========================================================================
   20. RESPONSIVE · NAVBAR INTERMEDIO
   ========================================================================== */

@media (min-width: 992px) and (max-width: 1350px) {
  .navbar-custom .container {
    width: calc(100% - 2.5rem) !important;
    max-width: 1140px !important;
    margin-inline: auto !important;
    padding-inline: 0 !important;
    flex-wrap: nowrap !important;
  }

  .navbar-collapse {
    min-width: 0;
  }

  .navbar-nav {
    align-items: center;
    flex-wrap: nowrap !important;
  }

  .navbar-nav .nav-link {
    padding-inline: 0.55rem;
    font-size: 0.78rem;
  }

  .btn-navbar-cta {
    margin-left: 0.8rem;
    padding: 0.58rem 1.35rem !important;
    white-space: nowrap;
  }
}

@media (min-width: 992px) and (max-width: 1150px) {
  .navbar-nav .nav-link {
    padding-inline: 0.4rem;
    font-size: 0.72rem;
  }

  .btn-navbar-cta {
    margin-left: 0.55rem;
    padding: 0.55rem 1rem !important;
  }
}


/* ==========================================================================
   21. RESPONSIVE · TABLET GENERAL
   ========================================================================== */

@media (max-width: 991px) {

  .navbar-nav .nav-item:last-child {
  width: 100%;
}
  .btn-navbar-cta {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 100%;

  margin: 1rem 0 0;

  padding: 0.8rem 1.5rem !important;

  text-align: center;
}

  .experience-heading {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 1.5rem;
  }

  .projects-grid {
    gap: 1.25rem;
  }

  .project-card-media {
    border-radius: 1.25rem;
  }

  .featured-motion {
    grid-template-columns: minmax(0, 1.4fr) minmax(230px, 0.8fr);
    gap: 2rem;
  }

  .featured-motion-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
  }

  .featured-motion-description {
    font-size: 0.95rem;
  }

  .contact-card-grid {
    grid-template-columns: minmax(0, 1fr) minmax(300px, 0.8fr);
    gap: 3rem;
  }

  .contact-card-details {
    padding-left: 2rem;
  }

  .contact-mini-photo {
    width: 78px;
    height: 94px;
  }
}

@media (min-width: 769px) and (max-width: 991px) {
  .footer-content-wrapper {
    gap: 3rem;
  }

  .footer-content-wrapper .footer-box:first-child {
    min-width: 275px;
  }

  .footer-tagline-medium {
    margin-left: 0;
    font-size: clamp(1.4rem, 3vw, 1.7rem);
  }
}


@media (max-width: 768px) {
  .footer-content-wrapper {
    flex-direction: column;
    align-items: center;
    gap: 2.5rem;
    text-align: center;
  }

  .social-circles {
    justify-content: center;
  }

  .footer-tagline-medium {
    margin-left: 0;
    margin-bottom: 1rem;
    font-size: 2.2rem;
  }
}


/* ==========================================================================
   22. RESPONSIVE · MÓVIL
   ========================================================================== */

@media (max-width: 767px) {
  #master-stage {
    padding-top: 100px !important;
    padding-bottom: 0 !important;
  }

  .card-front img {
    object-position: center 30% !important;
  }

  .services-text .lead {
    max-width: 100%;
    font-size: 0.95rem !important;
    line-height: 1.45;
  }

  .accordion-content li {
    font-size: 0.95rem;
  }

  .services-accordion {
    margin-bottom: 1rem !important;
  }

  #software {
    padding-top: 1.25rem !important;
    padding-bottom: 2.5rem !important;
  }

  #software .container {
    margin-bottom: 0.75rem !important;
  }

  .software-badge {
    margin-bottom: 0 !important;
    font-size: 1rem;
  }

  #about h2.display-3 {
    margin-bottom: 1.4rem !important;
    font-size: clamp(2.15rem, 10vw, 3rem) !important;
    line-height: 0.95;
  }

  #about h2.display-3 > .d-block {
    white-space: nowrap;
  }

  .hybrid-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr) !important;
    grid-template-rows: auto 1fr 1fr auto;
    gap: 0.85rem !important;
  }

  .bio-area {
    order: initial !important;
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .photo-area {
    order: initial !important;
    grid-column: 2 / 3;
    grid-row: 2 / 4;
    min-height: 245px !important;
    max-height: none !important;
    height: auto !important;
  }

  .photo-area img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
  }

  .info-area-1 {
    order: initial !important;
    grid-column: 1 / 2;
    grid-row: 2;
  }

  .info-area-2 {
    order: initial !important;
    grid-column: 1 / 2;
    grid-row: 3;
  }

  .info-area-1 .p-4,
  .info-area-2 .p-4 {
    padding: 1rem !important;
  }

  .info-area-1 h5,
  .info-area-2 h5 {
    font-size: 0.95rem;
    line-height: 1.1;
  }

  .info-area-1 p,
  .info-area-2 p {
    font-size: 0.7rem !important;
    line-height: 1.3;
  }

  .info-area-1 .editorial-label,
  .info-area-2 .editorial-label {
    font-size: 0.58rem;
  }

  .cta-area {
    order: initial !important;
    grid-column: 1 / -1;
    grid-row: 4;
  }

  .cta-link-rounded {
    padding: 1.15rem 1.4rem;
    font-size: 0.95rem;
  }

  .cta-link-rounded svg {
    width: 26px;
    height: 26px;
  }

  .experience-section {
    padding-block: 5rem;
  }

  .experience-title {
    width: 100%;
    font-size: clamp(2.4rem, 11vw, 3.2rem) !important;
    line-height: 0.92;
  }

  .experience-title .accent-serif {
    display: block;
    margin-top: 0.08em;
    white-space: nowrap;
  }

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

  .experience-card-featured {
    grid-column: auto;
  }

  .experience-card {
    min-height: auto;
    padding: 1.5rem;
    border-radius: 1.5rem;
  }

  .experience-card-top {
    flex-direction: column;
    gap: 1rem;
  }

  .experience-stages {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .projects-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem 0.75rem;
  }

  .project-card-media {
    aspect-ratio: 4 / 5;
    border-radius: 0.9rem;
  }

  .project-modal-content {
    padding: 0.25rem;
  }

  .project-modal-intro {
    margin-bottom: 2rem;
  }

  .project-modal-title {
    font-size: 2.4rem;
  }

  .project-modal-subtitle {
    margin-bottom: 1.25rem;
    font-size: 1.25rem;
  }

  .project-modal-description,
  .project-concept p {
    font-size: 0.9rem;
  }

  .project-software-list {
    gap: 1.25rem;
  }

  .project-software-item img {
    width: 28px;
    height: 28px;
  }

  .project-carousel-stage {
    aspect-ratio: 4 / 3;
    border-radius: 0.9rem;
  }

  .project-slide-frame {
    padding: 0.35rem;
  }

  .project-video-toggle {
    width: 58px;
    height: 58px;
  }

  .project-carousel-control {
    width: 40px;
    height: 40px;
  }

  .project-modal-carousel .carousel-control-prev {
    left: 0.35rem;
  }

  .project-modal-carousel .carousel-control-next {
    right: 0.35rem;
  }

  .project-modal-carousel .carousel-control-prev-icon,
  .project-modal-carousel .carousel-control-next-icon {
    width: 1.4rem;
    height: 1.4rem;
  }

  .featured-motion {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 3.5rem;
  }

  .featured-motion-media {
    border-radius: 1.25rem;
  }

  .featured-motion-info {
    padding-inline: 0.25rem;
  }

  .featured-motion-category {
    margin-bottom: 0.65rem;
  }

  .featured-motion-title {
    margin-bottom: 1rem;
    font-size: 1.8rem;
  }

  .featured-motion-description {
    max-width: none;
    font-size: 0.9rem;
  }

  .featured-motion-tools {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
  }

  .featured-motion-icons {
    gap: 1rem;
  }

  .featured-motion-tool img {
    width: 25px;
    height: 25px;
  }

  .featured-motion-tool span {
    font-size: 0.72rem;
  }

  #contact {
    margin-top: 4rem !important;
  }

  .contact-card {
    padding: 4rem 1.25rem 1.75rem;
    border-radius: 1.5rem;
  }

  .icon-box-top {
    top: -29px;
    width: 58px;
    height: 58px;
    border-radius: 14px;
  }

  .contact-card-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .contact-card-intro {
    align-items: center;
    text-align: center;
  }

  .contact-card-title {
    font-size: clamp(1.9rem, 9vw, 2.55rem) !important;
    line-height: 0.94;
  }

  .contact-card-description {
    margin-left: auto;
    margin-right: auto;
  }

  .contact-card-details {
    padding-top: 2rem;
    padding-left: 0;
    border-top: 1px solid rgba(28, 20, 16, 0.12);
    border-left: 0;
  }

  .contact-mini-profile {
    justify-content: center;
  }

  .contact-mini-photo {
    width: 76px;
    height: 90px;
  }

  .contact-card-action {
    min-height: 62px;
  }

  .contact-card-hint {
    text-align: center;
  }

  .footer-content-wrapper .footer-box:first-child {
    width: 100%;
    min-width: 0;
  }

  .footer-tagline-medium {
    margin: 0 auto 1rem;
    font-size: clamp(1.35rem, 6.6vw, 1.7rem);
    line-height: 1.22;
    text-align: center;
  }
}

@media (hover: none) and (max-width: 1024px) {
  .project-mobile-info {
    display: block !important;
    padding: 0.5rem 0.05rem 0;
  }

  .project-mobile-info span {
    display: block;
    margin-bottom: 0.18rem;
    color: rgba(28, 20, 16, 0.56);
    font-size: clamp(0.56rem, 1.25vw, 0.68rem) !important;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: 0.04em;
    text-transform: uppercase;
  }

  .project-mobile-info h3 {
    margin: 0;
    color: var(--text-dark);
    font-family: var(--font-sans);
    font-size: clamp(0.9rem, 2vw, 1.15rem) !important;
    font-weight: 600;
    line-height: 1.08;
    letter-spacing: -0.035em;
  }
}

@media (max-width: 480px) {
  .hero-ref-left .hero-ref-big,
  .hero-ref-right .hero-ref-big {
    font-size: 16vw !important;
  }

  .stage-inner {
    gap: 20px;
  }
}


/* ==========================================================================
   23. ACCESIBILIDAD · REDUCIR MOVIMIENTO
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  .experience-card,
  .experience-card::before,
  .experience-card::after,
  .experience-card-number,
  .experience-external-link span {
    transition: none !important;
  }
}