@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800;900&display=swap');

* {
    margin:0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background: #363737;
}

.contact body {
    background: #363737;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

a {
    color:white;
    text-decoration: none;
}

.navbar {
    position: fixed;
    left: 0;
    right: 0;
    width: 100%;
    padding: 25px 9%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
}

.navbar .logo {
    position: relative;
    font-size: 35px;
    font-weight: 700;
}

.navbar .logo::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 110%;
    height: 120%;
    background: #363737;
    animation: showRight 1s ease forwards;
    animation-delay: 1s;
}

@keyframes showRight {
    100% {
        width: 0;
    }
}

.navbar ul {
    display: flex;
}

.navbar ul li {
    list-style: none;
    margin-left: 35px;
}
.navbar ul li a {
    font-size: 20px;
    font-weight: 500;
    transition: .5s;
}

.navbar ul li:hover a,
.navbar ul li.active a {
    color: lightskyblue;
}
section {
    min-height: 100vh;
    padding: 10rem 9% 2rem;
}
.home {
    display: flex;
    align-items: center;
    height: calc(100svh - var(--nav-h));
    padding: clamp(56px, 8vh, 96px) 9% 48px;
    color: #fff;
}

@media (max-width: 768px){
  .home{
    padding: calc(var(--nav-h) + 24px) 6% 48px;
  }
}

.home-info {
    max-width: 60rem;
}

.home-info h1 {
    font-size: 70px;
}

.home-info h1::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background: #363737;
    animation: showRight 3s ease forwards;
    animation-delay: 1s;
}

.home-info .text-animate {
    position: relative;
    width: 32.8rem;
}


.home-info .text-animate h2 {
    font-size: 2.45rem;
    font-weight: 700;
    color: transparent;
    -webkit-text-stroke: 0.7px lightskyblue; 
    background-image: linear-gradient(lightskyblue, #00bcd4);
    background-repeat: no-repeat;
    -webkit-background-clip: text; 
    background-position: 0 0;
    animation: TxtColor 6s linear infinite; 
    animation-delay: 2s;
}

.home-info .text-animate h2::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    border-right: 2px solid lightskyblue; 
    z-index: -1;
    animation: showRight 1s ease forwards, homeCursorText 6s linear infinite; 
    animation-delay: 2s;
}

.home-info p {
    font-size: 25px;
    margin: 10px 0 25px;
}

.home-info .btn-sci {
    display: flex;
    align-items: center;
}

.btn {
    display: inline-block;
    padding: 10px 30px;
    background: lightskyblue;
    border: 2px lightskyblue;
    border-radius: 50px;
    box-shadow: 0 0 10px lightskyblue;
    font-size: 20px;
    color: #2a2d1f;
    font-weight: 600;
    transition: .5s
}

.btn:hover {
    background: transparent;
    color: lightskyblue;
    box-shadow: none;
}

.home-info .btn-sci .sci {
    margin-left: 20px;
}

.home-info .btn-sci .sci a {
    display: inline-flex;
    padding: 8px;
    border: 2px solid lightskyblue;
    border-radius: 50%;
    font-size: 20px;
    color: lightskyblue;
    margin: 0 8px;
    transition: .5s;
}

.home-info .btn-sci .sci a:hover {
    background: lightskyblue;
    color: #1f242d;
    box-shadow: 0 0 10px;
}

.divider {
    width: 100%;
    height: 2px;
    background: #00bcd4;
    margin: 3rem 0;
    box-shadow: 0 0 20px 5px rgba(0, 188, 212, 0.7);
    animation: rotateGlow 6s linear infinite;
}

