/* Layout: the app shell. Sidebar, navigation, top bar, page header and footer. */

.app {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 248px;
  padding: 30px 19px 0;
}

.brand {
  font-size: 27px;
}

.brandmark {
  font-size: 31px;
  width: 37px;
  height: 39px;
}

.club-switch>div:last-child {
  min-width: 0;
}

.sidebar-bottom {
  margin-top: auto;
}

.user>.account-link {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  flex: 1;
  color: inherit;
}

.account-link>div {
  min-width: 0;
}

.account-link:hover strong,
.account-link:focus-visible strong {
  text-decoration: underline;
}

.main {
  width: calc(100% - 248px);
  margin-left: 248px;
  display: flex;
  flex-direction: column;
}

.topbar {
  padding: 0 39px;
}

.breadcrumb {
  gap: 13px;
  font-size: 11px;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* Every page of a demo club says so, so a screenshot never passes the
   made-up athletes or results off as real. */
.demo-banner {
  margin: 0;
  padding: 10px 39px;
  border-bottom: 1px solid #ece27a;
  background: #fffbd6;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.45;
}

.content {
  padding: 35px 39px;
  max-width: 1600px;
  width: 100%;
  margin: 0 auto;
  flex: 1;
}

.footer {
  padding: 17px 39px;
  font-size: 9px;
}

.footer>span {
  display: flex;
  align-items: center;
  gap: 8px;
}

.search {
  width: 340px;
  padding: 0 12px;
}

.search input {
  outline: none;
  font-size: 11px;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline-offset: 3px;
  outline-color: #4567ec;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  display: flex;
  flex-direction: column;
  z-index: 20;
  /* Fixed to the viewport, so on short windows the menu scrolls on its own
     instead of cutting off settings and sign out. */
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--navy);
  border-right: 0;
  color: #fff;
  padding-top: 26px;
}

.brand {
  display: flex;
  align-items: center;
  font-weight: 700;
  white-space: nowrap;
  gap: 10px;
  color: #fff;
  letter-spacing: -1.8px;
}

.brandmark svg {
  width: 100%;
  height: 100%;
  transform: skew(5deg);
}

.wordmark {
  font-style: italic;
  font-size: 30px;
  font-weight: 900;
  letter-spacing: -1.8px;
}

.club-switch {
  display: flex;
  gap: 10px;
  padding: 28px 0 15px;
  align-items: center;
  padding-top: 29px;
}

.club-switch small {
  display: block;
  margin-bottom: 5px;
  color: #8d9bb9;
  font-size: 8px;
  letter-spacing: 1.3px;
}

.nav-label {
  margin: 29px 10px 12px;
  color: #7082a4;
  letter-spacing: 1.6px;
  font-size: 8px;
  margin-top: 29px;
}

nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.user {
  display: flex;
  align-items: center;
  gap: 9px;
  border-top: 1px solid var(--line);
  margin-top: 17px;
  padding: 18px 0;
  border-color: #2a3955;
}

.user .avatar {
  background: #304366;
  color: #e5edff;
}

.user strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 11px;
  font-weight: 600;
  color: #e5ecfc;
}

.user small {
  display: block;
  margin-top: 4px;
  font-size: 10px;
  color: #8d9cba;
}

.topbar {
  height: 76px;
  border-bottom: 1px solid var(--line);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-color: #e0e5ef;
}

.breadcrumb {
  display: flex;
  align-items: center;
  color: #8e9bb0;
}

.breadcrumb strong {
  font-weight: 500;
  color: #3d4e6c;
}

.footer b {
  font-weight: 900;
  font-style: italic;
  letter-spacing: -.3px;
  color: #344e7b;
}

.footer>span:last-child {
  font-size: 8px;
  letter-spacing: 1px;
}

.search {
  display: flex;
  align-items: center;
  gap: 9px;
  background: #fff;
  border: 1px solid var(--line);
  border-color: #dce3ef;
  border-radius: 4px;
  color: #8b9cb8;
}

.mobile-wordmark {
  display: none;
}

nav a {
  display: flex;
  align-items: center;
  gap: 11px;
  text-align: left;
  padding: 13px 12px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
  color: #a5b4d0;
  position: relative;
}

nav a:hover {
  background: #203052;
  color: #fff;
}

.hq {
  color: var(--yellow);
  font-size: 10px;
  align-self: flex-start;
  margin-top: 5px;
  font-weight: 800;
  letter-spacing: .6px;
}

