.login-button,
.feature-card,
.stat-card {
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

.hero-video {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  min-width: 100%;
  min-height: 100%;
  height: 80px;
  z-index: -1;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.hero-section {
  position: relative;
  overflow: hidden;
  padding: 60px;
  min-height: 55vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
}

@media (max-width: 1200px) {
  .hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    min-width: 100%;
    min-height: 100%;
    height: 10px;
    width: 100px;
    z-index: -1;
  }

  .hero-section {
    position: relative;
    overflow: hidden;
    padding: 60px;
    min-height: 420px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
  }
}

.hero-stats-container {
  position: relative;
  z-index: 2;
  margin-top: 80px;
}

.hero-section .stat-card {
  background-color: rgba(var(--primary-rgb), 0.05);
  border-color: rgba(var(--primary-rgb), 0.1);
  backdrop-filter: blur(5px);
}

.dark-theme .hero-section .stat-card {
  background-color: rgba(var(--primary-rgb), 0.1);
  border-color: rgba(var(--primary-rgb), 0.2);
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.2;
  font-weight: 900;
  max-width: 1200px;
  margin: 0 auto;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: var(--text-body);
  margin: 1.5rem auto 2.5rem;
  max-width: 900px;
}

.stat-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2rem 1rem;
  text-align: center;
  height: 100%;
}

.stat-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary);
}

.stat-number {
  font-size: clamp(2rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--primary);
}

.dark-theme .stat-number {
  color: var(--text-heading);
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-top: -6px;
}

.features-section {
  padding: 80px 0;
}

.section-title {
  font-size: 2rem;
}

.section-description {
  font-size: 1.1rem;
  color: var(--text-body);
  max-width: 900px;
  margin: 0.5rem auto 0;
}

.feature-card {
  background-color: var(--bg-canvas);
  border: 1px solid var(--border-color);
  padding: 2rem;
  border-radius: 16px;
  text-align: center;
  height: 100%;
}

.feature-card:hover {
  transform: translateY(-5px);
  border-color: rgba(var(--primary-rgb), 0.7);
  background-color: rgba(var(--primary-rgb), 0.05);
}

.feature-icon {
  font-size: 1.75rem;
  color: var(--primary);
  width: 60px;
  height: 60px;
  background-color: var(--primary-light-theme);
  border-radius: 12px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 1.5rem;
}

.feature-text {
  font-size: 0.9rem;
}

.dark-theme .feature-icon {
  background-color: rgba(var(--primary-rgb), 0.1);
}

.portfolio-section {
  padding: 80px 0;
  position: relative;
  overflow: hidden;
}

.portfolio-mosaic {
  margin-top: 5rem;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 250px;
  gap: 1.5rem;
  perspective: 1500px;
}

.mosaic-item-wrapper {
  grid-column: span 1;
  grid-row: span 1;
  position: relative;
  border-radius: 16px;
  overflow: hidden;
}
.mosaic-item-wrapper.wide {
  grid-column: span 2;
}
.mosaic-item-wrapper.tall {
  grid-row: span 2;
}

.mosaic-item {
  position: absolute;
  inset: 0;
  border-radius: 16px;
  overflow: hidden;
  color: #fff;
  text-decoration: none;
  transform-style: preserve-3d;
  transition: box-shadow 0.4s ease, transform 0.2s ease;
  display: block;
  backface-visibility: hidden;
}

.mosaic-item:hover {
  box-shadow: 0 15px 30px -8px rgba(0, 0, 0, 0.4);
  z-index: 10;
}
.dark-theme .mosaic-item:hover {
  box-shadow: 0 15px 30px -8px rgba(0, 0, 0, 0.6);
}

.mosaic-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1), opacity 0.4s ease;
  opacity: 0.8;
  border-radius: 16px;
}
.mosaic-item:hover .mosaic-bg {
  opacity: 0.85;
}

.mosaic-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(24, 24, 27, 0.98) 0%,
    rgba(24, 24, 27, 0.75) 20%,
    transparent 95%
  );
  opacity: 1;
  z-index: 1;
  border-radius: 16px;
}
.dark-theme .mosaic-overlay {
  background: linear-gradient(
    to top,
    rgba(24, 24, 27, 0.98) 0%,
    rgba(24, 24, 27, 0.75) 20%,
    transparent 95%
  );
}

