:root{--bg:#000;--text:#fff;--accent:#a49efc}
*{box-sizing:border-box}
html,body{height:100%}
body{margin:0;font-family:Helvetica,Arial,sans-serif;background:var(--bg);color:var(--text);-webkit-font-smoothing:antialiased;overflow-x:hidden; max-width:100%}
a{color:inherit;text-decoration:none}
.container{max-width:95%;margin:0 auto;padding:24px}

/* Background animation */
.bg-travel{position:fixed;inset:0;pointer-events:none;z-index:0}
.bg-travel-1{background:radial-gradient(circle at 10% 20%, rgba(155,89,255,0.06), transparent 8%), radial-gradient(circle at 80% 80%, rgba(200,220,255,0.04), transparent 12%);opacity:0.6;mix-blend-mode:screen;animation:travel 20s linear infinite}
.bg-travel-2{background:radial-gradient(circle at 30% 70%, rgba(255,240,220,0.03), transparent 10%), radial-gradient(circle at 70% 30%, rgba(230,200,255,0.03), transparent 10%);opacity:0.5;mix-blend-mode:screen;animation:travel 30s linear infinite reverse}
@keyframes travel{0%{background-position:0% 0%,100% 100%}50%{background-position:20% 30%,80% 70%}100%{background-position:0% 0%,100% 100%}}

/* Cursor blur */
.cursor-follower{position:fixed;top:0;left:0;width:100px;height:100px;border-radius:50%;background:rgba(155,89,255,0.14);box-shadow:0 0 90px rgba(155,89,255,0.22);pointer-events:none;z-index:999;transform:translate3d(-9999px,-9999px,0);backdrop-filter:blur(12px);mix-blend-mode:screen;will-change:transform}

/* Floating blobs */
/* Floating blobs â€” ahora mucho mÃ¡s notorios ðŸ’œ */
.floating {
  position: fixed;
  pointer-events: none;
  z-index: -1;
  filter: blur(20px);     /* definido mÃ¡s definido */
  opacity: 0.95;
  mix-blend-mode: normal;
  will-change: transform, opacity;
  transition: opacity .4s ease;
}


/* Blob principal violeta */
.f1 {
  left: -120px;
  top: -80px;
  width: 920px;
  height: 920px;
  background: radial-gradient(
    circle at 40% 40%,
    rgba(155, 89, 255, 0.55),
    rgba(120, 30, 255, 0.25) 40%,
    transparent 70%
  );
}

/* Blob azul pastel */
.f2 {
  right: -160px;
  top: 40px;
  width: 480px;
  height: 480px;
  background: radial-gradient(
    circle at 60% 40%,
    rgba(155, 89, 255, 0.55),
    rgba(120, 30, 255, 0.25) 40%,
    transparent 80%
  );
}

/* Blob lila-rosado */
.f3 {
  right: 20%;
  bottom: -120px;
  width: 320px;
  height: 320px;
  background: radial-gradient(
    circle at 60% 60%,
   rgba(155, 89, 255, 0.55),
    rgba(120, 30, 255, 0.25) 40%,
    transparent 80%
  );
}

/* Header */
header{display:flex;justify-content:space-between;align-items:center;padding:24px 0;position:relative;z-index:10}
.brand small{text-transform:uppercase;opacity:.7;letter-spacing:1px}
.site-nav{display:flex;gap:28px;align-items:center}
.site-nav a{opacity:0.95;font-size:18px; font-weight: 600;}

/* Hero */
.hero{width:100vw;max-width:90%;background:rgba(255,255,255,0.02);backdrop-filter:blur(6px);border:1px solid rgba(255,255,255,0.06);border-radius:50px;padding:58px; margin: 50px auto;}
.hero-inner{display:flex;gap:5%; align-items:center; }
.avatar{width:312px;height:312px;border-radius:50%;overflow:hidden;border:2px solid rgba(255,255,255,0.06);flex-shrink:0}
.avatar img{width:100%;height:100%;object-fit:cover;display:block}
.muted{color:rgba(255,255,255,0.6);font-size:16px}
.hero-title{margin:0;font-weight:800;line-height:0.92;font-size:50px}
.hero-sub{font-weight:600;font-size:58px;color:rgba(255,255,255,0.9)}
.subhead {
    font-weight: 600;
    font-size: 52px;
    color: rgba(255, 255, 255, 0.9);
    margin: 0 0 32px;
}.hero-bio{margin-top:12px;color:rgba(255,255,255,0.75);font-size:25px;}
.hero-links{margin-top:12px;display:flex;gap:14px;align-items:center}
.cv-link{color:var(--accent);font-weight:700;text-transform:uppercase;letter-spacing:1px;font-size:15px;}
.touch-link{color:rgba(255,255,255,0.8)}
.hero-stats{margin-top:12px;color:rgba(255,255,255,0.65);font-size:16px}

/* Headline animation */
.headline-wrap {
    width: 80%;
    padding: 18px 0;
    margin: 0 auto;
}
.headline{font-weight:900;line-height:0.95;text-align:center;font-size:54px;max-width:100%;margin:0 auto;}
.word{
	display:inline-block;
	margin-right:10px;
	opacity:0;
	transform:translateY(20px);
	transition:transform .48s cubic-bezier(.2,.9,.3,1),opacity .48s ease;
}
.section-work {
    margin: 0 auto;
    width: 80%;
    margin-top: 120px;
	max-width: 1200px;
}
.word.revealed{opacity:1;transform:translateY(0);}
.grad-text{background-image: linear-gradient(90deg, #c198d7 0%, #e9f7ff 30%, #fbeefc 60%, #f6e6ff 100%);background-size:220% 100%;-webkit-background-clip:text;background-clip:text;color:transparent;animation:movegrad 12s linear infinite; padding: 20px;}
@keyframes movegrad{0%{background-position:0% 50%}50%{background-position:100% 50%}100%{background-position:0% 50%;}}

/* About */
.section {
    width: 80vw;
    max-width: 1200px;
    margin: auto;
    margin-top: 100px;
}
.section-title{font-size:52px;margin:0 0 12px}
.about-text{font-size:46px;line-height:1.05;background:linear-gradient(90deg,rgba(255,255,255,0.95),rgba(230,220,255,0.8));-webkit-background-clip:text;background-clip:text;color:transparent}

/* Education & skills */
.education{margin-top: 120px;}
.education-item {
    background: rgb(230 220 255 / 7%);
    padding: 10px;
    border-radius: 8px;
    border: 1px solid rgb(255 255 255 / 8%);
    margin-top: 8px;
    font-size: 20px;
    font-weight: 300;
    max-width: 60%;
}
.note{margin-top:8px;color:rgba(255,255,255,0.7);font-size:23px;}
.skills{display:flex;flex-wrap:wrap;gap:12px;margin-top:8px;}
.skill {
    background: rgb(185 149 255 / 15%);
    padding: 8px 10px;
    border-radius: 50px;
    font-size: 19px;
    border: solid 1px #ffffff1a;
}
.skills-block{
	margin-top: 120px;
}

/* Beliefs */
.beliefs-list{display:flex;flex-direction:column;gap:20px;margin-top:10px;}
.belief{font-size: 63px; text-align: left; color:#fff; padding:20px; font-weight:800;line-height:1.1;transition:transform .3s,box-shadow .3s; background-color: #000000;}
.belief:hover{background:rgba(0,0,0,.25); font-style: italic; }
.belief-text{transition:background-position .45s ease,color .25s ease}
.belief:hover .belief-text{background-image:linear-gradient(90deg,#f6e6ff,#e9f7ff,#fbeefc);-webkit-background-clip:text;background-clip:text;color:transparent; }

/* Work */
.work-grid{display:grid; grid-template-columns:repeat(auto-fit,minmax(380px,1fr)); gap:18px; margin-top:18px;}
.work-item{overflow:hidden;border-radius:12px;cursor:pointer;border:1px solid rgba(255,255,255,0.05)}
.work-item img{width:100%;height:220px;object-fit:cover;display:block;transition:transform .5s}
.work-item:hover img{transform:scale(1.05)}

/* Modal */
.modal{position:fixed;inset:0;background:rgba(0,0,0,0.86);display:flex;align-items:center;justify-content:center;z-index:999;opacity:0;pointer-events:none;transition:opacity .3s}
.modal.open{opacity:1;pointer-events:auto}
.modal-content{max-width:1100px;width:90%;border-radius:10px}
.modal-content img{width:100%;border-radius:8px}
.modal-caption{color:#ccc;text-align:center;margin-top:10px}
.modal-close{position:absolute;top:20px;right:25px;font-size:24px;background:none;color:#fff;border:none;cursor:pointer}

/* Career */
.career-list{margin-top:12px;display:flex;flex-direction:column;gap:12px}
.career-item {
    padding: 16px;
    border-radius: 20px;
    border: 1px solid rgb(255 255 255 / 7%);
    background-color: rgb(123 104 172 / 9%);
}
.career-item h4{margin:0 0 4px;font-size:29px;}
.career-item p{margin:0;color:rgba(255,255,255,0.75);font-size:20px; font-weight: 300;}

/* Footer */
footer{position:fixed;left:50%;transform:translateX(-50%);bottom:20px;color:rgba(255,255,255,0.35);font-size:12px;z-index:20}

/* Responsive */
@media (max-width:900px){
  .hero{width:92vw}
  .headline{font-size:34px}
  .belief{font-size:24px}
  .work-item img{height:160px}
}
@media (max-width:560px){
  .work-item img{height:220px}
  .cursor-follower{display:none}
}


/* --- Fix: make background gradients/blobs visible and performative --- */

/* Ensure container sits above the backgrounds */
.container { position: relative; z-index: 2; }



/* Make travel layers slightly stronger so they're easier to see on black */
.bg-travel-1 { opacity: 0.75; mix-blend-mode: screen; }
.bg-travel-2 { opacity: 0.65; mix-blend-mode: screen; }

/* Slight tweak to keyframes (keeps same names) â€” ensures both background layers animate independently */
@keyframes travel {
  0%   { background-position: 0% 0%, 100% 100%; }
  50%  { background-position: 20% 30%, 80% 70%; }
  100% { background-position: 0% 0%, 100% 100%; }
}

/* Floating blobs behind content but above bg-travel, still visible */
.floating { z-index: -1; filter: blur(36px); opacity: 0.75; will-change: transform, opacity; }

/* Make the cursor halo stay above content (unchanged) */
.cursor-follower { z-index: 999; }

/* Optional: increase color contrast of blobs so they register more on black */
.f1 { background: radial-gradient(circle at 30% 30%, rgba(155,89,255,0.36), transparent 25%); }
.f2 { background: radial-gradient(circle at 80% 40%, rgba(200,220,255,0.16), transparent 25%); }
.f3 { background: radial-gradient(circle at 60% 60%, rgba(255,240,200,0.12), transparent 25%); }

/* Fallback: if prefers-reduced-motion prevented animations, allow a subtle fade-in */
@media (prefers-reduced-motion: reduce) {
  .bg-travel-1, .bg-travel-2, .floating { transition: opacity .6s ease; opacity: .6 !important; animation: none !important; }
}

/* For browsers that might have issues with mix-blend-mode: fallback stronger colors */
@supports (mix-blend-mode: screen) {
  /* keep as-is (modern browsers) */
}
@supports not (mix-blend-mode: screen) {
  .bg-travel-1 { background-color: rgba(155,89,255,0.06); }
  .bg-travel-2 { background-color: rgba(200,200,255,0.03); }
  .floating { filter: blur(28px); opacity: 0.6; }
}

/* --- Contact Hero --- */
/* Contact hero styled like intro card */
.contact-hero {
  width: 70vw;
  max-width: 90%;
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 50px;
  padding: 58px;
  margin: 80px auto 100px;
  text-align: center;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.contact-hero:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(155, 89, 255, 0.15);
}

.contact-content h2 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  line-height: 1.1;
  background: linear-gradient(90deg, #f6e6ff, #e9f7ff, #fbeefc, #f6e6ff);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: movegrad 10s linear infinite;
  margin-bottom: 24px;
}

.contact-content a {
  color: var(--accent);
  font-size: 1.4rem;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.contact-content a:hover {
  color: #d0b3ff;
  text-shadow: 0 0 20px rgba(155, 89, 255, 0.4);
}

/* Back to top button */
#backToTop {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 50px;
  height: 50px;
  border-radius: 999px;
  background: rgba(155, 89, 255, 0.18);
  box-shadow: 0 0 30px rgba(155, 89, 255, 0.25);
  backdrop-filter: blur(8px);
  color: white;
  border: none;
  font-size: 22px;
  font-weight: 700;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.3s ease;
  z-index: 999;
}

#backToTop.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

#backToTop:hover {
  background: rgba(155, 89, 255, 0.3);
  box-shadow: 0 0 40px rgba(155, 89, 255, 0.45);
  transform: scale(1.05);
}

/* ----------------------------
   Mobile overrides — add at end
   ---------------------------- */

/* Base mobile breakpoint: hasta 900px */
@media (max-width: 900px) {
  /* Container padding más cómodo en mobile */
  .container { padding: 18px; max-width: 100%; }

  /* Header: nav oculto para evitar solaparse con hero
     (puedes añadir luego un botón hamburger si quieres toggle JS) */
  .site-nav { display: none; }

  /* Hero: apilar y reducir tamaños */
  .hero { width: calc(100% - 32px); padding: 28px; border-radius: 28px; margin: 28px auto; }
  .hero-inner { flex-direction: column; gap: 18px; align-items: flex-start; }
  .avatar { width: 120px; height: 120px; }
  .hero-title { font-size: 28px; line-height: 1; }
  .hero-sub { font-size: 20px; }
  .hero-bio { font-size: 15px; margin-top: 8px; }

  /* Hero links: ocupar 100% y apilar en mobile si hay poco espacio */
  .hero-links { flex-wrap:wrap; gap:10px; }
  .cv-link, .touch-link { font-size: 14px; padding: 10px 12px; border-radius: 12px; }

  /* Headline: más pequeño y con padding */
  .headline-wrap { width: 100%; padding: 12px 8px; margin-top: 18px; }
  .headline { font-size: 28px; line-height: 1.05; }

  /* About: ajustar tipografía y ancho */
  .section { width: calc(100% - 32px); margin-top: 36px; }
  .section-title { font-size: 28px; }
  .about-text { font-size: 18px; line-height: 1.18; }

  /* Education items & skills: full width y tamaños reducidos */
  .education-item { max-width: 100%; font-size: 15px; padding: 8px; }
  .note { font-size: 15px; }
  .skill { font-size: 13px; padding: 6px 8px; }

  /* Work grid: 1 columna para mejorar lectura y touch targets */
  .work-grid { grid-template-columns: 1fr !important; gap: 14px; }
  .work-item img { height: 180px; object-fit: cover; }

  /* Beliefs: tamaño legible y espaciado */
  .belief { font-size: 20px; padding: 14px; border-radius: 12px; }
  .belief-text { font-size: 18px; }

  /* Career items: compact */
  .career-item h4 { font-size: 18px; }
  .career-item p { font-size: 15px; }

  /* Modal: ocupar más del viewport en mobile */
  .modal-content { width: calc(100% - 32px); max-width: 680px; }
  .modal-caption { font-size: 14px; color: #ddd; }

  /* Contact hero: compacto */
  .contact-hero { width: calc(100% - 36px); padding: 28px; margin: 40px auto 60px; border-radius: 28px; }
  .contact-content h2 { font-size: 1.6rem; }

  /* Footer: no fixed overlap en mobile, mover arriba de bottom si toca */
  @supports (position: sticky) {
    footer { position: static; transform: none; margin: 24px 0 40px; }
  }
  #backToTop { right: 18px; bottom: 18px; width:44px;height:44px;font-size:18px; }

  /* Reduce heavy blurs on small devices for performance */
  .cursor-follower { display: none; }
  .floating { filter: blur(28px); opacity: 0.6; }

  /* Accessibility: increase tap targets slightly */
  .work-item, .cv-link, .touch-link, .site-nav a { -webkit-tap-highlight-color: rgba(255,255,255,0.04); }

  /* Ensure headline grad padding doesn't overflow */
  .grad-text { padding: 12px 8px; }
}

/* Extra small screens: hasta 560px — ajustes más agresivos */
@media (max-width: 560px) {
  .avatar { width: 96px; height: 96px; }
  .hero-title { font-size: 22px; }
  .hero-sub { font-size: 16px; }
  .hero-bio { font-size: 14px; }

  .headline { font-size: 22px; }

  .work-item img { height: 150px; }

  .belief { font-size: 18px; padding: 12px; }
  .belief-text { font-size: 16px; }

  .education-item { font-size: 14px; padding: 8px; }
  .skill { font-size: 12px; padding: 6px 8px; }

  .contact-content a { font-size: 1.1rem; }

  /* Slightly reduce travel/animation opacity for low-perf devices */
  .bg-travel-1, .bg-travel-2 { opacity: 0.45; }
}

/* Very small phones: hasta 420px */
@media (max-width: 420px) {
  .hero { padding: 20px; border-radius: 18px; margin: 18px auto; }
  .hero-inner { gap: 12px; }
  .hero-links { gap:8px; }
  .section-title { font-size: 22px; }
  .about-text { font-size: 15px; }
  .work-item img { height: 140px; }
  .modal-content { max-width: 95%; width: calc(100% - 28px); }
}

