/*
theme: Guille's prototype
version: 2.0 (hoja unificada: reemplaza gmm.css, gmm-about-me.css y gmm-refinado.css)
author: Guille Moreno
license: GNU GPL

Las fuentes se cargan con <link> desde el <head> de cada página
(Inter + JetBrains Mono en todas; Gabriele Ribbon solo en tesis.html).
Las rutas url() son relativas a este archivo: ../img/...
*/

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

/* etiquetas */
:root {
    --width:1200px;
    --font-main: "JetBrains Mono", monospace;
    --font-text: "Inter", sans-serif;
    --font-scale: 1rem;
    --background-color: #fff;
    --bg-header-color: rgba(255 255 255 / 95%);
    --heading-color: #303030;
    --text-color: #ff0000;
    --link-color: #B2B2B2;
    --color-pink: #EB3FD2;
    --color-yellow: #F4A200;
    --color-blue: #286EFF;
    --color-cyan: #00C9FB;
    --button-color: #00C9FB;
    --border-color: #B2B2B2;
    --code-background-color: #f2f2f2;
    --code-color: #222;
    --blockquote-color: #B2B2B2;
    --scroll-thumb: var(--link-color);
    --scroll-track: var(--background-color);

    --transition-duration: 400ms;
}

/*Correct the line height in all browsers. Prevent adjustments of font size after orientation changes in iOS.*/
html {
  -webkit-text-size-adjust: 100%;
  scrollbar-color: var(--scroll-thumb) var(--scroll-track);
}

/* Body of the Website*/
body {
    font-family: var(--font-text);
    font-size: var(--font-scale);
    font-optical-sizing: auto;
    margin: auto;
    padding: 0 20px 20px 20px;
    max-width: var(--width);
    background-color: var(--background-color);
    word-wrap: break-word;
    overflow-wrap: break-word;
    text-align:justify;
    line-height: 1.4;
    color: var(--text-color);
}

::selection {
  background-color: var(--link-color);
  color: white;
}

/* headings */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-main);
    color: var(--heading-color);
    margin-bottom: 0.5rem;
}

h5 {
    font-weight: normal;
    font-size: large;
    text-transform: uppercase;
}

p {
    margin-block-start: 0.8em;
}

/* Links */
a {
    color: var(--link-color);
    text-decoration: none;
}

/* Header */
header {
    position: sticky;
    top: 0;
    z-index: 10;
    margin-bottom: 10px;
    padding-bottom: 10px;
    background-color: var(--bg-header-color);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
}

header::after {
    content: "";
    position: absolute;
    top: 100%;
    inset-inline: 0;
    height: 24px;
    background: linear-gradient(to bottom, var(--bg-header-color), transparent);
    pointer-events: none;
}

/* Header Title */
.title .site-name {
    display: block;
    font-family: var(--font-main);
    font-weight: bold;
    color: var(--heading-color);
    font-size: clamp(2.1rem, 7vw, 3rem);
    padding-top: 20px;
    margin: 0;
}

/* Navigation Bar */
header nav {
    font-family: var(--font-main);
    text-transform: uppercase;
}

header nav ul {
    list-style: none;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 2rem;
    justify-content: flex-start;
    margin-top: 0.5rem;
}

/* Bar Links Styling */
header nav a {
    line-height: 1.5;
    font-weight: 400;
    color: var(--color-blue);
    border-bottom: 2px solid currentColor;
    display: inline-block;
    transition: font-weight var(--transition-duration) ease, transform var(--transition-duration) ease;
}

header nav li:last-child {
    margin-left: auto;
}

header nav li:last-child a {
    color: var(--color-cyan);
}

header nav a.nav-home {
    color: var(--color-pink);
}

header nav a.nav-projects {
    color: var(--color-yellow);
}

header nav a:hover, header nav a:focus {
    font-weight: 900;
    transform: translateY(-4px);
}

/* Bold Text */
strong, b {
    color: var(--heading-color);
}

button {
    margin: 0;
    cursor: pointer; 
}

/* text below title */
i time {
 	font-family: var(--font-main);
  	font-style:normal;
    font-weight: bold;
}

/* Main Content */
main { line-height: 1.6;}

/*Main Text Content size*/
main p, main li {
    font-size: 1.1rem;
}

/* Main Title */
main h1 {
    font-size: 2.4rem;
    margin-bottom: 0;
}

/* Time */
body.post main h1 + p {
    display: inline-block;
    margin: 0 0 1rem;
}

body.post main h1 + p + p {
    display: inline-block;
    margin: 0 0 1rem;
}

body.post main h1 + p + p::before {
    content: " – ";
    font-family: var(--font-main);
}

/* Author names */
.post-author {
    font-family: var(--font-main);
    font-weight: normal;
    text-transform: uppercase;
}
/* Kinda tweaky */

main a {
    color: var(--text-color);
    font-family: var(--font-main);
    letter-spacing: -0.5px;
    text-decoration: none;
    border-bottom: 1px solid;
    transition: color 200ms ease;
}

main a:not(.social-bttn):hover {
    color: var(--link-color);
}

table {
    width: 100%;
}

/* Horizontal Line / Rule  */
hr {
    border-top: 2px solid;
}

/* Images */
img {
    display: block;
    width: 100%;
    height: auto;
    padding: 4px 0; /* espaciado entre imagenes */
    margin-inline: auto;
}

    /* Ilustraciones animadas (antes GIF, ahora WebP animado) */
    img[src$=gif], img.animated {
        pointer-events: none;
    }
    
/* Code */
code {
    font-family: monospace;
    padding: 2px;
    background-color: var(--code-background-color);
    color: var(--code-color);
    border-radius: 3px;
}

/* Blockquote */
blockquote {
    margin-inline-start: 8vw;
    color: var(--border-color);
    padding-left: 10px;
}

