/* ── SF Pro Display ── */
@font-face {
  font-family: 'SF Pro Display';
  src: url('assets/fonts/sf-pro-display-regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'SF Pro Display';
  src: url('assets/fonts/sf-pro-display-medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'SF Pro Display';
  src: url('assets/fonts/sf-pro-display-semibold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'SF Pro Display';
  src: url('assets/fonts/sf-pro-display-bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* ── Reset & Base ── */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Inter', 'Segoe UI', sans-serif;
  background: #0a0a0a;
  color: #fff;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

/* ── Navbar ── */
.nav {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2rem 3.5rem;
}

.nav__logo {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.nav__name,
.nav__role {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.01em;
}

.nav__name {
  text-align: right;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 2.2rem;
}

.nav__link {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.9);
  transition: opacity 0.2s;
}

.nav__link:hover {
  opacity: 0.7;
}

.nav__link--contact {
  border: 1.5px solid #fff;
  border-radius: 100px;
  padding: 0.45rem 1.2rem;
}

/* ── Hero ── */
.hero {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100vh;
  overflow: visible;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 60%;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0.0) 70%,
    rgba(15, 15, 12, 0.7) 100%
  );
}

.hero__title {
  position: relative;
  z-index: 3;
  font-weight: 700;
  font-size: clamp(2.5rem, 5.63vw, 85px);
  line-height: 1.068;
  letter-spacing: -0.02em;
  padding-bottom: 4vh;
  text-align: center;
  color: #fff;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0.6) 60%, rgba(0,0,0,0) 100%);
  mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0.6) 60%, rgba(0,0,0,0) 100%);
}

/* ── Hero info cards ── */
.hero__cards {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  display: flex;
  gap: 1.5rem;
  padding: 0 5rem;
  max-width: 1400px;
  width: 100%;
}

.hero__info-card {
  flex: 1;
  background: rgba(180, 180, 180, 0.35);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 2rem 2.2rem;
  opacity: 0;
  transform: translateY(60px);
  will-change: opacity, transform;
}

.hero__info-title {
  font-size: clamp(1.3rem, 2vw, 1.7rem);
  font-weight: 700;
  margin-bottom: 1rem;
  color: rgba(255, 255, 255, 0.95);
}

.hero__info-list {
  list-style: disc;
  padding-left: 1.2rem;
  font-size: clamp(0.9rem, 1.1vw, 1.05rem);
  font-weight: 500;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.8);
}

.hero__info-text {
  font-size: clamp(0.9rem, 1.1vw, 1.05rem);
  font-weight: 500;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.8);
}

/* ── Main content wrapper (persistent bg behind works + videogames) ── */
.main-content {
  position: relative;
  overflow: hidden;
}

.main-content__bg {
  position: absolute;
  top: -30vh;
  left: -10%;
  width: 120%;
  height: calc(100% + 30vh);
  object-fit: cover;
  object-position: center bottom;
  filter: blur(36px) brightness(0.7);
  transform: scaleY(-1);
  opacity: 0.7;
}

.main-content__overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 10, 0.45);
}

/* ── Decorative gradient blobs ── */
.gradient-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.5;
  pointer-events: none;
}

.gradient-blob--top-left {
  width: 1400px;
  height: 1400px;
  top: -5%;
  left: -15%;
  background: radial-gradient(circle, rgba(120, 160, 40, 0.7), rgba(80, 130, 20, 0.4), transparent 70%);
}

.gradient-blob--top-right {
  width: 1000px;
  height: 800px;
  top: 5%;
  right: -5%;
  background: radial-gradient(circle, rgba(180, 150, 30, 0.6), rgba(140, 110, 15, 0.3), transparent 70%);
}

.gradient-blob--bottom {
  width: 1100px;
  height: 1200px;
  bottom: -10%;
  right: 0%;
  background: radial-gradient(circle, rgba(160, 140, 40, 0.6), rgba(120, 100, 20, 0.3), transparent 70%);
}

/* ── Works ── */
.works {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 6rem 5rem;
}

.works__content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4rem;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
}

