body{
  padding-top: 0px;
}

.navbar {
  background: transparent !important;
  width: 100%;
  z-index: 100;
  position: fixed;
  top: 0;
  left: 0;

  transition:
    background-color 0.4s ease,
    backdrop-filter 0.4s ease,
    padding 0.4s ease;
}

.navbar.scrolled {
  background-color: black !important;
}

.portfolio-hero {
  position: relative;
  height: 100vh;
  overflow: hidden;
}

.hero-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    rgba(0,0,0,0.35),
    rgba(0,0,0,0.65)
  );
}

.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  text-align: center;
}

.hero-content h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: 74px;
  font-weight: 600;
  line-height: 1.05;
  margin-bottom: 25px;
}

.hero-content h1 span {
  display: block;
}

.hero-content p {
  font-family: 'Montserrat', sans-serif;
  font-size: 26px;
  color: var(--text-gray);
  font-weight:300;
}

.hero-quote {
  font-family: 'Montserrat', sans-serif;
  position: absolute;
  bottom: 60px;
  font-size: 26px;
  font-weight: 500;
}


/* =========================
   PORTAFOLIO
========================= */

.portfolio-gallery-section {
  padding: 120px 0;
  background: var(--black);
}

.portfolio-title-area {
  text-align: center;
  margin-bottom: 80px;
}

.portfolio-title-area h2 {
  font-size: 54px;
  font-family: 'Montserrat', sans-serif;
  margin-bottom: 10px;
  font-weight: 500;
}

.portfolio-title-area p {
  color: var(--yellow);
  font-family: 'Montserrat', sans-serif;
}

.portfolio-title-area p span {
  color: white;
}

.gallery-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.gallery-track-container {
  width: calc(100% - 140px);
  overflow: hidden;
  position: relative;
}

.gallery-track {
  display: flex;
  gap: 30px;

  overflow-x: auto;
  overflow-y: hidden;

  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;

  padding: 20px 0;
}

.gallery-track::-webkit-scrollbar {
  display: none;
}

.project-card {
  width: calc((100% - 60px) / 3);
  height: 520px;
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
  scroll-snap-align: start;
}

.project-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.project-card:hover img {
  transform: scale(1.08);
}

.project-overlay {
  position: absolute;
  inset: 0;

  background: linear-gradient(
    transparent,
    rgba(0,0,0,0.9)
  );

  display: flex;
  align-items: end;
  justify-content: center;

  padding-bottom: 35px;
}

.project-overlay h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 34px;
  font-weight: 500;
}

.gallery-btn {
  background: transparent;
  border: none;
  color: white;
  font-size: 80px;
  cursor: pointer;
  transition: 0.3s;
  padding: 20px;
}

.gallery-btn:hover {
  color: var(--yellow);
  transform: scale(1.1);
}

/* FRANJA DE LOGOS */
.clients-section {
  padding: 50px 0;
  overflow: hidden;
  background: #000;
  border-top: 1px solid rgba(255,255,255,0.08);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.clients-track-wrapper {
  overflow: hidden;
  width: 100%;
}

.clients-track {
  display: flex;
  align-items: center;
  gap: 60px;
  width: max-content;
  animation: scrollLogos 30s linear infinite;
}

.clients-track img {
  height: 45px;
  width: 130px;
  object-fit: contain;
  filter: grayscale(100%) brightness(1.5);
  opacity: 0.7;
  transition: opacity 0.3s, filter 0.3s;
}

.clients-track img:hover {
  filter: none;
  opacity: 1;
}

@keyframes scrollLogos {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* =========================
   TESTIMONIOS
========================= */

.testimonials-section {
  padding: 60px 0 120px;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
}

.testimonial-card {
  text-align: center;
}

.testimonial-card img {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 20px;
}

.testimonial-card h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 20px;
  font-weight: 500;
}

.testimonial-card h4 {
  color: var(--yellow);
  margin-bottom: 15px;
  font-size: 18px;
  font-weight: 500;
    font-family: 'Montserrat', sans-serif;
}

.testimonial-card p {
  color: var(--text-gray);
  font-size: 16px;
    font-family: 'Montserrat', sans-serif;
}

.testimonial-cta {
  margin-top: 120px;
  display: flex;
  justify-content: center;
}


/* =========================
   RESPONSIVE
========================= */

@media (max-width: 1200px) {

  .hero-content h1 {
    font-size: 60px;
  }

  .testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
  }

}


@media (max-width: 992px) {

  .portfolio-hero {
    height: 85vh;
  }

  .hero-content h1 {
    font-size: 52px;
  }

  .hero-content p {
    font-size: 22px;
  }

  .hero-quote {
    font-size: 20px;
    padding: 0 20px;
    text-align: center;
  }

  .gallery-track-container {
    width: 100%;
    overflow: hidden;
    position: relative;
  }

  .project-card {
    min-width: 300px;
    height: 450px;
  }

   .project-card {
    width: calc((100% - 30px) / 2);
  }

}


