/* =============================================
   NAVBAR STYLES — Canossa High School
   ============================================= */

*, *::before, *::after {
  box-sizing: border-box;
}

/* NAVBAR */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1200;
  background: #fff;
  border-bottom: 2px solid var(--border);
  box-shadow: 0 2px 20px rgba(10,124,110,.07);
  width: 100%;
  max-width: 100%;
  transition: box-shadow .3s, border-color .3s;
}
.navbar.scrolled {
  box-shadow: 0 4px 32px rgba(10,124,110,.15);
  border-bottom-color: rgba(10,124,110,.25);
}

/* NAVBAR INNER */
.navbar-inner {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 66px;
}

/* LOGO */
.nav-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
  padding-right: 24px;
  border-right: 1.5px solid var(--border);
}
.nav-logo img {
  width: 190px;
  height: auto;
  display: block;
}

/* NAV LINKS */
.nav-links {
  display: flex;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0 0 0 16px;
  flex: 1;
  justify-content: center;
  height: 66px;
  min-width: 0;
}
.nav-links > li {
  position: relative;
  display: flex;
  align-items: center;
  height: 100%;
  flex-shrink: 1;
  min-width: 0;
}
.nav-links > li > a {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 0 13px;
  font-family: 'Outfit', sans-serif;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text) !important;
  text-decoration: none;
  letter-spacing: .4px;
  text-transform: uppercase;
  white-space: nowrap;
  height: 100%;
  position: relative;
  transition: color .25s;
}
.nav-links > li > a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 13px;
  right: 13px;
  height: 3px;
  background: linear-gradient(90deg, var(--teal), var(--teal-light));
  border-radius: 3px 3px 0 0;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .28s cubic-bezier(.16,1,.3,1);
}
.nav-links > li > a:hover::after {
  transform: scaleX(1);
}
.nav-links > li > a:hover {
  color: var(--teal) !important;
}
.nav-links > li > a .di {
  font-size: 8px;
  color: var(--text-soft);
  transition: transform .25s, color .25s;
  flex-shrink: 0;
}
.nav-links > li:hover > a .di {
  transform: rotate(180deg);
  color: var(--teal);
}

/* DROPDOWN */
.nav-dd {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 230px;
  background: linear-gradient(160deg, #f0fdfa 0%, #e6faf6 60%, #d0f5ed 100%);
  border: 1.5px solid rgba(10,124,110,.18);
  border-top: 3px solid var(--teal);
  border-radius: 0 0 16px 16px;
  padding: 10px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all .28s cubic-bezier(.16,1,.3,1);
  z-index: 1400;
  box-shadow: 0 20px 52px rgba(10,124,110,.18), 0 4px 16px rgba(10,124,110,.1);
}
.nav-links > li:hover .nav-dd {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.nav-dd a {
  display: flex;
  align-items: center;
  padding: 10px 18px 10px 20px;
  font-family: 'Outfit', sans-serif;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-mid) !important;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: all .22s;
  border-bottom: 1px solid rgba(10,124,110,.07);
}
.nav-dd a:last-child {
  border-bottom: none;
}
.nav-dd a::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--teal), var(--teal-light));
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform .22s;
}
.nav-dd a:hover {
  color: var(--teal) !important;
  padding-left: 26px;
  background: rgba(10,124,110,.06);
}
.nav-dd a:hover::before {
  transform: scaleY(1);
}
.nav-dd hr {
  margin: 5px 16px;
  border: none;
  border-top: 1px dashed rgba(10,124,110,.2);
}

/* SUB-DROPDOWN */
.sub-wrap {
  position: relative;
}
.sub-wrap > a .sa {
  margin-left: auto;
  font-size: 10px;
  color: var(--teal-light);
  transition: transform .22s, color .22s;
}
.sub-wrap:hover > a .sa {
  transform: rotate(90deg);
  color: var(--gold);
}
.nav-sub {
  position: absolute;
  left: 100%;
  top: -6px;
  min-width: 210px;
  background: linear-gradient(160deg, #ecfdf5 0%, #d1fae5 60%, #a7f3d0 100%);
  border: 1.5px solid rgba(5,150,105,.22);
  border-top: 3px solid #059669;
  border-radius: 0 16px 16px 16px;
  padding: 10px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateX(8px);
  transition: all .25s cubic-bezier(.16,1,.3,1);
  z-index: 1500;
  box-shadow: 0 16px 48px rgba(5,150,105,.18), 0 4px 14px rgba(0,0,0,.06);
}
.sub-wrap:hover .nav-sub {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}
.nav-sub a {
  display: flex;
  align-items: center;
  padding: 9px 18px 9px 20px;
  font-family: 'Outfit', sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: #065f46 !important;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid rgba(5,150,105,.09);
  transition: all .22s;
}
.nav-sub a:last-child {
  border-bottom: none;
}
.nav-sub a::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, #059669, #34d399);
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform .22s;
}
.nav-sub a:hover {
  color: #047857 !important;
  padding-left: 26px;
  background: rgba(5,150,105,.08);
}
.nav-sub a:hover::before {
  transform: scaleY(1);
}