.home-selfie .img-box {
    margin-left: 15rem;
    width: 32vw;
    height: 32vw;
    background-image: conic-gradient(#00bcd4, #fff, #00bcd4, #fff, #00bcd4);
    border-radius: 50%;
    padding: 3px;
    position: relative;
    animation: rotateGlow 6s ease-in-out infinite;
}

@keyframes rotateGlow {
    0% {
        box-shadow: 0 0 5px 5px rgba(0, 188, 212, 0.7);
    }
    25% {
        box-shadow: 0 0 20px 5px lightskyblue;
    }
    50% {
        box-shadow: 0 0 35px 5px #00bcd4;
    }
    75% {
        box-shadow: 0 0 20px 5px lightskyblue;
    }
    100% {
        box-shadow: 0 0 5px 5px #00bcd4;
    }
}

.home-selfie .img-box .img-item {
    position: relative;
    width: 100%;
    height: 100%;
    background: lightskyblue;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    overflow: hidden;
}

.home-selfie .img-box .img-item img {
    position: absolute;
    display: block;
    width: 85%;
    object-fit: cover; 
}

@keyframes TxtColor {
    0%,
    10%,
    100% {
        background-position: -32.8rem 0;
    }
    65%,
    85% {
        background-position: 0 0;
    }
}

@keyframes homeCursorText {
    0%,
    10%,
    100% {
        width: 0;
    }
    65%,
    78%,
    85% {
        width: 100%;
        opacity: 1;
    }
    75%,
    81% {
        opacity: 0;
    }
}

.projects {
    padding: 50px;
  }
  
    .timeline {
    position: relative;
    max-width: 1800px;
    margin: 100px auto;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  
    .container {
    width: 90%;
    max-width: 900px;
    margin: 20px 0;
    padding: 10px 50px;
    position: relative;
    
    opacity: 0;
  }
  
    .timeline.active .container {
    animation: movedown 1s linear forwards;
  }
  
  
  .timeline.active .container:nth-child(1) { animation-delay: 0s; }
  .timeline.active .container:nth-child(2) { animation-delay: 1.2s; }
  .timeline.active .container:nth-child(3) { animation-delay: 2.4s; }
  .timeline.active .container:nth-child(4) { animation-delay: 3.6s; }
  .timeline.active .container:nth-child(5) { animation-delay: 4.8s; }



  
  @keyframes movedown {
    0% {
        opacity: 1;
        transform: translateY(-30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0px);
    }
  }


  .container:nth-child(1) {
    animation-delay: 0s;
  }
  
  .container:nth-child(2) {
    animation-delay: 1.2s;
  }

  .container:nth-child(3) {
    animation-delay: 2.4s;
  }

  .container:nth-child(4) {
    animation-delay: 3.6s;
  }

  .container:nth-child(5) {
    animation-delay: 4.8s;
  }
  
  

  .textbox {
    background-color: lightskyblue;
    padding: 20px 30px;
    position: relative;
    border-radius: 8px;
    font-size: 15px;
    animation: rotateGlow 6s ease-in-out infinite;
    color: #fff;
  }
  
  .left-container {
    align-self: flex-start;
  }
  
  .right-container {
    align-self: flex-end;
  }

  .container img{
    position: absolute;
    width: 75px;
    border-radius: 50%;
    right: -37px;
    top: 32px;
    z-index: 10;
    height: 75px;
  }

  .right-container img{
    left: -37px;
  }

  .timeline::after {
    content: '';
    position: absolute;
    width: 6px;
    height: 0;
    background: #00bcd4;
    top: 0;
    left: 50%;
    margin-left: -3px;
    z-index: -1;
 
  }
  .timeline.active::after {
    animation: moveline 5.5s linear forwards, rotateGlow 6s ease-in-out infinite;
  }

  @keyframes moveline {
    0% {
        height: 0;
    }
    100% {
        height: 100%;
    }
  }
  
  .textbox h2{
    font-weight: 600;
  }

  .textbox small {
    display: inline-block;
    margin-bottom: 15px;
  }


  .contact {
    min-height: 100vh;
    padding: 10rem 9% 4rem;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #fff;
  }
  
  .contact-card {
    width: 100%;
    max-width: 820px;
    background: #2d2e2e;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 0 20px rgba(0, 188, 212, 0.25);
  }
  
  .contact-card h2 {
    font-size: 2.2rem;
    margin-bottom: 0.25rem;
  }
  
  .contact-card p {
    opacity: 0.9;
    margin-bottom: 1.5rem;
  }
  
  #contact-form .row {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
  }
  
  #contact-form label {
    font-weight: 600;
    font-size: 0.95rem;
  }
  
  #contact-form input,
  #contact-form textarea {
    background: #1f2020;
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 0.9rem 1rem;
    color: #fff;
    outline: none;
    transition: border-color .25s ease, box-shadow .25s ease;
  }
  
  #contact-form input::placeholder,
  #contact-form textarea::placeholder {
    color: #a7a7a7;
  }
  
  #contact-form input:focus,
  #contact-form textarea:focus {
    border-color: lightskyblue;
    box-shadow: 0 0 10px rgba(135, 206, 250, 0.25);
  }
  
  #contact-form .btn {
    margin-top: 0.5rem;
  }
  
  
  #contact-status.status {
    margin-top: 0.75rem;
    font-size: 0.95rem;
    min-height: 1.25rem;
  }
  
  
  #contact-form .hp {
    position: absolute !important;
    left: -9999px !important;
    height: 0 !important;
    width: 0 !important;
    opacity: 0 !important;
  }
  

  .alt-contact {
    margin-top: 1rem;
    font-size: 0.95rem;
  }
  
  .alt-contact a {
    color: lightskyblue;
    text-decoration: underline;
  }
  
 
  @media (prefers-reduced-motion: reduce) {
    #contact-form input:focus,
    #contact-form textarea:focus { box-shadow: none; }
  }