blockquote p:has(a) {
    padding: 5px 0 5px 0;
    font-size: 1.2rem;
    font-weight: bold;
    
    a {
        color:var(--heading-color);
        display: inline-block;
        border-bottom: 2px solid var(--border-color);
        transition: color var(--transition-duration) ease, transform var(--transition-duration) ease;
    }
}

blockquote p a::before {
    content: "> ";
    padding-right: 0.2em;
}

blockquote p:has(a) a:hover, blockquote p:has(a) a:focus {
    color: var(--link-color);
    border-color: var(--link-color);
    transform: translateY(-4px);
}

/* Colores por sección (listas de enlaces y lista de proyectos) */
[data-section="illustration"] {--link-color: var(--color-pink);}
[data-section="web"] {--link-color: var(--color-blue);}
[data-section="emails"] {--link-color: var(--color-cyan);}
[data-section="tesis"] {--link-color: var(--color-yellow);}

/* Lista de enlaces a secciones (antes eran <blockquote>) */
ul.section-links {
    list-style: none;
    margin-inline-start: 8vw;
    padding-left: 10px;
}

ul.section-links li {
    margin-block: 1em;
    padding: 5px 0;
    font-size: 1.2rem;
    font-weight: bold;
}

ul.section-links a {
    color: var(--heading-color);
    display: inline-block;
    border-bottom: 2px solid var(--border-color);
    transition: color var(--transition-duration) ease, transform var(--transition-duration) ease;
}

ul.section-links a::before {
    content: "> ";
    padding-right: 0.2em;
}

ul.section-links a:hover, ul.section-links a:focus-visible {
    color: var(--link-color);
    border-color: var(--link-color);
    transform: translateY(-4px);
}

/* Footer */
footer {
    padding: 25px 0;
    font-family: var(--font-main);
    font-weight: bold;
    font-size: 0.9em;
    text-transform: uppercase;
    text-align: center;
}

.inline {
    width: auto !important;
}

/* TAGS */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-start;
    width: 100%;
    margin-top: 3rem;
}

.tags::before {
    content: "Herramientas Utilizadas";
    font-family: var(--font-main);
    font-size: var(--font-scale);
    font-weight: bold;
    color: var(--heading-color);
    text-transform: uppercase;
    width: 100%;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
    flex: 0 0 100%;
}

.tags :is(a, span) {
    font-size: 0.9em;
    display: inline-block;
    padding: 2px 1em;
    border: 1px solid var(--link-color);
    border-radius: 999px;
    letter-spacing: 0;
    font-weight: bold;
    color: var(--link-color);
    pointer-events: none;
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
}
/* End of TAGS */

/* Code */
.highlight, .code {
    padding: 2px 15px;
    background-color: var(--code-background-color);
    color: var(--code-color);
    border-radius: 3px;
    margin-block-start: 1em;
    margin-block-end: 1em;
    overflow-x: auto;
}

/* Blog post list page*/
ul.blog-posts {
    list-style-type: none;
    padding: unset;
}

ul.blog-posts li {
    display: flex;
    align-items: baseline;
    margin-bottom: 2rem;
}

ul.blog-posts li a {
    order: 1;
    flex: 1;
    min-width: 0;
    display: inline-block;
    transition: transform var(--transition-duration) ease;
}

ul.blog-posts li a:hover, ul.blog-posts li a:focus {
    transform: translateY(-4px);
}

ul.blog-posts li span {
    order: 2;
    flex: 0 0 auto;
    transform: translateY(6px);
    margin-inline-start: auto;
    white-space: nowrap;
    transition: transform var(--transition-duration) ease, color 200ms ease;
}

ul.blog-posts li:has(> a:hover) > span {
    transform: translateY(-2px);
    color: var(--link-color);
}

/* Color Post Labels: ver [data-section] más arriba */

.blog .tags {
    font-size: 1rem;
    --link-color: var(--color-cyan);
}
/* End of Blog post list page */

/* Bullet List */
ul { list-style-type: ">  "}


/* Home Page*/
    body.home img {
     width: 60%;
     padding: 0;
    }

    body.home p:has(> img) {
    margin-block: 0;
    }

    body.home footer {
    padding: 10px 0;
    }


.home, .page {--width: 980px;}

/* Pages Styling */
.page:not(.about-me) main h1 {text-align: center; margin-block: 0; font-size: clamp(1.8rem, 7vw, 2.6rem);}

.no-gap p img {padding: 0;}

/* End of Home */

/* About me Page */
@keyframes cat-x {
  from { 
    left: 0; 
  }
  to { 
    left: calc(var(--cat-screen-w) - (var(--cat-w) * 1px)); 
  }
}

@keyframes cat-y {
  from { 
    top: 0; 
  }
  to { 
    top: calc(var(--cat-screen-h) - (var(--cat-h) * 1px)); 
  }
}

@keyframes marquee {
    from {
    transform: translateY(0);
  }
  to {
    transform: translateY(calc(-100% - var(--gap)));
  }
}

@keyframes marquee-hor {
    from {
    transform: translateX(0);
  }
  to {
    transform: translateX(calc(-100% - var(--gap)));
  }
}

.about-me {
    --side-width: clamp(5rem, 8vw, 9rem);
    --width: calc(50vw + 450px);
    --gap: 10px;
    --cat-w: 100;
    --cat-h: 100;
    --cat-screen-w: 130vw;
    --cat-screen-h: 130vh;
    max-width: min(var(--width), calc(100vw - var(--side-width) - 1rem));
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(0, 3fr);
    align-items: start;
    column-gap: 2rem;
    margin-left: 0;
    text-align: start;
}

.about-me main ul {
    list-style-type:none;
    padding: unset;
    margin: 0;
}

body.about-me header {
    position: static;
}

body.about-me main {
    grid-column: 2;
    display:contents;
}

