/* ── Reset & base ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background: #f0f4f8;
    color: #333;
    min-height: 100vh;
}

/* ── Navbar ────────────────────────────────────────────────────── */
.navbar {
    background: #1a73e8;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    height: 56px;
    box-shadow: 0 2px 6px rgba(0,0,0,.18);
}
.nav-brand { font-size: 1.1rem; font-weight: 700; letter-spacing: .3px; }
.nav-right  { display: flex; align-items: center; gap: 14px; }
.nav-user   { font-size: .9rem; opacity: .9; }

/* ── Main content ──────────────────────────────────────────────── */
.main-content { max-width: 900px; margin: 36px auto; padding: 0 16px; }

.page-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 24px;
}
.page-header h2 { font-size: 1.5rem; color: #1a1a2e; }
.text-muted { color: #666; font-size: .92rem; margin-top: 4px; }

/* ── Cards ─────────────────────────────────────────────────────── */
.card {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    overflow: hidden;
}
.card-body { padding: 28px 32px; }
.card-body h4 { margin-bottom: 8px; color: #1a1a2e; }

/* ── Buttons ───────────────────────────────────────────────────── */
.btn {
    display: inline-block;
    padding: 9px 20px;
    border-radius: 6px;
    font-size: .9rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    text-decoration: none;
    transition: background .15s, opacity .15s;
}
.btn-primary { background: #1a73e8; color: #fff; }
.btn-primary:hover { background: #1557b0; }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.btn-outline { background: #fff; color: #1a73e8; border: 2px solid #1a73e8; }
.btn-outline:hover { background: #e8f0fe; }
.btn-sm { padding: 5px 12px; font-size: .82rem; }
.btn-block { width: 100%; text-align: center; }

/* ── Alerts ────────────────────────────────────────────────────── */
.alert {
    padding: 12px 18px;
    border-radius: 7px;
    margin-bottom: 20px;
    font-size: .92rem;
}
.alert-error   { background: #fce8e6; color: #b71c1c; border-left: 4px solid #e53935; }
.alert-success { background: #e6f4ea; color: #1b5e20; border-left: 4px solid #43a047; }

/* ── Drop zone ─────────────────────────────────────────────────── */
.drop-zone {
    border: 2px dashed #1a73e8;
    border-radius: 10px;
    padding: 40px 20px;
    text-align: center;
    background: #f8fbff;
    cursor: pointer;
    transition: background .15s, border-color .15s;
    margin-bottom: 20px;
    position: relative;
}
.drop-zone.drag-over { background: #e8f0fe; border-color: #1557b0; }
.drop-zone-icon { font-size: 2.5rem; margin-bottom: 10px; }
.file-input { position: absolute; opacity: 0; width: 0; height: 0; }
.file-name  { margin-top: 12px; color: #1a73e8; font-weight: 600; }

.upload-rules {
    background: #f8f9fa;
    border-radius: 7px;
    padding: 14px 20px;
    margin-bottom: 20px;
}
.upload-rules ul { list-style: none; }
.upload-rules li { padding: 3px 0; font-size: .88rem; color: #444; }

/* ── Stats row ─────────────────────────────────────────────────── */
.stats-row { display: flex; gap: 16px; margin-bottom: 24px; }
.stat-card {
    flex: 1; border-radius: 10px; padding: 20px;
    text-align: center; box-shadow: 0 2px 6px rgba(0,0,0,.08);
}
.stat-total   { background: #e8f0fe; }
.stat-success { background: #e6f4ea; }
.stat-fail    { background: #fce8e6; }
.stat-num   { font-size: 2.4rem; font-weight: 700; line-height: 1; }
.stat-label { font-size: .85rem; color: #555; margin-top: 6px; }

/* ── Result table ──────────────────────────────────────────────── */
.result-table {
    width: 100%; border-collapse: collapse; font-size: .88rem;
}
.result-table th {
    background: #1a73e8; color: #fff;
    padding: 10px 14px; text-align: left;
}
.result-table td { padding: 8px 14px; border-bottom: 1px solid #eee; }
.row-success td { background: #f6fff7; }
.row-fail    td { background: #fff6f6; color: #c62828; }

/* ── Login ─────────────────────────────────────────────────────── */
.login-body {
    background: linear-gradient(135deg, #1a73e8 0%, #0d47a1 100%);
    display: flex; align-items: center; justify-content: center; min-height: 100vh;
}
.login-card {
    background: #fff;
    border-radius: 14px;
    padding: 48px 44px;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 8px 30px rgba(0,0,0,.25);
}
.login-logo     { font-size: 3rem; text-align: center; margin-bottom: 10px; }
.login-title    { font-size: 1.4rem; font-weight: 700; text-align: center; color: #1a1a2e; }
.login-subtitle { text-align: center; color: #777; margin-bottom: 28px; font-size: .9rem; }

/* ── Forms ─────────────────────────────────────────────────────── */
.form-group       { margin-bottom: 18px; }
.form-group label { display: block; font-size: .88rem; font-weight: 600; margin-bottom: 5px; color: #444; }
.form-control {
    width: 100%; padding: 9px 13px; border: 1.5px solid #ccc;
    border-radius: 6px; font-size: .92rem; transition: border-color .15s;
}
.form-control:focus { outline: none; border-color: #1a73e8; }
.field-error { color: #e53935; font-size: .82rem; margin-top: 4px; display: block; }