.works__left {
  flex-shrink: 0;
  padding-top: 2rem;
  position: relative;
  z-index: 5;
}

.works__label {
  display: block;
  font-size: clamp(1.1rem, 1.99vw, 30px);
  font-weight: 500;
  letter-spacing: 0.1em;
  line-height: 0.93;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9), 0 0 20px rgba(0, 0, 0, 0.6);
}

.works__heading {
  font-size: clamp(2.5rem, 4.97vw, 75px);
  font-weight: 500;
  line-height: 1.07;
  letter-spacing: -0.015em;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 2.2rem;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.9), 0 0 25px rgba(0, 0, 0, 0.6);
}

.works__btn {
  display: inline-block;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  border: 1.5px solid rgba(255, 255, 255, 0.8);
  border-radius: 100px;
  padding: 0.5rem 1.4rem;
  transition: background 0.2s, color 0.2s;
}

.works__btn:hover {
  background: #fff;
  color: #0a0a0a;
}

.works__right {
  flex: 1;
  max-width: 700px;
  position: relative;
}

.works__cards {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  width: 100%;
}

.works__card {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 1.5rem 2.5rem;
  height: clamp(80px, 8vw, 120px);
  border-radius: 14px;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s;
}

.works__card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}

.works__card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.2));
}

/* Card backgrounds — replace placeholder images with your own */
.works__card--research {
  background: url('assets/images/card-agrivolt.jpg') center/cover no-repeat;
}

.works__card--gis {
  background: url('assets/images/card-agrigis.jpg') center/cover no-repeat;
}

.works__card--data {
  background: url('assets/images/card-sensor.jpg') center/cover no-repeat;
}

.works__card--migraine {
  background: url('assets/images/card-migraine.jpg') center/cover no-repeat;
}

.works__card--split {
  background: url('assets/images/card-split.jpg') center/cover no-repeat;
}

.works__card-title {
  position: relative;
  z-index: 1;
  font-size: clamp(1.5rem, 3.31vw, 50px);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6), 0 0 15px rgba(0, 0, 0, 0.4);
}

/* ── Works full-section background (when card is open) ── */
.works__full-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 0.5s ease;
  z-index: 0;
}

.works.is-open .works__full-bg {
  opacity: 1;
}

.works__full-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.45) 0%,
    rgba(0, 0, 0, 0.1) 50%,
    rgba(0, 0, 0, 0.05) 100%
  );
  opacity: 0;
  transition: opacity 0.5s ease;
  z-index: 0;
}

.works.is-open .works__full-overlay {
  opacity: 1;
}

.works__close {
  position: absolute;
  top: 2rem;
  right: 3rem;
  z-index: 10;
  background: rgba(0, 0, 0, 0.5);
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.5rem;
  font-weight: 400;
  cursor: pointer;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s, background 0.2s;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
}

.works.is-open .works__close {
  opacity: 1;
  pointer-events: auto;
}

.works__close:hover {
  background: rgba(0, 0, 0, 0.7);
  border-color: rgba(255, 255, 255, 0.7);
}

.works__close:hover {
  opacity: 1;
}

/* ── Works Detail info ── */
.works__detail {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.5s ease, opacity 0.4s ease;
  margin-bottom: 0;
}

.works__detail.is-open {
  max-height: 400px;
  opacity: 1;
  margin-bottom: 1rem;
}

.works__detail-category {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 0.6rem;
  text-transform: uppercase;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}

.works__detail-title {
  font-size: clamp(2.2rem, 4vw, 60px);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1.2rem;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.9), 0 0 25px rgba(0, 0, 0, 0.6);
}

.works__detail-meta {
  display: flex;
  gap: 3rem;
  margin-bottom: 1.2rem;
}

.works__detail-meta-label {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9), 0 0 20px rgba(0, 0, 0, 0.6);
}

.works__detail-meta-value {
  display: block;
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9), 0 0 20px rgba(0, 0, 0, 0.6);
}

.works__detail-desc {
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.75);
  max-width: 100%;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9), 0 0 20px rgba(0, 0, 0, 0.6);
}

