/* plain: white background, default black text */
body {
  background: #ffffff;
  color: #000000;
}

/* top navigation bar */
.topnav {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.9rem;
  padding: 0.5rem 0.75rem;
  margin-bottom: 1rem;
  background: #f2f2f2;
  border-bottom: 1px solid #000000;
}

.topnav .brand {
  font-weight: bold;
  margin-right: 0.25rem;
}

.topnav a {
  color: #000000;
  text-decoration: none;
}

.topnav a:hover {
  text-decoration: underline;
}

/* login form */
.login-form label {
  display: block;
  margin-top: 0.5rem;
}

.login-form input {
  display: block;
  margin-bottom: 0.5rem;
  padding: 0.2rem 0.35rem;
}

/* query forms (bonair column picker) */
.query-form label {
  display: block;
  margin-top: 0.5rem;
}

.query-form select,
.query-form button {
  margin-top: 0.2rem;
  padding: 0.2rem 0.35rem;
}

.login-error {
  color: #c62828;
}

.stale-warn {
  background: #fff3e0;
  border-left: 4px solid #ef6c00;
  color: #8d4a00;
  padding: 0.4rem 0.6rem;
  margin-bottom: 0.6rem;
}

table {
  border-collapse: collapse;
}

th, td {
  text-align: left;
  padding: 0.3rem 0.5rem;
  border-bottom: 1px solid #000000;
}

/* sortable scan table */
table.sortable thead th {
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}

table.sortable thead th:hover {
  background: #e8e8e8;
}

table.sortable thead th[data-dir="asc"]::after {
  content: " ▲";
}

table.sortable thead th[data-dir="desc"]::after {
  content: " ▼";
}

/* static enumeration column */
table.sortable thead th:first-child,
table.sortable tbody td:first-child {
  color: #555;
}

/* static columns (no data-type) aren't clickable */
table.sortable thead th:not([data-type]) {
  cursor: default;
}

table.sortable thead th:not([data-type]):hover {
  background: inherit;
}

/* services directory tree */
.tree {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.95rem;
  line-height: 1.6;
  background: #fafafa;
  border: 1px solid #000000;
  padding: 0.6rem 0.8rem;
  overflow-x: auto;
}

/* system architecture slide: overline + footer bar */
.overline {
  margin: 0 0 0.2rem 0;
  font-size: 0.8rem;
  font-weight: bold;
  letter-spacing: 0.25em;
}

.slide-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 1.2rem;
  padding-top: 0.5rem;
  border-top: 1px solid #000000;
  font-size: 0.85rem;
}

/* services sub-nav: second nav row on service pages */
.subnav {
  background: #fafafa;
  border-bottom: 1px solid #000000;
  padding: 0.3rem 0.75rem;
  font-size: 0.92rem;
}
.subnav .lbl {
  font-weight: bold;
  text-transform: uppercase;
  font-size: 0.78rem;
  margin-right: 0.9rem;
  letter-spacing: 0.04em;
}
.subnav a {
  color: #000000;
  text-decoration: none;
  margin-right: 0.9rem;
}
.subnav a:hover {
  text-decoration: underline;
}
.subnav .cur {
  font-weight: bold;
  margin-right: 0.9rem;
}
.hasdrop {
  position: relative;
  display: inline-block;
  margin-right: 0.9rem;
}
.hasdrop > a {
  margin-right: 0;
}
.droplbl {
  color: #000000;
  cursor: default;
  display: inline-block;
}
.hasdrop:hover .droplbl,
.hasdrop:focus-within .droplbl {
  text-decoration: underline;
}
.droplbl:focus {
  outline: 1px dotted #000000;
}
.drop {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #ffffff;
  border: 1px solid #000000;
  min-width: 11rem;
  padding: 0.25rem 0;
  z-index: 60;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.18);
  white-space: normal;
}
.drop a {
  display: block;
  margin: 0;
  padding: 0.3rem 0.9rem;
}
.drop a:hover {
  background: #f0f0f0;
}
/* section heading inside an algo-version dropdown (e.g. the gravilla
   "Paper accounts" section) — a label, not a link */
.drop .drop-sec {
  display: block;
  margin: 0;
  padding: 0.5rem 0.9rem 0.15rem 0.9rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #888888;
  border-top: 1px solid #e5e5e5;
}
.drop .drop-sec:first-child {
  border-top: none;
}
.hasdrop:hover .drop,
.hasdrop:focus-within .drop {
  display: block;
}

/* daily quote line under the ticker input */
.quote {
  font-size: 1.05rem;
  margin: 0.2rem 0 0.4rem 0;
}

.quote .q-price {
  font-weight: bold;
  font-size: 1.3rem;
}

/* flash message (stock-momentum add/toggle feedback) */
.msg {
  background: #eafaf1;
  border: 1px solid #2ecc71;
  padding: 8px 12px;
  border-radius: 6px;
  margin: 10px 0;
  color: #1e8449;
  font-size: 0.9em;
}

/* Services dropdown in the top nav: the same services bar as service
   pages, enlarged for clickability (operator request 2026-09-25). */
.svc-navdrop .subnav {
  font-size: 1.15rem;
  padding: 0.7rem 0.9rem;
}
.svc-navdrop .subnav a,
.svc-navdrop .subnav .cur,
.svc-navdrop .subnav .hasdrop {
  margin-right: 1.4rem;
}
.svc-navdrop .subnav .lbl {
  font-size: 0.95rem;
}
.svc-navdrop .drop a {
  font-size: 1.05rem;
  padding: 0.45rem 1rem;
}

/* floating site menu (hamburger, three lines) — injected on every page by
   app.py _render_template so the button + contents are identical everywhere.
   Fixed to the viewport top-left so it stays visible while scrolling. */
.sitemenu-wrap { position: fixed; top: 64px; left: 12px; z-index: 1100;
                  transition: top .18s ease; }
.sitemenu-wrap.docked { top: 12px; }
.sitemenu-btn { background: #ffffff; border: 1px solid #d7dae0;
                border-radius: 8px; padding: 7px 9px; cursor: pointer;
                display: flex; align-items: center; color: #111827;
                box-shadow: 0 1px 2px rgba(17, 24, 39, .08); }
.sitemenu-btn:hover { border-color: #9ca3af; }
.sitemenu-btn:focus { outline: none; border-color: #111827; }
.sitemenu { position: absolute; top: calc(100% + 4px); left: 0;
            background: #ffffff; border: 1px solid #d7dae0;
            border-radius: 10px; box-shadow: 0 6px 20px rgba(17, 24, 39, .12);
            padding: 4px 0; min-width: 180px; }
.sitemenu a { display: block; padding: 7px 12px; text-decoration: none;
              color: #111827; font-size: 14px; white-space: nowrap; }
.sitemenu a:hover { background: #f6f7f9; }
.sitemenu-sec { padding: 9px 12px 3px 12px; font-size: 11px;
               text-transform: uppercase; letter-spacing: .06em;
               color: #6b7280; font-weight: 600; }
.sitemenu a.sitemenu-sub { padding-left: 22px; font-size: 13px; }
