
:root {
    --ink: #10242d;
    --muted: #667c85;
    --primary: #0d5964;
    --primary-dark: #073b46;
    --accent: #d6a94b;
    --accent-soft: #fff5dc;
    --surface: rgba(255, 255, 255, .94);
    --line: #dfe9eb;
    --success: #0e8a62;
    --success-bg: #e9f8f2;
    --warning: #b36b00;
    --warning-bg: #fff4df;
    --danger: #b43a3a;
    --danger-bg: #fff0f0;
    --shadow: 0 24px 65px rgba(11, 49, 60, .14);
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background:
        linear-gradient(180deg, #f4faf9 0%, #f8fbfa 48%, #ffffff 100%);
    font-family: Tahoma, Arial, "Segoe UI", sans-serif;
    overflow-x: hidden;
}

button, input { font: inherit; }

button { cursor: pointer; }

.container {
    width: min(1120px, calc(100% - 32px));
    margin-inline: auto;
}

.page-glow {
    position: fixed;
    width: 460px;
    height: 460px;
    border-radius: 50%;
    filter: blur(90px);
    opacity: .22;
    pointer-events: none;
    z-index: -1;
}
.page-glow-one { top: -220px; right: -150px; background: #65c4bb; }
.page-glow-two { top: 380px; left: -260px; background: #e6bf67; }

.topbar {
    position: relative;
    z-index: 10;
    padding: 22px 0;
}
.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: inherit;
    text-decoration: none;
}
.brand-mark {
    display: grid;
    place-items: center;
    width: 45px;
    height: 45px;
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(145deg, var(--primary), var(--primary-dark));
    box-shadow: 0 10px 25px rgba(13, 89, 100, .22);
    font-size: 24px;
    font-weight: 900;
}
.brand strong, .brand small { display: block; }
.brand strong { font-size: 18px; }
.brand small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.sponsor {
    padding: 9px 14px;
    border: 1px solid rgba(13, 89, 100, .13);
    border-radius: 999px;
    color: var(--primary-dark);
    background: rgba(255,255,255,.7);
    font-size: 13px;
    font-weight: 700;
}

.hero {
    padding: 46px 0 62px;
}
.hero .container {
    display: grid;
    grid-template-columns: .9fr 1.1fr;
    align-items: center;
    gap: 56px;
}
.eyebrow, .mini-label {
    margin: 0 0 10px;
    color: var(--primary);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .01em;
}
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,.78);
    border: 1px solid rgba(13, 89, 100, .1);
}
.live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #14a875;
    box-shadow: 0 0 0 5px rgba(20,168,117,.12);
}
.hero h1 {
    margin: 22px 0 18px;
    font-size: clamp(42px, 5.4vw, 70px);
    line-height: 1.12;
    letter-spacing: -.045em;
}
.hero h1 span {
    color: var(--primary);
}
.hero-description {
    max-width: 560px;
    margin: 0;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.95;
}

.search-card {
    position: relative;
    padding: 30px;
    border: 1px solid rgba(255,255,255,.8);
    border-radius: var(--radius-xl);
    background: var(--surface);
    box-shadow: var(--shadow);
    backdrop-filter: blur(16px);
}
.search-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 5px;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    background: linear-gradient(90deg, var(--primary), #39a99b, var(--accent));
}
.search-card-head, .results-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}
.search-card h2, .results-head h2, .note-card h2 {
    margin: 0;
    font-size: 25px;
}
.database-badge {
    min-width: 82px;
    padding: 10px 12px;
    border-radius: 14px;
    text-align: center;
    background: var(--accent-soft);
    color: #815e18;
}
.database-badge strong, .database-badge span { display: block; }
.database-badge strong { font-size: 15px; }
.database-badge span { margin-top: 2px; font-size: 11px; }