/* Hidden card */
.works__card.is-hidden {
  max-height: 0;
  padding: 0 2.5rem;
  margin-bottom: -0.8rem;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, opacity 0.3s ease, padding 0.4s ease, margin 0.4s ease;
}

/* Gold bar */
.works__bar {
  height: 4px;
  margin-top: 0.8rem;
  border-radius: 2px;
  background: linear-gradient(to right, #8b7a2e, #c4a730, #8b7a2e);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.works__bar.is-visible {
  opacity: 1;
}

/* ── Videogames ── */
.videogames {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 5rem;
}

.videogames__card {
  display: flex;
  align-items: center;
  gap: 3rem;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
  background: rgba(225, 225, 225, 0.6);
  backdrop-filter: blur(35px);
  -webkit-backdrop-filter: blur(35px);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 4.5rem 5rem;
  min-height: 520px;
}

.videogames__left {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.videogames__label {
  display: block;
  font-size: clamp(1.1rem, 1.99vw, 30px);
  font-weight: 500;
  letter-spacing: 0.1em;
  line-height: 0.93;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 1rem;
  text-transform: uppercase;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 0 10px rgba(0, 0, 0, 0.25);
}

.videogames__heading {
  font-size: clamp(2.5rem, 4.97vw, 75px);
  font-weight: 500;
  line-height: 1.07;
  letter-spacing: -0.015em;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.45), 0 0 12px rgba(0, 0, 0, 0.3);
  margin-bottom: 1.8rem;
}

.videogames__desc {
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.6);
  max-width: 450px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 0 10px rgba(0, 0, 0, 0.25);
  letter-spacing: 0.01em;
}

.videogames__right {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Card stack effect */
.videogames__stack {
  position: relative;
  width: 420px;
}

.videogames__stack-card {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 18px;
  background: #000;
  overflow: hidden;
}

.videogames__stack-card--2 {
  transform: translateX(-70px) scale(0.92);
  background: linear-gradient(180deg, #4a3520 0%, #3d2b18 50%, #2a1d10 100%);
  filter: blur(2px);
  opacity: 0.5;
  z-index: 1;
}

.videogames__stack-card--1 {
  transform: translateX(-35px) scale(0.96);
  background: linear-gradient(180deg, #2c3e50 0%, #34495e 50%, #1a252f 100%);
  filter: blur(1px);
  opacity: 0.65;
  z-index: 2;
}

.videogames__game {
  position: relative;
  z-index: 3;
  width: 420px;
  border-radius: 18px;
  overflow: hidden;
  background: #0a0a0a;
  box-shadow: 0 12px 50px rgba(0, 0, 0, 0.45);
}

.videogames__game-img {
  width: 100%;
  height: 350px;
  background-color: #0a0a0a;
  background-size: cover;
  background-position: center;
}

.videogames__game-info {
  padding: 1rem 1.2rem 1.2rem;
  min-height: 170px;
  height: 170px;
  /*overflow: hidden;*/
  background: rgba(90, 120, 160, 0.4);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.videogames__game-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.videogames__game-name {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.videogames__game-meta {
  font-size: 0.95rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.7);
  margin-top: 0.2rem;
}

.videogames__play-btn {
  display: inline-block;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 0.4rem 1.3rem;
  border: 1.5px solid rgba(255, 255, 255, 0.85);
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.92);
  color: #111;
  transition: background 0.2s;
  white-space: nowrap;
}

.videogames__play-btn:hover {
  background: #fff;
}

.videogames__game-text {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.65);
}

/* Game card slide animation */
.videogames__game.is-sliding-out {
  animation: slideOut 0.25s ease-in forwards;
}

.videogames__game.is-sliding-in {
  animation: slideIn 0.25s ease-out forwards;
}

@keyframes slideOut {
  0% { opacity: 1; transform: translateX(0); }
  100% { opacity: 0; transform: translateX(-40px); }
}

@keyframes slideIn {
  0% { opacity: 0; transform: translateX(40px); }
  100% { opacity: 1; transform: translateX(0); }
}

/* Dots navigation */
.videogames__dots {
  display: flex;
  justify-content: center;
  gap: 0.9rem;
  margin-top: 1.5rem;
}

.videogames__dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2.5px solid rgba(255, 255, 255, 0.6);
  background: transparent;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, border-color 0.2s, transform 0.2s;
}

.videogames__dot:hover {
  border-color: #fff;
}

.videogames__dot.is-active {
  background: #fff;
  border-color: #fff;
}

/* ── Footer ── */
.footer {
  background: #f0f0f0;
  color: #111;
  padding: 3.5rem 5rem 3rem;
}

.footer__content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  max-width: 1400px;
  margin: 0 auto;
  gap: 3rem;
}

