/* Birlikdə Yük — dizayn sistemi (bölmə 10.1). Getdik-dən tam fərqli sima: kömür + narıncı. */
@font-face {
  font-family: 'BY Sans';
  src: local('DejaVu Sans');
}

:root {
  --coal: #131315;
  --coal-2: #1B1B1E;
  --card: #232327;
  --card-hi: #2C2C31;
  --amber: #E8862E;
  --amber-soft: #F2A65A;
  --txt: #F2F0EC;
  --txt-soft: #9C9A94;
  --line: #33333A;
  --ok: #4CAF7A;
  --warn: #E8C14A;
  --danger: #E15656;
  --radius: 18px;
  --radius-sm: 12px;
  --font-head: 'Space Grotesk', 'BY Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Manrope', 'BY Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--coal);
  color: var(--txt);
  font-family: var(--font-body);
  -webkit-tap-highlight-color: transparent;
  max-width: 100%;
  overflow-x: hidden;
}

img, svg { max-width: 100%; }

body {
  min-height: 100vh;
  padding-bottom: 72px; /* bottom nav */
}

h1, h2, h3, .num {
  font-family: var(--font-head);
  font-weight: 700;
  margin: 0 0 8px;
}

a { color: inherit; text-decoration: none; }

.container {
  max-width: 640px;
  width: 100%;
  margin: 0 auto;
  padding: 16px;
  overflow-wrap: break-word;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
  transition: background .15s ease;
}
.card:hover { background: var(--card-hi); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 20px;
  border-radius: var(--radius-sm);
  border: none;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  background: var(--card);
  color: var(--txt);
}
.btn-amber {
  background: var(--amber);
  color: #16130E;
}
.btn-amber:hover { background: var(--amber-soft); }
.btn-outline {
  background: transparent;
  border: 1px solid var(--amber);
  color: var(--amber);
}
.btn-block { width: 100%; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--line);
  color: var(--txt-soft);
}
.chip-active { border-color: var(--amber); color: var(--amber); }
.chip-warn { background: var(--warn); color: #16130E; border-color: var(--warn); }
.chip-ok { background: var(--ok); color: #0C1F16; border-color: var(--ok); }
.chip-urgent { background: var(--amber); color: #16130E; border-color: var(--amber); }
.chip-muted { color: var(--txt-soft); }

.route {
  font-family: var(--font-head);
  font-size: 22px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.route .arrow { color: var(--amber); }

.text-soft { color: var(--txt-soft); font-size: 14px; }
.link-amber { color: var(--amber); text-decoration: underline; }

input, select, textarea {
  width: 100%;
  background: var(--coal-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--txt);
  padding: 12px 14px;
  font-size: 15px;
  font-family: var(--font-body);
  min-height: 44px;
}
textarea { min-height: 96px; resize: vertical; }
label { display: block; font-size: 13px; color: var(--txt-soft); margin-bottom: 6px; }
.field { margin-bottom: 16px; }

.bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  display: flex;
  background: var(--coal-2);
  border-top: 1px solid var(--line);
  padding: 6px 8px env(safe-area-inset-bottom);
  z-index: 40;
}
.bottom-nav a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 11px;
  color: var(--txt-soft);
  padding: 8px 0;
  min-height: 44px;
}
.bottom-nav a.active { color: var(--amber); }
.bottom-nav .fab {
  flex: 0 0 44px;
  background: var(--amber);
  color: #16130E;
  border-radius: 50%;
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  margin-top: -18px;
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
  padding: 0;
}
.bottom-nav .fab.active { color: #16130E; }

.empty-state, .error-state {
  text-align: center;
  padding: 48px 16px;
  color: var(--txt-soft);
}

.skeleton {
  background: linear-gradient(90deg, var(--card) 25%, var(--card-hi) 37%, var(--card) 63%);
  background-size: 400% 100%;
  animation: skeleton-loading 1.4s ease infinite;
  border-radius: var(--radius-sm);
}
@keyframes skeleton-loading {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}
@media (prefers-reduced-motion: reduce) {
  .skeleton { animation: none; }
  * { scroll-behavior: auto !important; }
}

.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 16px;
  position: sticky;
  top: 0;
  background: rgba(19,19,21,.92);
  backdrop-filter: blur(6px);
  z-index: 30;
  border-bottom: 1px solid var(--line);
}
.brand { font-family: var(--font-head); font-weight: 700; font-size: 17px; white-space: nowrap; }
.brand .amber { color: var(--amber); }

.lang-switch { display: flex; gap: 4px; flex-shrink: 0; }
.lang-switch a {
  padding: 4px 7px;
  border-radius: 8px;
  font-size: 11px;
  color: var(--txt-soft);
  border: 1px solid var(--line);
}
.lang-switch a.active { color: var(--amber); border-color: var(--amber); }

.tabs { display: flex; gap: 8px; margin-bottom: 16px; }
.tabs a {
  flex: 1;
  text-align: center;
  padding: 10px;
  border-radius: var(--radius-sm);
  background: var(--card);
  border: 1px solid var(--line);
  font-weight: 600;
  font-size: 14px;
}
.tabs a.active { background: var(--amber); color: #16130E; border-color: var(--amber); }

.role-cards { display: grid; gap: 12px; }
.role-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  text-align: left;
  cursor: pointer;
}
.role-card:hover, .role-card.selected { border-color: var(--amber); background: var(--card-hi); }
.role-card .icon { font-size: 32px; }
.role-card h2 { font-size: 18px; }

.banner {
  background: var(--card);
  border-left: 3px solid var(--warn);
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  font-size: 14px;
}
.banner-error { border-left-color: var(--danger); }

/* PWA quraşdırma sheet-i (Q-Y13) */
.install-sheet[hidden], .install-reminder[hidden], .splash[hidden] {
  display: none !important;
}
.install-sheet {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(10,10,11,.88);
  display: flex; align-items: flex-end;
  animation: install-fade-in .25s ease;
}
@keyframes install-fade-in { from { opacity: 0; } to { opacity: 1; } }
.install-sheet-inner {
  background: var(--coal-2);
  border-top: 1px solid var(--line);
  border-radius: 24px 24px 0 0;
  padding: 28px 20px calc(28px + env(safe-area-inset-bottom));
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  position: relative;
  text-align: center;
}
.install-icon { font-size: 40px; margin-bottom: 8px; }
.install-close {
  position: absolute; top: 12px; right: 12px;
  background: none; border: none; color: var(--txt-soft);
  font-size: 18px; width: 32px; height: 32px; cursor: pointer;
}
.install-steps { text-align: left; list-style: none; padding: 0; margin: 16px 0 0; }
.install-steps li {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.install-step-num {
  flex-shrink: 0; width: 24px; height: 24px; border-radius: 50%;
  background: var(--amber); color: #16130E; font-weight: 700;
  display: flex; align-items: center; justify-content: center; font-size: 13px;
}
.install-share-icon {
  margin-left: auto; font-size: 20px;
  animation: install-bounce 1.4s ease infinite;
}
@keyframes install-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}
@media (prefers-reduced-motion: reduce) {
  .install-sheet { animation: none; }
  .install-share-icon { animation: none; }
}

.install-reminder {
  position: fixed; top: 0; left: 0; right: 0; z-index: 90;
  background: var(--amber); color: #16130E;
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px;
  font-size: 13px; font-weight: 600;
}
.install-reminder .install-close { color: #16130E; position: static; margin-left: auto; }

/* Splash (bölmə 10.2): kömür fon -> "Birlikdə" sakit -> "Yük" amber + yük maşını xətti -> içəri, ≤2s */
.splash {
  position: fixed; inset: 0; z-index: 200;
  background: var(--coal);
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 12px;
  animation: splash-out .3s ease 1.5s forwards;
}
.splash-inner { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.splash-word {
  font-family: var(--font-head);
  font-size: 32px;
  font-weight: 700;
  opacity: 0;
}
.splash-word-1 {
  color: var(--txt);
  animation: splash-fade-in .5s ease .1s forwards;
}
.splash-word-2 {
  color: var(--amber);
  animation: splash-fade-in .5s ease .5s forwards;
}
.splash-truck-path, .splash-wheel {
  stroke-dasharray: 220;
  stroke-dashoffset: 220;
  animation: splash-draw .9s ease .5s forwards;
}
@keyframes splash-fade-in { to { opacity: 1; } }
@keyframes splash-draw { to { stroke-dashoffset: 0; } }
@keyframes splash-out { to { opacity: 0; visibility: hidden; pointer-events: none; } }
@media (prefers-reduced-motion: reduce) {
  .splash { animation: splash-out .01s linear 1.5s forwards; }
  .splash-word, .splash-truck-path, .splash-wheel { animation: none; opacity: 1; stroke-dashoffset: 0; }
}
