:root {
  --bg:        #12111a;
  --surface:   #1d1c28;
  --surface2:  #272535;
  --border:    rgba(255,255,255,0.08);
  --text:      #ece9f5;
  --muted:     #7d7a95;
  --accent:    #f5b8cc;
  --accent2:   #f5d0dc;
  --green:     #a8f5c8;
  --glow-a:    rgba(245,184,204,0.14);
  --glow-b:    rgba(245,208,220,0.10);
  --nav-bg:    rgba(18,17,26,0.82);
  --footer-bg: #0e0d16;
}

[data-theme="light"] {
  --bg:        #fdf0f4;
  --surface:   #fef6f8;
  --surface2:  #fce8ee;
  --border:    rgba(200,140,160,0.15);
  --text:      #3a2530;
  --muted:     #9a7585;
  --accent:    #c4607a;
  --accent2:   #d4849a;
  --green:     #2da876;
  --glow-a:    rgba(196,96,122,0.08);
  --glow-b:    rgba(212,132,154,0.06);
  --nav-bg:    rgba(253,240,244,0.9);
  --footer-bg: #fce8ee;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Outfit', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  transition: background 0.35s, color 0.35s;
}

h1, h2, h3, .hero-name, .section-title, .data-section-title,
.tl-trigger-year, .team-name, .nav-brand {
  font-family: 'Playfair Display', Georgia, serif;
}

/* ══════════════════════════════
   NAV
══════════════════════════════ */

nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 3rem;
  height: 72px;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: background 0.35s, border-color 0.35s;
}

.nav-brand {
  font-size: 1.35rem;
  font-weight: 500;
  font-style: italic;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.nav-brand em {
  color: var(--accent);
  font-style: normal;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
}

.nav-links a {
  font-family: 'Outfit', sans-serif;
  font-size: 0.92rem;
  font-weight: 400;
  color: var(--muted);
  text-decoration: none;
  padding: 0.45rem 1rem;
  border-radius: 8px;
  transition: all 0.2s;
}

.nav-links a:hover {
  color: var(--text);
  background: var(--surface2);
}

.theme-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 0.4rem 1rem;
  cursor: pointer;
  color: var(--muted);
  font-family: 'Outfit', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  transition: all 0.2s;
  white-space: nowrap;
}

.theme-btn:hover {
  color: var(--text);
  border-color: var(--accent);
}

.theme-icon {
  font-size: 1rem;
}

/* ══════════════════════════════
   HERO INDEX
══════════════════════════════ */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px 5vw 60px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: var(--hero-bg-img);
  background-size: cover;
  background-position: center;
  filter: blur(7px) saturate(0.7) brightness(0.55);
  transform: scale(1.08);
  z-index: 0;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at center,
    rgba(18,17,26,0.25) 0%,
    rgba(18,17,26,0.55) 100%
  );
}

.hero::before {
  content: '';
  position: absolute;
  top: 5%;
  left: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--glow-a) 0%, transparent 65%);
  pointer-events: none;
  z-index: 1;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 5%;
  right: -5%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--glow-b) 0%, transparent 65%);
  pointer-events: none;
  z-index: 1;
}

.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.2fr auto 0.4fr;
  align-items: center;
  gap: 4rem;
  width: 100%;
  max-width: 1200px;
}

.hero-content {
  grid-column: 1;
  display: flex;
  flex-direction: column;
}

.hero-avatar-col {
  grid-column: 2;
  display: flex;
  justify-content: center;
}

.hero-right-spacer {
  grid-column: 3;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(245,184,204,0.1);
  border: 1px solid rgba(245,184,204,0.25);
  color: var(--accent);
  font-family: 'Outfit', sans-serif;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.3rem 0.85rem;
  border-radius: 100px;
  margin-bottom: 2rem;
  animation: fadeUp 0.6s ease both;
  width: fit-content;
}

.hero-badge::before {
  content: '';
  width: 5px;
  height: 5px;
  background: var(--green);
  border-radius: 50%;
  box-shadow: 0 0 6px var(--green);
}

