.navbar  {
  
    position: sticky;
  
    top: 0;
  
    z-index: 1000;
  
    min-height: 86px;
  
    display: flex;
  
    align-items: center;
  
    justify-content: flex-start;
  
    gap: 10px;
  
    padding: 14px clamp(20px, 5vw, 72px);
  
    background: rgba(255, 255, 255, .95);
  
    border-bottom: 1px solid rgba(15, 77, 58, .12);
  
    box-shadow: 0 12px 28px rgba(15, 77, 58, .08);
  
    backdrop-filter: blur(16px)

}

.brand  {
  
    display: flex;
  
    align-items: center;
  
    gap: 12px;
  
    min-width: 0;

    margin-right: auto

}

.brand img  {
  
    width: 54px;
  
    height: 54px;
  
    object-fit: contain

}

.brand strong  {
  
    display: block;
  
    color: var(--primary);
  
    font-size: 21px;
  
    font-weight: 900;
  
    line-height: 1

}

.brand small  {
  
    display: block;
  
    max-width: 310px;
  
    margin-top: 5px;
  
    color: #66746f;
  
    font-size: 11px;
  
    font-weight: 600;
  
    line-height: 1.25

}

.nav-links  {
  
    order: 2;

    display: flex;
  
    align-items: center;
  
    gap: 6px

}

.nav-links a  {
  
    display: inline-flex;
  
    align-items: center;
  
    justify-content: center;
  
    min-height: 42px;
  
    padding: 0 15px;
  
    border-radius: 8px;
  
    color: #33443d;
  
    font-size: 14px;
  
    font-weight: 800;
  
    transition: .2s

}

.nav-links a:hover, .nav-links a.active  {
  
    color: var(--primary);
  
    background: rgba(15, 77, 58, .08)

}

.nav-dropdown {
  
    position: relative

}

.nav-dropdown-toggle {
  
    display: inline-flex;
  
    align-items: center;
  
    justify-content: center;
  
    gap: 8px;
  
    min-height: 42px;
  
    padding: 0 15px;
  
    border: 0;
  
    border-radius: 8px;
  
    background: transparent;
  
    color: #33443d;
  
    font-size: 14px;
  
    font-weight: 800;
  
    cursor: pointer;
  
    transition: .2s

}

.nav-dropdown-toggle:after {
  
    content: "";
  
    width: 7px;
  
    height: 7px;
  
    border-right: 2px solid currentColor;
  
    border-bottom: 2px solid currentColor;
  
    transform: translateY(-2px) rotate(45deg);
  
    transition: transform .2s

}

.nav-dropdown:hover .nav-dropdown-toggle,
.nav-dropdown.open .nav-dropdown-toggle,
.nav-dropdown.active .nav-dropdown-toggle {
  
    color: var(--primary);
  
    background: rgba(15, 77, 58, .08)

}

.nav-dropdown.open .nav-dropdown-toggle:after,
.nav-dropdown:hover .nav-dropdown-toggle:after {
  
    transform: translateY(2px) rotate(225deg)

}

.nav-dropdown-menu {
  
    position: absolute;
  
    top: calc(100% + 10px);
  
    left: 0;
  
    z-index: 1100;
  
    min-width: 230px;
  
    display: none;
  
    padding: 8px;
  
    border: 1px solid rgba(15, 77, 58, .14);
  
    border-radius: 8px;
  
    background: #fff;
  
    box-shadow: 0 22px 48px rgba(15, 77, 58, .18)

}

.nav-dropdown-menu:before {
  
    content: "";
  
    position: absolute;
  
    left: 0;
  
    right: 0;
  
    top: -12px;
  
    height: 12px

}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown.open .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
  
    display: grid;
  
    gap: 6px;
  
    animation: navDropIn .18s ease

}

.nav-dropdown-menu a {
  
    justify-content: flex-start;
  
    width: 100%;
  
    min-height: 40px;
  
    padding: 0 12px

}

