/* Shambhala Fleet — vehicle landing page styles
 * Mobile-first. Designed for one-handed use on a phone while standing next to a vehicle. */

:root {
  --ink:        #1a1a1a;
  --paper:      #f5f1e8;
  --rule:       #d6cfb8;
  --accent:     #8b3a1e;    /* festival deep red — high contrast in sun */
  --accent-bg:  #ffe7dc;
  --muted:      #6b6358;
  --ok:         #2e7d32;
  --warn:       #b8860b;
  --shadow:     0 2px 4px rgba(0,0,0,.08);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
}

.page {
  max-width: 480px;
  margin: 0 auto;
  padding: 24px 20px 80px;
}

.header {
  text-align: center;
  padding: 20px 0 24px;
  border-bottom: 2px solid var(--rule);
  margin-bottom: 28px;
}

.vehicle-id {
  font-size: 80px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  margin: 0 0 12px;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.make-model {
  font-size: 18px;
  font-weight: 500;
  color: var(--ink);
  margin: 0 0 4px;
}

.type-category {
  font-size: 14px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.subheading {
  font-size: 15px;
  color: var(--muted);
  text-align: center;
  margin: 0 0 28px;
  line-height: 1.45;
}

.actions {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.action {
  display: block;
  padding: 22px 20px;
  background: white;
  border: 2px solid var(--ink);
  border-radius: 14px;
  font-size: 20px;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  text-align: center;
  box-shadow: var(--shadow);
  transition: transform .08s ease;
}

.action:active {
  transform: translateY(1px);
}

.action.primary {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.action.warning {
  background: var(--accent-bg);
  border-color: var(--accent);
  color: var(--accent);
}

.action .label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.7;
  margin-top: 4px;
}

.action.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
  background: var(--paper);
  border-style: dashed;
}

.action.disabled .label {
  text-transform: none;
  letter-spacing: 0;
  font-size: 13px;
}

.meta {
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  line-height: 1.5;
}

.meta a {
  color: var(--muted);
}

/* Index page list */
.vehicle-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 8px;
  margin-top: 16px;
}

.vehicle-grid a {
  display: block;
  padding: 12px 8px;
  background: white;
  border: 1px solid var(--rule);
  border-radius: 8px;
  text-align: center;
  text-decoration: none;
  font-weight: 600;
  color: var(--ink);
  font-size: 14px;
}

.vehicle-grid a:hover {
  border-color: var(--accent);
}

.search-box {
  width: 100%;
  padding: 14px;
  font-size: 18px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  margin: 16px 0;
  background: white;
}

h2.category-head {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin: 24px 0 8px;
}

/* Offline-mode hint banner — small, bottom-of-page */
.offline-hint {
  margin: 24px 0 0;
  padding: 12px 14px;
  background: white;
  border: 1px solid var(--rule);
  border-radius: 10px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  text-align: center;
}

.offline-hint strong { color: var(--ink); }
.offline-hint a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
}

/* Prominent install banner — top of page, dismissible */
.install-banner {
  margin: 0 0 20px;
  padding: 16px 16px 14px;
  background: linear-gradient(135deg, #fff8f3, #ffe7dc);
  border: 1.5px solid var(--accent);
  border-radius: 14px;
  box-shadow: var(--shadow);
}

.install-banner[hidden] { display: none !important; }

.ib-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.35;
}

.ib-head .ib-emoji {
  font-size: 22px;
  line-height: 1;
  flex: 0 0 auto;
}

.ib-body {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  margin: 0 0 12px;
}

.ib-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.ib-btn {
  flex: 1 1 auto;
  display: inline-block;
  padding: 11px 14px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  border: 1.5px solid var(--accent);
  cursor: pointer;
  font-family: inherit;
}

.ib-btn.primary {
  background: var(--accent);
  color: white;
}

.ib-btn.secondary {
  background: white;
  color: var(--accent);
}

.ib-btn.dismiss {
  background: transparent;
  color: var(--muted);
  border-color: var(--rule);
  flex: 0 0 auto;
  padding: 11px 12px;
  font-size: 13px;
  font-weight: 500;
}

.ib-learn {
  display: block;
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
}

.ib-learn a {
  color: var(--muted);
  text-decoration: underline;
}

/* Step-by-step training (offline-setup page) */
.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 16px 0;
}
.steps li {
  counter-increment: step;
  position: relative;
  padding: 18px 18px 18px 56px;
  background: white;
  border: 1px solid var(--rule);
  border-radius: 10px;
  margin-bottom: 12px;
  font-size: 15px;
  line-height: 1.5;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 14px;
  top: 16px;
  width: 32px;
  height: 32px;
  background: var(--accent);
  color: white;
  border-radius: 50%;
  text-align: center;
  line-height: 32px;
  font-weight: 700;
  font-size: 15px;
}