.hero-name {
  font-size: clamp(3.5rem, 7vw, 6.5rem);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.01em;
  margin-bottom: 1.5rem;
  animation: fadeUp 0.6s 0.1s ease both;
}

.hero-name .grad {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-style: italic;
}

.hero-sub {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  color: #fff;
  margin-bottom: 1.75rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  opacity: 0.85;
  animation: fadeUp 0.6s 0.2s ease both;
}

.hero-desc {
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  color: rgba(255,255,255,0.75);
  max-width: 460px;
  line-height: 1.85;
  margin-bottom: 2.5rem;
  opacity: 0.75;
  animation: fadeUp 0.6s 0.3s ease both;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  animation: fadeUp 0.6s 0.4s ease both;
}

.tag-link {
  text-decoration: none;
  display: inline-block;
  width: fit-content;
}

.tag-camera {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 32 32'%3E%3Ctext y='24' font-size='24'%3E%F0%9F%93%B7%3C/text%3E%3C/svg%3E") 16 16, pointer;
}

.tag {
  font-family: 'Outfit', sans-serif;
  font-size: 0.72rem;
  font-weight: 400;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 0.28rem 0.7rem;
  border-radius: 6px;
  transition: all 0.2s;
  backdrop-filter: blur(4px);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

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

/* ══════════════════════════════
   AVATAR
══════════════════════════════ */

.avatar-card {
  position: relative;
  z-index: 1;
  animation: fadeUp 0.7s 0.2s ease both;
}

.avatar-inner {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  width: 320px;
  transition: background 0.35s, border-color 0.35s, box-shadow 0.35s;
  box-shadow: 0 24px 60px rgba(0,0,0,0.45);
}

.avatar-inner img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease, filter 0.35s ease;
}

.avatar-inner:hover img {
  transform: scale(1.03);
  filter: brightness(1.08);
}

.avatar-inner:hover {
  border-color: var(--accent);
  box-shadow: 0 24px 70px rgba(245,184,204,0.2), 0 0 0 1px rgba(245,184,204,0.15);
}

.avatar-meta {
  padding: 1.1rem 1.4rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.avatar-meta-name {
  font-family: 'Playfair Display', serif;
  font-weight: 500;
  font-size: 1rem;
  letter-spacing: 0.01em;
}

.avatar-meta-role {
  font-family: 'Outfit', sans-serif;
  font-size: 0.7rem;
  color: var(--muted);
  margin-top: 0.1rem;
}

.avatar-dot {
  width: 8px;
  height: 8px;
  background: var(--green);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--green);
}

/* ══════════════════════════════
   SECCIONES GENERALES
══════════════════════════════ */

section {
  padding: 6rem 5vw;
  position: relative;
}

section + section {
  border-top: 1px solid var(--border);
}

.section-header {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 3rem;
}

.section-num {
  font-family: 'Outfit', sans-serif;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.12em;
  opacity: 0.7;
}

.section-title {
  font-size: 2.6rem;
  font-weight: 300;
  letter-spacing: -0.01em;
}

/* ══════════════════════════════
   TIMELINE
══════════════════════════════ */

.tl-grid-years {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.25rem;
}

.tl-year-card {
  position: relative;
  cursor: pointer;
  user-select: none;
  text-align: center;
}

.tl-year-front {
  aspect-ratio: 1 / 1;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1.4rem;
  transition: all 0.22s;
  position: relative;
  overflow: hidden;
  text-align: center;
}

.tl-year-front::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--glow-a), transparent 70%);
  opacity: 0;
  transition: opacity 0.22s;
}

.tl-year-card:hover .tl-year-front,
.tl-year-card.open .tl-year-front {
  border-color: var(--accent);
}

.tl-year-card.open .tl-year-front::before {
  opacity: 1;
}

.tl-trigger-year {
  font-size: 2.1rem;
  font-weight: 300;
  color: var(--accent);
  line-height: 1;
  letter-spacing: -0.02em;
  position: relative;
}

.tl-card-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  position: relative;
}

.tl-badge-all {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: rgba(168,245,200,0.1);
  border: 1px solid rgba(168,245,200,0.25);
  color: var(--green);
  font-family: 'Outfit', sans-serif;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border-radius: 100px;
  width: fit-content;
}

