/* Homepage branding and navigation for teacher profiles and sign-in. */
@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,400;12..96,700&family=Inter:wght@400;600;700&display=swap');

.top {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(247, 249, 243, .86);
  color: #08110f;
  border-bottom: 1px solid rgba(8, 17, 15, .06);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
}
.top .tp-header-inner {
  width: min(100%, 1240px);
  margin: 0 auto;
  padding: 0 clamp(1.1rem, 4vw, 2.5rem);
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: relative;
  box-sizing: border-box;
}
.top .tp-brand {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  flex: 0 0 auto;
  color: #08110f;
  text-decoration: none;
  white-space: nowrap;
}
.top .tp-brand img {
  display: block;
  width: 40px;
  height: 40px;
  max-width: none;
  border-radius: 12px;
  flex: 0 0 40px;
  box-shadow: 0 10px 20px -12px rgba(18, 121, 107, .9);
  transition: transform .5s cubic-bezier(.22, 1, .36, 1), box-shadow .4s cubic-bezier(.22, 1, .36, 1);
}
.top .tp-brand:hover img { transform: rotate(-4deg) scale(1.04); }
.top .tp-brand__type { display: flex; flex-direction: column; line-height: 1; }
.top .tp-brand__wordmark {
  font-family: 'Bricolage Grotesque', 'Inter', system-ui, sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -.035em;
}
.top .tp-brand__wordmark em { color: #12796b; font-style: normal; font-weight: 400; }
.top .tp-brand__tag {
  margin-top: 3px;
  font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: #5a6b66;
}
.top .tp-brand:focus-visible, .top .tp-site-nav a:focus-visible, .top .tp-nav-toggle:focus-visible {
  outline: 3px solid #12796b;
  outline-offset: 4px;
}
.top .tp-site-nav { display: flex; align-items: center; gap: .15rem; font-family: 'Inter', 'Segoe UI', system-ui, sans-serif; }
.top .tp-site-nav a {
  position: relative;
  padding: .55rem .9rem;
  border-radius: 12px;
  color: #08110f;
  font-size: .92rem;
  line-height: 1.65;
  font-weight: 600;
  text-decoration: none;
  transition: color .3s cubic-bezier(.22, 1, .36, 1), background .3s cubic-bezier(.22, 1, .36, 1);
}
.top .tp-site-nav a::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: .28rem;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #12796b;
  transform: translateX(-50%) scale(0);
  transition: transform .35s cubic-bezier(.34, 1.56, .64, 1);
}
.top .tp-site-nav a:hover::after, .top .tp-site-nav a[aria-current="page"]::after { transform: translateX(-50%) scale(1); }
.top .tp-site-nav a:hover { background: rgba(18, 121, 107, .08); }
.top .tp-site-nav .tp-nav-cta { margin-left: .5rem; padding: .6rem 1.15rem; background: #08110f; color: #e4ff8f; }
.top .tp-site-nav .tp-nav-cta::after { display: none; }
.top .tp-site-nav .tp-nav-cta:hover, .top .tp-site-nav .tp-nav-cta:focus-visible { background: #0d6659; color: #e4ff8f; }
.top .tp-nav-toggle { display: none; width: 46px; height: 46px; padding: 0; border: 1px solid #dce3dc; border-radius: 14px; background: #fff; cursor: pointer; }
.top .tp-nav-toggle span { display: block; width: 18px; height: 2px; margin: 4px auto; border-radius: 2px; background: #08110f; transition: transform .3s, opacity .2s; }
.top .tp-nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.top .tp-nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.top .tp-nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
/* Switch before the full desktop navigation collides with the wordmark. */
@media (max-width: 1060px) {
  .top .tp-header-inner { flex-wrap: wrap; gap: 0 1rem; }
  .top.tp-js .tp-header-inner { flex-wrap: nowrap; }
  .top .tp-brand { min-width: 0; flex: 0 1 auto; }
  .top .tp-brand__type { min-width: 0; }
  .top .tp-brand__tag { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .top .tp-nav-toggle { flex: 0 0 46px; }
  .top .tp-site-nav { flex: 0 0 100%; flex-direction: column; align-items: stretch; gap: .2rem; padding: .7rem 0 1.2rem; }
  .top .tp-site-nav a { display: block; flex: 0 0 auto; min-height: 44px; padding: .75rem .9rem; }
  .top .tp-site-nav a::after { display: none; }
  .top .tp-site-nav .tp-nav-cta { margin: .4rem 0 0; text-align: center; }
  /* Without JavaScript the links stay in the document flow and can be scrolled. */
  .top:not(.tp-js) { position: relative; }
  .top.tp-js .tp-nav-toggle { display: block; }
  .top.tp-js .tp-site-nav {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    max-height: calc(100vh - 76px);
    max-height: calc(100dvh - 76px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: .7rem clamp(1.1rem, 4vw, 2.5rem) 1.2rem;
    background: #f7f9f3;
    border-bottom: 1px solid #dce3dc;
    box-shadow: 0 24px 30px -30px rgba(8, 17, 15, .6);
  }
  .top.tp-js .tp-site-nav.is-open { display: flex; }
}
/* Avoid pushing the menu button onto a second row on common phone widths. */
@media (max-width: 480px) {
  .top .tp-brand__tag { display: none; }
}
@media (max-width: 380px) {
  .top .tp-header-inner { padding-inline: 1rem; gap: 0 .5rem; }
  .top .tp-brand { gap: .5rem; }
  .top .tp-brand img { width: 32px; height: 32px; flex-basis: 32px; }
  .top .tp-brand__wordmark { font-size: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) { .top .tp-brand img, .top .tp-site-nav a, .top .tp-site-nav a::after, .top .tp-nav-toggle span { transition: none; } }
