:root {
  --tabs-height: 44px;
}

.brand-tabs {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  min-height: var(--tabs-height);
  background: rgba(5,5,7,0.95);
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 30px rgba(5,5,7,0.35);
  z-index: 200;
  display: flex;
  justify-content: center;
  padding: 4px 0;
}

.brand-tabs-inner {
  width: 100%;
  max-width: var(--maxw, 1200px);
  padding: 6px 16px;
  display: flex;
  gap: 8px;
}

.brand-tabs-dropdown {
  display: none;
}

.brand-tab {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  font-size: 0.75rem;
  padding: 6px 12px;
  text-decoration: none;
  color: rgba(255,255,255,0.8);
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.04);
  transition: background 0.2s ease, color 0.2s ease, opacity 0.2s ease, border-color 0.2s ease;
  opacity: 0.85;
  --tab-dot: rgba(255,255,255,0.6);
}

.brand-tab::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--tab-dot);
  box-shadow: 0 0 12px rgba(0,0,0,0.25);
}

.brand-tab:hover {
  opacity: 1;
  border-color: rgba(255,255,255,0.4);
}

.brand-tab[aria-current="page"] {
  color: #fff;
  opacity: 1;
  border-color: transparent;
  box-shadow: 0 8px 22px rgba(0,0,0,0.25);
}

.brand-tab[data-division="passenger"] { --tab-color: linear-gradient(120deg, #7B1E2B, #C33E52); --tab-dot: #C33E52; }
.brand-tab[data-division="engineering"] { --tab-color: linear-gradient(120deg, #050505, #7B1E2B); --tab-dot: #7B1E2B; }
.brand-tab[data-division="student"] { --tab-color: linear-gradient(120deg, #8B6D00, #F6D46A); --tab-dot: #F5BD24; }
.brand-tab[data-division="sales"] { --tab-color: linear-gradient(120deg, #1f2c4c, #5a7da3); --tab-dot: #1f2c4c; }

.brand-tab[aria-current="page"] {
  background: var(--tab-color, rgba(255,255,255,0.12));
}

.brand-tab:not([aria-current="page"]):hover {
  background: rgba(255,255,255,0.08);
}

@media (max-width: 640px) {
  :root {
    --tabs-height: 68px;
  }
  .brand-tabs {
    padding: 8px 16px;
    align-items: flex-start;
    display: block;
    height: var(--tabs-height);
  }
  .brand-tabs-dropdown {
    display: inline-flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    font-size: 0.8rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    border-radius: 999px;
    padding: 10px 16px;
    cursor: pointer;
  }
  .brand-tabs-dropdown::after {
    content: '';
    width: 10px;
    height: 10px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    margin-left: auto;
    transition: transform .2s ease;
  }
  .brand-tabs.is-open .brand-tabs-dropdown::after {
    transform: rotate(-135deg);
  }
  .brand-tabs-inner {
    position: absolute;
    left: 16px;
    right: 16px;
    top: calc(100% - 6px);
    display: none;
    flex-direction: column;
    width: auto;
    max-width: none;
    background: rgba(5,5,7,0.98);
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,0.18);
    padding: 10px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.35);
  }
  .brand-tabs.is-open .brand-tabs-inner {
    display: flex;
  }
  .brand-tab {
    width: 100%;
  }
  .brand-tab::before {
    display: none;
  }
  .brand-tab {
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    border-radius: 14px;
    padding: 10px 14px;
  }
}