.tl-badge-progress {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: rgba(245,184,204,0.1);
  border: 1px solid rgba(245,184,204,0.25);
  color: var(--accent);
  font-family: 'Outfit', sans-serif;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border-radius: 100px;
  width: fit-content;
}

.tl-count {
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  color: var(--muted);
}

.tl-plus {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--accent);
  font-size: 1.1rem;
  font-weight: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s;
  line-height: 1;
  z-index: 1;
}

.tl-year-card.open .tl-plus {
  transform: rotate(45deg);
  background: rgba(245,184,204,0.15);
}

.tl-drawer {
  grid-column: 1 / -1;
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s ease;
}

.tl-drawer.open {
  grid-template-rows: 1fr;
}

.tl-drawer-inner {
  overflow: hidden;
}

.tl-drawer-content {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 1.5rem 2rem;
  margin-top: 0.75rem;
}

.tl-sublabel {
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  color: var(--muted);
  font-style: italic;
  margin: 0.75rem 0 0.5rem;
}

.tl-sublabel:first-child {
  margin-top: 0;
}

.tl-items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 0.5rem;
}

.tl-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.65rem 1rem;
  gap: 0.75rem;
  transition: border-color 0.15s;
}

.tl-item:hover {
  border-color: rgba(245,184,204,0.25);
}

.tl-name {
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
}

.tl-status {
  font-family: 'Outfit', sans-serif;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.18rem 0.5rem;
  border-radius: 5px;
  white-space: nowrap;
  flex-shrink: 0;
}

.tl-status.current {
  background: rgba(168,245,200,0.1);
  color: var(--green);
  border: 1px solid rgba(168,245,200,0.25);
}

.tl-status.done {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
}

/* ══════════════════════════════
   EQUIPO
══════════════════════════════ */

.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  justify-items: center;
}

.team-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 1.3rem;
  text-align: center;
  text-decoration: none;
  color: inherit;
  width: 100%;
  max-width: 280px;
  aspect-ratio: 1 / 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  transition: all 0.25s;
}

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

.team-card.me {
  border-color: rgba(245,184,204,0.35);
}

.team-img {
  width: 125px;
  height: 125px;
  border-radius: 18px;
  object-fit: cover;
  border: 2px solid var(--border);
  transition: border-color 0.25s;
}

.team-card:hover .team-img {
  border-color: var(--accent);
}

.team-you-badge {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: white;
  font-family: 'Outfit', sans-serif;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.22rem 0.65rem;
  border-radius: 100px;
}

.team-name {
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1.2;
}

.team-role {
  font-family: 'Outfit', sans-serif;
  font-size: 0.82rem;
  color: var(--muted);
}

/* ══════════════════════════════
   INSTITUCIÓN
══════════════════════════════ */

.inst-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 18px;
  overflow: hidden;
}

.inst-row {
  display: contents;
}

.inst-cell {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
  transition: background 0.2s;
}

.inst-cell:nth-child(even) {
  border-right: none;
}

.inst-row:last-child .inst-cell {
  border-bottom: none;
}

.inst-cell:hover {
  background: var(--surface2);
}

.inst-label {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 400;
  font-style: italic;
  color: var(--accent);
  margin-bottom: 0.85rem;
  letter-spacing: 0.01em;
}

.inst-entry {
  margin-bottom: 0.5rem;
}

.inst-key {
  font-family: 'Outfit', sans-serif;
  font-size: 0.6rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--muted);
  margin-bottom: 0.1rem;
}

.inst-val {
  font-family: 'Outfit', sans-serif;
  font-size: 0.88rem;
  line-height: 1.5;
}

.experiencia-texto {
  max-width: calc(50% - 1.5rem);
  display: flex;
  flex-direction: column;
}

.experiencia-texto .inst-key {
  display: block;
  margin-bottom: 0.35rem;
}

.experiencia-texto .inst-val {
  display: block;
  text-align: justify;
}

/* ══════════════════════════════
   FOOTER
══════════════════════════════ */