.menu-toggle  {

    order: 5;
  
    display: none;
  
    align-items: center;
  
    justify-content: center;
  
    width: 46px;
  
    height: 46px;
  
    border: 1px solid rgba(15, 77, 58, .18);
  
    border-radius: 8px;
  
    background: #fff;
  
    box-shadow: 0 10px 22px rgba(15, 77, 58, .12)

}

.menu-toggle span, .menu-toggle span:before, .menu-toggle span:after  {
  
    display: block;
  
    width: 22px;
  
    height: 2px;
  
    border-radius: 99px;
  
    background: var(--primary);
  
    transition: .2s

}

.menu-toggle span  {
  
    position: relative

}

.menu-toggle span:before, .menu-toggle span:after  {
  
    content: "";
  
    position: absolute;
  
    left: 0

}

.menu-toggle span:before  {
  
    top: -7px

}

.menu-toggle span:after  {
  
    top: 7px

}

.menu-toggle.active  {
  
    background: var(--primary)

}

.menu-toggle.active span  {
  
    background: transparent

}

.menu-toggle.active span:before  {
  
    top: 0;
  
    transform: rotate(45deg);
  
    background: #fff

}

.menu-toggle.active span:after  {
  
    top: 0;
  
    transform: rotate(-45deg);
  
    background: #fff

}

.global-search-toggle  {

    order: 3;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 8px;

    min-height: 44px;

    padding: 0 14px;

    border: 1px solid rgba(15, 77, 58, .14);

    border-radius: 8px;

    background: #f4faf7;

    color: var(--primary);

    font-weight: 900;

    white-space: nowrap;

    box-shadow: 0 10px 20px rgba(15, 77, 58, .08);

    cursor: pointer

}

.global-search-toggle span  {

    display: inline-grid;

    place-items: center;

    width: 24px;

    height: 24px;

    border-radius: 8px;

    background: rgba(15, 77, 58, .1);

    font-size: 0

}

.global-search-toggle span:before  {

    content: "";

    width: 10px;

    height: 10px;

    border: 2px solid currentColor;

    border-radius: 50%;

    box-shadow: 7px 7px 0 -5px currentColor

}

.global-search-toggle:hover  {

    background: var(--primary);

    color: #fff;

    transform: translateY(-1px)

}

.global-search[hidden]  {

    display: none

}

.global-search  {

    position: fixed;

    inset: 0;

    z-index: 2000;

    display: grid;

    place-items: start center;

    padding: 96px 16px 24px

}

.global-search-backdrop  {

    position: fixed;

    inset: 0;

    background: rgba(8, 32, 25, .42);

    backdrop-filter: blur(4px)

}

.global-search-panel  {

    position: relative;

    z-index: 1;

    width: min(760px, 100%);

    max-height: min(720px, calc(100vh - 128px));

    overflow: hidden;

    display: grid;

    grid-template-rows: auto auto minmax(0, 1fr);

    gap: 14px;

    padding: 20px;

    border: 1px solid rgba(15, 77, 58, .14);

    border-radius: 8px;

    background: #fff;

    box-shadow: 0 28px 80px rgba(8, 32, 25, .26)

}

.global-search-head  {

    display: flex;

    align-items: flex-start;

    justify-content: space-between;

    gap: 14px

}

.global-search-head h2  {

    margin: 6px 0 0;

    color: var(--primary);

    font-size: clamp(24px, 4vw, 34px)

}

.global-search-close  {

    min-height: 38px;

    padding: 0 12px;

    border: 1px solid rgba(15, 77, 58, .14);

    border-radius: 8px;

    background: #f4faf7;

    color: var(--primary);

    font-weight: 900

}

.global-search-input  {

    width: 100%;

    min-height: 54px;

    padding: 0 16px;

    border: 1px solid rgba(15, 77, 58, .18);

    border-radius: 8px;

    background: #f8fbfa;

    color: var(--primary);

    font-size: 16px;

    outline: none

}

.global-search-input:focus  {

    border-color: var(--primary);

    box-shadow: 0 0 0 4px rgba(15, 77, 58, .08)

}

