body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: "Poppins", sans-serif;
    background-color: black;
}

.bg-video{
    position: fixed;    
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;      
    z-index: 0;             
    pointer-events: none;   
    filter: brightness(.9); 
    opacity: 80%;
}

/*header*/
header {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    height:10vh;  
    background: color-mix(in oklab, #000000 5%, transparent);
    backdrop-filter: blur(6px);                 
}

header .logo {
    padding: 0 24px;  
    height: 44px;             
    width: auto;
    justify-self: start;
}

nav {
    display: flex;
    justify-content: center;
    flex: 1;   
    gap: 3rem;
}

nav a {
    position: relative;
    display: inline-flex;
    align-items: center;
    padding: .6rem 1.2rem;     
    text-decoration: none;
    color: #fff;
    font-size: 1.5rem;
    font-weight: 400;
    transition: all 0.3s ease;
}

nav a:hover {
    color:var(--fg,#f4349d);
    background: color-mix(in oklab, var(--fg,#f4349d) 12%, transparent); 
    border-radius: 50px;
}


#nav{
  position: relative;   
  z-index: 100000;        
  isolation: isolate;    
}

#nav.pin-spacer, 
#nav + .pin-spacer, 
#nav.parent-pin-spacer { z-index: 99999; }

/*project*/
iframe {
    border-radius: 30px;
}

.titulo {
    display: flex;
    justify-content: left;
    align-items: center;
    padding-top: 5%;
    padding-left: 12.5%;
}

.titulo h3 {
    color: white;
    margin-top: 0;
    font-size: 3rem;
}

.video-cont{
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;             
    margin: 0 auto;  
}

.video {
    display: block;
    width: min(90vw, 1200px);
    height: auto;
    margin-inline: auto;   
    border-radius: 30px;
}

.descripcion {
    width: 80%;
}

.descripcion p {
    display: flex;
    justify-content: left;
    align-items: center;
    padding-top: 1%;
    padding-left: 15.5%;
    font-size: 1.2rem;
    color: white;
}

.diseño {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 50px;
}

.diseño img {
    height: auto;
    width: 500px;
    border-radius: 20px;
}

.boton {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 5%;
}

.boton a{
    color:var(--fg,#f4349d);
    border: #f4349d solid;
    text-decoration: none;
    font-size: 1.4rem;
    text-align: center;
    border-radius: 100px;
    padding: 10px;
    transition: all 0.3s ease;
}

.boton a:hover {
    color: white;
    background: color-mix(in oklab, var(--fg,#f4349d) 50%, transparent); 
}

/*footer*/
footer{
    height: 40vh;
    margin-top: -2px;
    position: relative;
    display: grid;
    grid-template-columns: 1fr auto; 
    align-items: center;             
    gap: clamp(12px, 3vw, 48px);
    padding: clamp(20px, 5vw, 72px);
    color: #fff;    
}

.footer-brand{
  margin:0;
  font-weight: 700;
  font-size: clamp(40px, 10vw, 128px);
  display:flex; 
  align-items:center; 
  gap:.25em;
}

.footer-contact{
  font-weight: 100; 
  text-align:left;
  display:grid; 
  gap:.25em;
  font-size: 1.5rem;
  line-height: 0px;
}

.footer-contact a{
  color: var(--txt); text-decoration:none; opacity:.95;
}

.redes{
    width: auto;
    height: 50px;
    transition: all 0.3s ease;
}
.redes:hover {
    transform: scale(1.1);  
}


/* ===== NAV HAMBURGUESA ===== */
.nav-toggle{
  display:none;
  appearance:none;
  background:transparent;
  border:0;
  width:42px; height:42px;
  place-items:center;
  padding:0; margin:0 16px 0 auto;
  cursor:pointer;
  position:relative;
  z-index:100001;
}
.nav-toggle span{
  position:absolute; left:9px; right:9px; height:2px; background:#fff; transition:.25s;
}
.nav-toggle span:nth-child(1){ top:13px; }
.nav-toggle span:nth-child(2){ top:20px; }
.nav-toggle span:nth-child(3){ top:27px; }

/* dropdown móvil oculto por defecto */
#site-menu{ position:relative; }
@media (max-width: 768px){
  header{
    grid-template-columns: 1fr auto; /* logo | botón */
    height: auto;
    padding-block: clamp(8px, 2vw, 12px);
  }
  header .logo{ height: 38px; padding: 0 16px; }

  .nav-toggle{ display:grid; }

  /* ocultar la fila de links centrada de tu nav */
  #site-menu{
    position: absolute;
    top: 100%;
    right: 16px;
    display: none;
    flex-direction: column;
    gap: .2rem;
    padding: .6rem;
    background: color-mix(in oklab, #000 35%, transparent);
    backdrop-filter: blur(8px);
    border: 1px solid rgb(255 255 255 / .12);
    border-radius: 16px;
    box-shadow: 0 12px 32px rgb(0 0 0 / .35);
    z-index: 100000;
  }
  #site-menu a{
    padding: .8rem 1.2rem;
    font-size: 1.6rem;
    border-radius: 12px;
    white-space: nowrap;
  }
  #site-menu.is-open{ display:flex; }

  /* animación hamburguesa -> X */
  .nav-toggle[aria-expanded="true"] span:nth-child(1){ transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2){ opacity:0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3){ transform: translateY(-7px) rotate(-45deg); }

  /* hero más corto en móvil */
  main{ min-height: 56vh; justify-content: flex-end; }
}

/* ===== FOOTER RESPONSIVE ===== */
@media (max-width: 992px){
  footer{
    grid-template-columns: 1fr;
    height: auto;
    text-align: center;
    justify-items: center;
    gap: 1.2rem;
  }
  .footer-brand{ line-height: 1; }
  .footer-contact{
    text-align: center;
    line-height: 1.4;
    font-size: clamp(1.4rem, 1.8vw, 1.6rem);
    gap: .4rem;
  }
  .footer-contact > div{
    display:flex; gap: 12px; justify-content:center; align-items:center;
    margin-top: .2rem;
  }
  .redes{ height: 40px; }
}

/* Ajustes de stack en móvil (1 columna) */
@media (max-width: 768px){
  .stack{ height: 320vh; padding-inline: clamp(12px,4vw,24px); }
  .card{ grid-template-columns: 1fr; min-height: auto; }
  :root{ --gap: 55vh; --overlap: 45vh; }
  main h2{ font-size: clamp(2.4rem, 6vw, 4rem); padding-right: clamp(12px,6vw,10vh); }
}

.my-skills h2{
  font-size: clamp(2.2rem, 7vw, 3.6rem);  /* antes 4rem fijo */
}

/* ===== 3D — responsive patch (tablet/móvil) ===== */


/* 1) Título y paddings fluidos */
.titulo{ padding: clamp(16px, 6vw, 40px) clamp(16px, 7vw, 12.5%) 0; }
.titulo h3{ font-size: clamp(2rem, 6.5vw, 3rem); }

/* 2) Embeds Sketchfab fluidos (anula width/height fijos del iframe) */
.sketchfab-embed-wrapper{ width: min(92vw, 1200px); margin-inline:auto; }
.sketchfab-embed-wrapper iframe{
  width:100% !important;
  height:auto !important;
  aspect-ratio: 16/9;
  border-radius:30px;
  display:block;
}

/* 3) Descripciones legibles y centradas */
.descripcion{ width:auto; }
.descripcion p{
  padding: clamp(8px, 2vw, 12px) clamp(16px, 6vw, 12.5%);
  font-size: clamp(1.1rem, 3.6vw, 1.3rem);
  line-height: 1.5;
}

/* 4) Bloques con imágenes laterales (si aparecen), en columna */
@media (max-width: 768px){
  .diseño{ flex-direction: column; gap: 16px; }
  .diseño img{ width: clamp(220px, 88vw, 520px); height:auto; border-radius:20px; }
}

/* 5) Footer apilado/centrado en tablet y móvil */
@media (max-width: 992px){
  footer{
    grid-template-columns: 1fr;
    height:auto;
    text-align:center;
    justify-items:center;
    gap:1.2rem;
    padding: clamp(20px, 6vw, 48px);
  }
  .footer-brand{ line-height:1; }
  .footer-contact{
    text-align:center;
    line-height:1.4;
    font-size: clamp(1.3rem, 1.8vw, 1.6rem);
    gap:.4rem;
  }
  .footer-contact > div{
    display:flex; gap:12px; justify-content:center; align-items:center;
    margin-top:.2rem;
  }
  .redes{ height:40px; }
}