footer {
  background: var(--footer-bg);
  border-top: 1px solid var(--border);
  padding: 2.5rem 5vw;
  display: flex;
  align-items: center;
  gap: 2rem;
  transition: background 0.35s;
}

footer img {
  height: 30px;
  opacity: 0.35;
  filter: brightness(10);
}

footer p {
  font-family: 'Outfit', sans-serif;
  font-size: 0.73rem;
  color: var(--muted);
  line-height: 1.75;
  max-width: 620px;
}

/* ══════════════════════════════
   PORTFOLIO
══════════════════════════════ */

.portfolio-showcase {
  min-height: calc(100vh - 72px);
  padding: 72px 5vw 5rem;
  background:
    radial-gradient(circle at center, rgba(245,184,204,0.22), transparent 32%),
    radial-gradient(circle at center, rgba(245,208,220,0.12), transparent 48%),
    #020202;
  overflow: hidden;
  position: relative;
  border-top: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

/* TÍTULO PORTFOLIO */

.portfolio-intro {
  width: 100%;
  text-align: center;
  max-width: 1150px;
  margin: clamp(2.2rem, 4vw, 3.6rem) auto clamp(1.7rem, 3vw, 2.2rem);
  position: relative;
  z-index: 2;
  animation: fadeUp 0.6s ease both;
}

.portfolio-kicker {
  color: var(--accent);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  margin-bottom: 2.2rem;
}

.portfolio-intro h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(3rem, 5vw, 5.8rem);
  font-weight: 300;
  line-height: 0.95;
  margin-bottom: 0.9rem;
  color: #fff;
}

.portfolio-intro p {
  color: rgba(255,255,255,0.68);
  font-size: clamp(0.92rem, 1.1vw, 1.05rem);
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
  white-space: normal;
}

/* CURSORES */

.instagram-cursor {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 32 32'%3E%3Crect x='3' y='3' width='26' height='26' rx='8' fill='%23d6249f'/%3E%3Ccircle cx='16' cy='16' r='7' fill='none' stroke='white' stroke-width='3'/%3E%3Ccircle cx='23' cy='9' r='2.5' fill='white'/%3E%3C/svg%3E") 16 16, pointer;
}

.camera-cursor {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 32 32'%3E%3Ctext y='24' font-size='24'%3E%F0%9F%93%B7%3C/text%3E%3C/svg%3E") 16 16, pointer;
}

/* IMÁGENES PORTFOLIO */

.visual-stage {
  width: 100%;
  max-width: 1760px;
  margin: clamp(1rem, 2vw, 2rem) auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(0.55rem, 1.2vw, 2.3rem);
  perspective: 1000px;
  position: relative;
  z-index: 1;
}

.visual-stage::before {
  content: '';
  position: absolute;
  width: clamp(260px, 30vw, 560px);
  height: clamp(260px, 30vw, 560px);
  background: var(--accent);
  filter: blur(clamp(75px, 8vw, 135px));
  opacity: 0.34;
  z-index: -1;
  left: 50%;
  top: 55%;
  transform: translate(-50%, -50%);
}

.visual-stage::after {
  content: '';
  position: absolute;
  width: 4px;
  height: clamp(230px, 27vw, 460px);
  background: var(--accent);
  box-shadow: 0 0 28px var(--accent), 0 0 70px rgba(245,184,204,0.5);
  z-index: 5;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.visual-card {
  flex: 0 1 clamp(120px, 13.5vw, 290px);
  width: clamp(120px, 13.5vw, 290px);
  aspect-ratio: 0.62;
  min-height: 225px;
  max-height: 470px;
  border-radius: clamp(13px, 1.3vw, 24px);
  overflow: hidden;
  display: block;
  background: #111;
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 34px 95px rgba(0,0,0,0.72);
  transition: all 0.35s ease;
  position: relative;
  text-decoration: none;
}

.visual-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  filter: saturate(1) contrast(1.05);
  transition: all 0.35s ease;
}

/* PROFUNDIDAD */

.card-1 {
  transform: scale(0.9) translateY(18px);
  opacity: 0.85;
  z-index: 1;
}