.global-search-results  {

    display: grid;

    align-content: start;

    gap: 10px;

    min-height: 0;

    overflow-y: auto;

    padding-right: 4px;

    overscroll-behavior: contain;

    -webkit-overflow-scrolling: touch

}

.global-search-result  {

    display: grid;

    gap: 4px;

    padding: 14px;

    border: 1px solid rgba(15, 77, 58, .1);

    border-radius: 8px;

    background: #fff;

    color: inherit

}

.global-search-result:hover  {

    border-color: rgba(15, 77, 58, .26);

    background: #f4faf7

}

.global-search-result span  {

    color: var(--primary);

    font-size: 12px;

    font-weight: 900;

    letter-spacing: .06em;

    text-transform: uppercase

}

.global-search-suggestions  {

    display: flex;

    flex-wrap: wrap;

    gap: 8px;

    margin-top: -2px

}

.global-search-suggestions button  {

    min-height: 34px;

    padding: 0 12px;

    border: 1px solid rgba(15, 77, 58, .14);

    border-radius: 999px;

    background: #f4faf7;

    color: var(--primary);

    font-size: 13px;

    font-weight: 900;

    cursor: pointer

}

.global-search-suggestions button:hover  {

    background: var(--primary);

    color: #fff

}

.search-type.bantuan  {

    background: rgba(217, 197, 41, .26)

}

.search-type.tools  {

    background: rgba(41, 117, 217, .12)

}

.search-type.update  {

    background: rgba(15, 77, 58, .1)

}

.global-search-result strong  {

    color: var(--primary);

    font-size: 18px

}

.global-search-result small,
.global-search-empty  {

    color: var(--muted);

    line-height: 1.5

}

body.search-open  {

    overflow: hidden

}

.site-footer  {
  
    background: #0c3328;
  
    color: #dbe9e4;
  
    padding: 58px 0 0

}

.footer-grid  {
  
    width: min(1120px, calc(100% - 40px));
  
    margin: auto;
  
    display: grid;
  
    grid-template-columns: 1.4fr .8fr .8fr 1fr;
  
    gap: 28px

}

.footer-brand  {
  
    display: flex;
  
    align-items: center;
  
    gap: 10px;
  
    color: #fff;
  
    font-weight: 900;
  
    font-size: 20px

}

.footer-brand img  {
  
    width: 42px;
  
    height: 42px

}

.site-footer h3  {
  
    margin: 0 0 14px;
  
    color: #fff;
  
    font-size: 15px

}

.site-footer p  {
  
    margin: 12px 0 0;
  
    color: #b9ccc5

}

.site-footer a:not(.footer-brand)  {
  
    display: block;
  
    margin: 8px 0;
  
    color: #cfe0da

}

.site-footer a:hover  {
  
    color: #fff

}

.footer-bottom  {
  
    margin-top: 42px;
  
    padding: 18px clamp(20px, 5vw, 72px);
  
    display: flex;
  
    justify-content: space-between;
  
    gap: 14px;
  
    border-top: 1px solid rgba(255, 255, 255, .12);
  
    color: #a9bdb6;
  
    font-size: 14px

}

body.nav-open  {
  
    overflow: hidden

}

body.nav-open:before  {
  
    content: "";
  
    position: fixed;
  
    inset: 0;
  
    z-index: 998;
  
    background: rgba(15, 77, 58, .28);
  
    backdrop-filter: blur(3px)

}