.textbox.project { position: relative; overflow: hidden; }

.project-cta {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity .25s ease, transform .25s ease;
}

.textbox.project:hover .project-cta,
.textbox.project:focus-within .project-cta {
  opacity: 1;
  transform: translateY(0);
}


.btn-ghost {
  background: transparent;
  border: 2px solid lightskyblue;
  color: #fff;
  box-shadow: none;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.95rem;
  transition: .25s ease;
}
.btn-ghost:hover,
.btn-ghost:focus-visible {
  background: lightskyblue;
  color: #1f242d;
  outline: none;
}


.modal {
  position: fixed;
  inset: 0;
  display: none;
  justify-content: center;
  align-items: center;
  padding: 1.25rem;
  background: rgba(0,0,0,.65);
  z-index: 1000;
}
.modal.open { display: flex; }

.modal-card {
  width: min(100%, 960px);
  background: #2d2e2e;
  border-radius: 16px;
  padding: 0;
  overflow: hidden;
  box-shadow: 0 0 20px rgba(0, 188, 212, 0.25);
}

.modal-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: .75rem 1rem; color: #fff; border-bottom: 1px solid rgba(255,255,255,.08);
}
.modal-body { background: #000; aspect-ratio: 16/9; display: grid; place-items: center; }

.modal-close {
  background: transparent; border: 2px solid lightskyblue; color: #fff;
  border-radius: 999px; padding: .25rem .75rem; cursor: pointer;
}
.modal-close:hover { background: lightskyblue; color: #1f242d; }

.modal-gallery {
  display: flex; align-items: center; gap: .75rem; padding: .75rem; background: #000;
}
.modal-gallery img { max-height: 70vh; width: auto; border-radius: 8px; }


@media (hover: none) and (pointer: coarse) {
  .project-cta { opacity: 1; transform: none; }
}


@media (prefers-reduced-motion: reduce) {
  .project-cta { transition: none; }
}


.timeline .container {
  position: relative;              
}

.timeline .container .textbox {
  transition: transform .25s ease, box-shadow .25s ease, filter .25s ease;
  transform-origin: center;
  will-change: transform;
}

.timeline .container:hover .textbox,
.timeline .container:focus-within .textbox {
  transform: scale(1.05);           
  box-shadow: 0 12px 30px rgba(0, 188, 212, 0.32);
  z-index: 3;                        
}


.timeline .container img {
  transition: transform .25s ease;
}
.timeline .container:hover img,
.timeline .container:focus-within img {
  transform: scale(1.08);
}


@media (hover: none) and (pointer: coarse) {
  .timeline .container .textbox { transform: none !important; }
}


@media (prefers-reduced-motion: reduce) {
  .timeline .container .textbox { transition: box-shadow .2s ease; }
}

.gallery-stage {
  position: relative;
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  background: #000;
}
.gallery-stage img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.gallery-nav {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
}
.gallery-arrow {
  pointer-events: auto;
  background: rgba(0,0,0,.55);
  border: 2px solid lightskyblue;
  color: #fff;
  padding: .5rem .75rem;
  border-radius: 999px;
  margin: 0 .5rem;
  font-size: 1.25rem;
  line-height: 1;
}
.gallery-counter {
  position: absolute;
  bottom: .5rem;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,.55);
  border: 2px solid rgba(135,206,250,.35);
  padding: .25rem .6rem;
  border-radius: 999px;
  font-size: .9rem;
  color: #fff;
}


.projects-hint {
  text-align: center;
  margin: 0 0 12px;
  opacity: .85;
  font-size: .95rem;
}
@media (hover: none) and (pointer: coarse) {
  .projects-hint { display: none; } 
}

.projects-hint{

  font-family: "Poppins", system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  font-weight: 700;

  font-size: clamp(1rem, 1.2rem + .3vw, 1.25rem);
  letter-spacing: .6px;
  color: #fff;

  text-align: center;
  margin: 0 0 12px;


  text-shadow:
    0 0 6px rgba(135,206,250,.6),
    0 0 12px rgba(135,206,250,.55),
    0 0 24px rgba(135,206,250,.45);


  animation: hintGlow 2.4s ease-in-out infinite alternate;
}

.projects-hint--pill{
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(135,206,250,.12);
  box-shadow: 0 0 20px rgba(135,206,250,.25);
}

@keyframes hintGlow{
  from{ text-shadow: 0 0 4px rgba(135,206,250,.35), 0 0 10px rgba(135,206,250,.3), 0 0 18px rgba(135,206,250,.25); }
  to{   text-shadow: 0 0 10px rgba(135,206,250,.95), 0 0 22px rgba(135,206,250,.7), 0 0 42px rgba(135,206,250,.55); }
}
@media (prefers-reduced-motion: reduce){
  .projects-hint{ animation: none; }
}

@media (hover: none) and (pointer: coarse){
  .projects-hint{ display: none; }
}

img, video { max-width: 100%; height: auto; }

@media (max-width: 900px){
  .navbar { padding: 16px 6%; }
  .navbar .logo { font-size: 26px; }
  .navbar ul li { margin-left: 16px; }
  .navbar ul li a { font-size: 16px; }
  .home-info h1 { font-size: 44px; }
}

@media (max-width: 768px){
  /* Sections */
  section { padding: 7rem 6% 2rem; }
  .divider { margin: 2rem 0; }

  /* Home / hero */
  .home {
    flex-direction: column;
    align-items: center;
    text-align: center;
    height: auto;
    padding: 100px 6% 0; /* room for fixed navbar */
  }
  .home-info { max-width: 42rem; }
  .home-info .text-animate { width: auto; }
  .home-selfie .img-box {
    margin: 1.25rem auto 0;
    width: 64vw; height: 64vw;     /* fluid circle */
  }

  /* Projects */
  .projects { padding: 24px 0; }
  .timeline {
    margin: 24px auto;
    align-items: stretch;          /* let cards fill width */
  }
  .timeline::after { display: none; } /* hide tall center line on mobile */

  .container {
    width: 100%;
    max-width: 680px;
    padding: 16px 16px 20px;
    align-self: center !important; /* ignore left/right */
  }
  /* Move the round logo above the card on mobile so nothing overlaps */
  .container img {
    position: static;
    display: block;
    margin: 0 auto 10px;
    width: 64px; height: 64px;
  }
  .left-container, .right-container { align-self: center; }

  .textbox { text-align: center; }     /* center titles & copy */
  .project-cta {
    justify-content: center;
  }
  .project-cta .btn, .project-cta .btn-ghost {
    padding: 10px 18px;
  }

  /* Contact */
  .contact { padding: 7rem 6% 3rem; }
  .contact-card { padding: 1.25rem; }
}

/* 480px and down: slightly smaller text + paddings */
@media (max-width: 480px){
  .home-info h1 { font-size: 36px; }
  .home-info p { font-size: 16px; }
  .btn { font-size: 18px; padding: 10px 22px; }
  .textbox { font-size: 14px; padding: 16px; }
  .contact-card h2 { font-size: 1.8rem; }
}

@media (max-width: 768px){


  .home{
    display: grid;
    grid-template-columns: 1fr;
    grid-template-areas:
      "title"
      "subtitle"
      "selfie"
      "copy"
      "actions"
      "icons";
    justify-items: center;
    text-align: center;
    gap: 10px;
    padding-top: 96px;
  }

  /* / Make .home-info's children participate in the grid / */
  .home-info{ display: contents; }

  /* / Place pieces on the grid / */
  .home-info h1{ grid-area: title; margin: 0; }
  .home-info .text-animate,
  .home-info .text-animate h3{ grid-area: subtitle; margin: 0; }

  .home-selfie{ grid-area: selfie; }
  .home-selfie .img-box{
    width: 58vw; height: 58vw;
    margin: 6px 0 10px;
  }

  .home-info p{ grid-area: copy; max-width: 42rem; }

  /* / Try to catch your CTA row + social icons; adjust if your class names differ / */
  .home-info .btn, .home-info .btn-box, .home-actions{ grid-area: actions; }
  .home-sci, .social, .social-icons{ grid-area: icons; }

  /* / Center CTAs / */
  .btn-box, .home-actions, .social, .home-sci{ justify-self: center; }

  /* / Fix the animated subtitle on small screens / */
  .home-info .text-animate,
  .home-info .text-animate h3{
    font-size: clamp(26px, 7.4vw, 40px);
    line-height: 1.1;
  }
  .home-info .text-animate span{ display: block; }

  /* / Hide any “typing cursor”/decorative bars used by the animation */ */
  .home-info .text-animate::before,
  .home-info .text-animate::after,
  .home-info .text-animate h3::before,
  .home-info .text-animate h3::after{
    display: none !important;
    content: none !important;
  }
}

:root { --nav-h: 76px; }      /* a bit taller */

.navbar{
  position: fixed; top:0; left:0; right:0;
  min-height: var(--nav-h);   /* was: height: var(--nav-h) */
  height: auto;               /* let content decide if it needs more */
  display:flex; align-items:center; z-index:1000;
  padding: 14px 6%;
  background: #363737;
  backdrop-filter: saturate(160%) blur(12px);
  transition: transform .25s ease, background-color .25s ease, box-shadow .25s ease;
}

/* make the logo sit cleanly inside the bar */
.navbar .logo{ line-height: 1; }

/* Solid bar when scrolled */
.navbar.nav--solid{
  background: #1f242d;
  box-shadow: 0 8px 20px rgba(0,0,0,.25);
}

/* Slide away when scrolling down */
.navbar.nav--hidden{ transform: translateY(-100%); }

/* Don’t hide while user is interacting with it */
.navbar:hover, .navbar:focus-within{ transform: none !important; }

/* Offset page content for fixed navbar + smooth anchor jumps */
body{ padding-top: var(--nav-h); }
section{ scroll-margin-top: calc(var(--nav-h) + 12px); }

/* Small screens: slightly shorter bar */
@media (max-width: 480px){
  :root { --nav-h: 64px; }
  .navbar{ padding: 10px 5%; }
}

.nav-toggle{
  display:none;
  background:transparent;
  border:0;
  font-size: 30px;
  color:#fff;
  line-height:1;
  cursor:pointer;
}

/* Make the logo shrink a bit on very small screens */
@media (max-width: 380px){
  .navbar .logo { font-size: 22px; }
}

/* Mobile layout */
@media (max-width: 768px){
  .nav-toggle{ display:block; margin-left:auto; }

  /* Turn the list into a dropdown panel under the fixed bar */
  .navbar ul{
    position: fixed;
    top: var(--nav-h);
    left: 0; right: 0;
    display: none;                /* hidden until .open */
    flex-direction: column;
    gap: 10px;
    padding: 12px 6% 16px;
    background:#1f242d;
    box-shadow: 0 8px 20px rgba(0,0,0,.25);
    z-index: 999;                 /* above content */
  }
  .navbar.open ul{ display:flex; }

  .navbar ul li{ margin:0; }
  .navbar ul li a{ display:block; padding:10px 0; font-size:18px; }
}