@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;700&display=swap");

body {
  font-family: "Inter", sans-serif;
  background-color: #f3f4f6; /* Light gray background */
  background-image: url("background.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

/* Responsive background image - simplified */
@media (min-width: 769px) {
  body {
    background-size: cover !important;
    background-position: center !important;
  }
}

/* Enhanced dropdown styling */
#country-select,
#port-select {
  font-size: 1.125rem; /* 18px */
  font-weight: 500;
  line-height: 1.5;
  min-height: 48px;
  border-color: #f0f1f4;
}

#country-select option,
#port-select option {
  font-size: 1.125rem; /* 18px */
  font-weight: 500;
  padding: 8px 12px;
}

/* Ensure labels are properly sized */
label[for="country-select"],
label[for="port-select"] {
  font-size: 1.125rem; /* 18px */
  font-weight: 600;
  margin-bottom: 8px;
}

/* Better mobile responsiveness for dropdowns */
@media (max-width: 768px) {
  #country-select,
  #port-select {
    font-size: 1rem; /* 16px on mobile */
    min-height: 44px;
  }

  label[for="country-select"],
  label[for="port-select"] {
    font-size: 1rem; /* 16px on mobile */
  }
}
/* Aside menu - clean implementation */
#aside-menu {
  /* Match the exact height of the parent container */
  height: 100%;
  /* Keep the slide animation working properly */
  top: 0;
  left: 0;
}

/* Close button positioning to match burger menu */
#close-menu {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

/* Language selector styling */
#language-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 16px;
  padding-right: 32px;
}

#language-select:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.5);
}

#language-select option {
  background-color: white;
  color: #374151;
}

/* Language-specific menu adjustments for Russian and Ukrainian */
[data-lang="ru"] #aside-menu a,
[data-lang="uk"] #aside-menu a {
  padding: 0.5rem 0.75rem !important; /* Reduced from px-4 py-3 */
  font-size: 0.875rem !important; /* Smaller font size */
}

[data-lang="ru"] #aside-menu ul,
[data-lang="uk"] #aside-menu ul {
  gap: 0.25rem !important; /* Reduced spacing between items */
}

[data-lang="ru"] #aside-menu svg,
[data-lang="uk"] #aside-menu svg {
  width: 1rem !important;
  height: 1rem !important;
  margin-right: 0.5rem !important;
}

/* Mobile-specific header layout for port info page - prevent overflow with language selector + search button */
@media (max-width: 498px) {
  /* When port info page is active, use space-between for header to prevent overflow */
  .port-info-active header .relative.flex.items-center.justify-center {
    justify-content: space-between !important;
  }
}

/* Port info specific - extra small logo and title for 375-400px range */
@media (max-width: 400px) {
  .port-info-active #home-link img {
    width: 1.625rem !important; /* 26px - smaller than general 28px */
    height: 1.625rem !important; /* 26px - smaller than general 28px */
  }

  .port-info-active #home-link h1 {
    font-size: 0.9375rem !important; /* 15px - smaller than general 16px */
    font-weight: 600 !important;
  }

  .port-info-active #home-link {
    gap: 0.125rem !important; /* 2px - tighter than general 4px */
  }
}

/* Responsive header sizing - consolidated breakpoints */
@media (max-width: 430px) {
  #home-link img {
    width: 2rem !important; /* 32px */
    height: 2rem !important; /* 32px */
  }

  #home-link h1 {
    font-size: 1.125rem !important; /* 18px */
    font-weight: 700 !important;
  }

  #home-link {
    gap: 0.375rem !important; /* 6px */
  }
}

@media (max-width: 420px) {
  #home-link img {
    width: 1.875rem !important; /* 30px */
    height: 1.875rem !important; /* 30px */
  }

  #home-link h1 {
    font-size: 1.0625rem !important; /* 17px */
    font-weight: 650 !important;
  }

  #home-link {
    gap: 0.1875rem !important; /* 3px */
  }
}

@media (max-width: 400px) {
  #home-link img {
    width: 1.75rem !important; /* 28px */
    height: 1.75rem !important; /* 28px */
  }

  #home-link h1 {
    font-size: 1rem !important; /* 16px */
    font-weight: 600 !important;
  }

  #home-link {
    gap: 0.25rem !important; /* 4px */
  }
}

/* Extra small screens - most aggressive reduction (< 360px) */
@media (max-width: 360px) {
  /* Make logo very small */
  #home-link img {
    width: 1.5rem !important; /* 24px */
    height: 1.5rem !important; /* 24px */
  }

  /* Make title font very small */
  #home-link h1 {
    font-size: 0.875rem !important; /* 14px */
    font-weight: 600 !important; /* Keep weight */
  }

  /* Minimal spacing */
  #home-link {
    gap: 0.125rem !important; /* 2px */
  }
}
/* Button-style links - ensure proper appearance and behavior */
a.inline-block.text-center {
  text-decoration: none !important;
  color: white !important;
  display: inline-block;
  cursor: pointer;
}

a.inline-block.text-center:hover {
  text-decoration: none !important;
  color: white !important;
}

a.inline-block.text-center:visited {
  color: white !important;
}

a.inline-block.text-center:focus {
  outline: 2px solid rgba(255, 255, 255, 0.5);
  outline-offset: 2px;
}

/* Ensure spans inside button-links inherit proper styling */
a.inline-block.text-center span {
  color: inherit;
  text-decoration: none;
}