@import url("https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;600;800&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;600&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@200;300;400;500;600;700&display=swap");

:root {
  --color-blurple: #7289da;
  --color-not-quite-black: #23272a;
  --color-dark: #2c2f33;
  --color-lighter-dark: #45494e;
  --color-full-white: #ffffff;
  --color-grey-white: #b9bbbe;
  --color-grey-dark: #242629;
  --color-actually-black: #000000;
  --color-fantastic-green: #00ae7a;
  --font-size-multiplier: 1.2;
  --font-size-multiplier-small: 0.5;
  --font-size-h1-title: 3vw;
  --font-size-h2-title: 1.2vw;
}

li {
  list-style-type: none;
}

ul {
  margin: 0;
  padding: 0;
  display: flex;
  /*justify-content: center;*/
}

body {
  margin: 0;
  background: rgb(0, 0, 0);
  /*
  background: linear-gradient(
    0deg,
    rgba(2, 0, 36, 1) 36%,
    rgba(42, 42, 84, 1) 98%
  );
  background: linear-gradient(
    55deg,
    rgba(0, 0, 0, 1) 20%,
    rgba(42, 53, 84, 1) 100%
  );*/
  background-image: linear-gradient(
    55deg,
    rgb(0, 0, 0) 0%,
    rgb(5, 5, 6) 30%,
    rgb(13, 18, 27) 56%,
    rgb(7, 4, 37) 96%,
    rgba(0, 0, 0, 1) 99%
  );

  /*background: var(--color-actually-black);*/
  /*font-family: "Open Sans Extra Bold", sans-serif;
  font-weight: 800;*/
  color: var(--color-full-white);
  overflow-x: hidden;
  overflow: hidden;
}
/*
.bgImage {
  position: relative;
  width: 100%;
  height: 100vh;
  background-image: url("D:\\Documents\\Poster_JoaoVitorino_BioData2022_light.jpg");
  background-position: center center;
  background-size: 100%;
  background-repeat: no-repeat;
}

.bgImage::after {
  content: "";
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  background-color: rgba(0, 0, 0, 0.55);
}
*/
nav {
  position: fixed;
  top: 20px;
  right: 5vw;
  z-index: 1002;
}

