::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(16, 114, 58, 0.35);
    border-radius: 0; /* was 4px */
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(16, 114, 58, 0.6);
}

body.is-scrolling::-webkit-scrollbar-thumb {
    background: rgba(16, 114, 58, 0.5);
}

body.is-scrolling::-webkit-scrollbar-thumb:hover {
    background: rgba(16, 114, 58, 0.7);
}

html, body {
    height: 100%;
    overflow: hidden; /* prevent body from scrolling */
}

/* =========================
   GLOBAL
========================= */
*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    overflow-x: hidden;
    background-color: #f7f7fa;
    font-family: "Ubuntu", sans-serif;
}

/* =========================
   LAYOUT
========================= */
.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    padding-top: 80px;
    padding-bottom: 40px;
    padding-left: clamp(16px, 5vw, 40px);
    padding-right: clamp(16px, 5vw, 40px);
    height: 100%;
    overflow-y: scroll; /* scroll happens here, below nav */
    padding-top: 60px; /* match nav height */
}

.container::-webkit-scrollbar-thumb {
    background: rgba(16, 114, 58, 0.35);
    border-radius: 0; /* was 4px */
}

.container::-webkit-scrollbar-thumb:hover {
    background: rgba(16, 114, 58, 0.6);
}

.content {
    width: 100%;
    max-width: 520px;
    margin-top: 32px;
}

/* =========================
   NAVBAR
========================= */
.top-nav {
    width: 100%;
    background-color: #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 10px clamp(24px, 6vw, 96px); /* match login */

    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;

    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: transform 180ms ease;
}

.top-nav--hidden {
    transform: translateY(-110%);
}

.top-nav-left,
.top-nav-right {
    display: flex;
    align-items: center;
    font-size: larger;
}

.top-nav-right {
    gap: 16px;
}

.top-nav a {
    color: #111;
    text-decoration: none;
    font-family: "Rokkitt", sans-serif;
    font-weight: 600;
}

.top-nav a:hover {
    text-decoration: underline;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: inherit;
}

.logo {
    height: 40px; /* match login */
}

/* =========================
   MAIN CARD
========================= */
.login-form {
    width: 100%;
    padding: clamp(24px, 5vw, 40px);
    border-radius: 20px;
    border: 1px solid #e5e5e5;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
    background-color: #ffffff;
}

/* =========================
   HEADINGS
========================= */
h1 {
    margin: 0 0 16px 0;
    font-family: "Ubuntu", sans-serif;
    font-size: clamp(22px, 5vw, 28px);
}

h2 {
    margin-top: 20px;
    font-family: "Ubuntu", sans-serif;
    font-size: 16px;
}

/* =========================
   STATUS
========================= */
.status-open {
    font-size: 18px;
    font-weight: bold;
    color: #2e7d32;
    margin: 0 0 8px 0;
}

.status-closed {
    font-size: 18px;
    font-weight: bold;
    color: #c62828;
    margin: 0 0 8px 0;
}

.session-info {
    font-size: 13px;
    color: #555;
    margin-bottom: 16px;
    line-height: 1.6;
}

hr {
    border: none;
    border-top: 1px solid #eee;
    margin: 20px 0;
}

/* =========================
   LABEL
========================= */
label {
    display: block;
    font-size: 12px;
    color: #888;
    margin-bottom: 4px;
    font-family: "Ubuntu", sans-serif;
}

/* =========================
   INPUT
========================= */
input[type="text"] {
    width: 100%;
    padding: 10px 2px;
    margin-bottom: 16px;
    border: none;
    border-bottom: 1px solid #ccc;
    font-size: 15px;
    background: transparent;
    outline: none;
    font-family: "Ubuntu", sans-serif;
}

input[type="text"]:focus {
    border-bottom-color: #10723a;
}

/* =========================
   BUTTONS
========================= */
button {
    width: 100%;
    padding: 13px 0;
    border: none;
    border-radius: 999px;
    background: linear-gradient(90deg, #10723a, #54b11b);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    font-family: "Ubuntu", sans-serif;
    transition: opacity 0.2s;
}

button:hover {
    opacity: 0.9;
}

.secondary-btn {
    margin-top: 12px;
    background: #ffffff;
    color: #10723a;
    border: 1px solid #10723a;
}

.secondary-btn:hover {
    background: #f0f8f3;
    opacity: 1;
}

/* =========================
   MESSAGE
========================= */
#message {
    font-size: 13px;
    font-family: "Ubuntu", sans-serif;
    min-height: 18px;
    margin-top: 8px;
    margin-bottom: 0;
}

/* =========================
   LIST
========================= */
.attendee-list {
    list-style: none;
    padding: 0;
    margin: 8px 0 0 0;
    font-family: "Ubuntu", sans-serif;
    font-size: 14px;
}

.attendee-list li {
    padding: 9px 0;
    border-bottom: 1px solid #eee;
}

/* =========================
   TABLE
========================= */
.detailed-log {
    margin-top: 8px;
    overflow-x: auto; /* scroll on very small screens */
}

.attendance-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 8px;
    font-size: 13px;
    font-family: "Ubuntu", sans-serif;
}

.attendance-table th,
.attendance-table td {
    padding: 8px 6px;
    border-bottom: 1px solid #eee;
    text-align: left;
    white-space: nowrap;
}

.attendance-table th {
    color: #555;
    font-weight: 700;
    font-size: 12px;
}

/* =========================
   UTIL
========================= */
.hidden {
    display: none;
}

/* =========================
   MOBILE
========================= */
@media (max-width: 480px) {
    .login-form {
        border-radius: 14px;
        padding: 24px 20px;
    }

    h1 {
        font-size: 20px;
    }

    /* removed smaller nav text override to keep consistent with login */
}

.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
}

.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: #111;
    border-radius: 2px;
    transition: transform 200ms ease, opacity 200ms ease;
    transform-origin: center;
}

.hamburger.is-open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger.is-open span:nth-child(2) {
    opacity: 0;
}

.hamburger.is-open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 600px) {
    .hamburger {
        display: flex;
    }

    .top-nav-right {
        display: none;
        position: absolute;
        top: 100%;
        right: 0;
        background: #ffffff;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
        border-radius: 0 0 14px 14px;
        flex-direction: column;
        padding: 12px 0;
        min-width: 180px;
        z-index: 999;
    }

    .top-nav-right.nav-open {
        display: flex;
    }

    .top-nav-right a {
        padding: 10px 24px;
        font-size: 16px;
    }

    .top-nav-right a:hover {
        background: #f4f4f4;
        text-decoration: none;
    }
}

.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
}

.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: #111;
    border-radius: 2px;
    transition: transform 200ms ease, opacity 200ms ease;
    transform-origin: center;
}

.hamburger.is-open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger.is-open span:nth-child(2) {
    opacity: 0;
}

.hamburger.is-open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 600px) {
    .hamburger {
        display: flex;
    }

    .top-nav-right {
        display: none;
        position: absolute;
        top: 100%;
        right: 0;
        background: #ffffff;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
        border-radius: 0 0 14px 14px;
        flex-direction: column;
        padding: 12px 0;
        min-width: 180px;
        z-index: 999;
    }

    .top-nav-right.nav-open {
        display: flex;
    }

    .top-nav-right a {
        padding: 10px 24px;
        font-size: 16px;
    }

    .top-nav-right a:hover {
        background: #f4f4f4;
        text-decoration: none;
    }
}