.club-name {
  display: block;
  color: #eff3ff;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 155px;
}

.logout {
  font-size: 10px;
  background: none;
  border: 0;
  color: #9aaed0;
}

.auth-brand .brand {
  color: #152850;
}

/* On light pages the mark is inverted: a yellow square would vanish on the
   pale background (1.1:1), a navy one stands out at 16:1. */
.auth-brand .brandmark {
  background: var(--navy-deep);
  color: var(--yellow);
}

.auth-brand .hq {
  color: var(--blue);
}

@media (min-width: 1600px) {
  .content {
    padding-top: 45px;
  }
}

@media (max-width: 1200px) {
  .sidebar {
    width: 218px;
    padding-left: 15px;
    padding-right: 15px;
  }

  .main {
    margin-left: 218px;
    width: calc(100% - 218px);
  }

  .content {
    padding: 29px 26px;
  }

  .demo-banner {
    padding-inline: 26px;
  }

  .topbar {
    padding: 0 26px;
  }

  .content h1 {
    font-size: 29px;
  }

  .club-name {
    max-width: 130px;
  }
}

@media (max-width: 960px) {
  .sidebar {
    width: 190px;
  }

  .main {
    margin-left: 190px;
    width: calc(100% - 190px);
  }

  .brand {
    font-size: 23px;
  }

  .brandmark {
    width: 32px;
    height: 35px;
    font-size: 28px;
  }

  .top-actions {
    gap: 12px;
  }

  .club-name {
    max-width: 105px;
  }
}

/* The phone drawer's close button and the dimmed page behind it: hidden
   until the drawer slides in (max-width: 700px). */
/* .icon-btn (components.css) also sets display, so match its weight. */
.drawer-close.icon-btn,
.drawer-backdrop {
  display: none;
}

@media (max-width: 700px) {
  .sidebar.open {
    transform: translateX(0);
  }

  .drawer-close.icon-btn {
    display: inline-flex;
    align-self: flex-end;
    margin: -14px -6px 4px 0;
    color: #fff;
  }

  .drawer-close:hover {
    background: #ffffff1f;
  }

  /* After .main in the markup, so it covers the sticky top bar (same
     z-index) and stays under the drawer. */
  .sidebar.open~.drawer-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 19;
    background: #0c1a3c66;
  }

  .main {
    width: 100%;
    margin: 0;
  }

  .breadcrumb {
    gap: 7px;
    font-size: 10px;
  }

  .breadcrumb>span {
    display: none;
  }

  .top-actions {
    gap: 10px;
  }

  .content {
    padding: 25px 17px;
  }

  .demo-banner {
    padding-inline: 17px;
  }

  .footer {
    padding: 16px 18px;
    font-size: 8px;
  }

  .footer>span:last-child {
    display: none;
  }

  .search {
    width: auto;
    flex: 1;
    padding: 0 10px;
  }

  .search input {
    font-size: 10px;
  }

  .sidebar {
    transform: translateX(-100%);
    width: 248px;
    transition: transform .2s;
    box-shadow: 10px 0 40px #0c1a3c44;
  }

  .wordmark {
    font-size: 30px;
  }

  .topbar {
    height: 61px;
    padding: 0 17px;
    position: sticky;
    top: 0;
    z-index: 19;
    border-bottom: 2px solid var(--blue);
  }

  .breadcrumb>.mobile-wordmark {
    display: inline-block;
    font-size: 19px;
    font-style: italic;
    font-weight: 900;
    color: #203873;
    letter-spacing: -1px;
    margin-right: 5px;
  }

  .breadcrumb strong {
    font-size: 10px;
  }

  nav a {
    padding: 13px 12px;
  }

  .club-name {
    max-width: 155px;
  }

  .mobile-wordmark small {
    font-size: 8px;
    color: var(--blue);
  }
}

/* Overrides: these must come after the breakpoints above. */

.brandmark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-right: 4px;
  line-height: 1;
  background: var(--yellow);
  color: #152146;
  letter-spacing: 0;
  padding: 5px;
  width: 37px;
  height: 39px;
  border-radius: 4px;
  transform: skew(-5deg);
}

.footer {
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  color: #8190a9;
  border-color: #dce3f0;
  font-size: 9px;
}

.search input {
  border: 0;
  background: none;
  width: 100%;
  padding: 12px 0;
  font-size: 11px;
}
