﻿:root {
    --brand-1: #0b2447;
    --brand-2: #19376d;
    --brand-3: #2563eb;
    --accent: #14b8a6;
    --ink: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --bg: #f1f5f9;
}

body {
    font-family: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--ink);
    background: var(--bg);
}

.ico {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

/* ============ LOGIN PAGE ============ */
.login-body {
    background: #f8fafc;
    min-height: 100vh;
}

.login-wrap {
    display: flex;
    min-height: 100vh;
}

.brand-panel {
    position: relative;
    flex: 1 1 55%;
    overflow: hidden;
    color: #fff;
    display: flex;
    align-items: center;
    padding: 3rem 4rem;
    background: linear-gradient(135deg, var(--brand-1) 0%, var(--brand-2) 55%, var(--brand-3) 130%);
}

.brand-inner {
    position: relative;
    z-index: 2;
    max-width: 540px;
}

.shape {
    position: absolute;
    border-radius: 50%;
    z-index: 1;
}

    .shape.s1 {
        width: 440px;
        height: 440px;
        background: var(--accent);
        opacity: .20;
        top: -150px;
        right: -130px;
    }

    .shape.s2 {
        width: 320px;
        height: 320px;
        border: 55px solid #fff;
        opacity: .07;
        bottom: -120px;
        left: -100px;
    }

    .shape.s3 {
        width: 130px;
        height: 130px;
        background: #fff;
        opacity: .07;
        bottom: 16%;
        right: 10%;
    }

    .shape.s4 {
        width: 70px;
        height: 70px;
        background: var(--accent);
        opacity: .35;
        top: 18%;
        left: 8%;
    }

.brand-logo {
    display: flex;
    align-items: center;
    gap: .8rem;
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: .3px;
    margin-bottom: 3rem;
}

.logo-mark {
    width: 48px;
    height: 48px;
    border-radius: 13px;
    display: grid;
    place-items: center;
    background: rgba(255,255,255,.14);
    border: 1px solid rgba(255,255,255,.28);
}

    .logo-mark .ico {
        width: 26px;
        height: 26px;
    }

.brand-panel h1 {
    font-size: 2.7rem;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 1rem;
}

.brand-panel .lead {
    color: rgba(255,255,255,.82);
    font-size: 1.05rem;
    max-width: 450px;
}

.feature-list {
    list-style: none;
    padding: 0;
    margin: 2.2rem 0 0;
    display: grid;
    gap: 1rem;
}

    .feature-list li {
        display: flex;
        align-items: center;
        gap: .85rem;
        color: rgba(255,255,255,.93);
    }

.feature-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    flex: 0 0 38px;
    display: grid;
    place-items: center;
    background: rgba(255,255,255,.12);
}