.mosaic-content {
  position: relative;
  z-index: 3;
  padding: 1.5rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.mosaic-item:hover .mosaic-content {
  transform: translateY(-40px);
}

.content-top {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.partner-badge {
  align-self: flex-start;
  margin-bottom: 0.75rem;
  background-color: rgba(255, 255, 255, 0.1);
  color: #fff;
  padding: 0.4rem 0.8rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(5px);
}

.partner-name {
  font-size: 1.6rem;
  margin: 0 0 0.5rem;
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  line-height: 1.2;
}

.partner-description {
  font-size: 0.9rem;
  line-height: 1.6;
  color: #fff;
  margin-top: -6px;
  max-width: 60%;
  margin-bottom: 1.5rem;
  display: -webkit-box;
  line-clamp: 3;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stat-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.stat-pill {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.8rem;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 500;
  color: #fff;
  background-color: rgba(var(--text-heading-rgb), 0.2);
}

.stat-pill i {
  color: #fff;
  font-size: 1rem;
}

.stat-pill span {
  font-weight: 700;
}

.visit-prompt {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 1rem;
  text-align: center;
  background: var(--primary);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  opacity: 0;
  transform: translateY(100%);
  transition: opacity 0.3s ease, transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  z-index: 4;
  border-radius: 0 0 16px 16px;
}

.mosaic-item:hover .visit-prompt {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 991px) {
  .portfolio-mosaic {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 320px;
  }
  .mosaic-item-wrapper.wide,
  .mosaic-item-wrapper.tall {
    grid-column: span 1;
    grid-row: span 1;
  }
  .mosaic-item-wrapper.tall.wide {
    grid-column: span 2;
    grid-row: span 1;
  }
}

@media (max-width: 767px) {
  .portfolio-mosaic {
    grid-template-columns: 1fr;
    grid-auto-rows: 350px;
  }
  .mosaic-item-wrapper.wide,
  .mosaic-item-wrapper.tall,
  .mosaic-item-wrapper.tall.wide {
    grid-column: span 1;
    grid-row: span 1;
  }
  .mosaic-item:hover .mosaic-content {
    transform: translateY(-30px);
  }
}

.minor-projects-container,
.hero-stats-container {
  overflow-x: hidden;
}

.minor-projects-container {
  margin-top: 100px;
  text-align: center;
}
.carousel-wrapper {
  width: 100%;
  overflow: hidden;
  mask-image: linear-gradient(
    to right,
    transparent,
    var(--bg-canvas) 20%,
    var(--bg-canvas) 80%,
    transparent
  );
}
.carousel-track {
  display: flex;
  gap: 1.5rem;
  width: max-content;
  flex-wrap: nowrap;
  animation: scroll 40s linear infinite;
}
.carousel-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 400px;
  flex-shrink: 0;
}
.carousel-icon {
  font-size: 1.5rem;
  color: var(--primary);
  background-color: var(--primary-light-theme);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.dark-theme .carousel-icon {
  background-color: rgba(var(--primary-rgb), 0.15);
}
.carousel-text {
  text-align: left;
  line-height: 1.3;
}
.carousel-text strong {
  color: var(--text-heading);
  font-weight: 600;
  display: block;
}
.carousel-text span {
  font-size: 0.9rem;
  color: var(--text-muted);
}
@keyframes scroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

.final-cta-section {
  padding: 80px 0;
}

.cta-box {
  background-color: var(--bg-surface);
  padding: 4rem;
  text-align: center;
  border-radius: 24px;
}

.cta-title {
  font-size: 2rem;
  color: var(--text-heading);
}

.cta-subtitle {
  color: var(--text-body);
  margin: 1rem auto 1rem;
  max-width: 900px;
}

.dark-theme .cta-box {
  background-color: var(--bg-surface);
}

.stat-card .stat-tooltip {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
}

.stat-card .stat-tooltip.visible {
  opacity: 1;
  transform: translateY(0);
}

.stat-tooltip .online-dot {
  width: 9px;
  height: 9px;
  background-color: #3ba55d;
  border-radius: 50%;
  margin-right: 8px;
  animation: pulse 2s infinite cubic-bezier(0.66, 0, 0, 1);
}

#online-tooltip-text {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-heading);
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(59, 165, 93, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(59, 165, 93, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(59, 165, 93, 0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scroll-down-wave {
  0% {
    opacity: 0;
    transform: translateY(-20px);
  }
  60% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(20px);
  }
}

.scroll-indicator {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.scroll-indicator i {
  color: var(--text-heading);
  font-size: 1.3rem;
  opacity: 0;
  animation: scroll-down-wave 2.5s infinite;
}
