/* MMZ - Trang đăng nhập + Quản lý kỹ thuật - CSS thuần, không CDN */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: "Segoe UI", Roboto, Arial, sans-serif;
    background: #f3f4f6; min-height: 100vh; padding: 24px 16px; color: #111827;
}
a { color: #047857; }

/* ===== LOGIN ===== */
.login-wrap { max-width: 400px; margin: 8vh auto 0; }
.login-card {
    background: #fff; border-radius: 16px; overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .10); border: 1px solid #f3f4f6;
}
.login-header { background: #047857; color: #fff; padding: 24px; text-align: center; }
.login-header .brand {
    display: inline-block; background: #fff; color: #047857;
    font-weight: 900; font-size: 20px; letter-spacing: 1px;
    padding: 8px 14px; border-radius: 12px; margin-bottom: 8px;
}
.login-header .brand span { color: #84cc16; }
.login-header h1 { font-size: 15px; text-transform: uppercase; }
.login-header p { font-size: 12px; color: #d1fae5; margin-top: 4px; }
.login-form { padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.login-foot { text-align: center; font-size: 11px; color: #9ca3af; padding: 0 24px 20px; }

label {
    display: block; font-size: 11px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .5px; color: #374151; margin-bottom: 6px;
}
label .req { color: #ef4444; }
input, select {
    width: 100%; border: 1px solid #d1d5db; border-radius: 10px;
    padding: 10px 12px; font-size: 14px; font-family: inherit; background: #fff; outline: none;
    transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus { border-color: #047857; box-shadow: 0 0 0 3px rgba(4, 120, 87, .15); }

.btn {
    width: 100%; background: #047857; color: #fff; border: none;
    font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px;
    padding: 13px; border-radius: 12px; cursor: pointer; transition: background .15s;
}
.btn:hover { background: #065f46; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-danger { background: #dc2626; }
.btn-danger:hover { background: #b91c1c; }
.btn-sm { width: auto; padding: 8px 14px; font-size: 12px; border-radius: 8px; }
.btn-ghost { background: #fff; color: #374151; border: 1px solid #d1d5db; }
.btn-ghost:hover { background: #f9fafb; }

.msg {
    padding: 10px 12px; border-radius: 10px; font-size: 13px; display: none;
}
.msg.show { display: block; }
.msg.err { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }
.msg.ok { background: #f0fdf4; border: 1px solid #bbf7d0; color: #166534; }

/* ===== ADMIN ===== */
.container { max-width: 1100px; margin: 0 auto; }
.topbar {
    background: #fff; padding: 16px 20px; border-radius: 12px;
    border: 1px solid #e5e7eb; margin-bottom: 20px;
    display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between; align-items: center;
}
.topbar .left { display: flex; align-items: center; gap: 14px; }
.logo {
    background: #047857; color: #fff; font-weight: 900; font-size: 18px;
    padding: 8px 12px; border-radius: 10px; letter-spacing: .5px;
}
.logo span { color: #a3e635; }
.topbar h1 { font-size: 17px; color: #1f2937; }
.topbar .sub { font-size: 12px; color: #6b7280; }
.topbar .right { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.topbar .right label { display: inline; margin: 0; font-size: 11px; }
.topbar input[type="date"] { width: auto; padding: 8px 10px; font-size: 13px; }
.user-chip {
    font-size: 12px; font-weight: 700; color: #065f46;
    background: #d1fae5; padding: 7px 12px; border-radius: 999px;
}

.table-card { background: #fff; border-radius: 12px; border: 1px solid #e5e7eb; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 900px; }
thead th {
    background: #065f46; color: #fff; text-align: left;
    padding: 12px; font-size: 11px; text-transform: uppercase; letter-spacing: .5px;
    white-space: nowrap;
}
tbody td { padding: 12px; border-top: 1px solid #f3f4f6; vertical-align: top; }
tbody tr:hover { background: #f0fdf4; }
.empty { text-align: center; padding: 40px 12px; color: #9ca3af; font-weight: 500; }

.bid { font-weight: 800; color: #047857; }
.uudai-tag {
    display: inline-block; margin-top: 6px; padding: 2px 8px;
    font-size: 10px; font-weight: 700; border-radius: 6px;
    background: #ecfccb; color: #3f6212; border: 1px solid #bef264;
}
.cname { font-weight: 600; color: #111827; }
.csdt { font-size: 12px; color: #6b7280; }
.dev { font-weight: 700; }
.dev-laptop { color: #059669; }
.dev-pc { color: #9333ea; }
.date-main { font-weight: 600; color: #374151; }
.slot-chip {
    display: inline-block; margin-top: 4px; padding: 2px 8px;
    font-size: 11px; font-weight: 700; background: #d1fae5; color: #065f46; border-radius: 6px;
}
.note-cell { font-size: 12px; color: #4b5563; max-width: 220px; }

.badge {
    display: inline-block; padding: 4px 10px; border-radius: 999px;
    font-size: 11px; font-weight: 700; white-space: nowrap;
}
.badge.green { background: #dcfce7; color: #166534; }
.badge.emerald { background: #d1fae5; color: #065f46; }
.badge.blue { background: #dbeafe; color: #1e40af; }
.badge.yellow { background: #fef9c3; color: #854d0e; }
.badge.red { background: #fee2e2; color: #991b1b; }
.badge.gray { background: #e5e7eb; color: #374151; }

select.status-select {
    width: auto; min-width: 140px; padding: 7px 8px; font-size: 12px; border-radius: 8px;
}

/* Modal thêm user */
.modal-bg {
    position: fixed; inset: 0; background: rgba(0, 0, 0, .45);
    display: none; align-items: flex-start; justify-content: center; padding: 40px 12px; z-index: 50;
}
.modal-bg.show { display: flex; }
.modal {
    background: #fff; border-radius: 14px; width: 100%; max-width: 400px; padding: 22px;
    display: flex; flex-direction: column; gap: 14px;
}
.modal h2 { font-size: 16px; color: #1f2937; }
.modal .actions { display: flex; gap: 10px; }
.modal .actions .btn { width: auto; flex: 1; }

@media (max-width: 640px) {
    .topbar { flex-direction: column; align-items: stretch; }
    .topbar .right { justify-content: space-between; }
}
