/* Shared header and footer for every public traintomo.com page.
   Written into each page by scripts/site_chrome.py. Every class is prefixed
   tc- so nothing here collides with a page's own styles. */

.tc-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 10px 20px;
  background: rgba(17, 17, 17, 0.92);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #1f1f1f;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}
/* Pages built around the old fixed bar already leave room at the top. */
.tc-header.tc-fixed { position: fixed; left: 0; right: 0; }

.tc-logo {
  font-family: 'Unbounded', -apple-system, sans-serif;
  font-weight: 900;
  font-size: 20px;
  letter-spacing: 2px;
  color: #F5A623;
  text-decoration: none;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.tc-links { display: flex; align-items: center; gap: 4px; }
.tc-links a,
.tc-menu-list a {
  color: #bbb;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 0 12px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  border-radius: 8px;
}
.tc-links a:hover,
.tc-menu-list a:hover { color: #fff; }
.tc-links a[aria-current="page"],
.tc-menu-list a[aria-current="page"] { color: #F5A623; }

.tc-cta {
  margin-left: 8px;
  background: #F5A623;
  color: #111 !important;
  font-weight: 700 !important;
}
.tc-cta:hover { background: #ffb940; }

/* Small screens: the links fold into a menu that needs no script. */
.tc-menu { display: none; position: relative; }
.tc-menu summary {
  list-style: none;
  cursor: pointer;
  width: 44px;
  height: 44px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}
.tc-menu summary::-webkit-details-marker { display: none; }
.tc-menu summary span { display: block; width: 22px; height: 2px; background: #ddd; border-radius: 2px; }
.tc-menu-list {
  position: absolute;
  right: 0;
  top: 52px;
  min-width: 220px;
  display: flex;
  flex-direction: column;
  padding: 8px;
  background: #161616;
  border: 1px solid #262626;
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}
.tc-menu-list a { font-size: 16px; }
.tc-menu-list .tc-cta { margin: 8px 0 0; justify-content: center; }

@media (max-width: 860px) {
  .tc-links { display: none; }
  .tc-menu { display: block; }
}

.tc-footer {
  border-top: 1px solid #1f1f1f;
  margin-top: 64px;
  padding: 48px 24px 40px;
  background: #111;
  color: #888;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  text-align: left;
}
.tc-footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
}
.tc-footer-brand .tc-logo { font-size: 18px; min-height: 0; }
.tc-footer-brand .tc-logo span { color: #888; margin-left: 6px; letter-spacing: 0; font-weight: 700; }
.tc-footer-brand p { margin: 12px 0 0; line-height: 1.6; color: #888; }
.tc-footer h2 {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #F5A623;
  margin: 0 0 8px;
}
.tc-footer ul { list-style: none; margin: 0; padding: 0; }
.tc-footer li a {
  color: #bbb;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  min-height: 36px;
}
.tc-footer li a:hover { color: #fff; }
.tc-footer-legal {
  max-width: 960px;
  margin: 32px auto 0;
  padding-top: 20px;
  border-top: 1px solid #1a1a1a;
  font-size: 13px;
  color: #777;
}
.tc-footer-legal a { color: #bbb; }

@media (max-width: 720px) {
  .tc-footer-inner { grid-template-columns: 1fr 1fr; }
  .tc-footer-brand { grid-column: 1 / -1; }
}