@media(max-width:820px)  {
  
    .navbar  {
  
        min-height: 82px;
  
        gap: 8px;

        padding: 12px 16px
    
}

    .brand img  {
  
        width: 50px;
  
        height: 50px
    
}

    .brand strong  {
  
        font-size: 20px
    
}

    .brand small  {
  
        max-width: 220px;
  
        font-size: 10px
    
}

    .menu-toggle  {
  
        display: inline-flex;
  
        flex: 0 0 auto
    
}

    .global-search-toggle  {

        min-width: 46px;

        width: 46px;

        height: 46px;

        padding: 0;

        flex: 0 0 auto

}

    .dark-toggle  {

        width: 46px;

        height: 46px

}

    .global-search-toggle b  {

        display: none

}

    .global-search-toggle span  {

        background: transparent

}

    .global-search  {

        padding-top: 88px

}

    .global-search-panel  {

        max-height: calc(100vh - 112px);

        padding: 16px

}

    .nav-links  {
  
        position: fixed;
  
        top: 96px;
  
        left: 14px;
  
        right: 14px;
  
        z-index: 1002;
  
        display: none;
  
        grid-template-columns: 1fr;
  
        gap: 10px;
  
        width: auto;
  
        padding: 14px;
  
        border: 1px solid rgba(15, 77, 58, .14);
  
        border-radius: 8px;
  
        background: linear-gradient(180deg, #fff 0%, #f4faf7 100%);
  
        box-shadow: 0 24px 60px rgba(15, 77, 58, .24);
  
        transform: translateY(-10px) scale(.98);
  
        transform-origin: top right
    
}

    .nav-links.active  {
  
        display: grid;
  
        animation: navDropIn .22s ease both
    
}

    .nav-links:before  {
  
        content: "Menu SIPIL CARE";
  
        display: block;
  
        padding: 6px 8px 10px;
  
        color: var(--primary);
  
        font-size: 13px;
  
        font-weight: 900;
  
        letter-spacing: .08em;
  
        text-transform: uppercase
    
}

    .nav-links a  {
  
        justify-content: space-between;
  
        min-height: 54px;
  
        padding: 0 16px 0 18px;
  
        border: 1px solid rgba(15, 77, 58, .1);
  
        border-left: 5px solid var(--primary);
  
        background: #fff;
  
        box-shadow: 0 10px 20px rgba(15, 77, 58, .08);
  
        font-size: 16px
    
}

    .nav-dropdown  {

        display: grid

}

    .nav-dropdown-toggle  {

        justify-content: space-between;

        width: 100%;

        min-height: 54px;

        padding: 0 16px 0 18px;

        border: 1px solid rgba(15, 77, 58, .1);

        border-left: 5px solid var(--primary);

        background: #fff;

        box-shadow: 0 10px 20px rgba(15, 77, 58, .08);

        font-size: 16px

}

    .nav-dropdown-menu  {

        position: static;

        min-width: 0;

        margin: 8px 0 0 12px;

        padding: 8px;

        box-shadow: none;

        background: rgba(255, 255, 255, .72)

}

    .nav-dropdown-menu:before  {

        display: none

}

    .nav-dropdown:hover .nav-dropdown-menu  {

        display: none

}

    .nav-dropdown.open .nav-dropdown-menu,
    .nav-dropdown:focus-within .nav-dropdown-menu  {

        display: grid

}

    .nav-dropdown-menu a  {

        min-height: 48px;

        border-left-width: 3px;

        box-shadow: none;

        font-size: 15px

}

    .nav-links a:after  {
  
        content: ">";
  
        display: grid;
  
        place-items: center;
  
        width: 28px;
  
        height: 28px;
  
        border-radius: 50%;
  
        background: rgba(217, 197, 41, .28);
  
        color: var(--primary)
    
}

    .footer-grid  {
  
        grid-template-columns: 1fr
    
}

    .footer-bottom  {
  
        flex-direction: column
    
}

}

@media(min-width:821px) and (max-width:1120px)  {

    .navbar  {

        gap: 10px;

        padding-inline: 20px

}

    .brand small  {

        max-width: 190px

}

    .nav-links  {

        gap: 3px

}

    .nav-links a  {

        padding: 0 9px;

        font-size: 13px

}

    .global-search-toggle  {

        width: 44px;

        min-width: 44px;

        padding: 0

}

    .global-search-toggle b  {

        display: none

}

}

@keyframes navDropIn  {
  
    from  {
  
        opacity: 0;
  
        transform: translateY(-10px) scale(.98)
    
}

    to  {
  
        opacity: 1;
  
        transform: translateY(0) scale(1)
    
}

}

.student-logout, .student-password, .student-social, .student-login-link {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:42px;
  padding:0 15px;
  border:1px solid rgba(15, 77, 58, .14);
  border-radius:8px;
  background:#fff;
  color:var(--primary);
  font-weight:900
}

.student-logout:hover, .student-password:hover, .student-social:hover, .student-login-link:hover {
  background:var(--primary);
  color:#fff
}

.student-login-choice {
  position: relative;
  display: inline-flex;
}

.student-login-choice .student-login-link {
  cursor: pointer;
}

.student-login-choice-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: min(260px, calc(100vw - 32px));
  display: none;
  padding: 8px;
  border: 1px solid rgba(15, 77, 58, .14);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 22px 48px rgba(15, 77, 58, .18);
  z-index: 1200;
}