.card-2 {
  transform: scale(0.96) translateY(8px);
  opacity: 0.95;
  z-index: 2;
}

.card-3 {
  transform: scale(1.03);
  opacity: 1;
  z-index: 3;
}

.card-4 {
  transform: scale(1.03);
  opacity: 1;
  z-index: 3;
}

.card-5 {
  transform: scale(0.96) translateY(8px);
  opacity: 0.95;
  z-index: 2;
}

.card-6 {
  transform: scale(0.9) translateY(18px);
  opacity: 0.85;
  z-index: 1;
}

/* TEXTO SOBRE LAS IMÁGENES */

.card-info {
  position: absolute;
  inset: 0;
  z-index: 10;
  padding: clamp(0.8rem, 1.3vw, 1.6rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.85rem;
  text-align: center;
  background: linear-gradient(
    180deg,
    rgba(18,17,26,0.88),
    rgba(18,17,26,0.62)
  );
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}

.card-info h3 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1rem, 1.2vw, 1.55rem);
  font-weight: 400;
  color: #fff;
  line-height: 1.1;
}

.card-info p {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(0.72rem, 0.85vw, 0.92rem);
  color: rgba(255,255,255,0.76);
  line-height: 1.5;
  max-width: 240px;
}

/* HOVER PORTFOLIO */

.visual-card:hover img {
  filter: saturate(1) contrast(1.05) blur(2px) brightness(0.45);
}

.visual-card:hover .card-info {
  opacity: 1;
  transform: translateY(0);
}

.visual-card:hover {
  border-color: var(--accent);
  box-shadow: 0 34px 105px rgba(245,184,204,0.32);
}

.card-1:hover {
  transform: scale(0.94) translateY(4px);
}

.card-2:hover {
  transform: scale(1) translateY(-2px);
}

.card-3:hover {
  transform: scale(1.07) translateY(-10px);
}

.card-4:hover {
  transform: scale(1.07) translateY(-10px);
}

.card-5:hover {
  transform: scale(1) translateY(-2px);
}

.card-6:hover {
  transform: scale(0.94) translateY(4px);
}

/* BOTONES PORTFOLIO */

.portfolio-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1.75rem;
  border-radius: 999px;
  border: 1px solid rgba(245,184,204,0.25);
  background: rgba(0,0,0,0.58);
  color: #fff;
  text-decoration: none;
  font-size: 0.95rem;
  box-shadow: 0 0 32px rgba(245,184,204,0.28);
  transition: all 0.25s ease;
}

.portfolio-showcase > .portfolio-btn {
  margin-top: clamp(2.5rem, 9vh, 6rem);
  margin-bottom: 4rem;
}

.portfolio-btn:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 0 42px rgba(245,184,204,0.45);
}

.portfolio-btn span {
  font-size: 1.2rem;
}

/* TEXTOS INFERIORES PORTFOLIO */

.portfolio-features {
  width: 100%;
  max-width: 1100px;
  margin: 2.5rem auto 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
  text-align: center;
  position: relative;
  z-index: 2;
}

.feature-item h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.45rem;
  font-weight: 400;
  color: #fff;
  margin-bottom: 0.85rem;
}

.feature-item p {
  color: rgba(255,255,255,0.5);
  font-size: 0.95rem;
  line-height: 1.65;
}

/* BOTÓN VOLVER */

.inicio-btn {
  position: absolute;
  right: 4vw;
  bottom: 4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.75rem;
  border-radius: 999px;
  border: 1px solid rgba(245,184,204,0.25);
  background: rgba(0,0,0,0.58);
  color: #fff;
  text-decoration: none;
  font-size: 0.95rem;
  font-family: 'Outfit', sans-serif;
  box-shadow: 0 0 32px rgba(245,184,204,0.28);
  transition: all 0.25s ease;
}

.inicio-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 0 42px rgba(245,184,204,0.45);
}

/* ══════════════════════════════
   ANIMACIÓN
══════════════════════════════ */

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

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

/* ══════════════════════════════
   TABLET / NOTEBOOK CHICA
══════════════════════════════ */

