:root {
  color-scheme: light;
  font-family: "Inter Tight", Arial, sans-serif;
  color: #000;
  background: #fff;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  --muted: #595959;
  --rule: #dedede;
}
* { box-sizing: border-box; }
body { margin: 0; background: #fff; }
#dither-star { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
body > :not(#dither-star) { position: relative; z-index: 1; }
p, h1, h2 { margin: 0; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 5px; }
a:focus-visible { outline: 2px solid #000; outline-offset: 5px; border-radius: 2px; }
::selection { color: #fff; background: #000; }
.page {
  height: 100svh;
  min-height: 600px;
  padding: clamp(24px, 3.2vw, 62px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: clamp(22px, 3.5svh, 40px);
  max-width: 2000px;
  margin-inline: auto;
}
.masthead { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.identity { display: flex; align-items: center; gap: 15px; }
.avatar { width: clamp(56px, 4vw, 72px); height: clamp(56px, 4vw, 72px); object-fit: cover; border-radius: 50%; background: #eee; }
.name { font-size: clamp(17px, 1.4vw, 23px); font-weight: 600; letter-spacing: -.035em; }
.role { margin-top: 5px; font-size: clamp(12px, 1vw, 15px); color: var(--muted); }
.education { font-size: clamp(12px, .95vw, 15px); text-align: right; line-height: 1.5; }
.education-detail { display: block; color: var(--muted); }
.main { display: grid; grid-template-columns: 1.45fr 1fr; gap: clamp(38px, 5vw, 96px); align-items: center; min-height: 0; }
.eyebrow { font-size: clamp(10px, .8vw, 12px); font-weight: 500; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); line-height: 1.4; }
.hero > .eyebrow { display: flex; align-items: center; gap: 8px; margin-bottom: clamp(14px, 2.7svh, 30px); }
.status-dot { width: 5px; height: 5px; background: #000; border-radius: 50%; }
h1 { font-size: clamp(72px, min(8.8vw, 13.5svh), 154px); font-weight: 550; line-height: .92; letter-spacing: -.065em; }
.motion { display: inline-block; position: relative; font-family: "Instrument Serif", Georgia, serif; font-size: 1.32em; font-weight: 400; line-height: .92; letter-spacing: -.055em; transform-origin: 15% 70%; animation: drift 6s ease-in-out infinite; }
.motion::after { content: ""; position: absolute; left: 3%; right: 9%; bottom: .035em; height: 1px; background: #000; transform: scaleX(.72); transform-origin: left; opacity: .3; animation: trace 6s ease-in-out infinite; }
.motion-comma { padding-right: .08em; }
.last-line { font-size: .83em; letter-spacing: -.065em; white-space: nowrap; }
.expertise > .eyebrow { margin-bottom: clamp(16px, 2.5svh, 28px); }
.attributes { list-style: none; padding: 0; margin: 0; counter-reset: none; }
.attributes li { display: grid; grid-template-columns: 25px 1fr; gap: 12px; position: relative; padding-block: clamp(13px, 2.1svh, 23px); font-size: clamp(15px, 1.38vw, 22px); font-weight: 500; line-height: 1.25; letter-spacing: -.025em; }
.number { font-size: 10px; font-weight: 400; line-height: 1.9; color: var(--muted); letter-spacing: 0; }
.detail { color: var(--muted); font-weight: 400; }
.footer { position: relative; padding-top: clamp(17px, 2.7svh, 30px); display: flex; justify-content: space-between; align-items: end; gap: 25px; }
.collaborators { display: flex; align-items: center; gap: clamp(20px, 2.3vw, 44px); }
.logos { display: flex; align-items: center; gap: clamp(22px, 2.6vw, 48px); }
.logo { display: block; height: clamp(28px, 2.4vw, 38px); width: auto; max-width: 120px; object-fit: contain; filter: grayscale(1); opacity: .85; transition: opacity 250ms ease, transform 350ms ease; }
.logo-entry:hover .logo { opacity: 1; transform: translateY(-3px); }
.logo-anahuac { height: clamp(40px, 3.4vw, 52px); max-width: none; }
.logo-luna { height: clamp(30px, 2.6vw, 40px); }
.contact { text-align: right; }
.contact-links { display: flex; align-items: center; gap: clamp(14px, 1.7vw, 32px); font-size: clamp(12px, 1vw, 15px); font-weight: 500; }
.contact-links a { display: inline-flex; align-items: center; min-height: 28px; white-space: nowrap; text-decoration: none; }

.arrow { display: inline-block; margin-left: 4px; transition: transform 180ms ease; }
a:hover .arrow { transform: translate(2px, -2px); }
.copyright { font-size: 10px; color: var(--muted); margin-top: 12px; }
/* Separate entrance wrappers keep idle and pointer motion independent. */
:root { --ease-out: cubic-bezier(.22, 1, .36, 1); }
.avatar-entry { display: block; flex: none; animation: avatar-in 650ms var(--ease-out) backwards; }
.avatar { display: block; animation: avatar-idle 7s ease-in-out 950ms infinite; }
.name, .role, .education, .eyebrow, .copyright {
  animation: rise-in 550ms var(--ease-out) var(--delay, 0ms) backwards;
}
.name { --delay: 70ms; }
.role { --delay: 130ms; }
.education { --delay: 190ms; }
.hero > .eyebrow { --delay: 160ms; }
.expertise > .eyebrow { --delay: 230ms; }
.collaborators > .eyebrow { --delay: 620ms; }
.copyright { --delay: 880ms; }
.hero { transform: translate3d(var(--hero-x, 0px), var(--hero-y, 0px), 0); transition: transform 700ms var(--ease-out); }
.hero-line { display: block; width: fit-content; padding: .08em .08em .12em 0; margin-block: -.10em; animation: line-reveal 750ms var(--ease-out) var(--delay, 160ms) backwards; }
.hero-line:nth-child(2) { --delay: 270ms; }
.hero-line:nth-child(3) { --delay: 380ms; }
.hero-line-content { display: block; animation: rise-in 750ms var(--ease-out) var(--delay, 160ms) backwards; }
.hero-line-motion { padding-left: .035em; margin-left: -.035em; }
.attributes li { --delay: 300ms; transition: transform 300ms var(--ease-out); }
.attributes li:nth-child(2) { --delay: 370ms; }
.attributes li:nth-child(3) { --delay: 440ms; }
.attributes li:nth-child(4) { --delay: 510ms; }
.attributes li:nth-child(5) { --delay: 580ms; }
.attributes li:nth-child(6) { --delay: 650ms; }
.attributes li > span { animation: rise-in 550ms var(--ease-out) var(--delay) backwards; }
.attributes li > .number { animation-name: number-in; transition: color 250ms ease; }
.attributes li:hover, .attributes li:focus-within { transform: translateX(4px); }
.attributes li:hover .number, .attributes li:focus-within .number { color: #000; }
.attributes li::before, .footer::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: var(--rule); transform-origin: left;
  animation: rule-in 650ms var(--ease-out) var(--delay, 480ms) backwards;
}
.logo-entry { display: block; --delay: 600ms; animation: rise-in 600ms var(--ease-out) var(--delay) backwards; }
.logo-entry:nth-child(2) { --delay: 690ms; }
.logo-entry:nth-child(3) { --delay: 780ms; }
.logo-idle { display: block; animation: logo-breathe 6s ease-in-out 1200ms infinite; }
.logo-entry:nth-child(2) .logo-idle { animation-delay: 1900ms; }
.logo-entry:nth-child(3) .logo-idle { animation-delay: 2600ms; }
.contact-links a { position: relative; animation: rise-in 550ms var(--ease-out) 700ms backwards; }
.contact-links a:nth-child(2) { animation-delay: 770ms; }
.contact-links a:nth-child(3) { animation-delay: 840ms; }
.contact-links a:nth-child(4) { animation-delay: 910ms; }
.contact-links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 1px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform 300ms var(--ease-out); }
.contact-links a:hover::after, .contact-links a:focus-visible::after { transform: scaleX(1); }
a:focus-visible .arrow { transform: translate(2px, -2px); }
@keyframes rise-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes avatar-in { from { opacity: 0; transform: scale(.82); } to { opacity: 1; transform: scale(1); } }
@keyframes line-reveal { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes number-in { from { opacity: 0; transform: translateX(-8px); } to { opacity: 1; transform: translateX(0); } }
@keyframes rule-in { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes avatar-idle { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-2px); } }
@keyframes logo-breathe { 0%, 100% { transform: translateY(0) scale(1); } 50% { transform: translateY(-1px) scale(1.018); } }
@keyframes drift { 0%, 100% { transform: translateX(0) rotate(-1deg); } 50% { transform: translateX(.035em) rotate(1deg); } }
@keyframes trace { 0%, 100% { transform: scaleX(.72); opacity: .3; } 50% { transform: scaleX(1); opacity: .65; } }
@media (max-width: 700px) {
  .page { padding: clamp(18px, 5vw, 28px); gap: clamp(15px, 2.5svh, 23px); }
  .masthead { align-items: start; flex-direction: column; gap: 12px; }
  .identity { gap: 12px; }
  .avatar { width: 48px; height: 48px; }
  .name { font-size: 18px; }
  .role { font-size: 12px; margin-top: 3px; }
  .education { font-size: 10px; line-height: 1.4; text-align: left; }
  .education-detail { display: inline; }
  .education-detail::before { content: " · "; }
  .main { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr) auto; gap: clamp(14px, 2.5svh, 24px); }
  .hero { align-self: center; }
  .hero > .eyebrow { margin-bottom: clamp(10px, 1.8svh, 18px); }
  .eyebrow { font-size: 9px; letter-spacing: .08em; }
  h1 { font-size: clamp(45px, min(14.8vw, 8.1svh), 67px); line-height: .89; }
  .motion { font-size: 1.31em; }
  .last-line { font-size: .88em; }
  .expertise > .eyebrow { margin-bottom: 10px; }
  .attributes { display: grid; grid-template-columns: 1fr 1fr; column-gap: 20px; }
  .attributes li { grid-template-columns: 15px 1fr; gap: 6px; padding-block: clamp(8px, 1.2svh, 12px); font-size: clamp(11px, 3.1vw, 13px); line-height: 1.24; }
  .number { font-size: 8px; line-height: 1.7; }
  .detail { display: block; }
  .footer { display: grid; gap: clamp(13px, 2svh, 20px); padding-top: 13px; }
  .collaborators { justify-content: space-between; gap: 15px; }
  .logos { gap: clamp(15px, 5vw, 25px); }
  .logo { height: 25px; max-width: 80px; }
  .logo-audi { height: 22px; }
  .logo-anahuac { height: 36px; }
  .contact { display: flex; align-items: center; justify-content: space-between; gap: 12px; text-align: left; }
  .contact-links { gap: clamp(10px, 3vw, 16px); font-size: 11px; flex-wrap: wrap; }
  .arrow { margin-left: 2px; }
  .copyright { font-size: 8px; margin-top: 0; white-space: nowrap; }
}
@media (min-width: 701px) and (max-width: 1050px) {
  .main { grid-template-columns: 1.3fr 1fr; gap: 28px; }
  h1 { font-size: min(8.8vw, 13svh); }
  .collaborators { gap: 15px; }
  .logos { gap: 18px; }
  .logo { max-width: 84px; height: 28px; }
  .contact-links { gap: 12px; }
}
@media (max-height: 699px) and (max-width: 700px) {
  .page { gap: 13px; padding-block: 16px; }
  .masthead { gap: 8px; }
  .main { gap: 13px; }
  h1 { font-size: clamp(43px, 7.9svh, 55px); }
  .hero > .eyebrow { margin-bottom: 9px; }
  .attributes li { padding-block: 7px; }
  .footer { gap: 10px; padding-top: 10px; }
}
@media (max-height: 599px) { .page { height: auto; min-height: 100svh; } .main { min-height: 340px; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .hero, .attributes li:hover, .attributes li:focus-within, .logo-entry:hover .logo { transform: none; }
}
.is-hidden *, .is-hidden *::before, .is-hidden *::after { animation-play-state: paused !important; }

/* Leave room for the blue-buddy mascot (fixed, bottom-right). */
.footer { padding-right: clamp(70px, 8.4vw, 108px); }

/* Contact links: always underlined, each in the color of the app it opens. */
.contact-links a { text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 3px; transition: opacity 180ms ease; }
.contact-links a::after { display: none; }
.contact-links a:hover { opacity: .7; }
.contact-links .l-instagram { color: #E1306C; }
.contact-links .l-email { color: #EA4335; }
.contact-links .l-whatsapp { color: #1DA851; }
.contact-links .l-drive { color: #1A73E8; }
@media (max-width: 700px) {
  .contact { display: grid; justify-content: start; gap: 4px; }
  .contact-links { flex-wrap: nowrap; }
}

/* Universidad Veracruzana + Coppel */
.logo-entry:nth-child(4) { --delay: 870ms; }
.logo-entry:nth-child(5) { --delay: 960ms; }
.logo-entry:nth-child(4) .logo-idle { animation-delay: 3300ms; }
.logo-entry:nth-child(5) .logo-idle { animation-delay: 4000ms; }
.logo-uv { height: clamp(34px, 2.9vw, 44px); }
.logo-coppel { height: clamp(16px, 1.3vw, 20px); max-width: none; }
@media (max-width: 700px) {
  .logos { gap: 14px; }
  .logo { max-width: 64px; }
  .logo-anahuac { height: 32px; }
  .logo-audi { height: 18px; }
  .logo-luna { height: 24px; }
  .logo-uv { height: 30px; }
  .logo-coppel { height: 12px; max-width: 70px; }
}
.collaborators { min-width: 0; }

/* Experience block (matches the PDF CV), stacked above the expertise list. */
.side { display: grid; gap: clamp(14px, 2.6svh, 34px); min-height: 0; }
.experience > .eyebrow { margin-bottom: clamp(6px, 1.2svh, 14px); }
.side .attributes li { padding-block: clamp(8px, 1.45svh, 17px); font-size: clamp(14px, min(1.25vw, 2.3svh), 20px); }
.exp-list li:nth-child(1) { --delay: 260ms; }
.exp-list li:nth-child(2) { --delay: 320ms; }
.exp-list li:nth-child(3) { --delay: 380ms; }
.experience > .eyebrow { --delay: 200ms; }
.exp-list em { font-style: italic; }
@media (max-width: 700px) {
  .side { gap: 10px; }
  .exp-list { grid-template-columns: 1fr; }
  .exp-list .detail { display: inline; }
  .side .attributes li { padding-block: clamp(5px, .9svh, 9px); font-size: clamp(10.5px, 3vw, 12.5px); }
  .experience > .eyebrow { margin-bottom: 4px; }
}
/* Short phones: with Experience added, allow a little scroll instead of overlapping. */
@media (max-width: 700px) and (max-height: 760px) {
  .page { height: auto; min-height: 100svh; }
  .main { grid-template-rows: auto auto; }
}