.student-login-choice.open .student-login-choice-menu {
  display: grid;
  gap: 6px;
  animation: navDropIn .18s ease;
}

.student-login-choice-menu a {
  display: grid !important;
  gap: 2px;
  margin: 0 !important;
  padding: 11px 12px;
  border-radius: 8px;
  color: var(--primary) !important;
  text-align: left;
}

.student-login-choice-menu a:hover {
  background: rgba(15, 77, 58, .08);
  color: var(--primary) !important;
}

.student-login-choice-menu strong {
  font-size: 14px;
  line-height: 1.2;
}

.student-login-choice-menu span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

@media(max-width:820px) {
  .student-logout, .student-password, .student-social, .student-login-link {
  width:100%;
  justify-content:space-between;
  min-height:54px;
  border-left:5px solid var(--primary);
  box-shadow:0 10px 20px rgba(15, 77, 58, .08)
}

  .student-login-choice {
    width: 100%;
  }

  .student-login-choice-menu {
    position: static;
    width: 100%;
    margin-top: 8px;
    box-shadow: 0 12px 24px rgba(15, 77, 58, .12);
  }

}

.floating-socials {
  position: fixed;
  right: clamp(14px, 2.5vw, 28px);
  bottom: clamp(18px, 4vw, 34px);
  z-index: 950;
  display: grid;
  gap: 10px;
  pointer-events: none;
}

.floating-social {
  width: 52px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .36);
  box-shadow: 0 18px 34px rgba(12, 51, 40, .24);
  pointer-events: auto;
  transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}

.floating-social svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.floating-social.instagram {
  background: radial-gradient(circle at 30% 110%, #fdf497 0 18%, #fd5949 42%, #d6249f 68%, #285aeb 100%);
}

.floating-social.youtube {
  background: #ff0033;
}

.floating-social:hover {
  transform: translateY(-4px) scale(1.04);
  box-shadow: 0 22px 42px rgba(12, 51, 40, .3);
  filter: saturate(1.08);
}

.floating-social:focus-visible {
  outline: 3px solid rgba(217, 197, 41, .9);
  outline-offset: 4px;
}

.floating-help {
  position: fixed;
  left: clamp(14px, 2.5vw, 28px);
  bottom: clamp(18px, 4vw, 34px);
  z-index: 951;
  min-width: 58px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, .36);
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), #238464);
  color: #fff;
  box-shadow: 0 18px 34px rgba(12, 51, 40, .24);
  font-weight: 900;
  transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}

.floating-help span {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, .18);
  font-size: 17px;
  line-height: 1;
}

.floating-help b {
  font-size: 13px;
  letter-spacing: .04em;
}

.floating-help:hover {
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 22px 42px rgba(12, 51, 40, .3);
  filter: saturate(1.08);
}

.floating-help:focus-visible {
  outline: 3px solid rgba(217, 197, 41, .9);
  outline-offset: 4px;
}