.form-panel {
    flex: 1 1 45%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.form-card {
    width: 100%;
    max-width: 430px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 22px;
    padding: 2.6rem 2.3rem 2rem;
    box-shadow: 0 25px 60px rgba(15,23,42,.10);
    animation: rise .5s ease both;
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(14px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.form-card h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: .25rem;
}

.form-card .sub {
    color: var(--muted);
    margin-bottom: 1.8rem;
}

.field {
    margin-bottom: 1.2rem;
}

    .field label {
        display: block;
        margin-bottom: .4rem;
        font-size: .74rem;
        font-weight: 700;
        letter-spacing: .06em;
        text-transform: uppercase;
        color: #475569;
    }

.input-wrap {
    position: relative;
}

    .input-wrap .i-left {
        position: absolute;
        left: 15px;
        top: 50%;
        transform: translateY(-50%);
        color: #94a3b8;
        pointer-events: none;
        display: flex;
    }

    .input-wrap input.form-control {
        height: 54px;
        padding-left: 47px;
        padding-right: 48px;
        border: 1.5px solid var(--line);
        border-radius: 13px;
        background: #f8fafc;
        font-size: 1rem;
        transition: border-color .15s, box-shadow .15s, background .15s;
    }

        .input-wrap input.form-control:focus {
            background: #fff;
            border-color: var(--brand-3);
            box-shadow: 0 0 0 4px rgba(37,99,235,.13);
        }

    .input-wrap:focus-within .i-left {
        color: var(--brand-3);
    }

.toggle-pass {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: #94a3b8;
    padding: 8px;
    border-radius: 9px;
    display: flex;
    cursor: pointer;
}

    .toggle-pass:hover {
        color: var(--brand-3);
        background: #eff6ff;
    }

.caps-warn {
    display: none;
    margin-top: .45rem;
    font-size: .8rem;
    color: #b45309;
}

.alert-login {
    display: flex;
    align-items: flex-start;
    gap: .6rem;
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
    border-radius: 12px;
    padding: .8rem 1rem;
    margin-bottom: 1.2rem;
    font-size: .92rem;
}

    .alert-login .ico {
        margin-top: 2px;
    }

.btn-wrap {
    position: relative;
    margin-top: 1.6rem;
}

.btn-login {
    width: 100%;
    height: 54px;
    border: 0;
    border-radius: 13px;
    font-weight: 600;
    font-size: 1.02rem;
    letter-spacing: .3px;
    color: #fff;
    background: linear-gradient(135deg, var(--brand-3), var(--brand-2));
    box-shadow: 0 10px 22px rgba(37,99,235,.30);
    transition: transform .15s, box-shadow .15s;
    cursor: pointer;
}

    .btn-login:hover {
        transform: translateY(-1px);
        box-shadow: 0 14px 26px rgba(37,99,235,.38);
    }

    .btn-login:active {
        transform: translateY(0);
    }

.btn-wrap.is-loading .btn-login {
    color: transparent;
    pointer-events: none;
    opacity: .92;
}

.btn-wrap.is-loading::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 22px;
    height: 22px;
    margin: -11px 0 0 -11px;
    border: 3px solid rgba(255,255,255,.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin .7s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.help-text {
    text-align: center;
    color: var(--muted);
    font-size: .85rem;
    margin-top: 1.6rem;
}

.secure-note {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: .4rem;
    color: #94a3b8;
    font-size: .78rem;
    margin-top: 1.1rem;
}

    .secure-note .ico {
        width: 14px;
        height: 14px;
    }

@media (max-width: 991.98px) {
    .login-wrap {
        flex-direction: column;
    }

    .brand-panel {
        flex: 0 0 auto;
        padding: 1.8rem 1.5rem 4rem;
    }

    .brand-logo {
        margin-bottom: 1.2rem;
    }

    .brand-panel h1 {
        font-size: 1.65rem;
    }

    .brand-panel .lead {
        font-size: .95rem;
    }

    .feature-list {
        display: none;
    }

    .shape.s1 {
        width: 260px;
        height: 260px;
        top: -110px;
        right: -90px;
    }

    .shape.s4 {
        display: none;
    }

    .form-panel {
        margin-top: -2.6rem;
        padding: 0 1rem 2rem;
        align-items: flex-start;
        position: relative;
        z-index: 3;
    }

    .form-card {
        padding: 2rem 1.4rem 1.6rem;
    }
}

@media (max-width: 380px) {
    .form-card h2 {
        font-size: 1.45rem;
    }
}

/* ============ APP (after login) ============ */
.app-nav {
    background: linear-gradient(90deg, var(--brand-1), var(--brand-2));
}

    .app-nav .navbar-brand {
        display: flex;
        align-items: center;
        gap: .6rem;
        font-weight: 700;
    }

.nav-logo {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    display: grid;
    place-items: center;
    background: rgba(255,255,255,.15);
    border: 1px solid rgba(255,255,255,.25);
}

.user-chip {
    display: flex;
    align-items: center;
    gap: .6rem;
    color: #fff;
}

    .user-chip .uname {
        font-weight: 600;
        font-size: .92rem;
    }

.avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: #fff;
    font-weight: 700;
    font-size: .9rem;
    background: linear-gradient(135deg, var(--accent), var(--brand-3));
}

    .avatar.lg {
        width: 88px;
        height: 88px;
        font-size: 1.9rem;
        border: 3px solid rgba(255,255,255,.4);
        box-shadow: 0 8px 20px rgba(0,0,0,.18);
    }

.hero {
    position: relative;
    overflow: hidden;
    color: #fff;
    border-radius: 22px;
    padding: 1.9rem;
    background: linear-gradient(135deg, var(--brand-1) 0%, var(--brand-3) 130%);
    box-shadow: 0 18px 40px rgba(37,99,235,.22);
}

    .hero::after {
        content: "";
        position: absolute;
        width: 300px;
        height: 300px;
        border-radius: 50%;
        right: -90px;
        top: -120px;
        background: rgba(255,255,255,.08);
    }

    .hero::before {
        content: "";
        position: absolute;
        width: 160px;
        height: 160px;
        border-radius: 50%;
        right: 120px;
        bottom: -90px;
        background: rgba(20,184,166,.25);
    }

.hero-body {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 1.3rem;
    flex-wrap: wrap;
}

.hero .greet {
    color: rgba(255,255,255,.8);
    font-size: .95rem;
}

.hero h3 {
    font-weight: 700;
    margin: .1rem 0 .15rem;
}

.hero .desig {
    color: rgba(255,255,255,.9);
}

.chip {
    display: inline-block;
    margin: .6rem .4rem 0 0;
    padding: .28rem .75rem;
    border-radius: 999px;
    font-size: .8rem;
    background: rgba(255,255,255,.16);
    border: 1px solid rgba(255,255,255,.2);
}

.info-card {
    height: 100%;
    display: flex;
    align-items: center;
    gap: .95rem;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 1.1rem 1.25rem;
}

.info-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    flex: 0 0 44px;
    display: grid;
    place-items: center;
    color: var(--brand-3);
    background: #eff6ff;
}

.info-label {
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--muted);
}

