/* HMI Room Booking: design rules from the approved design (README.md). */
:root {
  --text: #24364A; --text-2: #5A6B7D; --text-quiet: #687788; --line: #E3EBF3; --line-2: #F0F4F8;
  --blue: #1F5F93; --blue-2: #2A7DB3; --link: #2F6A99; --ink: #1F4F78;
  --amber: #E8A55C; --amber-line: #F3D3B0; --amber-bg: #FFF8EF;
  --green-bg: #EAF7F0; --green: #1E6B47; --red: #A63A2B; --red-bg: #FDF0EE;
}
* { box-sizing: border-box; }
body {
  margin: 0; font-family: 'Nunito Sans', system-ui, sans-serif; color: var(--text); font-size: 15px;
  background: linear-gradient(165deg, #F2F7FD 0%, #F5FAFD 55%, #F2FAF5 100%); background-attachment: fixed; min-height: 100vh;
}
h1, h2 { line-height: 1.1; letter-spacing: -0.02em; margin: 0; }
h1 { font-size: 28px; font-weight: 700; } h2 { font-size: 20px; font-weight: 700; }
p { margin: 0; line-height: 1.5; }
a { color: var(--link); }
:focus-visible { outline: 3px solid #93D7F0; outline-offset: 2px; }

/* header: frosted white glass with a 3px colour strip */
header.top { position: sticky; top: 0; z-index: 10; background: rgba(255,255,255,.72); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); box-shadow: 0 10px 18px -14px rgba(16,40,70,.18); }
header.top .strip { height: 3px; background: linear-gradient(90deg, #9DBBD8, #93D7F0, #96DDB8); }
header.top .bar { max-width: 1360px; margin: 0 auto; padding: 0 32px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 14px; }
.brand img { height: 44px; width: auto; display: block; margin: 10px 0; }   /* supplied logo is stacked (725x418), so sized by height */
.center .brand img { height: 72px; margin: 0; }
.center .brand { margin-bottom: 8px; }
.brand .wordmark { font-weight: 700; font-size: 20px; color: #004E89; letter-spacing: -0.02em; }
.brand .product { font-weight: 600; font-size: 15px; color: #004E89; padding-left: 14px; border-left: 1px solid #D3DEE9; }
nav { display: flex; flex-wrap: wrap; gap: 2px; flex: 1; }
nav a { color: #4A5B6E; text-decoration: none; padding: 12px 14px; border-radius: 8px; font-size: 14px; font-weight: 500; min-height: 44px; display: inline-flex; align-items: center; }
nav a[aria-current="page"] { color: var(--ink); background: #EEF5FD; font-weight: 600; }
.who { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--text-2); }

main { max-width: 1360px; margin: 0 auto; padding: 28px 32px 48px; display: flex; flex-direction: column; gap: 18px; }
.lead { color: var(--text-2); }

/* buttons: one strong action per screen, others quiet */
button { font: inherit; cursor: pointer; transition: transform .35s cubic-bezier(.2,.8,.2,1), background-color .2s; }
button:active { transform: scale(.97); transition: transform 100ms ease-out; }
button:disabled { opacity: .6; cursor: default; }
.btn { white-space: nowrap; min-height: 44px; padding: 0 22px; border-radius: 999px; font-weight: 600; border: 1.5px solid #2F6A99; background: #fff; color: var(--ink); }
.btn.primary { border: 0; color: #fff; font-weight: 700; background: linear-gradient(120deg, #1F5F93, #2A7DB3); box-shadow: 0 10px 22px -8px rgba(31,95,147,.55); }
.btn.small { min-height: 44px; padding: 0 14px; font-size: 14px; }
.linkbtn { background: none; border: 0; color: var(--link); font-weight: 600; padding: 0 6px; min-height: 44px; }

/* cards: flat for information, soft shadow for things you act on */
.card { background: rgba(255,255,255,.7); border: 1px solid #E8EEF4; border-radius: 16px; padding: 24px; }
.card.act { background: #fff; box-shadow: 0 12px 30px -18px rgba(16,40,70,.25); }
.notice { border-left: 4px solid var(--amber); border: 1px solid var(--amber-line); border-left: 4px solid var(--amber); background: var(--amber-bg); border-radius: 12px; padding: 14px 18px; }
.error { color: var(--red); background: var(--red-bg); border-radius: 10px; padding: 10px 14px; font-weight: 600; }
.ok { color: var(--green); background: var(--green-bg); border-radius: 10px; padding: 10px 14px; font-weight: 600; }

/* centred pages: sign in, change password */
.center { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.center .card { width: 100%; max-width: 440px; display: flex; flex-direction: column; gap: 16px; }
form { display: flex; flex-direction: column; gap: 16px; }
label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 14px; }
label small { font-weight: 400; color: var(--text-2); }
input[type=text], input[type=email], input[type=password], input[type=search] {
  font: inherit; min-height: 44px; padding: 0 14px; border: 1.5px solid #C9D6E3; border-radius: 10px; color: var(--text); background: #fff; width: 100%;
}
.secret { font-family: ui-monospace, Menlo, monospace; font-size: 20px; letter-spacing: .04em; text-align: center; background: #F5FAFD; }

/* table */
.tablewrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-weight: 600; color: var(--text-2); font-size: 13px; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 6px 12px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
td.num { color: #3F5064; }
.chip { display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; background: #EEF2F6; color: var(--text-2); white-space: nowrap; }
.chip.warn { background: #FCEBD3; color: #8A5200; } .chip.good { background: var(--green-bg); color: var(--green); }
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.toolbar input { max-width: 320px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.row.left { justify-content: flex-start; } .row.mid { justify-content: center; }
a.linkish { align-self: flex-start; text-decoration: none; display: inline-flex; align-items: center; }

/* dialogs */
dialog { border: 0; border-radius: 18px; padding: 26px; width: min(480px, calc(100vw - 32px)); box-shadow: 0 30px 80px -20px rgba(16,40,70,.45); color: var(--text); font-family: inherit; }
dialog::backdrop { background: rgba(20,40,64,.35); }
dialog .stack { display: flex; flex-direction: column; gap: 16px; }

@media (max-width: 720px) { main, header.top .bar { padding-left: 16px; padding-right: 16px; } .brand img { height: 38px; } }
@media (prefers-reduced-motion: reduce) { * { transition: opacity .2s ease !important; transform: none !important; } }
@media (prefers-reduced-transparency: reduce) { header.top { background: #fff; backdrop-filter: none; -webkit-backdrop-filter: none; } }
@media (prefers-contrast: more) { header.top { background: #fff; border-bottom: 1px solid #5A6B7D; } .card, input { border-color: #5A6B7D; } }