@media (max-width: 1200px) {
  nav {
    padding: 0 2rem;
  }

  .hero-inner {
    gap: 2.5rem;
  }

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

  .visual-stage {
    gap: 0.7rem;
  }

  .portfolio-features {
    gap: 1.6rem;
  }
}

/* ══════════════════════════════
   CELULAR Y TABLET VERTICAL
══════════════════════════════ */

@media (max-width: 900px) {
  nav {
    height: 64px;
    padding: 0 1.1rem;
  }

  .nav-brand {
    font-size: 1.08rem;
  }

  .nav-links {
    display: none;
  }

  .theme-btn {
    padding: 0.38rem 0.75rem;
    font-size: 0.76rem;
  }

  section {
    padding: 4rem 1.15rem;
  }

  .section-header {
    margin-bottom: 2rem;
    gap: 0.65rem;
  }

  .section-title {
    font-size: clamp(1.9rem, 8vw, 2.35rem);
    line-height: 1.15;
  }

  /* HOME */
  .hero {
    min-height: auto;
    padding: 100px 1.15rem 4rem;
  }

  .hero-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2.6rem;
    text-align: center;
  }

  .hero-content {
    align-items: center;
    order: 1;
  }

  .hero-avatar-col {
    order: 2;
    width: 100%;
  }

  .hero-right-spacer {
    display: none;
  }

  .hero-badge {
    margin-bottom: 1.4rem;
  }

  .hero-name {
    font-size: clamp(2.8rem, 15vw, 4.1rem);
    margin-bottom: 1rem;
  }

  .hero-sub {
    font-size: 0.88rem;
    margin-bottom: 1.25rem;
  }

  .hero-desc {
    font-size: 0.9rem;
    line-height: 1.7;
    margin-bottom: 1.8rem;
  }

  .tags {
    justify-content: center;
  }

  .avatar-inner {
    width: min(100%, 290px);
    margin: 0 auto;
  }

  /* TIMELINE */
  .tl-grid-years {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
  }

  .tl-year-front {
    padding: 1rem 0.65rem;
  }

  .tl-trigger-year {
    font-size: 1.8rem;
  }

  .tl-badge-all,
  .tl-badge-progress {
    font-size: 0.55rem;
  }

  .tl-drawer-content {
    padding: 1rem;
  }

  .tl-items-grid {
    grid-template-columns: 1fr;
  }

  .tl-item {
    padding: 0.65rem 0.75rem;
  }

  /* EQUIPO */
  .team-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
  }

  .team-card {
    max-width: none;
    padding: 0.9rem 0.55rem;
    gap: 0.55rem;
    aspect-ratio: auto;
    min-height: 235px;
  }

  .team-img {
    width: 92px;
    height: 92px;
  }

  .team-name {
    font-size: 1rem;
  }

  .team-role {
    font-size: 0.72rem;
  }

  /* INSTITUCIÓN */
  .inst-wrap {
    grid-template-columns: 1fr;
  }

  .inst-cell {
    border-right: none;
    padding: 1.2rem 1rem;
  }

  .inst-row:last-child .inst-cell:first-child {
    border-bottom: 1px solid var(--border);
  }

  .experiencia-texto {
    max-width: 100%;
  }

  /* PORTFOLIO */
  .portfolio-showcase {
    min-height: auto;
    padding: 64px 1rem 3.5rem;
  }

  .portfolio-intro {
    margin: 2.2rem auto 2.5rem;
    max-width: 100%;
  }

  .portfolio-kicker {
    font-size: 0.68rem;
    letter-spacing: 0.18em;
    margin-bottom: 1.1rem;
  }

  .portfolio-intro h1 {
    font-size: clamp(2.2rem, 11vw, 3.2rem);
    line-height: 1.02;
    margin-bottom: 1rem;
  }

  .portfolio-intro p {
    font-size: 0.9rem;
    line-height: 1.65;
    max-width: 360px;
    white-space: normal;
  }

  .visual-stage {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 0.85rem;
    margin-top: 1.25rem;
    perspective: none;
  }

  .visual-stage::before {
    width: 250px;
    height: 250px;
    top: 40%;
    opacity: 0.28;
  }

  .visual-stage::after {
    display: none;
  }

  .visual-card,
  .card-1,
  .card-2,
  .card-3,
  .card-4,
  .card-5,
  .card-6 {
    width: 100%;
    min-height: 0;
    max-height: none;
    aspect-ratio: 0.68;
    height: auto;
    transform: none;
    opacity: 1;
    filter: none;
    border-radius: 16px;
  }

  .card-info {
    opacity: 1;
    transform: none;
    justify-content: flex-end;
    padding: 0.9rem 0.65rem;
    gap: 0;
    background: linear-gradient(
      180deg,
      transparent 48%,
      rgba(18,17,26,0.92) 100%
    );
  }

  .card-info h3 {
    font-size: 1rem;
  }

  .card-info p {
    display: none;
  }

  .visual-card:hover,
  .card-1:hover,
  .card-2:hover,
  .card-3:hover,
  .card-4:hover,
  .card-5:hover,
  .card-6:hover {
    transform: none;
  }

  .visual-card:hover img {
    filter: saturate(1) contrast(1.05);
  }

  .portfolio-showcase > .portfolio-btn {
    margin-top: 2.5rem;
    margin-bottom: 2.5rem;
  }

  .portfolio-btn {
    padding: 0.72rem 1.35rem;
    font-size: 0.87rem;
  }

  .portfolio-features {
    grid-template-columns: 1fr;
    gap: 1.8rem;
    margin-top: 2.5rem;
    max-width: 350px;
  }

  .feature-item h3 {
    font-size: 1.25rem;
    margin-bottom: 0.45rem;
  }

  .feature-item p {
    font-size: 0.85rem;
  }

  .inicio-btn {
    position: relative;
    right: auto;
    bottom: auto;
    margin-top: 3rem;
    padding: 0.7rem 1.3rem;
    font-size: 0.85rem;
  }

  /* FOOTER */
  footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.2rem;
    padding: 2rem 1.15rem;
  }

  footer p {
    font-size: 0.68rem;
    line-height: 1.65;
  }
}