body.about-me .main-content, 
body.about-me header,
body.about-me footer { grid-column: 2; min-width: 0;}


.right_side {
    position: fixed;
    top: 0;
    right: 0;
    width: var(--side-width);
    height: 100vh;
    display: flex;
    z-index: 8;
}

.right_side > * {
    flex: 1;
    min-width: 0;
}

.marquee {
    --gap: 2rem;
    display: flex;
    overflow: hidden;
    flex-direction: column;
    gap: var(--gap);
}

.marquee--blue {background-color: var(--color-blue);}
.marquee--pink {background-color: var(--color-pink);}
.marquee--reverse .marquee_content {animation-direction: reverse;}
.marquee:hover .marquee_content {animation-play-state: paused;}
.right_side .label-end {text-align: right;}

.marquee_content {
    position: relative;
    flex-direction: column;
    flex-shrink: 0;
    display: flex;
    justify-content: space-around;
    align-items: center;
    gap: var(--gap);
    min-width: 100%;
    animation: marquee 120s linear infinite;
}

.marquee_content li {
    font-family: var(--font-main);
    font-weight:300;
    font-size: calc(14px + (21 - 14) * ((100vw - 320px) / (2560 - 320)));
    line-height: 2;
    color:#ffffff;
    text-transform: uppercase;
    writing-mode:sideways-lr;
    text-orientation: mixed;
}

.right_side span {
    font-family: var(--font-main);
    font-weight:300;
    font-size: calc(12px + (24 - 12) * ((100vw - 320px) / (2560 - 320)));
    /* font-size: calc(12px + (22 - 12) * ((100vw - 320px) / (2560 - 320))); */
    line-height: 1.4;
    padding-inline: 3vh;
    /* margin-block-start: 4px; */
    writing-mode:sideways-lr;
    text-orientation: mixed;
    align-content:end;
}

.cat_screen {
  position: fixed;
  inset: -15vh -15vw;
  width: var(--cat-screen-w);
  height: var(--cat-screen-h);
  overflow: hidden;
  pointer-events: none;
  z-index: 10; 
}

.cat {
    position: absolute;
    width: calc(var(--cat-h) * 1px);
    height: calc(var(--cat-h) * 1px);
    pointer-events: auto;
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    animation: 
    cat-x 50s linear infinite alternate,
    cat-y 35s linear infinite alternate;
}

.about-me main h1 {
    font-size: 2rem;
    gap: 1.5rem;
    margin-block: 1rem 0;
}

img.logo {
    width: 6rem; 
    margin-right: 0;
    /* transform: rotate(3deg); */
    padding: 0;
    grid-column: 2;
}

.side {
    grid-row: 2;
    position: sticky;
    top: 10rem;
    align-self: start;
    margin-block-start: -10vh;
    display: flex;
    align-items:end;
    flex-direction: column;
    gap: 1rem;
}

.side-img {
    width: 100%;
    aspect-ratio: 2 / 3;
    overflow: hidden;
}

.side-img img {
    width: 100%;
  height: 100%;
  object-fit: cover;
  padding: 0;
}

.vertical-text {   
    writing-mode:sideways-lr;
    font-family: var(--font-main);
    font-size: 1.2rem;
    color: var(--text-color);
}

@media (max-width: 768px) {
    .about-me {
        --cat-w: 80;
        --cat-h: 80;
        --cat-screen-w: 200vw;
        --cat-screen-h: 110vh;
        max-width: 100%;
        grid-template-columns: 1fr;
        margin-inline: auto;
        overflow-x: hidden;
        text-align: justify;
    }

    body.about-me header,
    body.about-me .side,
    body.about-me .main-content,
    body.about-me footer, img.logo {
        grid-column: 1;
    }

    .side {
        position: static;
        grid-row: 4;
        margin-block-start: 0;
        width: 100%;
        align-items: center;
        gap: 0.5rem;
    }

    .side-img {
        position: relative;
        aspect-ratio: 3 / 2;
        container-type: size;
    }

    .side-img img {
        position: absolute;
        top: 50%;
        left: 50%;
        width: 90cqh;
        height: 90cqw;
        max-width: none;
        transform: translate(-50%, -50%) rotate(90deg);
    }

    body.about-me .vertical-text {
        writing-mode: horizontal-tb;
        font-size: 1rem;
    }

    .right_side {
        position: relative;
        display: flex;
        flex-direction: column;
        height: auto;
        width: 100vw;
        left: 50%;
        right: 50%;
        margin-left: -50vw;
        margin-right: -50vw;
        margin-block-end: 2rem;
    }

    .cat_screen{
        inset: -5vh -50vw;
    }

    .cat {
    animation: 
    cat-x 20s linear infinite alternate,
    cat-y 60s linear infinite alternate;
    }

    .marquee {
        --gap: 1rem;
        flex-direction: row;
        padding-block: 4px;
        width: 100%;
    }

    .marquee_content {
        flex-direction: row;
        animation: marquee-hor 50s linear infinite;
    }

    .right_side span, .marquee_content li {writing-mode: horizontal-tb;}

    .marquee_content li {
    font-size: 1.1rem;
    }

    .right_side span {
    font-size: 1.1rem;
    padding-inline: 20px;
    margin-block-start: 1.8rem;
    }

    .about-me main h1 {
    text-align: center;
    }

    img.logo {
    grid-row: 2;
    width: 5rem; 
    margin-inline: auto;
    /* margin-block-end: 1rem; */
    transform: none;
    }

}

.contact-buttons {
    grid-column: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    max-width: max(80%, 650px);
    margin: 2rem 0;
    /* margin: 2rem auto; */
}

.social-bttn {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    padding: 8px 2rem;
    border: 1.5px solid;
    border-radius: calc(infinity * 1px);
    gap: 12px;
    color: var(--button-color);
    font-family: var(--font-main);
    font-weight: bold;
    text-decoration: none;
    letter-spacing: 0;
    transition-property: background-color, color, border;
    transition-duration: var(--transition-duration);
    transition-timing-function: ease;
}

