/* DinePOS Web Admin - a small, deliberately plain stylesheet.
   No build step: this file is served straight from public/, so the admin can
   be deployed to Hostinger without npm, node or a compiled asset pipeline. */

:root {
    --bg: #0f1216;
    --panel: #171b21;
    --panel-2: #1e242c;
    --line: #2a323d;
    --ink: #e7ecf2;
    --muted: #93a1b1;
    --accent: #2f9e6d;
    --danger: #d9534f;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font: 15px/1.5 -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.muted { color: var(--muted); }
.mono { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; }
.small { font-size: 12px; }

/* --- chrome ------------------------------------------------------------- */
.topbar {
    display: flex; align-items: center; gap: 20px;
    padding: 12px 20px;
    background: var(--panel);
    border-bottom: 1px solid var(--line);
    flex-wrap: wrap;
}
.brand { font-weight: 700; font-size: 17px; color: var(--ink); }
.brand span { color: var(--muted); font-weight: 400; }
.nav { display: flex; gap: 4px; flex-wrap: wrap; }
.nav a {
    padding: 6px 10px; border-radius: 6px; color: var(--muted); font-size: 14px;
}
.nav a:hover { background: var(--panel-2); color: var(--ink); text-decoration: none; }
.nav a.on { background: var(--panel-2); color: var(--ink); }
.topbar .right { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.who { font-size: 13px; color: var(--muted); }
.who em { color: var(--accent); font-style: normal; }

main { max-width: 1100px; margin: 0 auto; padding: 24px 20px 60px; }
h1 { font-size: 22px; margin: 0 0 4px; }
h2 { font-size: 16px; margin: 28px 0 10px; }

.foot {
    max-width: 1100px; margin: 0 auto; padding: 16px 20px 40px;
    color: var(--muted); font-size: 12px;
}

/* --- tiles -------------------------------------------------------------- */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; margin-top: 18px; }
.tile {
    background: var(--panel); border: 1px solid var(--line);
    border-radius: 10px; padding: 14px 16px; display: flex; flex-direction: column; gap: 6px;
}
.tile .k { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.tile .v { font-size: 24px; font-weight: 600; }
.tile.small .v { font-size: 19px; }

/* --- tables ------------------------------------------------------------- */
table { width: 100%; border-collapse: collapse; margin-top: 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
th, td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); font-size: 14px; }
th { color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: var(--panel-2); }

.pill {
    display: inline-block; padding: 2px 8px; border-radius: 999px;
    background: var(--panel-2); border: 1px solid var(--line); font-size: 12px;
}

.row-actions { display: flex; gap: 10px; align-items: center; justify-content: flex-end; }
.row-actions form { margin: 0; }

.head-row { display: flex; align-items: center; gap: 14px; }
.head-row .btn, .head-row .muted { margin-left: auto; }

.search { display: flex; gap: 8px; margin-top: 14px; align-items: center; }
.search input { max-width: 320px; }

/* --- forms -------------------------------------------------------------- */
.card {
    background: var(--panel); border: 1px solid var(--line);
    border-radius: 12px; padding: 20px;
}
.login-wrap { display: flex; justify-content: center; padding-top: 40px; }
.login { width: 100%; max-width: 380px; }
.login h1 { margin-bottom: 2px; }
.login button { width: 100%; margin-top: 14px; }

.form { max-width: 520px; margin-top: 16px; }
label { display: block; margin: 14px 0 5px; font-size: 13px; color: var(--muted); }
label + input[type=checkbox] { margin-bottom: 0; }
input[type=checkbox] { width: 16px; height: 16px; accent-color: var(--accent); }

input[type=text], input[type=number], input[type=password], input:not([type]), select {
    width: 100%; padding: 8px 10px;
    background: var(--bg); color: var(--ink);
    border: 1px solid var(--line); border-radius: 8px; font: inherit;
}
input:focus, select:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

.actions { display: flex; gap: 14px; align-items: center; margin-top: 22px; }

button, .btn {
    font: inherit; padding: 8px 14px; border-radius: 8px;
    border: 1px solid var(--line); background: var(--panel-2); color: var(--ink); cursor: pointer;
}
button:hover, .btn:hover { border-color: var(--accent); text-decoration: none; }
button.primary, .btn.primary { background: var(--accent); border-color: var(--accent); color: #06210f; font-weight: 600; }

button.link, .link {
    background: none; border: 0; padding: 0; color: var(--accent);
    cursor: pointer; font: inherit; font-size: 14px;
}
button.link.danger, .link.danger { color: var(--danger); }

/* --- flash -------------------------------------------------------------- */
.flash { padding: 9px 12px; border-radius: 8px; margin: 12px 0; font-size: 14px; }
.flash.ok { background: rgba(47, 158, 109, .15); border: 1px solid var(--accent); }
.flash.bad { background: rgba(217, 83, 79, .15); border: 1px solid var(--danger); }

.pagination { display: flex; gap: 8px; margin-top: 14px; list-style: none; padding: 0; }
.pagination li { font-size: 13px; }