/* HAMBURGER */
.nav-ham {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  margin-left: auto;
  border-radius: 8px;
  transition: background .2s;
  z-index: 1400;
  position: relative;
  flex-shrink: 0;
}
.nav-ham:hover {
  background: var(--teal-frost);
}
.nav-ham span {
  display: block;
  width: 23px;
  height: 2px;
  background: var(--teal);
  border-radius: 2px;
  transition: all .32s cubic-bezier(.16,1,.3,1);
}
.nav-ham.open span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.nav-ham.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-ham.open span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

/* MOBILE OVERLAY */
.mob-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1398;
  background: rgba(0,0,0,.45);
  transition: opacity .3s ease;
  opacity: 0;
}
.mob-overlay.active {
  display: block;
  opacity: 1;
}

/* MOBILE DRAWER */
.mob-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 300px;
  max-width: 85vw;
  z-index: 1399;
  background: #ffffff;
  box-shadow: -8px 0 40px rgba(10,124,110,.22);
  overflow-y: auto;
  overflow-x: hidden;
  transform: translateX(100%);
  transition: transform .35s cubic-bezier(.16,1,.3,1);
  display: flex;
  flex-direction: column;
  border: none;
}
.mob-drawer.active {
  transform: translateX(0);
}
.mob-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 18px;
  background: linear-gradient(135deg, var(--teal), var(--teal-mid));
  flex-shrink: 0;
  position: sticky;
  top: 0;
  z-index: 2;
}
.mob-header-title {
  font-family: 'Outfit', sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  letter-spacing: .4px;
}
.mob-x {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.3);
  color: #fff;
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .2s;
  flex-shrink: 0;
}
.mob-x:hover {
  background: rgba(255,255,255,.32);
}
.mob-nav {
  flex: 1;
  padding: 6px 0 36px;
}
.mob-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 13px 20px;
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--text) !important;
  text-decoration: none;
  border-bottom: 1px solid rgba(10,124,110,.08);
  background: transparent;
  border-left: none;
  border-right: none;
  border-top: none;
  cursor: pointer;
  text-align: left;
  transition: background .2s, padding-left .2s, color .2s;
}
.mob-item:hover {
  color: var(--teal) !important;
  background: rgba(10,124,110,.06);
  padding-left: 26px;
}
.mob-item i {
  font-size: 12px;
  color: var(--teal);
  width: 15px;
  text-align: center;
  flex-shrink: 0;
}
.mob-item .mob-arr {
  margin-left: auto;
  font-size: 10px;
  color: var(--text-soft);
  transition: transform .25s;
}
.mob-item.expanded .mob-arr {
  transform: rotate(90deg);
}
.mob-sub {
  display: none;
  background: rgba(10,124,110,.03);
}
.mob-sub.show {
  display: block;
}
.mob-sub a {
  display: flex;
  align-items: center;
  padding: 10px 20px 10px 44px;
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-soft) !important;
  text-decoration: none;
  border-bottom: 1px solid rgba(10,124,110,.06);
  transition: background .18s, padding-left .18s, color .18s;
}
.mob-sub a:hover {
  color: var(--teal) !important;
  background: rgba(10,124,110,.08);
  padding-left: 50px;
}

/* =============================================
   RESPONSIVE BREAKPOINTS
   ============================================= */

/* Large desktop */
@media (max-width: 1280px) {
  .navbar-inner { padding: 0 24px; }
  .nav-links > li > a { padding: 0 10px; font-size: 12px; }
  .nav-logo img { width: 170px; }
}

/* Small desktop / laptop */
@media (max-width: 1100px) {
  .navbar-inner { padding: 0 20px; }
  .nav-links > li > a { padding: 0 8px; font-size: 11.5px; letter-spacing: .2px; }
  .nav-logo img { width: 155px; }
}

/* iPad Pro, Nested Hub, Surface Pro — switch to hamburger */
@media (max-width: 1024px) {
  .nav-links { display: none; }
  .nav-ham { display: flex; }
  .nav-logo img { width: 190px; }
  .navbar-inner { padding: 0 24px; }
}

/* iPad Mini, tablets */
@media (max-width: 768px) {
  .navbar-inner { padding: 0 18px; }
  .nav-logo img { width: 170px; }
}

/* Mobile */
@media (max-width: 480px) {
  .navbar-inner { padding: 0 14px; }
  .nav-logo img { width: 150px; }
}