.social-bttn:hover {
    color: var(--background-color);
    border-color: var(--button-color);
    background-color: var(--button-color);
}

.social-bttn:active {
    background-color: var(--button-color);
    color: var(--background-color);
 }

.social-bttn.behance {
    --button-color: var(--color-yellow);
    flex: 1;
}

.social-bttn.ig {
    --button-color: var(--color-pink);
    flex: 2;
}
.social-bttn.correo {
    --button-color: var(--color-blue);
    width: 100%;
}

/* Post Pages */

.client-project {
    display: flex;
    justify-content:space-between;
    align-items: flex-end;
    margin-block-end: 1.5em;
    pointer-events: none;
}

.client-title {
    width: 40%;
    max-width: 350px;
    height: auto;
    padding: 0;
    margin: 0;
}

.client-logo {
    max-width: 20%;
    max-height: 90px;
    width: auto;
    height: auto;
    padding: 0;
    margin: 0;
}

@media (max-width: 768px) {

    .contact-buttons {
        max-width: 100%;
    }

    .social-bttn:is(.behance) .bttn-text {display: none;}

    .social-bttn {
        padding: 0.6rem;
    }

    .social-bttn.correo {order: -1;}
    
    .client-title {
        width: 60%;
    }

    .client-logo {
        max-width: 15%;
    }

    img, body.home img {
        width: 100%;
    }

    header {
        position: static;
    }

    body.about-me .side {
        top: 1rem;
    }

    main a {
        transition: none;
    }

    header nav ul {
        justify-content: space-between; font-size: 0.9rem; gap: 1rem 1.2rem;
    }

    header nav li:last-child {
        margin-left: 0;
    }

    main p, main li {
        font-size: 1rem;
    }

    .no-gap p img {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    }
}

