@tailwind base;
@tailwind components;
@tailwind utilities;

/* Base styles */
html {
  scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #1f2937;
}

::-webkit-scrollbar-thumb {
  background: #eab308;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #ca8a04;
}

/* Fixed navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(17, 24, 39, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid #374151;
  z-index: 40;
  padding-top: 0.5rem;
  padding-bottom: 0.8rem;
  animation: navbarFadeSlide 1.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Desktop navbar - smaller height */
@media (min-width: 768px) {
  .navbar {
    padding-top: 0.1rem;
    padding-bottom: 0.8rem;
  }
}

/* Add padding to body to account for fixed navbar */
body {
  padding-top: 80px;
}

/* Desktop body padding adjustment */
@media (min-width: 768px) {
  body {
    padding-top: 65px;
  }
}

/* Carousel animation */
.carousel-container {
  position: relative;
  width: 100%;
  height: 12rem;
  overflow: hidden;
}

.carousel-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 1s ease-in-out;
}

/* Modal improvements */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 50;
  backdrop-filter: blur(8px);
  padding: 1rem;
}

.modal.show {
  display: flex;
}

.modal-content {
  background: #1f2937;
  border-radius: 1rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  width: 100%;
  max-width: 50rem;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  border: 2px solid #374151;
}

/* Team modal specific styling */
.team-modal-content {
  padding: 2rem;
}

.team-modal-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 2px solid #374151;
}

.team-modal-image {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #eab308;
  flex-shrink: 0;
  box-shadow: 0 8px 16px rgba(234, 179, 8, 0.3),
    0 4px 8px rgba(234, 179, 8, 0.2);
  transition: transform 0.3s ease;
}

.team-modal-image:hover {
  transform: scale(1.05);
}