@media(max-width:820px) {
  .floating-socials {
    right: 14px;
    bottom: 16px;
    gap: 8px;
  }

  .floating-social {
    width: 46px;
    height: 46px;
  }

  .floating-social svg {
    width: 22px;
    height: 22px;
  }

  .floating-help {
    left: 14px;
    bottom: 16px;
    height: 46px;
    min-width: 46px;
    padding: 0 11px;
  }

  .floating-help b {
    display: none;
  }

  .floating-help span {
    width: 22px;
    height: 22px;
    font-size: 16px;
  }
}

.student-account {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.student-account-toggle {
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(15, 77, 58, .16);
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), #238464);
  color: #fff;
  box-shadow: 0 12px 24px rgba(15, 77, 58, .16);
  cursor: pointer;
}

.student-account-toggle span {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, .16);
  color: #fff;
  font-size: 14px;
  font-weight: 900;
}

.student-account-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: min(280px, calc(100vw - 32px));
  display: none;
  padding: 10px;
  border: 1px solid rgba(15, 77, 58, .14);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 22px 48px rgba(15, 77, 58, .18);
  z-index: 1200;
}

.student-account.open .student-account-menu {
  display: grid;
  gap: 8px;
  animation: navDropIn .18s ease;
}

.student-account-info {
  padding: 12px;
  border-radius: 8px;
  background: var(--soft);
}

.student-account-info strong,
.student-account-info span {
  display: block;
  overflow-wrap: anywhere;
}

.student-account-info strong {
  color: var(--primary);
  font-size: 15px;
  line-height: 1.25;
}

.student-account-info span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.student-account-action {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--primary);
  text-align: left;
  font-weight: 900;
  cursor: pointer;
}

.student-account-action:hover {
  background: rgba(15, 77, 58, .08);
}

.student-account-action.danger {
  color: #b42318;
}

.student-account-action.danger:hover {
  background: rgba(180, 35, 24, .08);
}

@media(max-width:820px) {
  .student-account {
    width: 100%;
    justify-content: flex-end;
  }

  .student-account-toggle {
    width: 52px;
    height: 52px;
  }

  .student-account-menu {
    top: calc(100% + 8px);
    right: 0;
  }
}