/* CUSTOM CLASSES */
:root:has(body.illustration),
body.illustration {--link-color: var(--color-pink);}
:root:has(body.web),
body.web {--link-color: var(--color-blue);}
:root:has(body.emails), :root:has(body.about-me), body.about-me,
body.emails {--link-color: var(--color-cyan);}
:root:has(body.tesis),
body.tesis {--link-color: #d3a345; --scroll-track: #151B26;}

/* Laqha Styling */

.laqha {
    --link-color: #9393D4;
    overflow-x: hidden;
    transform-style:preserve-3d;
    header {position: static;}


.parallax {
    isolation: isolate;
    contain: paint;
    padding-top: min(150cqmin, 1800px);
    background-color: white;
    z-index: -1;
    display: grid;
    grid-template-areas: "stack";
    --parallax-speed: 1;
    pointer-events: none;
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
}

.parallax > * {
    grid-area: stack;
    padding: 0;
    animation: parallax linear;
    animation-timeline: scroll();
}

.parallax > img {
    width: 100%;
}

.parallax_background {
    --parallax-distance: 90;
    z-index: -1;
    position: relative;
    top: max(-60cqmin, -800px);
}

.parallax_text {
    --parallax-distance: -30;
    position: absolute;
    padding:0 4rem;
    line-height: 1.8;
    font-family: var(--font-main);
    color: rgb(180 197 228 / .8);
    mix-blend-mode: multiply;
    top: max(-60vmin, -600px);
    z-index: 1;
}

.parallax_text p {font-size: 1.2rem;}

.parallax_text > p:first-child {
    animation: appear linear both;
    animation-timeline: view();
    animation-range: 0% 35%;
}

.parallax_logo {
    --parallax-distance: 160;
    position: relative;
    left: 3vw;
    top: max(-130cqmin, -1200px);
    z-index: 2;
    animation: parallax linear,
        laqha-logo-entrance 6s cubic-bezier(.2, .8, .2, 1) both,
        laqha-logo-aurora 8s linear infinite;
    animation-timeline: scroll(), auto, auto;
}

img.parallax_logo {width: 60%;}

@media (prefers-reduced-motion: reduce) {
    .parallax_logo {
        animation: none;
        opacity: 1;
        scale: 1;
        -webkit-filter: drop-shadow(0px 0 5px white);
        filter: drop-shadow(0 0 5px white);
    }
}

.parallax_bgmountains {
    --parallax-distance: 180;
    z-index: 3;
    position: relative;
    bottom: min(60cqmin, 600px);
}

.parallax_mountain {
    --parallax-distance: -15;
    position: relative;
    top: min(50cqmin, 500px);
    z-index: 4;
}

.parallax_foreground {
    z-index: 5;
    position: fixed;
    bottom: 0;
}

.parallax-fallback {
    display: none;
}

.parallax-fade {
    height: 300px;
    background: linear-gradient(
    to bottom,
    #170523,
    #6C5CAA 25%,
    rgb(147 147 212 / .75) 50%,
    rgb(142 168 206 / 0.5) 65%,
    transparent);
}

.title-laqha {
    --heading-color: white;
     position: relative;
    z-index: 1;
    margin-top: -16em;
    text-align: center;
    text-shadow: 0px 2px 15px #6C5CAA;
}

.title-laqha > * {
    animation: appear-t linear both;
    animation-timeline: view();
}

.title-laqha h1 {
    font-size: 6em;
    line-height: 1.2;
    margin-top: 0;
    animation-range: 0% 50%;
}

.title-laqha h2 {
    font-weight: normal;
    font-size: 1.8em;
    line-height: 1.2;
    margin-top: 0;
    animation-range: 20% 60%;
}

.title-laqha .project-meta {
    font-family: var(--font-main);
    color: var(--heading-color);
    font-size: large;
    text-transform: uppercase;
    margin-top: 5px;
    animation-range: 30% 60%;
}

p img {
    padding: 0;
    animation: appear-t linear both;
    animation-timeline: view();
    animation-range: 0% 25%;
}

h1, h2 {
    animation: appear-t linear both;
    animation-timeline: view();
    animation-range: 10% 50%;
}

@media (max-width: 980px) and (orientation: portrait) {
   .parallax {   
    --parallax-speed: .7;
    }

    .parallax, .parallax-fade, .parallax-fallback, p img {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    }

.parallax_text {
    --parallax-distance: -120;
    padding:0 1.5rem;
    line-height: 1.6;
    top: -20vmin;
}

.parallax_text p {font-size: .8em;}

    .parallax_text > p:first-child {
    animation: appear linear both;
    animation-timeline: view();
    animation-range: 0% 20%;
}    

    .parallax_logo {
    top: -120cqmin;
    }

    .parallax .parallax_background {
    --parallax-distance: 35;
    top: -20cqmin;
    }

    .parallax_bgmountains {
    --parallax-distance: 160;
    bottom: 50cqmin;
    }

    .parallax_mountain {
    --parallax-distance: -25;
    top: 50cqmin;
    }
}

@supports not (animation-timeline:scroll()) {
    .parallax {display: none}

    .parallax-fallback {
        display: block;
        aspect-ratio: 3 / 4;
        background: center / contain no-repeat url("https://cdn.guillegmm.com/guillermo/assets/lapha_plain.56361d72.webp");
    }
}
}

/* No tocar */
@keyframes parallax {
    to {
         transform: translateY(calc(var(--parallax-speed) * var(--parallax-distance) * clamp(20px, .5vh, 100px)));
    }
}

@keyframes appear {
    0% { 
        opacity: 0;
        filter: blur(5px);
    }

    100% {
        opacity: 1;
        filter: blur(0px);
    }

}

@keyframes appear-t {
    0% { 
        opacity: 0;
        filter: blur(5px);
        color: #0062FF;
        transform: translateY(15px);
    }

    50% {
        color:#52fff9;
    }

    100% {
        opacity: 1;
        filter: blur(0px);
        transform: translateY(0);
    }
}

@keyframes laqha-logo-entrance {
    from {
        opacity: 0;
        scale: 0;
    }

    to {
        opacity: 1;
        scale: 1;
    }
}

@keyframes laqha-logo-aurora {
    0%, 100% {
        filter: drop-shadow(0 0 1px white)
        drop-shadow(0 0 4px #94fbff)
        drop-shadow(0 0 6px #f1abfa);
    }
    
    25% {
        filter: drop-shadow(0 0 12px white)
        drop-shadow(15px 14px 14px #d37efa)
        drop-shadow(-20px -18px 22px #76adff);
    }
    
    75% {
        filter: drop-shadow(0 0 8px white)
        drop-shadow(-20px 20px 10px #6bcaf0)
        drop-shadow(20px -10px 16px #ff77e8);
    }

    90% {
        filter: drop-shadow(0 0 8px white)
        drop-shadow(-5px 0px 6px #7b86e7)
        drop-shadow(5px 0px 8px #f16be6);
    }
}

/* TESIS Styling */ 

.tesis {
    --width: 100vw;
    --background-color: #FCF4E8;
    --bg-header-color: rgba(252 244 232 / 70%);
    --heading-color: #4d72b9;
    --color-orange: #9C4B22;
    --text-color: #41281C;
    --link-color: #B2B2B2;
    --border-color: #bc9759;
    --color-pink: #ff620e;
    --color-yellow: #d3a345;
    --color-blue: #4d72b9;
    --color-cyan: #3d9cc8;
    --sticker-shadows: rgb(118 79 64 / .25);
    --font-main: 'Gabriele Ribbon FG', sans-serif;
    --font-text: 'Gabriele Ribbon FG', monospace;
    --transition-duration: 500ms;

    padding: 0;

    /* Headings tesis */
    h1, h2, h3, h4, h5 {
        font-weight: normal;
        margin-bottom: 2rem;
    }

    h1 {
        color: var(--text-color);
        margin-bottom: 0.5rem;
    }

    h2 {
        font-size: 1.8rem;
        text-align: center;
    }

    h3, .cita {
        color: var(--text-color);
        font-size: 1.4rem;
    }

    /* Cita de apertura (antes era un <h3>) */
    main p.cita {
        font-family: var(--font-main);
        font-size: 1.4rem;
        letter-spacing: normal;
        margin-block: 1em 2rem;
    }

    .orange {
        color: var(--color-orange);
    }

    /* Navigation Bar Tesis */
    header {
        padding: 0 20px 10px 20px;
        margin-bottom: 0;
    }

    .title .site-name {
        font-size: calc(2rem + .25vw);
        padding-top: 10px;
    }

    header nav {font-family: "JetBrains Mono", monospace;}

    header nav ul { margin-bottom: 0;}

    /* Main Content*/
    main {
        display: grid;
        grid-template-columns: minmax(0, 1fr) min(900px, 100%) minmax(0, 1fr);
        position: relative;
        overflow-x: clip;
        transform-style: preserve-3d;
        z-index: 1;
    }

    .main-content {
        grid-column: 2;
        margin-block-end: 2rem;
    }

    main a {
        font-family: 'Gabriele Ribbon FG';
        font-weight: 300;
        color: var(--color-blue);
        border-bottom: 2px dashed;
    }

    main a:hover {
    color: var(--link-color);
    }

    main p, main li {
        font-size: 1.25rem;
        letter-spacing: -1px;
        line-height: 1.6;
        margin-block: 1.4em;
    }

    img {
        padding: 0;
    }

    /* Blockquote tesis */
    blockquote {
        margin-inline-start: 0;
        padding-left: 0;
        color: var(--color-blue);
        font-weight: bold;
        }
    
       blockquote p:has(a) > a {font-weight: bold;}

    blockquote p a::before {content: none;}
    

    /* Hero Banner */

    .tesis-banner {
        grid-column: 1/-1;
        height: 75vh;
        background-image: 
        linear-gradient(to bottom, transparent 75%, rgba(57, 23, 2, 0.4) 89%, rgba(161 86 43 / 75%) 95%, var(--background-color) 100%),
        linear-gradient(to top, transparent 95%, var(--background-color) 100%),
        url('https://cdn.guillegmm.com/guillermo/assets/bg-hero-tesis.972bb1bc.webp'); 
        background-size:cover;
        background-position: top;
        display: flex;
        align-items: center;
        flex-direction: column;
        justify-content: center;
        color:#ffc26e;
    }

    /* Footer */

    footer {
    position: relative;
    z-index: 0;
    background-image: 
        linear-gradient(to bottom, var(--background-color) 0%, transparent 30%),
        url('https://cdn.guillegmm.com/guillermo/assets/s-tesis-4.d9ea0491.webp');
    background-size: cover;
    background-position: center;
    padding: 53vh 0 4vh;
    margin-top: 8rem;
    }   

    footer > span {
        font-family: "JetBrains Mono", monospace;
        color: var(--text-color);
        background-color: var(--background-color);
        display: inline-block;
        padding: 0.8em 2em;
        border: 1.5px solid var(--text-color);
        border-radius: 999px;
        transition: border-color var(--transition-duration) ease,
            background-color var(--transition-duration) ease;
    }

    footer > span:has(> a:hover) {
        background-color: var(--link-color);
        border-color: var(--link-color);
    }

    footer > span:has(> a:hover) > a {
        color: var(--background-color);
    }

    /* Foto papa footer */

    #papa {
        position:fixed;
        z-index: 2;
        max-width: min(27vw, 600px);
        right: 5dvw;
        bottom: -35dvh;
        rotate: 4deg;
        -webkit-filter: drop-shadow(5px 5px 5px var(--sticker-shadows));
        filter: drop-shadow(5px 5px 5px var(--sticker-shadows));
        transition: scale var(--transition-duration) ease-in-out, filter var(--transition-duration) ease-in-out;
    }

    #papa:hover {
        -webkit-filter: drop-shadow(0px 0px 10px #FFB65E);
        filter: drop-shadow(0px 0px 10px #FFB65E);
    }

    /* Tesis Logo */

    .tesis-logo {
    width: min(500px, 90%);
    aspect-ratio: 5 / 4;
    transform: translateY(-20px);
    background-size: cover;
    background-position: center;
    -webkit-filter: drop-shadow(0 0 8px #ff5a2c) drop-shadow(0 0 50px #ff652e);
    filter: drop-shadow(0 0 8px #ff5a2c) drop-shadow(0 0 50px #ff652e);
    z-index: 2;
    animation: tesis-logo 700ms steps(1) infinite;
    }

    .tesis-logo:hover {animation-play-state: paused;}

    @media (prefers-reduced-motion: reduce) {
        .tesis-logo {animation: none; background-image: url(https://cdn.guillegmm.com/guillermo/assets/logo/logo-t1.dbd806a5.webp);}
    }

    /* Full bleed */

    .full-bleed {
         grid-column: 1 / -1;
         z-index: 1;
    }

    #collage { width: 70%;}

    /* Composition Sueter */

.comp-tesis {
    position: relative;
    width: 100%;
    aspect-ratio: 8 / 9;
    margin-block: 4rem;
    display: grid;
    grid-template-areas: "stack";
    pointer-events: none;
}

.comp-tesis > * {
    grid-area: stack;
    padding: 0;
    animation: comp-t linear;
    animation-timeline: view();
}

.comp-t1 {--comp-distance: 1; z-index: 1; -webkit-filter: drop-shadow(6px 6px 3px var(--sticker-shadows));
        filter: drop-shadow(6px 6px 3px var(--sticker-shadows));}
.comp-t2 {--comp-distance: 4; z-index: 2; position: relative; transform: translateY(-60px); -webkit-filter: drop-shadow(6px 6px 3px var(--sticker-shadows));
        filter: drop-shadow(6px 6px 3px var(--sticker-shadows));}
.comp-t3 {--comp-distance: 8; z-index: 3; position: relative; transform: translateY(-100px); -webkit-filter: drop-shadow(6px 6px 3px var(--sticker-shadows));
        filter: drop-shadow(6px 6px 3px var(--sticker-shadows));}

    /* Stickers */

    .side-stickers {
        position: relative;
        container: initial;
        height: 100%;
        display: grid;
        grid-template-areas: "stack";
        pointer-events: none;
    }

    .left {
        grid-column: 1;
    }

    .right {
        grid-column: 3;
    }

    .photos, .cites, .objects {
        height: 100%;
        grid-area: stack;
        container-type: size;
        animation: stickers linear both;
        animation-timeline: view();
        animation-range: entry 0% exit 88%;
    }
    
    .photos {
        z-index: 2;
        --shift-amount: -5;
        --sticker-shift: 30px;
    }
    
    .cites {
        z-index: 0;
        -webkit-filter: drop-shadow(6px 6px 4px var(--sticker-shadows));
        filter: drop-shadow(6px 6px 3px var(--sticker-shadows));
        --shift-amount: -3;
        --sticker-shift: 10px;
    }

    .objects {
        z-index: 4;
        -webkit-filter: drop-shadow(6px 6px 4px var(--sticker-shadows));
        filter: drop-shadow(6px 6px 3px var(--sticker-shadows));
        --shift-amount: 70;
        --sticker-shift: 4px;
    }
    
    .sticker {
        position: absolute;
        height: auto;
        margin: 0;
    }

    /* Stickers Positions */
.a1{ width: min(90cqw,400px); top: 7cqh; left: -16cqw; rotate: 12deg;}
.a2{ width: min(89cqw,350px); top: 13cqh; right: 16cqw; rotate: 52deg;}
.a3{ width: min(75cqw,300px); bottom: 26cqh; right: 12cqw; rotate: 6deg;}
.a4{ width: min(10cqw,50px); bottom: 22cqh; right: 18cqw; rotate: -90deg;}
.a5{ width: min(25cqw,120px); bottom: 1cqh; right: 45cqw; rotate: 125deg;}
.a6{ width: min(98cqw,400px); bottom: 10cqh; right: -2cqw;}

.b1{ width: min(93cqw,400px); top: 3cqh; left: 4cqw;}
.b2{ width: min(55cqw,180px); top: 2cqh; left: 25cqw;}
.b3{ width: min(42cqw,160px); bottom: 30cqh; left: 18cqw; rotate: 36deg;}
.b4{ width: min(27cqw,140px); bottom: 23cqh; right: 20cqw; rotate: -40deg;}
.b5{ width: min(13cqw,65px); bottom: 19cqh; left: 28cqw; rotate: 53deg;}
.b6{ width: min(75cqw,270px); top: 85cqh; left: 10cqw; rotate: -75deg;}

.c1{ width: min(30cqw,100px); top: -15cqh; right: 35cqw; rotate: 44deg;}
.c2{ width: min(43cqw,140px); top: 18cqh; left: -2cqw; rotate: 130deg;}
.c3{ width: min(103cqw,380px); bottom: 1cqh; left: -6cqw; rotate: -4deg;}

.d1{ width: min(65cqw,230px); top: 10cqh; left: 8cqw; rotate: 13deg;}
.d2{ width: min(59cqw,240px); top: 42cqh; right: -1cqw; rotate: -10deg;}
.d3{ width: min(92cqw,400px); bottom: 1cqh; left: 10cqw; rotate: 7deg;}
.d4{ width: min(18cqw,70px); top: 40cqh; left: 12cqw; rotate: 126deg;}

.e1{ width: min(90cqw,420px); top: 6cqh; left: -10cqw; rotate: -8deg;}
.e2{ width: min(98cqw,450px); top: 48cqh; right: 4cqw;}
.e3{ width: min(105cqw,380px); bottom: -2cqh; left: -15cqw;}
.e4{ width: min(32cqw,110px); top: 17cqh; right: 15cqw;}
.e5{ width: min(15cqw,50px); top: 30cqh; right: 45cqw; rotate: -14deg;}
.e6{ width: min(22cqw,80px); top: 53cqh; right: 18cqw; rotate: -127deg;}
.e7{ width: min(70cqw,200px); top: 63cqh; right: 28cqw; rotate: -80deg;}

.f1{ width: min(40cqw,140px); top: -17cqh; left: 38cqw;}
.f2{ width: min(98cqw,320px); top: 25cqh; left: 22cqw; rotate: 6.5deg;}
.f3{ width: min(112cqw,440px); top: 14cqh; right: -0.5cqw;}

.g1{ width: min(90cqw,350px); top: 25cqh; right: 18cqw;rotate: 6deg;}
.g2{ width: min(75cqw,260px); top: 54cqh; right: 12cqw;rotate: 7deg;}
.g3{ width: min(84cqw,320px); bottom: 14cqh; left: -1cqw;rotate: -10deg;}
.g4{ width: min(100cqw,380px); top:32cqh; right: 5cqw;rotate: -6deg;}
.g5{ width: min(27cqw,110px); bottom: 35cqh; right: 50cqw;rotate: 44deg;}

.h1{ width: min(90cqw,340px); top: 10cqh; right: -3cqw;}
.h2{ width: min(30cqw,110px); top: 20cqh; left: 20cqw;rotate: 14deg;}
.h3{ width: min(12cqw,40px); top: 29cqh; left: 52cqw;rotate: -110deg;}
.h4{ width: min(42cqw,150px); top: 42cqh; left: 22cqw;rotate: 54deg;}
.h5{ width: min(35cqw,100px); bottom: 38cqh; right: 20cqw;rotate: 119deg;}
.h6{ width: min(70cqw,250px); bottom: 22cqh; left: 20cqw;rotate: -4deg;}

@supports not (animation-timeline:view()) {
.a1{ width: min(90cqw,400px); top: 2cqh; left: -16cqw; rotate: 12deg;}
.a2{ width: min(85cqw,350px); top: 20cqh; right: 18cqw; rotate: 52deg;}
.a3{ width: min(70cqw,300px); bottom: 24cqh; right: 12cqw; rotate: 6deg;}
.a4{ width: min(10cqw,50px); bottom: 20cqh; right: 18cqw; rotate: -90deg;}
.a5{ width: min(25cqw,120px); bottom: 0; right: 45cqw; rotate: 125deg;}
.a6{ width: min(95cqw,400px); bottom: 8cqh; right: -2cqw;}

.b1{ width: min(93cqw,400px); top: 1cqh; left: 1cqw;}
.b2{ width: min(55cqw,180px); top: 10cqh; left: 25cqw;}
.b3{ width: min(42cqw,160px); bottom: 30cqh; left: 18cqw; rotate: 36deg;}
.b4{ width: min(27cqw,140px); bottom: 23cqh; right: 20cqw; rotate: -40deg;}
.b5{ width: min(13cqw,65px); bottom: 19cqh; left: 28cqw; rotate: 53deg;}
.b6{ width: min(75cqw,270px); top: 85cqh; left: 10cqw; rotate: -75deg;}

.c1{ width: min(30cqw,100px); top: -5cqh; right: 35cqw; rotate: 44deg;}
.c2{ width: min(43cqw,140px); top: 18cqh; left: -2cqw; rotate: 130deg;}
.c3{ width: min(103cqw,380px); bottom: 1cqh; left: -6cqw; rotate: -4deg;}

.d1{ width: min(65cqw,230px); top: 2cqh; left: 8cqw; rotate: 13deg;}
.d2{ width: min(59cqw,240px); top: 38cqh; right: -1cqw; rotate: -10deg;}
.d3{ width: min(92cqw,400px); bottom: 1cqh; left: 10cqw; rotate: 7deg;}
.d4{ width: min(18cqw,70px); top: 52cqh; left: 12cqw; rotate: 126deg;}

.e1{ width: min(90cqw,420px); top: -1cqh; left: -10cqw; rotate: -8deg;}
.e2{ width: min(88cqw,450px); top: 40cqh; right: 10cqw;}
.e3{ width: min(105cqw,380px); bottom: -2cqh; left: -15cqw;}
.e4{ width: min(32cqw,110px); top: 17cqh; right: 15cqw;}
.e5{ width: min(15cqw,50px); top: 30cqh; right: 45cqw; rotate: -14deg;}
.e6{ width: min(22cqw,80px); top: 53cqh; right: 18cqw; rotate: -127deg;}
.e7{ width: min(64cqw,180px); top: 63cqh; right: 35cqw; rotate: -80deg;}

.f1{ width: min(35cqw,140px); top: -12cqh; left: 40cqw;}
.f2{ width: min(95cqw,320px); top: 32cqh; left: 22cqw; rotate: 7.5deg;}
.f3{ width: min(105cqw,400px); top: 13cqh; right: 0cqw;}

.g1{ width: min(78cqw,280px); top: 18cqh; right: 18cqw;rotate: 6deg;}
.g2{ width: min(60cqw,230px); top: 52cqh; right: 15cqw;rotate: 7deg;}
.g3{ width: min(84cqw,320px); bottom: 10cqh; left: -1cqw;rotate: -10deg;}
.g4{ width: min(100cqw,380px); top:37cqh; right: 5cqw;rotate: -6deg;}
.g5{ width: min(27cqw,110px); bottom: 30cqh; right: 50cqw;rotate: 44deg;}

.h1{ width: min(90cqw,340px); top: 10cqh; right: -3cqw;}
.h2{ width: min(30cqw,110px); top: 27cqh; left: 20cqw;rotate: 14deg;}
.h3{ width: min(12cqw,40px); top: 35cqh; left: 52cqw;rotate: -110deg;}
.h4{ width: min(39cqw,160px); top: 44cqh; left: 22cqw;rotate: 54deg;}
.h5{ width: min(30cqw,110px); bottom: 37cqh; right: 20cqw;rotate: 119deg;}
.h6{ width: min(60cqw,250px); bottom: 20cqh; left: 20cqw;rotate: -4deg;}
}

@media (max-width: 1000px) {
    /* Headings tesis */
    h1, h2, h3, h4, h5 {margin-bottom: 1rem;}
    h2 {font-size: 1.6rem;}
    h3, main p.cita {font-size: 1.2rem;}

    .side-stickers {
        display: none;
    }

    .main-content {
        padding-inline: 20px;
        margin-block-end: 0.5rem;
    }

    main p, main li {
        font-size: 1rem;
        margin-block: 1.6em;
    }
    
    .comp-tesis, p img {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    }

    #collage { width: 100%;}

    .comp-t2 {transform: translateY(-70px);}
    .comp-t3 {transform: translateY(-140px);}


    #papa {
        position:relative;
        z-index: 2;
        max-width: 90%;
        right: 0;
        bottom: -2dvh;
        rotate: 4deg;
        scale: 1;
        transition: none;
    }

     footer {
    padding: 30vh 0 4vh;
    margin-top: 1rem;
    }   
}

}

@keyframes tesis-logo {
    0%, 100% { background-image: url(https://cdn.guillegmm.com/guillermo/assets/logo/logo-t1.dbd806a5.webp);}
    25% { background-image: url(https://cdn.guillegmm.com/guillermo/assets/logo/logo-t2.8e41ef4e.webp);}
    50% { background-image: url(https://cdn.guillegmm.com/guillermo/assets/logo/logo-t3.b001bbc3.webp);}
    75% { background-image: url(https://cdn.guillegmm.com/guillermo/assets/logo/logo-t4.0435bd88.webp);}
}

@keyframes stickers {
    from {
        transform: translateY(calc(var(--shift-amount) * var(--sticker-shift)));
    }

    to {
        transform: translateY(var(--sticker-shift));
    }
}

@keyframes comp-t {
    to {
         transform: translateY(calc(var(--comp-distance) * clamp(5px, 2vh, 80px)));
    }

    70% {opacity: 100%;}
    100% {opacity: 0%;}
}
/* ============================================================
   Accesibilidad
   ============================================================ */

/* Enlace "Saltar al contenido": oculto hasta que recibe foco con el teclado */
.skip-link {
    position: absolute;
    top: -100px;
    left: 1rem;
    z-index: 100;
    padding: 0.5rem 1rem;
    font-family: var(--font-main);
    font-weight: bold;
    color: var(--background-color);
    background-color: var(--heading-color);
    border-radius: 4px;
}

.skip-link:focus {
    top: 1rem;
}

/* Texto solo para lectores de pantalla */
.visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

/* Foco visible y consistente al navegar con teclado */
:focus-visible {
    outline: 2px solid var(--color-blue);
    outline-offset: 3px;
}

/* Menos movimiento para quien lo pide en su sistema */
@media (prefers-reduced-motion: reduce) {
    .marquee_content,
    .cat,
    .comp-tesis > *,
    .photos, .cites, .objects,
    .title-laqha > *,
    .parallax_text > p:first-child,
    .laqha p img,
    .laqha h1, .laqha h2 {
        animation: none !important;
    }

    header nav a, ul.section-links a, ul.blog-posts li a, ul.blog-posts li span {
        transition: none;
    }
}