form { margin-top: 27px; }
label {
    display: block;
    margin-bottom: 10px;
    font-size: 14px;
    font-weight: 800;
}
.input-wrap {
    display: grid;
    grid-template-columns: 44px 1fr auto;
    align-items: center;
    padding: 7px 7px 7px 8px;
    border: 1.5px solid var(--line);
    border-radius: 17px;
    background: #fff;
    transition: .2s ease;
}
.input-wrap:focus-within {
    border-color: rgba(13, 89, 100, .65);
    box-shadow: 0 0 0 5px rgba(13, 89, 100, .08);
}
.input-icon {
    display: grid;
    place-items: center;
    color: var(--primary);
}
input {
    width: 100%;
    min-width: 0;
    padding: 15px 4px;
    border: 0;
    outline: 0;
    color: var(--ink);
    background: transparent;
    font-size: 16px;
}
input::placeholder { color: #9aacb3; }
.input-wrap button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 50px;
    padding: 0 22px;
    border: 0;
    border-radius: 13px;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    box-shadow: 0 10px 20px rgba(13, 89, 100, .18);
    font-weight: 800;
    transition: transform .18s ease, opacity .18s ease;
}
.input-wrap button:hover { transform: translateY(-1px); }
.input-wrap button:disabled { opacity: .65; cursor: wait; transform: none; }
.search-hint {
    margin: 11px 2px 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.7;
}
.status-box {
    margin-top: 18px;
    padding: 14px 16px;
    border-radius: 13px;
    font-size: 14px;
    line-height: 1.7;
}
.status-box.loading { color: var(--primary-dark); background: #eaf5f5; }
.status-box.error { color: var(--danger); background: var(--danger-bg); }
.status-box.empty { color: #815e18; background: var(--warning-bg); }

.results-section {
    padding: 12px 0 80px;
}
.results-head { margin-bottom: 24px; }
.secondary-button {
    padding: 10px 16px;
    border: 1px solid var(--line);
    border-radius: 12px;
    color: var(--primary-dark);
    background: #fff;
    font-weight: 800;
}
.results-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}
.result-card {
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: #fff;
    box-shadow: 0 15px 38px rgba(12, 53, 64, .07);
}
.result-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.status-pill {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 11px;
    border-radius: 999px;
    background: var(--success-bg);
    color: var(--success);
    font-size: 12px;
    font-weight: 900;
}
.status-pill.warning { color: var(--warning); background: var(--warning-bg); }
.status-pill.danger { color: var(--danger); background: var(--danger-bg); }
.copy-button {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border: 1px solid var(--line);
    border-radius: 10px;
    color: var(--muted);
    background: #fff;
}
.student-name {
    margin: 20px 0 16px;
    font-size: 21px;
    line-height: 1.55;
}
.student-seat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 13px;
    border-radius: 12px;
    background: #f5f8f8;
}
.student-seat span { color: var(--muted); font-size: 13px; }
.student-seat strong { color: var(--primary-dark); font-size: 17px; letter-spacing: .03em; }
.score-area {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 22px;
}
.score-main {
    display: flex;
    align-items: baseline;
    gap: 6px;
}
.score-number {
    color: var(--primary-dark);
    font-size: 32px;
    font-weight: 900;
}
.score-max { color: var(--muted); font-size: 13px; }
.percentage-circle {
    min-width: 83px;
    text-align: left;
}
.percentage-circle span, .percentage-circle small { display: block; }
.percentage-circle span {
    color: var(--primary);
    font-size: 20px;
    font-weight: 900;
}
.percentage-circle small { margin-top: 2px; color: var(--muted); font-size: 11px; }
.progress-track {
    height: 7px;
    margin-top: 16px;
    overflow: hidden;
    border-radius: 999px;
    background: #eaf0f1;
}
.progress-track span {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--primary), #3aa897, var(--accent));
    transition: width .55s ease;
}
.limit-note {
    margin: 18px 0 0;
    padding: 12px 14px;
    border-radius: 12px;
    color: #815e18;
    background: var(--warning-bg);
    font-size: 13px;
}

.service-note { padding: 5px 0 75px; }
.note-card {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 26px 28px;
    border: 1px solid rgba(214,169,75,.25);
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, #fffaf0, #fff);
}
.note-icon {
    display: grid;
    place-items: center;
    flex: 0 0 58px;
    width: 58px;
    height: 58px;
    border-radius: 18px;
    background: var(--accent-soft);
    font-size: 28px;
}
.note-card p:last-child {
    margin: 8px 0 0;
    color: var(--muted);
    line-height: 1.7;
}

footer {
    padding: 28px 0;
    border-top: 1px solid var(--line);
    background: #fff;
}
.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}
.footer-inner p { margin: 0; font-size: 12px; }
.disclaimer { color: var(--muted); }

@media (max-width: 850px) {
    .hero { padding-top: 25px; }
    .hero .container { grid-template-columns: 1fr; gap: 32px; }
    .hero-copy { text-align: center; }
    .hero-description { margin-inline: auto; }
    .eyebrow { justify-content: center; }
    .hero h1 { margin-top: 18px; }
}

@media (max-width: 650px) {
    .container { width: min(100% - 22px, 1120px); }
    .topbar { padding: 15px 0; }
    .sponsor { padding: 8px 10px; font-size: 11px; }
    .brand-mark { width: 40px; height: 40px; border-radius: 12px; }
    .brand strong { font-size: 16px; }
    .brand small { font-size: 10px; }
    .hero { padding: 22px 0 45px; }
    .hero h1 { font-size: 39px; }
    .hero-description { font-size: 15px; }
    .search-card { padding: 22px 16px; border-radius: 22px; }
    .search-card h2 { font-size: 21px; }
    .database-badge { min-width: 74px; }
    .input-wrap {
        grid-template-columns: 38px 1fr;
        padding: 6px;
    }
    .input-wrap button {
        grid-column: 1 / -1;
        width: 100%;
        margin-top: 5px;
    }
    input { padding: 14px 2px; font-size: 15px; }
    .results-grid { grid-template-columns: 1fr; }
    .results-section { padding-bottom: 55px; }
    .student-name { font-size: 19px; }
    .note-card { align-items: flex-start; padding: 22px 18px; }
    .footer-inner { flex-direction: column; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
    * { scroll-behavior: auto !important; transition: none !important; }
}
