/* Student Portal - style sheet
   Colour theme: deep navy blue + bright blue accent + green for bars
   (only colours - the CSS is still basic and easy to explain) */

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

body { font-family: Arial, sans-serif; background: #eef3f9; color: #222; }

a { color: #1f4e79; }

/* ---------- Layout : sidebar + content ---------- */
.layout { display: flex; min-height: 100vh; }

.sidebar { width: 200px; background: #1f4e79; color: white; padding: 15px; }
.sidebar .logo { font-size: 19px; font-weight: bold; text-align: center; padding: 10px 0 15px 0; border-bottom: 1px solid #2e86de; margin-bottom: 15px; }
.sidebar a { display: block; color: white; text-decoration: none; padding: 9px 10px; margin-bottom: 4px; }
.sidebar a:hover { background: #2e86de; }
.sidebar a.active { background: #12314e; font-weight: bold; }

.content { flex: 1; padding: 20px; }

.topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; }
.topbar h2 { font-size: 21px; color: #1f4e79; }

.footer { text-align: center; color: #777; font-size: 13px; padding: 15px; }

/* ---------- Cards and panels ---------- */
.cards { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 15px; }
.card { background: white; border: 1px solid #ccc; padding: 15px; min-width: 150px; flex: 1; text-align: center; }
.card h3 { font-size: 22px; color: #1f4e79; }
.card p { color: #555; font-size: 13px; margin-top: 4px; }
.card.big h3 { font-size: 26px; }

.panel { background: white; border: 1px solid #ccc; padding: 18px; margin-bottom: 15px; }
.panel h3 { color: #1f4e79; margin-bottom: 12px; font-size: 17px; }
.panel p { margin-bottom: 8px; line-height: 1.5; }

/* ---------- Tables ---------- */
table { width: 100%; border-collapse: collapse; }
th, td { border: 1px solid #ccc; padding: 8px; text-align: left; font-size: 14px; }
th { background: #dcebfb; color: #1f4e79; }

/* ---------- Attendance bar ---------- */
.bar { background: #ddd; height: 14px; width: 100%; }
.bar-fill { background: #27ae60; height: 14px; }

/* ---------- Notices ---------- */
.notice { border: 1px solid #ccc; border-left: 4px solid #1f4e79; background: #f2f8ff; padding: 10px 12px; margin-bottom: 10px; }
.notice b { color: #1f4e79; }
.notice p { margin: 4px 0 0 0; font-size: 14px; }

/* ---------- Forms and buttons ---------- */
label { display: block; margin: 10px 0 5px 0; font-size: 14px; }
input { width: 100%; padding: 8px; border: 1px solid #999; font-size: 14px; }
.btn { background: #1f4e79; color: white; border: none; padding: 9px 18px; font-size: 14px; cursor: pointer; margin-top: 12px; }
.btn:hover { background: #2e86de; }
.search { margin-bottom: 12px; }
.error { color: red; font-size: 14px; margin-top: 8px; }

/* ---------- Login and register pages ---------- */
.login-page { display: flex; justify-content: center; align-items: center; min-height: 100vh; background: #dcebfb; }
.login-card { background: white; border: 1px solid #bbb; padding: 25px; width: 340px; }
.login-card h1 { text-align: center; color: #1f4e79; font-size: 24px; }
.login-card .sub { text-align: center; color: #555; font-size: 14px; margin: 8px 0 10px 0; line-height: 1.5; }
.login-card .btn { width: 100%; }
.demo-note { background: #eef3f9; border: 1px solid #ccc; padding: 8px; font-size: 13px; text-align: center; margin-top: 14px; }

/* ---------- Small screens ---------- */
@media (max-width: 700px) {
    .layout { flex-direction: column; }
    .sidebar { width: 100%; }
    .login-card { width: 92%; }
}