/* ══════════════════════════════
   CELULAR CHICO
══════════════════════════════ */

@media (max-width: 520px) {
  nav {
    padding: 0 0.8rem;
  }

  .nav-brand {
    font-size: 0.95rem;
  }

  .theme-btn {
    padding: 0.34rem 0.6rem;
  }

  #themeLabel {
    display: none;
  }

  .hero {
    padding-top: 90px;
  }

  .hero-name {
    font-size: clamp(2.45rem, 15vw, 3.2rem);
  }

  .hero-sub {
    letter-spacing: 0.02em;
  }

  .section-header {
    align-items: flex-start;
  }

  .tl-grid-years {
    grid-template-columns: 1fr;
  }

  .tl-year-front {
    aspect-ratio: auto;
    min-height: 150px;
  }

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

  .team-card {
    max-width: 290px;
    margin: 0 auto;
    width: 100%;
  }

  .portfolio-showcase {
    padding-left: 0.85rem;
    padding-right: 0.85rem;
  }

  .portfolio-intro {
    margin-top: 1.75rem;
    margin-bottom: 2rem;
  }

  .portfolio-intro h1 {
    font-size: clamp(2rem, 11vw, 2.55rem);
  }

  .visual-stage {
    gap: 0.65rem;
  }

  .visual-card,
  .card-1,
  .card-2,
  .card-3,
  .card-4,
  .card-5,
  .card-6 {
    border-radius: 13px;
  }

  .card-info h3 {
    font-size: 0.92rem;
  }

  .portfolio-features {
    margin-top: 2rem;
  }
}

/* ══════════════════════════════
   CELULAR MUY ANGOSTO
══════════════════════════════ */

@media (max-width: 360px) {
  .visual-stage {
    grid-template-columns: 1fr;
  }

  .visual-card,
  .card-1,
  .card-2,
  .card-3,
  .card-4,
  .card-5,
  .card-6 {
    max-width: 270px;
    margin: 0 auto;
  }
}