.footer__left {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 280px;
}

.footer__logo {
  display: flex;
  align-items: flex-start;
  gap: 1.2rem;
}

.footer__name,
.footer__role {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.35;
  color: #1a1a1a;
  letter-spacing: 0.01em;
}

.footer__name {
  text-align: right;
}

.footer__socials {
  display: flex;
  gap: 1rem;
}

.footer__social {
  color: #111;
  transition: opacity 0.2s;
}

.footer__social:hover {
  opacity: 0.6;
}

.footer__right {
  flex: 1;
  max-width: 580px;
}

.footer__form {
  background: #fff;
  border-radius: 14px;
  padding: 2rem 2rem;
  border: 1px solid #e0e0e0;
}

.footer__form-row {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.footer__form-row--bottom {
  align-items: flex-end;
  margin-bottom: 0;
}

.footer__field {
  flex: 1;
}

.footer__label {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #1a1a1a;
  letter-spacing: 0.01em;
}

.footer__input {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border: 1.5px solid #ccc;
  border-radius: 5px;
  font-family: inherit;
  font-size: 1.05rem;
  background: #fff;
  color: #111;
  transition: border-color 0.2s;
}

.footer__input:focus {
  outline: none;
  border-color: #333;
}

.footer__submit {
  flex-shrink: 0;
  padding: 0.6rem 2rem;
  background: #1a1a1a;
  color: #fff;
  border: none;
  border-radius: 5px;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
  text-transform: uppercase;
}

.footer__submit:hover {
  background: #000;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .hero__cards {
    padding: 0 2.5rem;
  }

  .nav {
    padding: 1.5rem 2rem;
  }

  .works {
    padding: 4rem 2.5rem;
    margin-top: 250px;
  }

  .works__content {
    flex-direction: column;
    gap: 2.5rem;
  }

  .works__cards {
    max-width: 100%;
  }

  .videogames {
    padding: 3rem 2.5rem;
  }

  .videogames__card {
    flex-direction: column;
    padding: 2.5rem 2rem;
  }

  .videogames__right {
    justify-content: center;
  }

  .footer {
    padding: 3rem 2.5rem;
  }

  .footer__content {
    flex-direction: column;
  }

  .footer__left {
    min-height: auto;
    gap: 2rem;
  }

  .footer__right {
    max-width: 100%;
  }
}

@media (max-width: 640px) {
  .hero__cards {
    flex-direction: column;
    padding: 0 1.5rem;
    gap: 1rem;
  }

  .nav {
    padding: 1.2rem 1.5rem;
  }

  .nav__links {
    gap: 1rem;
  }

  .nav__link {
    font-size: 0.75rem;
  }

  .hero__title {
    padding-inline: 1.5rem;
    padding-bottom: 3vh;
  }

  .works {
    padding: 3rem 1.5rem;
    margin-top: 350px;
  }

  .works__card {
    height: 80px;
  }

  .videogames {
    padding: 2rem 1.5rem;
  }

  .videogames__card {
    padding: 2rem 1.5rem;
  }

  .videogames__stack,
  .videogames__game {
    width: 100%;
  }

  .footer {
    padding: 2rem 1.5rem;
  }

  .footer__form {
    padding: 1.5rem;
  }

  .footer__form-row {
    flex-direction: column;
    gap: 1rem;
  }

  .footer__submit {
    width: 100%;
    padding: 0.8rem;
  }

  .gradient-blob {
    filter: blur(80px);
    opacity: 0.2;
  }
}
