/**
 * Mobile Header Improvements
 *
 * @package Bucksalc
 */

/* Hide top-header on mobile */
@media only screen and (max-width: 767px) {
  .top-header {
    display: none;
  }
}

/* Hide desktop search form on mobile */
@media only screen and (max-width: 767px) {
  .header_wrapper form.search-form {
    display: none;
  }
}

/* Mobile actions wrapper */
.mobile-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

@media only screen and (min-width: 1024px) {
  .mobile-actions {
    justify-content: space-between;
    width: 100%;
  }
}

/* Mobile search toggle button */
.mobile-search-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: 15px 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media only screen and (min-width: 768px) {
  .mobile-search-toggle {
    display: none;
  }
}

.mobile-search-toggle img {
  filter: brightness(0) invert(1);
  width: 24px;
  height: 24px;
}

/* Mobile top menu styling */
.mobile-top-menu {
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  padding-bottom: 15px;
  margin-bottom: 15px;
}

.mobile-top-menu .top-menu-mobile {
  padding: 15px 49px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
}

.mobile-top-menu .top-menu-mobile li {
  list-style-type: none;
}

.mobile-top-menu .top-menu-mobile li a {
  color: #fff;
  font-size: 16px;
  font-weight: 400;
  line-height: 140%;
  padding: 5px 0;
  display: block;
}

.mobile-top-menu .top-menu-mobile li a:hover {
  color: var(--color-primary, #2E2766);
  transition: color 300ms ease;
}

/* Mobile Search Modal */
.mobile-search-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 9999;
  align-items: flex-start;
  justify-content: center;
  padding-top: 20vh;
}

.mobile-search-modal.is-active {
  display: flex;
}

.mobile-search-content {
  background: var(--color-secondary, #E67E23);
  padding: 30px;
  border-radius: 10px;
  width: 90%;
  max-width: 500px;
  position: relative;
}

.mobile-search-close {
  position: absolute;
  top: 10px;
  right: 10px;
  background: none;
  border: none;
  color: #fff;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
  padding: 5px 10px;
}

.mobile-search-close:hover {
  color: var(--color-primary, #2E2766);
}

.mobile-search-form {
  display: flex;
  gap: 10px;
  align-items: center;
  padding-top: 20px;
}

.mobile-search-field {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 16px;
}

.mobile-search-field::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

.mobile-search-field:focus {
  outline: none;
  border-color: var(--color-primary, #2E2766);
  background: rgba(255, 255, 255, 0.15);
}

.mobile-search-submit {
  background: var(--color-primary, #2E2766);
  border: none;
  padding: 12px 16px;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 300ms ease;
}

.mobile-search-submit:hover {
  background: #1f1a4a;
}

.mobile-search-submit img {
  width: 20px;
  height: 20px;
  filter: brightness(0) invert(1);
}
