/* Parent login / dashboard (copy of student/assets/auth.css + parent parts at the end) — matches the home page (index.php) colours & fonts */
:root {
    --ca-blue: #1c4c88;
    --ca-blue-2: #0066ff;
    --ca-text: #334155;
    --ca-muted: #64748b;
    --ca-bg: #f1f5f9;
    --ca-line: #e2e8f0;
    --ca-green: #16a34a;
}
body.auth-body { font-family: 'Inter', sans-serif; color: var(--ca-text); background: var(--ca-bg); min-height: 100vh; display: flex; flex-direction: column; -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4, .auth-title { font-family: 'Plus Jakarta Sans', sans-serif; color: #0f172a; }

.auth-nav { background: var(--ca-blue); padding: 10px 0; position: sticky; top: 0; z-index: 10; }
.auth-logo img { height: 38px; width: auto; max-width: 52vw; object-fit: contain; display: block; }
.auth-logo { color: #fff; font-weight: 700; text-decoration: none; }
.auth-nav-icon, .auth-nav-btn { color: #fff; text-decoration: none; border-radius: 10px; background: rgba(255,255,255,.12); display: inline-flex; align-items: center; justify-content: center; gap: 6px; font-weight: 600; font-size: .9rem; }
.auth-nav-icon { width: 40px; height: 40px; }
.auth-nav-btn { height: 40px; padding: 0 14px; }
.auth-nav-icon:hover, .auth-nav-btn:hover { background: #fff; color: var(--ca-blue); }

.auth-main { flex: 1; padding: 36px 0 48px; }
.auth-card-wrap { max-width: 460px; margin: 0 auto; }
.auth-wide { max-width: 960px; margin: 0 auto; }
.auth-card { background: #fff; border: 1px solid var(--ca-line); border-radius: 16px; box-shadow: 0 10px 30px rgba(15, 23, 42, .06); padding: 28px 26px; }
.auth-title { font-size: 1.5rem; font-weight: 800; margin-bottom: 4px; }
.auth-sub { color: var(--ca-muted); font-size: .92rem; margin-bottom: 20px; }
.auth-alert { border-radius: 12px; font-size: .92rem; }

.auth-card .form-label { font-weight: 600; font-size: .88rem; margin-bottom: 6px; }
.auth-card .form-control { border-radius: 10px; padding: 11px 13px; border-color: #cbd5e1; }
.auth-card .form-control:focus { border-color: var(--ca-blue-2); box-shadow: 0 0 0 .2rem rgba(0, 102, 255, .12); }
.auth-card .input-group > .btn { border-color: #cbd5e1; border-radius: 0 10px 10px 0; }
.auth-card .input-group > .form-control { border-radius: 10px 0 0 10px; }
.auth-card .input-group-text { border-radius: 10px 0 0 10px; background: #f8fafc; border-color: #cbd5e1; font-weight: 600; }
.auth-card .input-group-text + .form-control { border-radius: 0 10px 10px 0; }
.auth-otp { font-size: 1.5rem; letter-spacing: .6em; text-align: center; font-weight: 700; }

.btn-ca { background: var(--ca-blue-2); border: 0; color: #fff; font-weight: 700; border-radius: 10px; padding: 12px; width: 100%; }
.btn-ca:hover, .btn-ca:focus { background: #0052cc; color: #fff; }
.btn-ca:disabled { opacity: .7; }
.btn-ca-outline { border: 1.5px solid var(--ca-line); background: #fff; color: var(--ca-text); font-weight: 600; border-radius: 10px; padding: 11px; width: 100%; }
.btn-ca-outline:hover { border-color: var(--ca-blue-2); color: var(--ca-blue-2); }
.btn-link-ca { background: none; border: 0; padding: 0; color: var(--ca-blue-2); font-weight: 600; text-decoration: none; font-size: .9rem; }
.btn-link-ca:hover { text-decoration: underline; }
.btn-link-ca:disabled { color: var(--ca-muted); text-decoration: none; }

/* Student / Parent tabs */
.auth-role { display: flex; background: #f1f5f9; border-radius: 12px; padding: 4px; margin-bottom: 20px; }
.auth-role a, .auth-role span { flex: 1; text-align: center; padding: 9px; border-radius: 9px; font-weight: 600; font-size: .92rem; color: var(--ca-muted); text-decoration: none; }
.auth-role .active { background: #fff; color: var(--ca-blue); box-shadow: 0 2px 6px rgba(15, 23, 42, .08); }
.auth-role .soon { cursor: not-allowed; }
.auth-role .soon small { font-size: .7rem; background: #fef3c7; color: #92400e; border-radius: 6px; padding: 1px 6px; margin-left: 4px; }

/* Password / OTP switch */
.auth-mode { display: flex; gap: 18px; border-bottom: 1px solid var(--ca-line); margin-bottom: 18px; }
.auth-mode a { padding: 8px 0; color: var(--ca-muted); font-weight: 600; font-size: .92rem; text-decoration: none; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.auth-mode a.active { color: var(--ca-blue-2); border-bottom-color: var(--ca-blue-2); }

.auth-divider { text-align: center; color: var(--ca-muted); font-size: .88rem; margin-top: 18px; }
.auth-divider a { color: var(--ca-blue-2); font-weight: 600; text-decoration: none; }
.auth-sent { background: #eff6ff; border-radius: 10px; padding: 10px 12px; font-size: .88rem; margin-bottom: 16px; display: flex; justify-content: space-between; align-items: center; gap: 10px; }

/* account picker */
.auth-account { display: flex; align-items: center; gap: 12px; border: 1.5px solid var(--ca-line); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; cursor: pointer; }
.auth-account:has(input:checked) { border-color: var(--ca-blue-2); background: #f5f9ff; }
.auth-account input { accent-color: var(--ca-blue-2); width: 18px; height: 18px; flex: 0 0 auto; }
.auth-account-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.auth-account-name { font-weight: 700; }
.auth-account-meta { color: var(--ca-muted); font-size: .82rem; overflow-wrap: anywhere; }
.auth-account-badge { font-size: .75rem; font-weight: 700; border-radius: 20px; padding: 3px 10px; background: #f1f5f9; color: var(--ca-muted); white-space: nowrap; }
.auth-account-badge.has { background: #dcfce7; color: var(--ca-green); }

/* dashboard */
.dash-hello { background: linear-gradient(120deg, var(--ca-blue), #2563eb); color: #fff; border-radius: 18px; padding: 26px; margin-bottom: 22px; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; }
.dash-hello h1 { color: #fff; font-size: 1.6rem; margin: 0 0 4px; }
.dash-hello p { margin: 0; opacity: .85; }
.dash-avatar { width: 58px; height: 58px; border-radius: 50%; background: rgba(255,255,255,.18); display: flex; align-items: center; justify-content: center; font-size: 1.5rem; font-weight: 800; flex: 0 0 58px; }
.dash-tile { background: #fff; border: 1px solid var(--ca-line); border-radius: 16px; padding: 20px; height: 100%; }
.dash-tile i.dash-ico { width: 44px; height: 44px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; font-size: 1.15rem; margin-bottom: 12px; }
.dash-tile h3 { font-size: 1.05rem; margin-bottom: 4px; }
.dash-tile p { color: var(--ca-muted); font-size: .88rem; margin: 0; }
.dash-soon { font-size: .7rem; font-weight: 700; background: #fef3c7; color: #92400e; border-radius: 6px; padding: 2px 7px; margin-left: 6px; vertical-align: middle; }
.dash-info dt { font-size: .78rem; color: var(--ca-muted); font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.dash-info dd { font-weight: 600; margin-bottom: 12px; word-break: break-all; }

.auth-footer { text-align: center; color: var(--ca-muted); font-size: .85rem; padding: 18px 12px; }
.auth-footer a { color: inherit; }

@media (max-width: 480px) {
    .auth-main { padding: 20px 0 32px; }
    .auth-card { padding: 22px 18px; border-radius: 14px; }
    .dash-hello { padding: 20px; }
    .auth-logo img { height: 30px; }
    .auth-nav-icon, .auth-nav-btn { height: 36px; }
    .auth-nav-icon { width: 36px; }
}

/* parent dashboard: child switcher */
.pd-children { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }
.pd-children form { margin: 0; }
.pd-child { display: inline-flex; align-items: center; gap: 10px; background: #fff; border: 1.5px solid var(--ca-line); border-radius: 14px; padding: 8px 14px 8px 8px; color: var(--ca-text); text-decoration: none; font-size: .92rem; cursor: pointer; }
.pd-child:hover { border-color: var(--ca-blue-2); }
.pd-child.on { border-color: var(--ca-blue-2); background: #f5f9ff; box-shadow: 0 2px 8px rgba(0, 102, 255, .12); }
.pd-child-av { width: 34px; height: 34px; border-radius: 50%; background: #e0edff; color: var(--ca-blue-2); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; }
.pd-child-txt { display: flex; flex-direction: column; text-align: left; line-height: 1.2; }
.pd-child-txt small { color: var(--ca-muted); font-size: .75rem; }
.pd-add { border-style: dashed; color: var(--ca-blue-2); font-weight: 600; padding: 8px 16px; }