@media (max-width: 768px) {

  .portfolio-hero {
    height: 75vh;
  }

  .hero-content h1 {
    font-size: 42px;
  }

  .hero-content p {
    font-size: 18px;
  }

  .hero-quote {
    font-size: 16px;
    bottom: 40px;
  }

  .portfolio-title-area h2 {
    font-size: 42px;
  }

  .gallery-track-container {
    width: 100%;
  }

  .gallery-btn {
    position: absolute;
    z-index: 5;
    font-size: 50px;
  }

  .prev {
    left: 0;
  }

  .next {
    right: 0;
  }

  .project-card {
    min-width: 85%;
    height: 420px;
  }

  .project-card {
    width: 100%;
  }

  .project-overlay h3 {
    font-size: 28px;
  }

  .testimonials-grid {
    grid-template-columns: 1fr;
  }

}


@media (max-width: 576px) {

  .hero-content h1 {
    font-size: 34px;
  }

  .hero-content p {
    font-size: 16px;
  }

  .hero-quote {
    font-size: 14px;
  }

  .gallery-track-container {
    width: 100%;
  }

  .project-card {
    height: 360px;
  }

  .testimonial-card img {
    width: 140px;
    height: 140px;
  }

}

/* MODAL REDISEÑO */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.93);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-overlay.active {
  display: flex;
}

.modal-box {
  position: relative;
  background: #0d1117;
  border: 1px solid rgba(255, 194, 28, 0.3);
  box-shadow: 0 0 80px rgba(255, 194, 28, 0.08);
  max-width: 1000px;
  padding: 40px;
  border-radius: 12px;
}

.modal-box h2 {
  color: #fff;
  font-size: 36px;
  font-weight: 800;
  margin: 10px 0 6px;
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 20px;
  background: none;
  border: none;
  color: #fff;
  font-size: 22px;
  cursor: pointer;
  z-index: 10;
}

.modal-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

.modal-left {
  padding: 0;
}

.modal-right {
  padding: 0;
}

.modal-thumbs {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.modal-subtitle {
  color: #aaa;
  font-size: 14px;
  margin-bottom: 12px;
}

.modal-desc {
  font-size: 14px;
  color: #ddd;
  line-height: 1.6;
  margin-bottom: 15px;
}

.modal-box hr {
  border-color: rgba(255,255,255,0.1);
  margin: 15px 0;
}

.modal-list {
  list-style: none;
  padding: 0;
  margin-bottom: 15px;
}

.modal-list li {
  font-size: 14px;
  color: #ddd;
  padding: 3px 0 3px 18px;
  position: relative;
}

.modal-list li::before {
  content: "✔";
  color: var(--yellow);
  position: absolute;
  left: 0;
  font-size: 12px;
}

@media (max-width: 768px) {
  .modal-content {
    grid-template-columns: 1fr;
  }
}

.modal-main-img {
  width: 100%;
  height: 360px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

.modal-tag {
  border-color: var(--yellow);
  color: var(--yellow);
}

.modal-section-title {
  color: var(--yellow);
  font-size: 16px;
}

.modal-meta {
  background: #1a1f2e;
  border-radius: 10px;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 15px;
  float: none;
  width: auto;
  margin-left: 0;
}

.modal-meta > div {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
}

.modal-meta > div > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.modal-meta strong {
  color: var(--yellow);
  font-size: 13px;
  display: block;
}

.modal-meta span {
  color: #fff;
  font-size: 13px;
}

.modal-btn {
  background: var(--yellow);
  color: #000;
  border: none;
  padding: 12px 35px;
  font-weight: 700;
  font-family: 'Montserrat', sans-serif;
  letter-spacing: 1px;
  border-radius: 3px;
  display: inline-block;
  text-decoration: none;
  transition: 0.3s;
  clear: both;
  margin-top: 20px;
}

.modal-btn:hover {
  background: #e6ac00;
  color: #000;
}

.modal-thumbs img {
  width: 70px;
  height: 50px;
  object-fit: cover;
  border-radius: 4px;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.3s;
  max-width: 70px;
  max-height: 50px;
}

.modal-meta img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.modal-list-and-meta {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.modal-list-and-meta .modal-list {
  flex: 1;
  margin-bottom: 0;
}

.modal-list-and-meta .modal-meta {
  flex-shrink: 0;
  width: 160px;
  word-break: break-word;
}

.modal-btn {
  display: block;
  text-align: center;
  margin-top: 20px;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
  padding: 8px 25px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 2px;
}

@media (max-width: 768px) {
  .modal-content {
    grid-template-columns: 1fr;
  }

  .modal-right {
    padding: 0 20px 20px;
  }

  .modal-box {
    padding: 20px;
    max-height: 95vh;
    overflow-y: auto;
  }

  .modal-main-img {
    height: 220px;
  }

  .modal-thumbs img {
    width: 55px;
    height: 40px;
  }

  .modal-meta {
    float: none;
    width: 100%;
  }

  .modal-btn {
    width: 100%;
    text-align: center;
  }
}