 /* NAVBAR */
.topnav {
    background: var(--primary);
    position: relative;
}

/* Hide nav links by default on mobile */
.nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
}

/* Show menu when responsive class is added */
.topnav.responsive .nav-links {
    display: flex;
}

/* Navigation links */
.topnav a {
    color: white;
    padding: 14px 16px;
    text-decoration: none;
    display: block;
}

/* Hamburger icon */
.topnav .icon {
    display: block;
    color: white;
    font-size: 24px;
    padding: 14px 16px;
    cursor: pointer;
    margin-left: auto;
}

/* DESKTOP VIEW */
@media screen and (min-width: 769px) {

    .topnav {
        display: flex;
        align-items: center;
    }

    .nav-links {
        display: flex !important;
        flex-direction: row;
        align-items: center;
        width: 100%;
    }

    .topnav .icon {
        display: none;
    }

    .nav-right {
        margin-left: auto;
    }
}
/* Add these to your main stylesheet if not already there */
    .drop-item-btn {
        width: 100%; 
        text-align: left; 
        padding: 12px; 
        border: none; 
        background: #f8f9fa; 
        border-radius: 8px; 
        margin-bottom: 10px; 
        cursor: pointer;
        font-family: inherit;
        font-size: 14px;
        transition: 0.2s;
    }
    .drop-item-btn:hover { background: #eee; }
    
    .btn-notify-style { background: #f0f7f4; color: var(--primary); font-weight: 600; }
    .btn-delete-style { background: #fff1f0; color: var(--danger); }
    .btn-logout { background: #fff1f0; color: #000080;; }
     .btn-logout-style { background: #fff1f0; color:black  }
     
/* =========================
   LOGO AREA
========================= */

.logo-container {
    padding: 15px 5%;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo-container img {
    height: 50px;
}

/* =========================
   NAV DROPDOWN
========================= */
.nav-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #ffffff;
    min-width: 200px;
    box-shadow: 0px 8px 16px rgba(0,0,0,0.1);
    z-index: 1100;
    border-radius: 0 0 8px 8px;
    overflow: hidden;
}

.dropdown-content a {
    color: var(--dark) !important;
    padding: 12px 16px !important;
    text-decoration: none;
    display: block;
    text-align: left;
    border-bottom: 1px solid #f1f1f1;
    font-size: 10px;
}

.dropdown-content a:hover {
    background-color: #f9f9f9;
    color: var(--primary) !important;
}

/* Desktop hover */
@media (min-width: 769px) {
    .nav-dropdown:hover .dropdown-content {
        display: block;
    }
}

/* =========================
   HERO
========================= */
.hero {
    background: linear-gradient(135deg, var(--primary), #1e5d3b);
    color: white;
    padding: 60px 5%;
    text-align: center;
}

.hero h1 {
    font-size: 2.5rem;
    margin: 0 0 10px 0;
    font-weight: 800;
}

/* =========================
   LAYOUT
========================= */
.main-wrapper {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

.card {
    background: var(--white);
    padding: 30px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    margin-top: 40px;
    margin-bottom: 30px;
}

/* =========================
   FORM
========================= */
.test-code-form {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.test-code-form input[type="text"] {
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #ddd;
    width: 100%;
    max-width: 300px;
    font-size: 16px;
}

/* =========================
   BUTTON
========================= */
.btn-main {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    padding: 12px 28px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(46, 139, 87, 0.3);
    text-transform: uppercase;
    max-width: 300px;
}

/* =========================
   GRID
========================= */


.quiz-box {
    background: #fff;
    padding: 25px;
    border-radius: 12px;
    border-left: 5px solid var(--primary);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: var(--transition);
}

.quiz-box:hover {
    transform: translateY(-5px);
}

.quiz-title {
    font-size: 1.25rem;
    color: var(--primary);
    font-weight: bold;
    text-decoration: none;
}

/* =========================
   USER DROPDOWN
========================= */
.user-dropdown {
    display: none;
    position: fixed;
    top: 65px;
    right: 5%;
    background: #fff;
    width: 280px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    z-index: 1001;
    padding: 20px;
}

.user-dropdown.active {
    display: block;
}



/* =========================
   NOTIFICATION BADGE
========================= */
.notif-badge {
    background: var(--danger);
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    position: absolute;
    top: 12px;
    right: 5px;
}

            /* Modal overlay styling */
.modal-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1002;
}

.modal-content {
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  width: 90%;
  max-width: 400px;
  max-height: 70vh;
  overflow-y: auto;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  position: relative;
}

.modal-content h2 {
  margin-top: 0;
  border-bottom: 1px solid #ddd;
  padding-bottom: 8px;
}

.close-btn {
  position: absolute;
  top: 10px; right: 17px;
  font-size: 24px;
  cursor: pointer;
  color: #888;
}

.close-btn:hover {
  color: #333;
}

.notification-item {
  background: #f9f9f9;
  border-radius: 8px;
  padding: 10px;
  margin-bottom: 8px;
  border-left: 4px solid #007bff;
}

/* =========================
   MOBILE
========================= */
@media (max-width: 768px) {


    /* DROPDOWN MOBILE */
    .dropdown-content {
        position: static;
        display: block;
        background: rgba(0,0,0,0.05);
        box-shadow: none;
        width: 100%;
    }

    .dropdown-content a {
        color: white !important;
        padding-left: 40px !important;
    }

    .hero h1 {
        font-size: 1.8rem;
    }

    .card {
        margin-top: 20px;
        padding: 20px;
    }

    .test-code-form {
        flex-direction: column;
    }

    .test-code-form input,
    .btn-main {
        width: 90%;
        max-width: 90%;
    }


    .user-dropdown {
        width: 80%;
        left: 5%;
        right: 5%;
        top: 60px;
    }
}

/* =========================
   ANIMATION
========================= */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
