/* Layout on top of the shared 802 brand. brand.css is copied in at deploy time. */
@import url("brand.css");

.topbar { padding: 0 1.5rem; }
.topbar nav a { color: var(--text-muted); margin-right: 1.1rem; padding: 6px 0; display: inline-block; border-bottom: 2px solid transparent; }
.topbar nav a.active, .topbar nav a:hover { color: var(--amber); border-bottom-color: var(--amber); }
.topbar .who { color: var(--text-muted); font-size: 0.85rem; display: flex; gap: 0.6rem; align-items: center; }
.topbar .logo { height: 34px; margin-right: 1.2rem; }

/* brand.css lays out the landing page: main is a centred flex column and .card is capped at
   400px for its three buttons. These pages are full width tables and plans, so both are reset. */
main { display: block; max-width: 1400px; margin: 0 auto; padding: 1.2rem 1.5rem 4rem; width: 100%; flex: 1; }
h1 { font-size: 1.5rem; margin-bottom: 0.8rem; }
h2 { font-size: 1.05rem; margin-bottom: 0.6rem; }

.card { background: var(--dark-2); border: 1px solid var(--dark-4); border-radius: var(--radius);
         padding: 0.9rem 1.1rem; margin: 0 0 1rem; max-width: none; text-align: left; }
.grid { display: grid; gap: 0.9rem; }
.grid.stats { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.grid.two { grid-template-columns: 2fr 1fr; }
@media (max-width: 1000px) { .grid.two { grid-template-columns: 1fr; } }

.stat .n { font-size: 1.8rem; font-weight: 700; line-height: 1.2; color: var(--amber); }
.stat .l { color: var(--text-muted); font-size: 0.8rem; }
.stat.bad .n { color: var(--danger); }

table { width: 100%; border-collapse: collapse; font-size: 0.87rem; }
th, td { text-align: left; padding: 0.4rem 0.5rem; border-bottom: 1px solid var(--dark-4); vertical-align: top; }
th { color: var(--text-muted); font-weight: 600; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.03em; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
tbody tr:hover td { background: var(--dark-3); }

input, select, button { font: inherit; color: inherit; }
input, select { background: var(--dark-3); border: 1px solid var(--dark-4); border-radius: 8px; padding: 0.45rem 0.6rem; color: var(--text); }
input:focus, select:focus { outline: 2px solid var(--amber-dark); outline-offset: 1px; }
button { background: var(--amber); color: #1a1a1a; border: 0; border-radius: 8px; padding: 0.45rem 0.9rem; cursor: pointer; font-weight: 600; transition: background var(--transition); }
button:hover { background: var(--amber-light); }
button.ghost { background: transparent; color: var(--amber); border: 1px solid var(--amber-dark); }
button.danger { background: var(--danger); color: #1a1a1a; }
button.small { padding: 0.2rem 0.5rem; font-size: 0.8rem; }
button:disabled { opacity: 0.5; cursor: default; }

.row { display: flex; gap: 0.6rem; flex-wrap: wrap; align-items: center; }
.muted { color: var(--text-muted); }
.right { text-align: right; }
.pill { display: inline-block; padding: 0.05rem 0.5rem; border-radius: 999px; font-size: 0.75rem; background: var(--dark-4); }
.pill.ok { background: #1f4028; color: #a5e0b5; }
.pill.warn { background: #4a3410; color: var(--amber-light); }
.pill.bad { background: #4a1d18; color: #f5a39a; }
.pill.info { background: #14344a; color: #8fd0ef; }

.msg { padding: 0.5rem 0.8rem; border-radius: 8px; margin: 0.5rem 0; display: none; }
.msg.show { display: block; }
.msg.err { background: #4a1d18; color: #f5a39a; }
.msg.ok { background: #1f4028; color: #a5e0b5; }

.banner { background: #4a1d18; color: #f5a39a; border: 1px solid var(--danger); padding: 0.7rem 1rem; border-radius: var(--radius); margin-bottom: 0.9rem; font-weight: 600; display: flex; gap: 0.8rem; align-items: center; flex-wrap: wrap; }

svg.tunnel { width: 100%; height: auto; display: block; }
.legend span { display: inline-block; margin-right: 0.9rem; font-size: 0.75rem; color: var(--text-muted); }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 0.25rem; vertical-align: middle; }
.tip { position: fixed; pointer-events: none; background: var(--dark-4); color: var(--text); border: 1px solid var(--amber-dark); padding: 0.4rem 0.6rem; border-radius: 8px; font-size: 0.78rem; display: none; z-index: 20; max-width: 260px; }
.events { max-height: 26rem; overflow: auto; font-size: 0.83rem; }
.events div.ev { padding: 0.3rem 0; border-bottom: 1px solid var(--dark-4); }

.muster tr.lost td { background: #3a1a16; }
.muster tr.done td { opacity: 0.5; text-decoration: line-through; }
.login { max-width: 22rem; margin: 12vh auto; }
.login h1 { font-size: 1.3rem; margin-bottom: 0.9rem; }
.login input { width: 100%; margin-bottom: 0.7rem; }
.login button { width: 100%; }

@media print {
  .topbar, button, .noprint { display: none !important; }
  body { background: #fff; color: #000; }
  .card { border: 0; background: #fff; }
  th, td { border-bottom: 1px solid #ccc; }
  .muster tr.lost td { background: #eee; }
}