section {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

.home .section {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}

section h2 {
  position: relative;
  color: #fff;
  font-size: 12em;
}

section .limage {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.darken {
  /* Darken the element by setting its opacity to 0.5 */
  /*background: rgba(0, 0, 0, 0.4);*/
}

.container {
  transform-style: preserve-3d;
  transform: perspective(1000px);
  width: 100vw;
  height: 100%;
  position: absolute;
  display: flex;

  max-width: 1200px;
  flex-wrap: wrap;
  z-index: 1001;
}

.container .card {
  position: relative;

  width: 60vw;
  height: 10vh;
  margin: 0px;
  box-shadow: 20px 20px 20px rgba(0, 0, 0, 0.1);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
  justify-content: center;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  /*backdrop-filter: blur(2px);*/
}

.container .content {
  padding: 10px;
  text-align: right;
  transition: 0.5s;
  overflow: hidden;
}

.container .content h1 {
  font-size: calc(1rem + 3vw);
  color: rgba(255, 255, 255, 0.05);
  pointer-events: none;

  animation: animate 5s linear infinite;
  transform-style: preserve-3d;
  z-index: 1002;

  transform: translateZ(20px);
}
.container .content h2 {
  font-family: "Lato", sans-serif;
  font-weight: 300;
  font-size: calc(0.2rem + 1.4vw);
  color: rgba(255, 255, 255, 0.05);
  pointer-events: none;
  text-align: right !important;
  animation: animate 5s linear infinite;
  transform-style: preserve-3d;
  z-index: 1003;
}

@keyframes animate {
  0% {
    color: #ffffff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.203),
      0 0 20px rgba(255, 255, 255, 0.203), 0 0 40px rgba(255, 255, 255, 0.203);
  }
  50% {
    color: #fff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.203),
      0 0 20px rgba(255, 255, 255, 0.203), 0 0 40px rgba(255, 255, 255, 0.203),
      0 0 80px rgba(255, 255, 255, 0.203), 0 0 120px rgba(255, 255, 255, 0.203);
  }
  100% {
    color: #ffffff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.203),
      0 0 20px rgba(255, 255, 255, 0.203), 0 0 40px rgba(255, 255, 255, 0.203);
  }
}

.vidcontainer {
  position: relative;
  top: 15vh;
  left: 0;
  width: 100vw;
}

#myImage {
  width: 100%;
  height: auto;
  left: 0px;
  right: 0px;
}

.limage {
  position: absolute;
  width: 110vw;
  height: 105%;
}

.benzene {
  width: 20vw;
  top: 44vh;
  height: auto;
  z-index: -1;
}

.flex {
  display: flex;
  gap: var(--gap, 1.5rem);
}

.primary-header {
  align-content: center;
  justify-content: space-between;
}

.text-white {
  color: white;
  /*font-family: "Lato", sans-serif;*/
  font-family: "Roboto", sans-serif;
}
.uppercase {
  text-transform: uppercase;
}

.frontimg {
  position: absolute;
  width: 100%;
  min-width: 800px;
  top: calc(35% - 9vw);
}

.title-container {
  position: absolute;
  top: 38%;
  left: 29%;
  text-align: right;
  transform: translate(-50%, -50%);
}

.title-container h1 {
  font-size: calc(3vw * var(--font-size-multiplier));
  font-family: "Open Sans", sans-serif;
  font-weight: 700;
  color: white;
  display: block;
  line-height: 1.5;
  position: relative;
}

.title-container h2 {
  font-size: calc(1.2vw * var(--font-size-multiplier));
  font-family: "Open Sans Light", sans-serif;
  font-weight: 100;
  color: white;
  display: inline-block;
  position: absolute;
  top: calc(5.3vw * var(--font-size-multiplier));
  right: 0.2em;
}

.title-container h1,
.title-container h2 {
  transform: translateX(10px);
}

.color-change {
  color: rgb(255, 145, 0);
}
.right-align {
  text-align: right;
}

.logo {
  position: absolute;
  top: 32%;
  left: 97%;
  transform: translate(-50%, -50%);
  width: calc(3.7vw * var(--font-size-multiplier));
  height: calc(3.7vw * var(--font-size-multiplier));
}

.logo-head-home {
  color: #ffffff;
  position: fixed;
  margin: 1rem;
  top: 0;
  left: 0;
  height: auto;
  width: 6vw;
  z-index: 6000;
}
.social-media-container {
  position: absolute;
  left: 0;
  bottom: 0;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.social-media-container .sociallogo {
  object-fit: contain;
  height: 30px;
  padding: 15px;
}
.social-media-container .sociallogo:hover {
  transform: scale(1.2);
  transition: 0.5s cubic-bezier(0.075, 0.82, 0.165, 1);
}

.floating {
  animation-name: floating;
  animation-duration: 3s;
  animation-iteration-count: infinite;
  animation-timing-function: ease-in-out;
}

@keyframes floating {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(1px);
  }
  100% {
    transform: translateY(-0px);
  }
}
.floating2 {
  animation-name: floating;
  animation-duration: 3s;
  animation-iteration-count: infinite;
  animation-timing-function: ease-in-out;
}

@keyframes floating2 {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(3px);
  }
  100% {
    transform: translateY(-0px);
  }
}
.floating-diagonal {
  animation-name: floating;
  animation-duration: 5s;
  animation-iteration-count: infinite;
  animation-timing-function: ease-in-out;
}

@keyframes floating-diagonal {
  0% {
    transform: translateX(0px);
    transform: translateY(0px);
  }
  50% {
    transform: translateX(-15px);
    transform: translateY(-15px);
  }
  100% {
    transform: translateX(0px);
    transform: translateY(0px);
  }
}