.info-value {
    font-weight: 600;
    word-break: break-word;
}

.section-title {
    font-weight: 700;
    font-size: 1.05rem;
    margin: 2rem 0 1rem;
}

.tile {
    position: relative;
    height: 100%;
    text-align: center;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 1.4rem 1rem;
    transition: transform .18s, box-shadow .18s;
}

    .tile:hover {
        transform: translateY(-3px);
        box-shadow: 0 14px 28px rgba(15,23,42,.10);
    }

.tile-icon {
    width: 56px;
    height: 56px;
    border-radius: 15px;
    margin: 0 auto .8rem;
    display: grid;
    place-items: center;
    color: #fff;
}

    .tile-icon .ico {
        width: 26px;
        height: 26px;
    }

.tile h6 {
    font-weight: 700;
    margin-bottom: .2rem;
}

.tile p {
    color: var(--muted);
    font-size: .82rem;
    margin: 0;
}

.tile .soon {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: .64rem;
    font-weight: 700;
    padding: .15rem .55rem;
    border-radius: 999px;
    background: #eef2ff;
    color: #4338ca;
}

.c1 {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

.c2 {
    background: linear-gradient(135deg, #14b8a6, #0f766e);
}

.c3 {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.c4 {
    background: linear-gradient(135deg, #8b5cf6, #6d28d9);
}

.c5 {
    background: linear-gradient(135deg, #ec4899, #be185d);
}

.c6 {
    background: linear-gradient(135deg, #64748b, #334155);
}

.app-footer {
    text-align: center;
    color: #94a3b8;
    font-size: .8rem;
    padding: 1.5rem 0;
}

@media (max-width: 575.98px) {
    .hero {
        padding: 1.4rem 1.2rem;
    }

    .avatar.lg {
        width: 72px;
        height: 72px;
        font-size: 1.5rem;
    }

    .tile {
        padding: 1.1rem .7rem;
    }
}
/* ---- Photo support (avatar image sits on top of the initials) ---- */
.avatar {
    position: relative;
    overflow: hidden;
}

.avatar-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

a.user-chip {
    text-decoration: none;
}

    a.user-chip:hover .uname {
        text-decoration: underline;
    }
/* Active badge + tile links */
.tile .soon.live {
    background: #dcfce7;
    color: #166534;
}

a.tile {
    display: block;
    text-decoration: none;
    color: inherit;
}

    a.tile:hover {
        color: inherit;
    }
/* ---- Attendance marks (shared) ---- */
.m-p {
    --mc: #047857;
    --mb: #d1fae5;
}

.m-a {
    --mc: #b91c1c;
    --mb: #fee2e2;
}

.m-l {
    --mc: #1d4ed8;
    --mb: #dbeafe;
}

.m-h {
    --mc: #7c3aed;
    --mb: #ede9fe;
}

.m-lwp {
    --mc: #c2410c;
    --mb: #ffedd5;
}

.m-wo {
    --mc: #475569;
    --mb: #e2e8f0;
}

.m-hol {
    --mc: #0f766e;
    --mb: #ccfbf1;
}

.m-o {
    --mc: #92400e;
    --mb: #fef3c7;
}

.m-none {
    --mc: #94a3b8;
    --mb: #f1f5f9;
}

.mark-pill {
    display: inline-block;
    min-width: 34px;
    text-align: center;
    padding: .15rem .55rem;
    border-radius: 8px;
    font-weight: 700;
    font-size: .85rem;
    color: var(--mc);
    background: var(--mb);
}

.punch-chip {
    display: inline-block;
    margin: .15rem .3rem .15rem 0;
    padding: .2rem .65rem;
    border-radius: 999px;
    background: #eff6ff;
    color: #1e40af;
    font-size: .82rem;
    font-weight: 600;
}

.punch-line {
    font-size: .9rem;
    margin-top: .3rem;
}

.punch-note {
    font-size: .78rem;
    color: var(--muted);
    margin-top: .25rem;
}