/* ===== DARK MODE TOGGLE BUTTON ===== */
.dark-toggle {
  order: 4;
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(15, 77, 58, .18);
  border-radius: 999px;
  background: var(--soft, #edf4f1);
  color: var(--primary);
  box-shadow: 0 10px 20px rgba(15, 77, 58, .08);
  cursor: pointer;
  transition: background .2s, color .2s, border-color .2s, transform .2s;
  flex-shrink: 0;
}

.dark-toggle:hover {
  background: var(--primary);
  color: #fff;
  transform: scale(1.08);
}

.dark-toggle svg {
  width: 20px;
  height: 20px;
  transition: opacity .15s;
}

/* hide/show icons based on mode */
.dark-toggle .icon-moon { display: block; }
.dark-toggle .icon-sun  { display: none; }
html.dark .dark-toggle .icon-moon { display: none; }
html.dark .dark-toggle .icon-sun  { display: block; }

/* dark mode navbar */
html.dark .navbar {
  background: rgba(14, 26, 22, .95);
  border-bottom-color: rgba(74, 222, 154, .1);
  box-shadow: 0 12px 28px rgba(0,0,0,.3);
}

html.dark .brand strong { color: var(--primary); }
html.dark .brand small  { color: #6b9e8d; }

html.dark .nav-links a {
  color: #b0cfc5;
}

html.dark .nav-links a:hover,
html.dark .nav-links a.active {
  color: var(--primary);
  background: rgba(74, 222, 154, .1);
}

html.dark .nav-dropdown-toggle {
  color: #b0cfc5;
}

html.dark .nav-dropdown:hover .nav-dropdown-toggle,
html.dark .nav-dropdown.open .nav-dropdown-toggle,
html.dark .nav-dropdown.active .nav-dropdown-toggle {
  color: var(--primary);
  background: rgba(74, 222, 154, .1);
}

html.dark .nav-dropdown-menu {
  background: #162520;
  border-color: rgba(74, 222, 154, .14);
  box-shadow: 0 22px 48px rgba(0, 0, 0, .32);
}

html.dark .menu-toggle {
  background: #162520;
  border-color: rgba(74, 222, 154, .18);
}

html.dark .menu-toggle span,
html.dark .menu-toggle span:before,
html.dark .menu-toggle span:after {
  background: var(--primary);
}

html.dark .menu-toggle.active {
  background: var(--primary);
}

html.dark .menu-toggle.active span { background: transparent; }
html.dark .menu-toggle.active span:before,
html.dark .menu-toggle.active span:after { background: #0e1a16; }

html.dark .global-search-toggle,
html.dark .global-search-close {
  background: #1a2e27;
  color: var(--primary);
  border-color: rgba(74, 222, 154, .18);
}

html.dark .global-search-panel,
html.dark .global-search-result {
  background: #162520;
  border-color: rgba(74, 222, 154, .14);
}

html.dark .global-search-input {
  background: #1a2e27;
  color: var(--primary);
  border-color: rgba(74, 222, 154, .18);
}

html.dark .global-search-result:hover {
  background: #1a2e27;
}

html.dark .nav-links {
  background: linear-gradient(180deg, #162520 0%, #132219 100%);
  border-color: rgba(74, 222, 154, .12);
}

html.dark .nav-links a {
  background: #1a2e27;
  border-color: rgba(74, 222, 154, .1);
  border-left-color: var(--primary);
}

html.dark .nav-dropdown-toggle {
  background: #1a2e27;
  border-color: rgba(74, 222, 154, .1);
  border-left-color: var(--primary);
}

html.dark .dark-toggle {
  background: #1a2e27;
  border-color: rgba(74, 222, 154, .2);
  color: var(--primary);
}

html.dark .student-account-menu {
  background: #162520;
  border-color: rgba(74, 222, 154, .14);
}

html.dark .student-login-choice-menu {
  background: #162520;
  border-color: rgba(74, 222, 154, .14);
}

html.dark .student-login-choice-menu a:hover {
  background: rgba(74, 222, 154, .1);
}

html.dark .student-login-choice-menu span {
  color: #9fb6ad;
}

html.dark .student-account-info {
  background: #1a2e27;
}

html.dark .student-account-action {
  color: var(--primary);
}

html.dark .student-account-action:hover {
  background: rgba(74, 222, 154, .1);
}

html.dark .student-account-action.danger { color: #f87171; }
html.dark .student-account-action.danger:hover { background: rgba(248, 113, 113, .1); }

html.dark .student-logout,
html.dark .student-password,
html.dark .student-social,
html.dark .student-login-link {
  background: #1a2e27;
  color: var(--primary);
  border-color: rgba(74, 222, 154, .18);
}

html.dark .student-logout:hover,
html.dark .student-password:hover,
html.dark .student-social:hover,
html.dark .student-login-link:hover {
  background: var(--primary);
  color: #0e1a16;
}

@media(max-width:820px) {
  .dark-toggle {
    width: 46px;
    height: 46px;
  }
}

/* ===== GREETING BAR ===== */
.student-greeting-bar {
  background: linear-gradient(90deg, var(--primary, #0f4d3a), #1a6b52);
  color: #fff;
  padding: 0;
}

.student-greeting-inner {
  width: min(1120px, calc(100% - 40px));
  margin: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
}

.student-greeting-avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255,255,255,.2);
  font-size: 14px;
  font-weight: 900;
  flex-shrink: 0;
}

.student-greeting-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1;
  min-width: 0;
}

.student-greeting-text strong {
  font-size: 14px;
  font-weight: 900;
  line-height: 1.2;
  color: #fff;
}

.student-greeting-text small {
  font-size: 12px;
  color: rgba(255,255,255,.72);
}

.student-greeting-tag {
  font-size: 12px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.16);
  color: #d9f7e8;
  white-space: nowrap;
  flex-shrink: 0;
}

html.dark .student-greeting-bar {
  background: linear-gradient(90deg, #0a2e22, #0f3d2c);
}

@media(max-width:680px) {
  .student-greeting-tag { display: none; }
  .student-greeting-text small { display: none; }
}

/* ===== NOTIFICATION BADGE on toggle button ===== */
.student-account-toggle {
  position: relative;
}

.student-notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: #e53935;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  display: grid;
  place-items: center;
  border: 2px solid #fff;
  line-height: 1;
  animation: badgePop .3s ease;
}

html.dark .student-notif-badge {
  border-color: #0e1a16;
}

@keyframes badgePop {
  0% { transform: scale(0); }
  70% { transform: scale(1.2); }
  100% { transform: scale(1); }
}

/* ===== UPGRADED ACCOUNT MENU ===== */
.student-account-avatar-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.student-account-avatar-big {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary, #0f4d3a), #238464);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 20px;
  font-weight: 900;
  flex-shrink: 0;
}

.student-account-info strong {
  display: block;
  color: var(--primary, #0f4d3a);
  font-size: 14px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.student-account-info span {
  display: block;
  margin-top: 3px;
  color: var(--muted, #63736d);
  font-size: 12px;
  font-weight: 800;
}

.student-account-status {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  font-size: 12px;
  color: #16a34a;
  font-weight: 700;
}

.student-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #16a34a;
  box-shadow: 0 0 0 3px rgba(22,163,74,.18);
  display: inline-block;
  flex-shrink: 0;
}

.student-account-divider {
  height: 1px;
  background: var(--line, #dce6e2);
  margin: 4px 0;
}

/* ===== NOTIFICATION ROW in menu ===== */
.student-notif-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  transition: background .15s;
}

.student-notif-row:hover {
  background: rgba(15,77,58,.07);
}

.student-notif-icon {
  font-size: 16px;
  flex-shrink: 0;
}

.student-notif-label {
  flex: 1;
  font-size: 14px;
  font-weight: 800;
  color: var(--primary, #0f4d3a);
}

.student-notif-badge-menu {
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: #e53935;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

/* Dark mode overrides for new elements */
html.dark .student-account-info strong { color: var(--primary); }
html.dark .student-account-info span { color: var(--muted); }
html.dark .student-account-divider { background: var(--line); }
html.dark .student-notif-label { color: var(--primary); }
html.dark .student-notif-row:hover { background: rgba(74,222,154,.08); }
html.dark .student-account-avatar-big { background: linear-gradient(135deg, #0f4d3a, #1a6b52); }

.student-push-preferences {
  display: grid;
  gap: 10px;
  padding: 10px 0;
}

.student-push-preferences strong {
  color: var(--primary);
  font-size: 13px;
}

.student-push-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.student-push-options label {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
}

.student-push-options input {
  accent-color: var(--primary);
}

@media (max-width: 520px) {
  .student-push-options {
    grid-template-columns: 1fr;
  }
}

.maintenance-active body {
  overflow: hidden;
}

.maintenance-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(rgba(15, 77, 58, .86), rgba(15, 77, 58, .9)),
    url('../assets/images/engineering-bg.png') center/cover;
}

.maintenance-dialog {
  width: min(520px, 100%);
  padding: 32px;
  border-radius: 16px;
  background: #fff;
  border: 1px solid rgba(255,255,255,.4);
  box-shadow: 0 28px 70px rgba(0,0,0,.22);
  text-align: center;
}

.maintenance-dialog img {
  width: 78px;
  height: 78px;
  object-fit: contain;
  margin-bottom: 14px;
}

.maintenance-dialog span {
  color: #c8a600;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.maintenance-dialog h1 {
  margin: 10px 0;
  color: #0f4d3a;
  font-size: clamp(28px, 5vw, 44px);
  line-height: 1.05;
}

.maintenance-dialog p {
  margin: 0;
  color: #435650;
  line-height: 1.7;
}
