@font-face {
    font-family: 'Montserrat';
    src: url('/core/static/fonts/Montserrat-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
  }
  
  @font-face {
    font-family: 'Montserrat';
    src: url('/core/static/fonts/Montserrat-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
  }
  
  @font-face {
    font-family: 'Montserrat';
    src: url('/core/static/fonts/Montserrat-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
  }
  
  @font-face {
    font-family: 'Montserrat';
    src: url('/core/static/fonts/Montserrat-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
  }
  
  @font-face {
    font-family: 'Montserrat';
    src: url('/core/static/fonts/Montserrat-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
  }





  *,
  *::before,
  *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }

body {
    font-family: 'Montserrat', system-ui, -apple-system, sans-serif;
    color: #111;
}

/* ===== NAVBAR ===== */
.navbar {
    background: #f8fbff;
    border-bottom: 1px solid #e6e6e6;
}

.navbar-container {
    width: 93%;
    max-width: 3200px;
    margin: 0 auto;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar-left img {
    height: 3em;
}

.navbar-center {
    flex: 1;
    max-width: 50vw;
}

.search-form {
    display: flex;
    align-items: center;
    background: #fff;
    border-radius: 999px;
    padding: 6px 12px;
    border: 1px solid #dcdcdc;
}

.search-form input {
    flex: 1;
    border: none;
    outline: none;
    padding: 8px;
}

.search-form button {
    background: none;
    border: none;
    cursor: pointer;
}

.search-form img {
    height: 18px;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-item {
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    color: #111;
}

.nav-item img {
    height: 2em;
}

.badge {
    position: absolute;
    top: -4px;
    right: -3px;
    background: red;
    color: white;
    font-size: 0.7em;
    padding: 2px 6px;
    border-radius: 50%;
}

/* =============== TOASTS =============== */
#toast-container {
    position: fixed;
    top: 5rem;
    right: 1rem;
    display: flex;
    flex-direction: column;
    gap: .5rem;
    z-index: 9999;
  }
  .toast {
    min-width: 200px;
    max-width: 300px;
    padding: .75rem 1rem;
    border-radius: .25rem;
    color: #fff;
    font-size: .9rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    opacity: 0;
    transform: translateY(-20px);
    animation: slideDown .3s forwards;
  }
  .toast.success { background-color: #28a745; }
  .toast.error   { background-color: #dc3545; }
  .toast.warning { background-color: #ffc107; color: #212529; }
  .toast.info    { background-color: #17a2b8; }

  @keyframes slideDown {
    from {
      opacity: 0;
      transform: translateY(-20px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  @keyframes fadeOut {
    from {
      opacity: 1;
      transform: translateY(0);
    }
    to {
      opacity: 0;
      transform: translateY(-10px);
    }
  }
  

/* ===== CONTENT ===== */
.page-content {
    min-height: 60vh;
    padding: 0 0 32px 0;
}

/* ===== FOOTER ===== */
.footer {
    background: radial-gradient(circle at top, #101b33, #060b18);
    color: #cbd5e1;
}

.footer-container {
    margin: 0 auto;
    padding: 48px 32px;
    display: flex;
    gap: 32px;
    justify-content: space-around;
    font-size: 0.8em;
}

.footer-column {
    display: flex;
    flex-direction: column;
    gap: 1em;
}
.right {
    flex-direction: row;
    align-items: center;
    gap: 2em;
}

.footer h4 {
    color: #fff;
    margin-bottom: 16px;
}

.footer ul {
    list-style: none;
}

.footer li {
    margin-bottom: 10px;
}

.footer a {
    color: #cbd5e1;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

.social-icons {
    display: flex;
    gap: 1em;
}

.social-icons img {
    height: 32px;
}

.footer-bottom {
    text-align: center;
    padding: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 14px;
}


/* ===== SEARCH DROPDOWN ===== */
.search-form {
    position: relative;
}

.search-results {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
    z-index: 1000;
    overflow: hidden;
}

.search-result-item {
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.search-result-item a {
    text-decoration: none;
    color: #111;
    display: block;
}

.search-result-item small {
    color: #64748b;
    font-size: 12px;
}

.search-result-item:hover,
.search-result-item.active {
    background: #f1f5f9;
}

/* highlight matched text */
.search-highlight {
    background: #fff3c4;
    font-weight: 600;
    border-radius: 3px;
    padding: 0 2px;
}
.mobile-search-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-search-toggle img {
    height: 2em;
}
.mobile-search-container {
    display: none;
    padding: 8px 16px;
    border-bottom: 1px solid #e6e6e6;
    background: #f8fbff;
}
.user-menu {
    position: relative;
    cursor: pointer;
  }
  
  .user-dropdown {
    position: absolute;
    right: 0;
    top: 100%;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    min-width: 160px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
    display: none;
    z-index: 1000;
  }
  
  .user-dropdown a {
    display: block;
    padding: 10px 14px;
    text-decoration: none;
    color: #333;
  }
  
  .user-dropdown a:hover {
    background: #f5f5f5;
  }

  .footer p {
    display: flex;
    flex-direction: row;
    gap: 5px;
    align-items: center;
  }
  html {
    scroll-behavior: smooth;
  }






















@media (min-width: 1025px) {
.user-menu:hover .user-dropdown {
    display: block;
}

.user-greeting {
    display: none;
}
}



@media (max-width: 1023px) {
    .navbar-container {
        padding: 12px 0;
    }
    .navbar-left img {
        height: 2em;
    }
    .navbar-center {
        display: none;
    }
    .mobile-search-toggle {
        display: block;
    }
    .mobile-search-container.open {
        display: block;
    }
    .nav-user-name {
        display: none;
    }
    .footer-container {
        display: flex;
        flex-direction: column-reverse;
    }
    .footer li {
        font-size: 0.8em;
        margin-bottom: 5px;
    }
    .footer-column {
        gap: 1em;
    }
    .footer p {
        font-size: 0.8em;
    }
    .footer h4 {
        margin-bottom: 0;
    }
    .user-dropdown {
        position: fixed;
        top: 64px;
        right: 10px;
        display: none;
    }

    .user-menu.active .user-dropdown {
        display: block;
    }

    .user-greeting {
        padding: 12px 14px;
        font-weight: 600;
        border-bottom: 1px solid #eee;
    }

}