.team-modal-info h2 {
  color: #eab308;
  font-size: 2rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

.team-modal-info .role {
  color: #9ca3af;
  font-size: 1.25rem;
  font-weight: 600;
}

.team-modal-section {
  margin-bottom: 2rem;
}

.team-modal-section h3 {
  color: #eab308;
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.team-modal-section p {
  color: #d1d5db;
  line-height: 1.8;
  font-size: 1.1rem;
  text-align: justify;
}

/* Button hover effects */
.btn-primary {
  background: #d97706;
  color: white;
  font-weight: 600;
  padding: 1rem 2rem;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  background: #b45309;
  transform: scale(1.05);
}

/* Card hover effects */
.game-card,
.team-card,
.blog-card {
  transition: all 0.3s ease;
  cursor: pointer;
}

.game-card:hover,
.team-card:hover,
.blog-card:hover {
  transform: translateY(-0.5rem);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.team-card {
  position: relative;
  overflow: hidden;
  box-shadow: 0 12px 24px rgba(234, 179, 8, 0.4),
    0 8px 16px rgba(234, 179, 8, 0.3), 0 4px 8px rgba(234, 179, 8, 0.2),
    0 0 0 2px rgba(234, 179, 8, 0.3);
  border: 3px solid rgba(234, 179, 8, 0.4);
  transform: translateZ(0);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  background: linear-gradient(145deg, #1f2937, #111827);
}

.team-card:hover {
  transform: translateY(-0.75rem) scale(1.03) rotateX(5deg);
  box-shadow: 0 25px 50px rgba(234, 179, 8, 0.5),
    0 15px 30px rgba(234, 179, 8, 0.4), 0 10px 20px rgba(234, 179, 8, 0.3),
    0 5px 10px rgba(234, 179, 8, 0.2), 0 0 0 3px rgba(234, 179, 8, 0.5);
  border-color: rgba(234, 179, 8, 0.7);
}

.team-card::before {
  content: "Batafsil ko'rish/Details";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(
    to top,
    rgba(234, 179, 8, 0.95),
    rgba(234, 179, 8, 0.7),
    transparent
  );
  color: white;
  text-align: center;
  padding: 1.5rem 1rem;
  transform: translateY(100%);
  transition: transform 0.3s ease;
  font-weight: 600;
  font-size: 0.9rem;
  backdrop-filter: blur(4px);
}

.team-card:hover::before {
  transform: translateY(0);
}

.team-card::after {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(
    45deg,
    rgba(234, 179, 8, 0.6),
    rgba(234, 179, 8, 0.3),
    rgba(234, 179, 8, 0.6)
  );
  border-radius: inherit;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.team-card:hover::after {
  opacity: 1;
}

/* Enhanced team card image styling */
.team-card img {
  transition: all 0.4s ease;
  filter: brightness(0.9) contrast(1.1);
}

.team-card:hover img {
  transform: scale(1.1);
  filter: brightness(1) contrast(1.2);
}

/* Add 3D perspective to the team section */
#team .grid {
  perspective: 1000px;
  perspective-origin: center center;
}

/* Form styling */
.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  background: #374151;
  color: white;
  border: 1px solid #4b5563;
  transition: border-color 0.3s ease;
}

.form-input:focus {
  outline: none;
  border-color: #eab308;
  box-shadow: 0 0 0 3px rgba(234, 179, 8, 0.1);
}

/* Mobile menu */
.mobile-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #374151;
  border-top: 1px solid #374151;
  padding: 0.5rem;
}

.mobile-menu.show {
  display: block;
}

/* Close button styling */
.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(0, 0, 0, 0.5);
  border: none;
  color: #9ca3af;
  font-size: 2rem;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.modal-close:hover {
  background: rgba(0, 0, 0, 0.8);
  color: white;
  transform: scale(1.1);
}

/* Media Queries */
@media (max-width: 768px) {
  .desktop-menu {
    display: none;
  }

  .mobile-menu-btn {
    display: block;
  }

  .team-modal-header {
    flex-direction: column;
    text-align: center;
  }

  .team-modal-image {
    width: 100px;
    height: 100px;
  }

  .modal-content {
    margin: 0.5rem;
    max-height: 95vh;
  }
}

@media (min-width: 769px) {
  .mobile-menu-btn {
    display: none;
  }
}

/* Hide duplicate "Home" text link in the desktop menu, but keep the logo visible */
@media (min-width: 769px) {
  .desktop-menu a[href="#home"] {
    display: none !important;
  }
}

/* Flag Icons Customization */
.flag-icon {
  display: inline-block;
  background-size: contain;
  background-position: 50%;
  background-repeat: no-repeat;
  position: relative;
  width: 1.5em;
  height: 1.5em;
  margin-right: 0.5em;
  border-radius: 2px;
}

.flag-icon:before {
  content: "\00a0";
}

.flag-icon.flag-icon-uz {
  background-image: url(https://cdnjs.cloudflare.com/ajax/libs/flag-icon-css/6.6.6/flags/4x3/uz.svg);
}

.flag-icon.flag-icon-us {
  background-image: url(https://cdnjs.cloudflare.com/ajax/libs/flag-icon-css/6.6.6/flags/4x3/us.svg);
}

/* Language Button Styling */
.language-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0.75rem !important;
  transition: all 0.3s ease !important;
}

.language-btn img {
  width: 36px !important;
  height: 24px !important;
  object-fit: cover !important;
  border-radius: 2px !important;
  transition: box-shadow 0.3s, transform 0.3s;
}

.language-btn:hover {
  background-color: rgba(234, 179, 8, 0.2) !important;
}

.language-btn:hover img {
  box-shadow: 0 0 12px 2px #fde047, 0 0 20px 4px #b27b00;
  transform: scale(1.12);
}

/* Mobile specific adjustments */
@media (max-width: 768px) {
  .language-btn {
    padding: 0.5rem !important;
  }

  .language-btn img {
    width: 37px !important;
    height: 20px !important;
  }
}

/* Desktop Menu Styles */
.desktop-menu {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
}

@media (max-width: 768px) {
  .desktop-menu {
    display: none !important;
  }
}

/* Mobile Menu Button */
@media (min-width: 769px) {
  .mobile-menu-btn {
    display: none !important;
  }
}

/* Mobile-only menu item */
.mobile-only-menu {
  display: block;
}

@media (min-width: 769px) {
  .mobile-only-menu {
    display: none !important;
  }
}

/* Add CSS classes for logo and button visibility */
.logo-container.visible {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  align-items: center !important;
}

.eagle-logo.visible {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  margin-right: 15px !important;
}

.language-btn.active {
  background-color: rgba(234, 179, 8, 0.3) !important;
  color: rgb(253, 224, 71) !important;
}

.language-btn:not(.active) {
  color: white !important;
}

/* Responsive eagle-logo size – significantly larger on all screens */
.eagle-logo {
  width: 70px; /* mobile & small screens - increased from 400px */
  height: 60px; /* increased from 250px */
  opacity: 1;
  margin-left: 0.5rem;
}

@media (min-width: 768px) {
  .eagle-logo {
    width: 105px; /* desktop & larger - increased from 600px */
    height: 85px; /* increased from 360px */
    border-radius: 9999px;
    opacity: 1;
    margin-left: 1rem;
  }
}

@media (min-width: 768px) {
  .eagle-logo:hover {
    filter: drop-shadow(4px 8px 8px #fdfd00);
    transform: scale(1.08);
    transition: transform 0.3s, filter 0.3s;
    cursor: pointer;
  }
}

.company-name {
  font-family: "Aladin", system-ui;
  font-size: 1.3rem;
  font-weight: bold;
  color: #f8e3e3;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5), 0 0 20px #fde047,
    0 0 40px #b27b00;
  letter-spacing: 2px;
  transition: all 0.3s ease;
  display: inline-block;
  cursor: pointer;
  padding: 3px 5px;
  border-radius: 3px;
}

.company-name:hover {
  color: #fde047;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5), 0 0 25px #fde047,
    0 0 50px #b27b00;
  transform: scale(1.05);
}

@media (min-width: 768px) {
  .company-name {
    font-size: 3.5rem;
    cursor: pointer;
  }
}

/* Optionally, make the logo-container a bit larger for nav bar alignment */
.logo-container {
  align-items: normal;
}
@media (min-width: 768px) {
  .logo-container {
    min-height: 64px;
  }
}

/* Separate container styles for eagle logo and company name */
.eagle-logo-container {
  display: flex;
  align-items: center;
  justify-content: center;
}

.company-name-container {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Ensure both containers are visible */
.eagle-logo-container a,
.company-name-container a {
  display: flex !important;
  align-items: center !important;
  text-decoration: none !important;
}

/* Navbar fade-in and slide-down animation */
@keyframes navbarFadeSlide {
  0% {
    opacity: 0;
    transform: translateY(-24px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}
.navbar {
  animation: navbarFadeSlide 1.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 767px) {
  .navbar {
    min-height: 4.5rem;
  }
  .mobile-menu {
    padding-top: 2.5rem;
    padding-bottom: 1rem;
    min-height: 15vh;
  }
}

.navbar a,
.desktop-menu a,
.mobile-menu a {
  font-size: 1.25rem;
}

.navbar a:hover,
.desktop-menu a:hover,
.mobile-menu a:hover {
  color: #fde047 !important;
  /* box-shadow: 0 0 16px 4px #fde047, 0 0 32px 8px #b27b00; */
  text-shadow: 0 0 12px #fde047, 0 0 24px #b27b00;
  transform: scale(1.08);
  background: rgba(178, 123, 0, 0.12);
}

@media (max-width: 767px) {
  .mobile-menu a {
    text-shadow: 2px 2px 4px #b27b00, -2px -2px 4px #b27b00;
  }
  .mobile-menu a:hover {
    color: #fde047 !important;
    text-shadow: 2px 2px 4px #b27b00, -2px -2px 4px #b27b00;
    background: none !important;
    box-shadow: none !important;
    transform: none !important;
  }
}