.logo-image {
  width: 27vw;
}
.bottom-text {
  text-justify: center;
  position: fixed;
  left: 0;
  bottom: 0;
  width: 100%;
  text-align: center;
}

.bottom-text p {
  margin: 0;
  padding: 10px;
  font-family: "Open Sans", sans-serif;
  font-size: 0.7rem;
  font-weight: 200;
  color: rgba(168, 168, 168, 0.623);
  font-style: italic;
}
.sr-only {
  font-size: large;
}

.writter-overall {
  max-width: 30vw;
  position: relative;
  font-family: "Poppins", sans-serif;
  font-weight: 100;
  display: flex;
  top: 35vh;
  left: 57vw;
  z-index: 10;
}
.writter-container {
  position: relative;
  display: flex;
  justify-content: start;
  align-items: start;
}
.writter-container p {
  font-size: 1.5vw;
  padding: 0.5rem;

  letter-spacing: 0.1rem;
  text-align: left;
  overflow: hidden;
}
.writter-container p span.typed-text {
  font-weight: 200;
  color: #fb9b00;
}
.writter-container p span.cursor {
  display: inline-block;
  background-color: #ccc;
  margin-left: 0.1rem;
  width: 2px;
  animation: blink 1s infinite;
}
.writter-container p span.cursor.typing {
  animation: none;
}
@keyframes blink {
  0% {
    background-color: #ccc;
  }
  49% {
    background-color: #ccc;
  }
  50% {
    background-color: transparent;
  }
  99% {
    background-color: transparent;
  }
  100% {
    background-color: #ccc;
  }
}

/* ── Homepage mobile overrides ─────────────────────────────────────────────
   On narrow screens:
   - Parallax layers and the animated frontimg cause layout flash and overflow.
     Hide all of them; show a static full-screen background instead.
   - Typewriter block is absolutely positioned with vw units that take it
     off-screen. Override to a safe centered position.
   - Logo image shrinks below legibility at 27vw on phones. Scale it up.
   - logo-head-home (SVG icon) is 6vw which becomes tiny; enlarge it.
   ───────────────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  /* Hide all parallax layer images — they cause flash and overflow */
  section .limage {
    display: none;
  }

  /* The main hero molecule image: hide the animated version on mobile.
     A static background is applied to <section> instead (see below). */
  .frontimg {
    display: none;
  }

  /* Static full-screen hero for mobile.
     Using the dedicated mobile mockup — already portrait-cropped and
     centred on the molecule/logo area.
     Path is relative to the CSS file location (css/), so ../assets/ */
  section {
    background-image: url("../assets/mockup_mobile.jpg");
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
  }

  /* Logo and typewriter are baked into the static image — hide the
     HTML versions so they don't double up */
  .title-container,
  .writter-overall {
    display: none;
  }

  /* Typewriter text: pull back from 57vw left into a readable position */
  .writter-overall {
    max-width: 80vw;
    left: 8vw;
    top: 58vh;
  }

  /* Font size is 1.5vw on desktop (~22px at 1440px). On mobile 1.5vw = ~6px. */
  .writter-container p {
    font-size: clamp(0.85rem, 4vw, 1.4rem);
  }

  /* Logo image: 27vw on phone ≈ 100px, too small */
  .logo-image {
    width: clamp(160px, 60vw, 320px);
  }

  /* Title container: recentered on portrait */
  .title-container {
    top: 32%;
    left: 50%;
    transform: translate(-50%, -50%);
  }

  /* Nav logo SVG: 6vw ≈ 23px on a 375px phone — too small to tap */
  .logo-head-home {
    width: clamp(36px, 10vw, 56px);
  }

  /* Social media icons: keep them clear of the typewriter */
  .social-media-container {
    bottom: 30px;
  }

  /* Inner-page logo cap */
  .logo-head {
    max-width: clamp(80px, 16vw, 200px);
  }
}
