/* Hide mobile-only items on desktop */
.mobile-only {
  display: none;
}

/* ============================================
   SMALL TABLETS (576px+)
   ============================================ */
@media (min-width: 576px) {
  .grid--2 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid--3 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid--4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .info-strip__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================
   TABLETS (768px+)
   ============================================ */
@media (min-width: 768px) {
  .grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }

  .grid--4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .feature {
    flex-direction: row;
  }

  .feature--reverse {
    flex-direction: row-reverse;
  }

  .contact-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-content {
    grid-template-columns: repeat(2, 1fr);
  }

  .tritip-feature {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .tritip-feature .feature__image {
    aspect-ratio: auto;
    height: 100%;
  }
}

/* ============================================
   DESKTOPS (1024px+)
   ============================================ */
@media (min-width: 1024px) {
  .grid--4 {
    grid-template-columns: repeat(4, 1fr);
  }

  .footer-content {
    grid-template-columns: 2fr 1fr 1fr;
  }

  .hero {
    min-height: 80vh;
  }
}

/* ============================================
   MOBILE NAV (below 768px)
   ============================================ */
@media (max-width: 767px) {
  .header-phone {
    display: none;
  }

  .header-row {
    justify-content: space-between;
  }

  .nav-toggle {
    display: block;
    order: 99;
  }

  /* Full-screen mobile menu */
  .nav-list {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    background: #000;
    flex-direction: column;
    align-items: stretch;
    padding: var(--space-4xl) var(--space-2xl) var(--space-2xl);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transform: translateX(100%);
    transition: transform var(--transition-normal);
    z-index: 99999;
  }

  .nav-list.open {
    transform: translateX(0);
  }

  /* Hide dropdown toggle buttons on mobile — show all links flat */
  .nav-dropdown__toggle {
    display: none;
  }

  /* Hide desktop-only dropdown items on mobile */
  .desktop-only {
    display: none;
  }

  /* Show mobile-only items */
  .mobile-only {
    display: list-item;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: var(--space-sm);
  }

  /* Section labels for dropdown groups */
  .nav-dropdown {
    margin-bottom: var(--space-sm);
  }

  /* All nav links: clean white on black */
  .nav-link {
    padding: var(--space-sm) 0;
    font-size: var(--fs-body);
    color: #fff;
    border-bottom: none;
  }

  .nav-link::after {
    display: none;
  }

  .nav-link.active {
    color: var(--color-accent);
    font-weight: var(--fw-bold);
  }

  /* Dropdown submenus — always visible, flat list */
  .nav-dropdown__menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    background: transparent;
    padding: 0;
    display: block;
  }

  .nav-dropdown__menu li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .nav-dropdown__menu li:last-child {
    border-bottom: none;
    margin-bottom: var(--space-md);
  }

  .nav-dropdown__menu a {
    padding: var(--space-md) 0;
    color: #fff;
    display: block;
    background: transparent;
  }

  .nav-dropdown__menu a:hover {
    background: transparent;
    color: #fff;
  }

  /* Show rich dropdown content on mobile */
  .dropdown-rich {
    display: flex !important;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md) 0 !important;
  }

  .dropdown-rich:hover {
    color: #fff;
  }

  .dropdown-rich__icon {
    display: block;
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    color: #fff;
  }

  .dropdown-rich__icon[src] {
    filter: brightness(0) invert(1);
  }

  .dropdown-rich:hover .dropdown-rich__icon {
    color: #fff;
  }

  .dropdown-rich:hover .dropdown-rich__icon[src] {
    filter: brightness(0) invert(1);
  }

  .dropdown-rich__text {
    display: flex;
    flex-direction: column;
  }

  .dropdown-rich__text strong {
    font-size: 1rem;
    color: #fff;
  }

  .dropdown-rich:hover .dropdown-rich__text strong {
    color: #fff;
  }

  /* Show direct-link dropdown menus on mobile */
  .nav-dropdown__link + .nav-dropdown__menu {
    display: block;
  }

  .nav-dropdown__link {
    display: none;
  }

  /* Hide announcement bar when mobile menu is open */
  .announcement-bar.menu-open {
    display: none;
  }

  .dropdown-rich__text small {
    display: block;
    font-size: var(--fs-tiny);
    color: rgba(255, 255, 255, 0.5);
    margin-top: 2px;
  }

  .nav-social {
    display: none;
  }

  /* Mobile nav hero image */
  .mobile-nav-hero {
    display: block !important;
    margin: calc(-1 * var(--space-4xl)) calc(-1 * var(--space-2xl)) var(--space-lg) calc(-1 * var(--space-2xl));
    height: 216px;
    overflow: hidden;
    list-style: none;
    border-bottom: none !important;
    flex-shrink: 0;
  }

  .mobile-nav-hero__img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  /* Close button */
  .nav-close {
    position: absolute;
    top: var(--space-lg);
    right: var(--space-lg);
    background: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    padding: var(--space-sm);
    color: #fff;
    z-index: 2;
  }

  .nav-close svg {
    width: 28px;
    height: 28px;
  }

  /* Overlay hidden — full screen menu doesn't need it */
  .nav-overlay {
    display: none;
  }

  .feature {
    flex-direction: column;
  }

  .feature--reverse {
    flex-direction: column;
  }

  .feature__image {
    margin-inline: calc(-1 * var(--container-padding));
    border-radius: 0;
  }

  .hero {
    min-height: 80vh;
  }

  .hero__content {
    margin-left: 0;
    padding: 0 var(--container-padding);
    max-width: 100%;
  }

  .hero--short {
    min-height: 26vh;
  }

  .hero__actions {
    flex-direction: column;
    width: 100%;
  }

  .hero__actions .btn {
    width: 100%;
  }
}
