/* COVID-X: 2036 — mobile-first, dark post-apocalyptic UI */

:root {
  --bg-deep: #0a0c0e;
  --bg-panel: #12161c;
  --bg-elevated: #1a2028;
  --border: #2a3340;
  --text: #e6e8ec;
  --text-muted: #8b95a5;
  --accent: #c45c3e;
  --accent-dim: #8f4230;
  --hp: #c23d3d;
  --hp-track: #3a2224;
  --energy: #3d8cc2;
  --energy-track: #1e2c38;
  --success: #5a9f6e;
  --warning: #c9a227;
  --danger: #b84a4a;
  --font-ui: system-ui, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "Cascadia Code", monospace;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --radius: 10px;
  --tap-size: 48px;
}

@keyframes popIn {
  from {
    transform: scale(0.9);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.flow-pop {
  animation: popIn 0.28s cubic-bezier(0.22, 1, 0.36, 1) both;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  height: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 1.45;
  color: var(--text);
  background: var(--bg-deep);
  background-image:
    linear-gradient(180deg, rgba(6, 7, 8, 0.72), rgba(6, 7, 8, 0.92)),
    radial-gradient(ellipse 120% 80% at 50% -20%, rgba(196, 92, 62, 0.12), transparent 55%),
    url("assets/background/bg.png"),
    linear-gradient(180deg, #0d1014 0%, var(--bg-deep) 40%, #060708 100%);
  background-size: cover, auto, cover, auto;
  background-position: center, center, center, center;
  background-repeat: no-repeat;
}

.app {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  max-width: 480px;
  margin: 0 auto;
  padding-bottom: calc(72px + var(--safe-bottom));
}

.top-bar {
  padding: 14px 16px 10px;
  border-bottom: 1px solid var(--border);
  background: rgba(10, 12, 14, 0.92);
  backdrop-filter: blur(8px);
}

.top-bar__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.top-bar__logout {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(211, 65, 74, 0.55);
  background: rgba(28, 10, 14, 0.85);
  color: #ffd9dd;
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.12s ease;
}

.top-bar__logout:hover {
  background: rgba(60, 14, 20, 0.95);
  border-color: rgba(211, 65, 74, 0.85);
}

.top-bar__logout:active {
  transform: scale(0.96);
}

.top-bar__logout-icon {
  font-size: 0.95rem;
  line-height: 1;
}

@media (max-width: 360px) {
  .top-bar__logout-label { display: none; }
  .top-bar__logout { padding: 6px 8px; }
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand__logo {
  display: block;
  width: 112px;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(91, 255, 99, 0.16));
}

.brand__title {
  font-weight: 800;
  letter-spacing: 0.06em;
  font-size: 1.15rem;
  color: var(--accent);
  text-transform: uppercase;
}

.brand__year {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.tagline {
  margin: 6px 0 0;
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.35;
}

.main {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}

.panel {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  padding: 12px 14px 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.panel--active {
  position: relative;
  inset: auto;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  opacity: 1;
  pointer-events: auto;
}

.panel[hidden] {
  display: none !important;
}

.panel-inner {
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1 1 auto;
  min-height: 0;
}

.card {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

.card--passport {
  min-width: 0;
  padding: 10px;
  background:
    linear-gradient(145deg, rgba(22, 27, 35, 0.82), rgba(8, 10, 13, 0.88)),
    var(--bg-panel);
  border-color: rgba(255, 255, 255, 0.08);
}

.card__title {
  margin: 0 0 10px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.stat-row:last-child {
  margin-bottom: 0;
}

.stat-row__label {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.stat-row__value {
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--text);
}

.bar-wrap {
  margin-top: 4px;
}

.bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  margin-bottom: 4px;
  color: var(--text-muted);
}

.bar-track {
  height: 10px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--hp-track);
  border: 1px solid var(--border);
}

.bar-track--energy {
  background: var(--energy-track);
}

.bar-fill {
  height: 100%;
  width: 0%;
  border-radius: 5px;
  transition: width 0.45s cubic-bezier(0.33, 1, 0.68, 1);
}

.bar-fill--hp {
  background: linear-gradient(90deg, #8f2d2d, var(--hp));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.bar-fill--energy {
  background: linear-gradient(90deg, #256a94, var(--energy));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.combat-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--warning);
}

.gear-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.gear-grid--three {
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

@media (max-width: 359px) {
  .gear-grid--three {
    grid-template-columns: 1fr 1fr;
  }
}

.gear-slot {
  background: var(--bg-elevated);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 10px 8px 12px;
  min-height: 72px;
  text-align: center;
}

.gear-slot__pic {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 6px auto 4px;
  width: 56px;
  height: 56px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  overflow: hidden;
}

.gear-slot__img {
  width: 80%;
  height: 80%;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.45));
}

.gear-slot__label {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.gear-slot__name {
  font-size: 0.88rem;
  font-weight: 600;
}

.gear-slot--empty .gear-slot__name {
  color: var(--text-muted);
  font-weight: 400;
  font-style: italic;
}

.resource-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.resource-pill {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px;
  background: var(--bg-elevated);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.resource-pill__name {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.resource-pill__amt {
  font-family: var(--font-mono);
  font-size: 1.05rem;
  font-weight: 700;
}

.skills-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.skill-item {
  padding: 8px 10px;
  background: var(--bg-elevated);
  border-radius: 8px;
  border: 1px solid var(--border);
  font-size: 0.82rem;
}

.skill-item strong {
  display: block;
  font-size: 0.68rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 2px;
}

.list-plain {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mission-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  background: var(--bg-elevated);
}

.mission-card__title {
  margin: 0 0 6px;
  font-size: 1rem;
  font-weight: 700;
}

.mission-card__meta {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 10px;
  line-height: 1.4;
}

.mission-card__rewards {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: var(--tap-size);
  padding: 0 16px;
  width: 100%;
  border: none;
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.08s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: linear-gradient(180deg, var(--accent), var(--accent-dim));
  color: #fff;
}

.btn--primary:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.btn--secondary {
  background: var(--bg-panel);
  color: var(--text);
  border: 1px solid var(--border);
}

.craft-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px;
  background: var(--bg-elevated);
  border-radius: 8px;
  border: 1px solid var(--border);
  margin-bottom: 8px;
}

.craft-row:last-child {
  margin-bottom: 0;
}

.craft-row__info {
  flex: 1;
  min-width: 140px;
}

.craft-row__name {
  font-weight: 600;
  font-size: 0.9rem;
}

.craft-row__cost {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.craft-row .btn {
  width: auto;
  min-width: 110px;
  min-height: 44px;
  padding: 0 14px;
}

.shelter-wrap {
  text-align: center;
  padding: 8px 0;
}

.shelter-wrap img {
  max-width: 100%;
  height: auto;
  max-height: 160px;
  object-fit: contain;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.5));
}

.pixel-art {
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.specialist-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.specialist-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
}

.specialist-item--locked {
  opacity: 0.55;
}

.specialist-item__name {
  font-weight: 600;
  font-size: 0.9rem;
}

.specialist-item__effect {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.badge {
  font-size: 0.65rem;
  padding: 4px 8px;
  border-radius: 6px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.badge--ok {
  background: rgba(90, 159, 110, 0.25);
  color: var(--success);
  border: 1px solid rgba(90, 159, 110, 0.4);
}

.badge--off {
  background: rgba(139, 149, 165, 0.12);
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.item-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.item-list li {
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.86rem;
}

.item-list li:last-child {
  border-bottom: none;
}

.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  max-width: 480px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 8px 10px calc(8px + var(--safe-bottom));
  background: rgba(10, 12, 14, 0.96);
  border-top: 1px solid var(--border);
  backdrop-filter: blur(10px);
  z-index: 50;
}

.bottom-nav__btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 10px 6px;
  min-height: var(--tap-size);
  border: none;
  border-radius: var(--radius);
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.bottom-nav__btn--active {
  background: var(--bg-elevated);
  color: var(--accent);
}

.bottom-nav__icon {
  font-size: 1.35rem;
  line-height: 1;
}

.bottom-nav__label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.toast-host {
  position: fixed;
  left: 50%;
  bottom: calc(88px + var(--safe-bottom));
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
  max-width: min(90vw, 400px);
  width: 100%;
  align-items: center;
}

.toast {
  pointer-events: none;
  padding: 10px 14px;
  border-radius: var(--radius);
  background: rgba(26, 32, 40, 0.95);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 0.85rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  animation: toast-in 0.25s ease;
}

.toast--success {
  border-color: rgba(90, 159, 110, 0.45);
}

.toast--warn {
  border-color: rgba(201, 162, 39, 0.45);
}

.toast--err {
  border-color: rgba(184, 74, 74, 0.45);
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.save-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: -4px;
}

/* ——— Prisijungimas / istorija ——— */

.flow-screen {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 18px calc(24px + env(safe-area-inset-bottom, 0));
  background:
    linear-gradient(180deg, rgba(2, 4, 6, 0.54), rgba(2, 4, 6, 0.88)),
    radial-gradient(ellipse 90% 70% at 50% 0%, rgba(196, 92, 62, 0.18), transparent 55%),
    url("assets/background/bg.png"),
    linear-gradient(165deg, #07090c 0%, var(--bg-deep) 45%, #040506 100%);
  background-size: cover, auto, cover, auto;
  background-position: center, center, center, center;
  background-repeat: no-repeat;
  overflow: hidden;
}

.flow-screen::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 55% at 50% 50%, transparent 0%, rgba(0, 0, 0, 0.34) 72%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.42), transparent 28%, transparent 72%, rgba(0, 0, 0, 0.42));
}

.flow-screen__panel,
.flow-screen__story {
  position: relative;
  z-index: 1;
}

.flow-screen__panel {
  width: min(100%, 380px);
  padding: 22px 20px;
  border-radius: 16px;
  background: rgba(18, 22, 28, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(14px) saturate(1.15);
}

.flow-screen__brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 12px;
}

.flow-screen__logo {
  display: block;
  width: min(230px, 76vw);
  height: auto;
  object-fit: contain;
  filter:
    drop-shadow(0 0 10px rgba(91, 255, 99, 0.22))
    drop-shadow(0 8px 20px rgba(0, 0, 0, 0.45));
}

.flow-screen__year {
  font-family: var(--font-mono);
  color: var(--text-muted);
  font-size: 0.95rem;
}

.flow-screen__hook {
  margin: 0 0 16px;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-form__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.auth-form__label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}

.auth-form input[type='text'],
.auth-form input[type='password'] {
  width: 100%;
  padding: 12px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(8, 10, 12, 0.66);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
}

.auth-form input:focus {
  outline: none;
  border-color: rgba(196, 92, 62, 0.55);
  box-shadow: 0 0 0 3px rgba(196, 92, 62, 0.18);
}

.auth-form__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
}

.auth-form__error {
  margin: 12px 0 0;
  font-size: 0.82rem;
  color: var(--danger);
  text-align: center;
}

.flow-screen--story .flow-screen__story {
  width: min(100%, 420px);
  text-align: center;
  padding: 28px 22px;
  border-radius: 18px;
  background: rgba(12, 14, 18, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(16px) saturate(1.1);
}

.story-logo {
  display: block;
  width: min(250px, 78vw);
  height: auto;
  object-fit: contain;
  margin: 0 auto 22px;
  filter:
    drop-shadow(0 0 12px rgba(91, 255, 99, 0.2))
    drop-shadow(0 10px 22px rgba(0, 0, 0, 0.5));
}

.story-text {
  margin: 0 0 14px;
  font-size: clamp(1rem, 3.8vw, 1.15rem);
  line-height: 1.5;
  color: var(--text);
}

.story-text--emph {
  color: var(--accent);
  font-weight: 700;
}

.story-cta {
  margin-top: 22px;
}

/* ——— Inventoriaus tinklelis (pikselinės ikonos) ——— */

.inv-section__subtitle {
  margin: 0 0 10px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.inv-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.inv-grid--gear {
  grid-template-columns: repeat(auto-fill, minmax(76px, 1fr));
}

@media (min-width: 400px) {
  .inv-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }
}

.inv-tile {
  position: relative;
  aspect-ratio: 1;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: linear-gradient(145deg, rgba(26, 32, 40, 0.95), rgba(14, 16, 20, 0.92));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 6px 4px 8px;
  cursor: pointer;
  transition: transform 0.12s ease, border-color 0.12s ease, box-shadow 0.12s ease;
  -webkit-tap-highlight-color: transparent;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.inv-tile:active {
  transform: scale(0.97);
}

.inv-tile:focus {
  outline: none;
  border-color: rgba(196, 92, 62, 0.55);
  box-shadow: 0 0 0 3px rgba(196, 92, 62, 0.15);
}

.inv-tile--empty {
  opacity: 0.45;
  cursor: default;
}

.inv-tile--empty:active {
  transform: none;
}

.inv-tile__img {
  width: 52%;
  height: auto;
  max-height: 48%;
  object-fit: contain;
  margin-bottom: 4px;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.45));
}

.inv-tile__label {
  font-size: 0.6rem;
  line-height: 1.15;
  text-align: center;
  color: var(--text-muted);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.inv-tile__qty {
  position: absolute;
  top: 4px;
  right: 5px;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--warning);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
  background: rgba(0, 0, 0, 0.45);
  padding: 1px 5px;
  border-radius: 6px;
  letter-spacing: 0.02em;
}

.inv-tile__qty--eq {
  color: var(--success);
  background: rgba(0, 0, 0, 0.55);
}

/* ——— Inventoriaus filtravimo juosta ——— */

.inv-filter-bar {
  display: flex;
  gap: 6px;
  margin: 0 0 12px;
  padding: 4px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.inv-filter-bar::-webkit-scrollbar {
  display: none;
}

.inv-filter-btn {
  flex: 1 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}

.inv-filter-btn:active {
  transform: scale(0.97);
}

.inv-filter-btn--active {
  background: var(--bg-elevated);
  color: var(--accent);
  border-color: rgba(196, 92, 62, 0.45);
  box-shadow: inset 0 0 0 1px rgba(196, 92, 62, 0.15);
}

/* Scroll'inamas inventoriaus konteineris (50+ daiktų) */

.inv-wrap {
  position: relative;
}

.inv-grid--scroll {
  max-height: 52dvh;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 4px;
  margin: 0 -4px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.inv-grid--scroll::-webkit-scrollbar {
  width: 6px;
}

.inv-grid--scroll::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}

.inv-grid--scroll::-webkit-scrollbar-track {
  background: transparent;
}

.gear-slot--interactive {
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.gear-slot--interactive:active {
  transform: scale(0.99);
}

.gear-slot__hint {
  margin-top: 8px;
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* ——— Survivor ID Card / Passport ——— */

@keyframes poison-flicker {
  0%, 100% {
    filter: brightness(1);
    opacity: 0.92;
  }
  45% {
    filter: brightness(1.7) saturate(1.5);
    opacity: 1;
  }
  62% {
    filter: brightness(0.8);
    opacity: 0.72;
  }
}

.survivor-passport {
  position: relative;
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 12px;
  overflow: hidden;
  padding: 12px;
  border: 1px solid rgba(193, 211, 229, 0.18);
  border-image: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.18),
    rgba(196, 92, 62, 0.5) 32%,
    rgba(255, 255, 255, 0.08) 64%,
    rgba(91, 255, 99, 0.18)
  ) 1;
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), transparent 34%),
    radial-gradient(ellipse 120% 80% at 15% 0%, rgba(58, 120, 170, 0.2), transparent 46%),
    linear-gradient(145deg, rgba(18, 23, 30, 0.72), rgba(5, 7, 10, 0.88));
  box-shadow:
    0 18px 45px rgba(0, 0, 0, 0.48),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -18px 34px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(14px) saturate(1.18);
}

.survivor-passport::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(
      92deg,
      rgba(255, 255, 255, 0.035) 0 1px,
      transparent 1px 14px
    ),
    linear-gradient(135deg, rgba(0, 0, 0, 0.32), transparent 28%, transparent 70%, rgba(0, 0, 0, 0.38));
  mix-blend-mode: screen;
  opacity: 0.52;
}

.survivor-passport::after {
  content: "";
  position: absolute;
  inset: 6px;
  pointer-events: none;
  border: 1px dashed rgba(230, 232, 236, 0.16);
  border-radius: 11px;
  opacity: 0.7;
}

.survivor-passport__avatar {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 76px;
  min-height: 96px;
  border: 1px solid rgba(110, 195, 255, 0.36);
  border-radius: 10px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 24%, rgba(122, 211, 255, 0.38), transparent 19%),
    radial-gradient(circle at 50% 63%, rgba(67, 137, 190, 0.36), transparent 32%),
    linear-gradient(180deg, rgba(7, 24, 37, 0.96), rgba(4, 10, 17, 0.98));
  box-shadow:
    inset 0 0 24px rgba(78, 187, 255, 0.18),
    0 8px 22px rgba(0, 0, 0, 0.36);
  color: rgba(210, 238, 255, 0.88);
  font-family: var(--font-mono);
  font-size: 2.2rem;
  font-weight: 800;
  text-shadow: 0 0 12px rgba(97, 190, 255, 0.55);
}

.survivor-passport__avatar::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    180deg,
    rgba(137, 220, 255, 0.14) 0 1px,
    transparent 1px 4px
  );
  opacity: 0.62;
}

.survivor-passport__avatar::after {
  content: "SCAN";
  position: absolute;
  right: 5px;
  bottom: 5px;
  font-family: var(--font-mono);
  font-size: 0.52rem;
  letter-spacing: 0.14em;
  color: rgba(126, 217, 255, 0.7);
}

.survivor-passport__avatar span {
  position: relative;
  z-index: 1;
}

.survivor-passport__avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  image-rendering: pixelated;
  filter: saturate(0.85) contrast(1.06) brightness(0.96) hue-rotate(-4deg);
  z-index: 0;
}

.survivor-passport__avatar--has-image > span {
  display: none;
}

.survivor-passport__origin {
  margin: 4px 0 8px;
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(180, 200, 195, 0.7);
}

.survivor-passport__origin b {
  color: #a9f5b6;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: none;
}

.survivor-passport__identity,
.survivor-passport__vitals {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.survivor-passport__agency {
  margin: 0 0 4px;
  max-width: calc(100% - 66px);
  font-family: var(--font-mono);
  font-size: 0.52rem;
  line-height: 1.25;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(190, 205, 220, 0.75);
}

.survivor-passport__name {
  margin: 0;
  font-size: clamp(1.18rem, 5.4vw, 1.8rem);
  line-height: 1.02;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.survivor-passport__title {
  margin: 3px 0 10px;
  font-size: 0.78rem;
  color: #9cc7df;
}

.passport-xp__meta,
.passport-stat__label {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
}

.passport-xp__track,
.passport-stat__track {
  height: 6px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.42);
}

.passport-xp__fill,
.passport-stat__track > div {
  height: 100%;
  border-radius: inherit;
  transition: width 0.45s cubic-bezier(0.33, 1, 0.68, 1);
}

.passport-xp__fill {
  background: linear-gradient(90deg, #6f7d8d, #d7e2ee);
  box-shadow: 0 0 10px rgba(215, 226, 238, 0.28);
}

.survivor-passport__vitals {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}

.passport-stat__label b {
  color: var(--text);
  font-weight: 700;
}

.passport-stat__track--hp > div {
  background: linear-gradient(90deg, #5b1118, #b72e37, #e15b5b);
  box-shadow: 0 0 12px rgba(194, 61, 61, 0.42);
}

.passport-stat__track--energy > div {
  background: linear-gradient(90deg, #7a4200, #ff9f1a, #ffd166);
  box-shadow: 0 0 14px rgba(255, 159, 26, 0.45);
}

.passport-stat__track--mood > div {
  background: linear-gradient(90deg, #5532b8, #8d7cff, #6ee7ff);
  box-shadow: 0 0 14px rgba(110, 231, 255, 0.35);
}

.passport-stat__track--poison > div {
  animation: poison-flicker 1.1s infinite steps(3, end);
  background: linear-gradient(90deg, #1c6b20, #7dff33, #caff7a);
  box-shadow: 0 0 16px rgba(125, 255, 51, 0.55);
}

.passport-stat--poison {
  grid-column: 1 / -1;
}

.survivor-passport__stamp {
  position: absolute;
  z-index: 2;
  top: 8px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  transform: rotate(-13deg);
  border: 4px double rgba(255, 78, 78, 0.92);
  border-radius: 50%;
  color: rgba(255, 85, 85, 0.95);
  background: rgba(80, 0, 0, 0.07);
  box-shadow:
    inset 0 0 18px rgba(255, 0, 0, 0.14),
    0 0 16px rgba(255, 0, 0, 0.13);
  font-family: var(--font-mono);
  text-align: center;
  text-transform: uppercase;
  mix-blend-mode: screen;
}

.survivor-passport__stamp::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid rgba(255, 78, 78, 0.75);
  border-radius: 50%;
}

.survivor-passport__stamp-label {
  display: block;
  margin-bottom: -20px;
  font-size: 0.55rem;
  letter-spacing: 0.18em;
}

.survivor-passport__stamp strong {
  display: block;
  font-size: 1.45rem;
  line-height: 1;
}

.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
}

.skills-list--passport {
  grid-template-columns: 1fr;
  gap: 6px;
}

.skills-list--passport .skill-item {
  padding: 7px 8px;
  background: rgba(9, 12, 16, 0.54);
  border-color: rgba(255, 255, 255, 0.08);
}

.gear-grid--passport {
  grid-template-columns: 1fr;
  gap: 6px;
}

.gear-grid--passport .gear-slot {
  min-height: 74px;
  padding: 8px;
  border-style: solid;
  background: rgba(9, 12, 16, 0.54);
}

.gear-grid--passport .gear-slot__pic {
  width: 38px;
  height: 38px;
  margin: 2px auto 6px;
}

.gear-grid--passport .gear-slot__name {
  font-size: 0.76rem;
  line-height: 1.2;
}

.gear-grid--passport .gear-slot__hint {
  display: none;
}

@media (min-width: 390px) {
  .survivor-passport {
    grid-template-columns: 82px minmax(0, 1fr) 128px;
  }

  .survivor-passport__avatar {
    width: 82px;
    min-height: 112px;
  }

  .survivor-passport__vitals {
    grid-column: auto;
    grid-template-columns: 1fr;
    align-content: center;
  }

  .survivor-passport__agency {
    max-width: calc(100% - 24px);
  }
}

@media (max-width: 345px) {
  .survivor-passport {
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 9px;
    padding: 10px;
  }

  .survivor-passport__avatar {
    width: 64px;
    min-height: 86px;
    font-size: 1.8rem;
  }

  .survivor-passport__stamp {
    width: 56px;
    height: 56px;
  }

  .survivor-passport__vitals {
    grid-template-columns: 1fr;
  }
}

/* ——— Modalas (stikliškas fonas) ——— */

.modal {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
  padding-bottom: calc(16px + env(safe-area-inset-bottom, 0));
}

.modal[hidden] {
  display: none !important;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 6, 8, 0.62);
  backdrop-filter: blur(8px) brightness(0.85);
}

.modal__box {
  position: relative;
  z-index: 1;
  width: min(100%, 400px);
  max-height: min(78dvh, 560px);
  overflow-y: auto;
  border-radius: 18px;
  padding: 20px 18px 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(22, 26, 32, 0.88);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(18px) saturate(1.12);
}

.modal__close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.25);
  color: var(--text);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease;
}

.modal__close:hover,
.modal__close:focus-visible {
  background: rgba(255, 255, 255, 0.1);
  outline: none;
}

.modal__visual {
  display: flex;
  justify-content: center;
  margin: 8px 0 12px;
}

.modal__icon {
  width: 88px;
  height: 88px;
  object-fit: contain;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.22);
  padding: 8px;
  border: 1px solid var(--border);
}

.modal__icon[hidden] {
  display: none;
}

.modal__title {
  margin: 0 0 8px;
  font-size: 1.12rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.25;
}

.modal__desc {
  margin: 0 0 10px;
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.45;
  text-align: center;
}

.modal__meta {
  margin: 0 0 14px;
  font-size: 0.78rem;
  color: var(--warning);
  text-align: center;
  font-family: var(--font-mono);
}

.modal__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.modal__actions .btn {
  min-height: 46px;
}

.btn--danger {
  background: rgba(120, 40, 40, 0.35);
  border: 1px solid rgba(184, 74, 74, 0.45);
  color: #f0c4c4;
}

.btn--danger:disabled {
  opacity: 0.45;
}

/* ===========================================================================
   Personažo pasirinkimas — mobile-first karuselė
   =========================================================================== */

@keyframes character-pulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(108, 247, 130, 0.55),
                0 0 18px rgba(108, 247, 130, 0.22) inset;
  }
  50% {
    box-shadow: 0 0 0 6px rgba(108, 247, 130, 0.10),
                0 0 28px rgba(108, 247, 130, 0.42) inset;
  }
}

@keyframes char-slide-in-right {
  from { opacity: 0; transform: translateX(36px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes char-slide-in-left {
  from { opacity: 0; transform: translateX(-36px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes char-fade-in {
  from { opacity: 0; transform: scale(0.98); }
  to   { opacity: 1; transform: scale(1); }
}

.flow-screen--character .flow-screen__panel {
  max-width: 460px;
  width: min(96vw, 460px);
  padding: 18px 14px 22px;
}

.flow-screen__brand--compact {
  margin-bottom: 6px;
}

.character-screen__title {
  margin: 4px 0 2px;
  text-align: center;
  font-family: var(--font-display, "Cinzel", "Georgia", serif);
  font-size: clamp(1.0rem, 4.6vw, 1.35rem);
  letter-spacing: 0.1em;
  color: #e3eaef;
  text-shadow: 0 0 14px rgba(108, 247, 130, 0.15);
}

.character-screen__sub {
  margin: 0 0 14px;
  text-align: center;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(214, 224, 232, 0.62);
}

/* --- Carousel layout --- */
.character-carousel {
  display: grid;
  grid-template-columns: 40px 1fr 40px;
  align-items: center;
  gap: 8px;
  margin: 0 auto;
  max-width: 380px;
}

.character-carousel__nav {
  appearance: none;
  width: 40px;
  height: 84px;
  background: linear-gradient(180deg, rgba(20, 24, 28, 0.85), rgba(8, 10, 12, 0.92));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  color: rgba(214, 224, 232, 0.85);
  font-size: 28px;
  line-height: 1;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition: transform 120ms ease, background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.character-carousel__nav:hover,
.character-carousel__nav:focus-visible {
  background: linear-gradient(180deg, rgba(28, 48, 34, 0.85), rgba(10, 18, 12, 0.92));
  border-color: rgba(108, 247, 130, 0.45);
  color: #c1ffce;
  outline: none;
}

.character-carousel__nav:active {
  transform: scale(0.94);
}

.character-carousel__stage {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: stretch;
  min-height: 1px;
  touch-action: pan-y;
}

/* --- Active card (single, centered) --- */
.character-card {
  width: 100%;
  background:
    linear-gradient(180deg, rgba(16, 32, 22, 0.7), rgba(6, 12, 9, 0.92)),
    radial-gradient(circle at 50% 0%, rgba(108, 247, 130, 0.18), transparent 65%);
  border: 1px solid #6cf782;
  border-radius: 16px;
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 0 24px rgba(108, 247, 130, 0.18),
              0 10px 30px rgba(0, 0, 0, 0.5);
  animation: char-fade-in 240ms ease;
}

.character-card--slide-right {
  animation: char-slide-in-right 280ms ease;
}

.character-card--slide-left {
  animation: char-slide-in-left 280ms ease;
}

.character-card__portrait {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #0a0c10;
  border-bottom: 1px solid rgba(108, 247, 130, 0.35);
  overflow: hidden;
}

.character-card__portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  image-rendering: pixelated;
  filter: saturate(0.92) contrast(1.05);
  display: block;
}

.character-card__portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(255, 255, 255, 0.05) 0 1px,
    transparent 1px 3px
  );
  pointer-events: none;
}

.character-card__meta {
  padding: 12px 14px 14px;
  text-align: center;
}

.character-card__name {
  margin: 0;
  font-family: var(--font-display, "Cinzel", "Georgia", serif);
  font-size: 1.25rem;
  letter-spacing: 0.1em;
  color: #c1ffce;
  text-transform: uppercase;
  text-shadow: 0 0 12px rgba(108, 247, 130, 0.45);
}

.character-card__role {
  margin: 4px 0 10px;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(180, 200, 195, 0.78);
}

.character-card__bonus {
  display: inline-block;
  padding: 5px 12px;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: #a9f5b6;
  background: rgba(108, 247, 130, 0.12);
  border: 1px solid rgba(108, 247, 130, 0.45);
  border-radius: 999px;
}

/* --- Dots indicator --- */
.character-carousel__dots {
  display: flex;
  justify-content: center;
  gap: 7px;
  margin: 12px 0 4px;
}

.character-carousel__dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  cursor: pointer;
  transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.character-carousel__dot--active {
  background: #6cf782;
  transform: scale(1.3);
  box-shadow: 0 0 10px rgba(108, 247, 130, 0.55);
}

/* --- Description block --- */
.character-info {
  margin: 10px 4px 0;
  text-align: center;
  font-size: 0.85rem;
  line-height: 1.45;
  color: rgba(210, 220, 215, 0.85);
  min-height: 3.2em;
}

.character-info__tag {
  margin: 0 0 6px;
  font-style: italic;
  color: rgba(220, 230, 220, 0.92);
}

.character-info__meta {
  margin: 0;
  font-size: 0.78rem;
  color: rgba(190, 210, 200, 0.78);
}

.character-info b {
  color: #c1ffce;
  font-weight: 600;
}

/* --- Confirm button --- */
.character-screen__actions {
  margin-top: 16px;
  display: flex;
  justify-content: center;
}

.character-screen__confirm {
  width: 100%;
  min-height: 48px;
  letter-spacing: 0.06em;
}

.character-screen__confirm:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: grayscale(0.4);
}

/* --- Tablet / wider phones --- */
@media (min-width: 520px) {
  .flow-screen--character .flow-screen__panel {
    max-width: 500px;
    width: min(96vw, 500px);
    padding: 22px 18px 24px;
  }
  .character-carousel { max-width: 420px; }
  .character-carousel__nav { width: 44px; height: 92px; font-size: 30px; }
  .character-card__name { font-size: 1.35rem; }
}

/* ===========================================================================
   Hero status pill (top-bar) + Nuotykių tab'as.
   =========================================================================== */
.hero-status {
  margin: 6px 0 0;
  padding: 6px 10px;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(20, 24, 28, 0.55);
  color: rgba(214, 224, 232, 0.78);
  text-align: center;
  backdrop-filter: blur(6px);
  transition: background 200ms ease, border-color 200ms ease, color 200ms ease;
}

.hero-status--base {
  border-color: rgba(108, 247, 130, 0.32);
  color: #a9f5b6;
  background: rgba(10, 22, 14, 0.55);
}

.hero-status--away {
  border-color: rgba(196, 92, 62, 0.55);
  color: #f3b89e;
  background: rgba(36, 18, 12, 0.55);
  animation: hero-status-pulse 2.2s ease-in-out infinite;
}

@keyframes hero-status-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(196, 92, 62, 0); }
  50%      { box-shadow: 0 0 14px 0 rgba(196, 92, 62, 0.35); }
}

.adventure-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-top: 10px;
}

.adventure-card {
  padding: 12px 14px;
}

.adventure-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.adventure-card__title {
  margin: 0;
  font-family: var(--font-display, "Cinzel", "Georgia", serif);
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  color: var(--text);
  text-transform: uppercase;
}

.adventure-card__meta,
.adventure-card__blurb {
  margin: 0 0 8px;
  font-size: 0.82rem;
  color: rgba(210, 220, 215, 0.78);
}

.adventure-card__blurb {
  font-style: italic;
  opacity: 0.85;
}

.adventure-card__meta b {
  color: var(--text);
}

.adventure-card .btn {
  width: 100%;
  min-height: 44px;
}

.adventure-card--active {
  border: 1px solid rgba(196, 92, 62, 0.55);
  box-shadow: 0 0 18px rgba(196, 92, 62, 0.18);
}

.adventure-zone {
  display: inline-block;
  padding: 3px 9px;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 999px;
  border: 1px solid currentColor;
}

.adventure-zone--yellow { color: #e8c34a; background: rgba(232, 195, 74, 0.08); }
.adventure-zone--orange { color: #e07a2c; background: rgba(224, 122, 44, 0.08); }
.adventure-zone--red    { color: #d3414a; background: rgba(211, 65, 74, 0.08); }

.adventure-status {
  border: 1px solid rgba(196, 92, 62, 0.45);
  background:
    linear-gradient(180deg, rgba(36, 18, 12, 0.55), rgba(8, 10, 12, 0.88)),
    radial-gradient(circle at 50% 0%, rgba(196, 92, 62, 0.18), transparent 65%);
}

.adventure-status__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 6px;
  font-size: 0.82rem;
  color: rgba(210, 220, 215, 0.82);
}

.adventure-status__phase {
  margin: 0 0 8px;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(243, 184, 158, 0.85);
}

.adventure-progress {
  height: 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  position: relative;
  margin-bottom: 8px;
}

.adventure-progress__fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #c45c3e, #f0a05a, #c45c3e);
  background-size: 200% 100%;
  animation: adv-progress-stripes 2.4s linear infinite;
  transition: width 0.45s cubic-bezier(0.33, 1, 0.68, 1);
  box-shadow: 0 0 10px rgba(196, 92, 62, 0.5);
}

@keyframes adv-progress-stripes {
  from { background-position: 0 0; }
  to   { background-position: 200% 0; }
}

.adventure-status__timer {
  margin: 0;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  color: var(--text);
}

.adventure-status__timer b {
  font-size: 1.15rem;
  color: #f3b89e;
}

/* ===========================================================================
   GYVUMO ANIMACIJOS — animuotos juostos, štampo dūzgimas, scan-line, nav glow.
   Tikslas: pažadinti UI nesivarginant performansu — visi efektai naudoja tik
   `transform`, `opacity`, `box-shadow`, `background-position`.
   =========================================================================== */

@keyframes bar-shimmer {
  0%   { transform: translateX(-110%); opacity: 0; }
  10%  { opacity: 1; }
  60%  { transform: translateX(140%); opacity: 1; }
  100% { transform: translateX(140%); opacity: 0; }
}

@keyframes hp-critical {
  0%, 100% {
    box-shadow: 0 0 12px rgba(194, 61, 61, 0.42);
    filter: brightness(1);
  }
  50% {
    box-shadow: 0 0 26px rgba(255, 72, 72, 0.9), 0 0 6px rgba(255, 130, 130, 0.6);
    filter: brightness(1.18);
  }
}

@keyframes energy-glow {
  0%, 100% { box-shadow: 0 0 12px rgba(255, 159, 26, 0.32); }
  50%      { box-shadow: 0 0 22px rgba(255, 200, 80, 0.7); }
}

@keyframes mood-drift {
  0%, 100% { background-position: 0% 0; }
  50%      { background-position: 100% 0; }
}

@keyframes xp-stripes {
  from { background-position: 0 0, 0 0; }
  to   { background-position: 0 0, 28px 0; }
}

@keyframes xp-glow {
  0%, 100% { box-shadow: 0 0 8px rgba(215, 226, 238, 0.22); }
  50%      { box-shadow: 0 0 16px rgba(215, 226, 238, 0.55); }
}

@keyframes stamp-throb {
  0%, 100% {
    transform: rotate(-13deg) scale(1);
    box-shadow:
      inset 0 0 18px rgba(255, 0, 0, 0.14),
      0 0 14px rgba(255, 0, 0, 0.12);
  }
  50% {
    transform: rotate(-13deg) scale(1.04);
    box-shadow:
      inset 0 0 22px rgba(255, 0, 0, 0.22),
      0 0 22px rgba(255, 0, 0, 0.36);
  }
}

@keyframes scan-rolling {
  from { background-position: 0 0; }
  to   { background-position: 0 4px; }
}

@keyframes scan-sweep {
  0%   { top: -6%; opacity: 0; }
  12%  { opacity: 0.85; }
  88%  { opacity: 0.85; }
  100% { top: 104%; opacity: 0; }
}

@keyframes nav-glow {
  0%, 100% { opacity: 0.55; box-shadow: 0 0 6px rgba(196, 92, 62, 0.5); }
  50%      { opacity: 1;    box-shadow: 0 0 14px rgba(196, 92, 62, 0.9); }
}

@keyframes brand-flicker {
  0%, 92%, 100% { filter: drop-shadow(0 0 6px rgba(108, 247, 130, 0.18)); }
  94%           { filter: drop-shadow(0 0 14px rgba(108, 247, 130, 0.55)); }
  96%           { filter: drop-shadow(0 0 4px rgba(108, 247, 130, 0.12)); }
}

@keyframes panel-fade {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* --- Universal bar shimmer sweep (HP, Energija, Nuotaika, Poison, XP) --- */
.passport-xp__fill,
.passport-stat__track > div {
  position: relative;
  overflow: hidden;
}

.passport-xp__fill::after,
.passport-stat__track > div::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0,
    rgba(255, 255, 255, 0.22) 50%,
    transparent 100%
  );
  transform: translateX(-110%);
  animation: bar-shimmer 2.8s cubic-bezier(0.55, 0.05, 0.45, 1) infinite;
  pointer-events: none;
  mix-blend-mode: screen;
}

/* Skirtingos juostos — skirtingi „tempo" ir gloss tonai. */
.passport-stat__track--hp > div::after        { animation-duration: 2.4s; animation-delay: 0.1s; }
.passport-stat__track--energy > div::after    { animation-duration: 1.9s; }
.passport-stat__track--mood > div::after      { animation-duration: 3.6s; }
.passport-stat__track--poison > div::after    { animation-duration: 1.4s; }
.passport-xp__fill::after                     { animation-duration: 2.2s; animation-delay: 0.2s; }

/* HP žemas (-25%) — pulsuojantis kraujavimo efektas (klasė užteptama iš JS). */
.passport-stat__track--hp.passport-stat__track--low > div {
  animation: hp-critical 0.95s ease-in-out infinite;
}

/* Energija — visada lengvai švyti. */
.passport-stat__track--energy > div {
  animation: energy-glow 2.6s ease-in-out infinite;
}

/* Nuotaika — gradiento slinkimas tarp purpurinės ir žydros. */
.passport-stat__track--mood > div {
  background: linear-gradient(90deg, #5532b8, #8d7cff, #6ee7ff, #8d7cff, #5532b8);
  background-size: 220% 100%;
  animation: mood-drift 5.2s ease-in-out infinite;
}

/* XP — slenkančios diagonalios juostos + švelnus švytėjimas. */
.passport-xp__fill {
  background:
    linear-gradient(90deg, #6f7d8d, #d7e2ee),
    repeating-linear-gradient(
      45deg,
      rgba(255, 255, 255, 0.14) 0 6px,
      transparent 6px 14px
    );
  background-blend-mode: overlay;
  animation: xp-stripes 1.8s linear infinite, xp-glow 2.6s ease-in-out infinite;
}

/* KG štampas — lengvas „antspaudo" dūzgimas. */
.survivor-passport__stamp {
  animation: stamp-throb 3.4s ease-in-out infinite;
  transform-origin: 50% 50%;
}

/* Avataras — slankiojanti vertikali skenavimo linija ir judantis scanline rastras. */
.survivor-passport__avatar::before {
  animation: scan-rolling 1.4s linear infinite;
}

.survivor-passport__avatar .scan-bar {
  position: absolute;
  left: 0;
  right: 0;
  top: -6%;
  height: 14%;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(146, 220, 255, 0.32) 45%,
    rgba(220, 240, 255, 0.55) 50%,
    rgba(146, 220, 255, 0.32) 55%,
    transparent 100%
  );
  filter: blur(0.4px);
  pointer-events: none;
  animation: scan-sweep 4s ease-in-out infinite;
  z-index: 2;
}

/* Apačios meniu — aktyvaus mygtuko švytintis paryškinimas. */
.bottom-nav__btn--active {
  position: relative;
}

.bottom-nav__btn--active::after {
  content: "";
  position: absolute;
  left: 22%;
  right: 22%;
  top: 4px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--accent) 50%,
    transparent
  );
  animation: nav-glow 1.8s ease-in-out infinite;
  pointer-events: none;
}

.bottom-nav__btn {
  transition: background 0.15s ease, color 0.15s ease, transform 0.12s ease;
}

.bottom-nav__btn:active {
  transform: scale(0.94);
}

/* Brand logo — retas „migtelėjimas" lyg neonas. */
.brand__logo {
  animation: brand-flicker 7s ease-in-out infinite;
}

/* Kortelės atsiranda su mini fade-up. */
.card {
  animation: panel-fade 0.35s ease both;
}

/* Resursų ir inventoriaus plytelių interakcija. */
.res-tile,
.inv-tile {
  transition: transform 0.14s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.res-tile:hover,
.inv-tile:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45),
              0 0 12px rgba(196, 92, 62, 0.18);
  border-color: rgba(196, 92, 62, 0.45);
}

.res-tile:active,
.inv-tile:active {
  transform: scale(0.96);
}

/* --- Nav v3: Pagrindinis / Profilis / Žemėlapis --- */
.panel-inner--map {
  flex: 1 1 auto;
  min-height: 0;
  justify-content: center;
  padding-bottom: calc(8px + var(--safe-bottom));
}

.map-card {
  flex: 0 1 auto;
  width: 100%;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.profile-subnav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-bottom: 12px;
}

.profile-subnav__btn {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 10px 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(20, 24, 28, 0.65);
  color: rgba(214, 224, 232, 0.75);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.profile-subnav__btn.is-active {
  border-color: rgba(108, 247, 130, 0.55);
  background: rgba(12, 28, 18, 0.75);
  color: #c1ffce;
  box-shadow: 0 0 14px rgba(108, 247, 130, 0.15);
}

.profile-grid--solo {
  grid-template-columns: 1fr;
}

/* --- Žemėlapis --- */
.map-card .map-stage {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: #0a0d10;
  margin-top: 8px;
}

.map-stage__img {
  display: block;
  width: 100%;
  height: auto;
  vertical-align: middle;
  min-height: 280px;
  aspect-ratio: 800 / 520;
  object-fit: contain;
  object-position: center center;
}

.map-pins {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* Žymeklis: tikslus taškas miesto pozicijoje + atskira etiketė šalia. */
.map-pin {
  pointer-events: auto;
  position: absolute;
  z-index: 2;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  padding: 0;
  border: 0;
  background: transparent;
  font-family: inherit;
  cursor: pointer;
}

.map-pin__dot {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 12px;
  margin: -6px 0 0 -6px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid rgba(8, 10, 12, 0.95);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85), 0 0 0 4px rgba(8, 10, 12, 0.7), 0 4px 10px rgba(0, 0, 0, 0.6);
  transition: transform 0.12s ease;
}

.map-pin__dot--base {
  width: 24px;
  height: 24px;
  margin: -12px 0 0 -12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  line-height: 1;
  background: rgba(22, 18, 8, 0.95);
  border-color: rgba(232, 195, 74, 0.9);
  box-shadow: 0 0 0 2px rgba(232, 195, 74, 0.45), 0 4px 12px rgba(0, 0, 0, 0.65);
}

.map-pin__label {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: inline-block;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(8, 10, 12, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--text);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  line-height: 1.1;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.55);
  pointer-events: none;
}

.map-pin--label-right .map-pin__label { transform: translate(14px, -50%); left: 0; }
.map-pin--label-left  .map-pin__label { transform: translate(calc(-100% - 14px), -50%); left: 0; }
.map-pin--label-above .map-pin__label { transform: translate(-50%, calc(-100% - 12px)); top: 0; }
.map-pin--label-below .map-pin__label { transform: translate(-50%, 12px); top: 0; }

.map-pin:hover .map-pin__dot { transform: scale(1.18); }
.map-pin:active .map-pin__dot { transform: scale(0.92); }

.map-pin--base { pointer-events: none; cursor: default; }

/* Zonų akcentas: spalvotas ring'as aplink baltą dot'ą — kontrastas išlieka. */
.map-pin--city.adventure-zone--yellow .map-pin__dot { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85), 0 0 0 4px rgba(232, 195, 74, 0.9), 0 4px 10px rgba(0, 0, 0, 0.6); }
.map-pin--city.adventure-zone--orange .map-pin__dot { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85), 0 0 0 4px rgba(224, 122, 44, 0.95), 0 4px 10px rgba(0, 0, 0, 0.6); }
.map-pin--city.adventure-zone--red    .map-pin__dot { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85), 0 0 0 4px rgba(211, 65, 74, 0.95), 0 4px 10px rgba(0, 0, 0, 0.6); }

.map-pin--city.adventure-zone--yellow .map-pin__label { border-color: rgba(232, 195, 74, 0.7); }
.map-pin--city.adventure-zone--orange .map-pin__label { border-color: rgba(224, 122, 44, 0.78); }
.map-pin--city.adventure-zone--red    .map-pin__label { border-color: rgba(211, 65, 74, 0.85); color: #ffd9dd; }

.map-pin--base.adventure-zone--yellow .map-pin__label {
  border-color: rgba(232, 195, 74, 0.7);
  color: #f5ecc8;
  background: rgba(22, 18, 8, 0.95);
}

/* --- Kalibravimo režimas: vilkimas ant taško --- */
.map-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 6px 0 0;
  flex-wrap: wrap;
}

.map-tools__hint {
  font-size: 0.7rem;
  color: rgba(200, 215, 220, 0.7);
  letter-spacing: 0.02em;
}

.map-stage.is-calibrating { cursor: crosshair; }
.map-stage.is-calibrating .map-pin { cursor: grab; pointer-events: auto !important; }
.map-stage.is-calibrating .map-pin:active { cursor: grabbing; }
.map-stage.is-calibrating .map-pin--base { pointer-events: auto !important; }
.map-stage.is-calibrating .map-pin__dot { box-shadow: 0 0 0 2px rgba(108, 247, 130, 0.6), 0 4px 10px rgba(0, 0, 0, 0.55); }

.map-hud {
  margin-bottom: 10px;
}

/* --- Pagrindinis (chat placeholder) --- */
.home-info {
  font-size: 0.88rem;
  line-height: 1.45;
  color: rgba(220, 228, 232, 0.88);
}

.home-feed {
  margin: 10px 0 0;
  padding-left: 18px;
  font-size: 0.82rem;
  color: rgba(200, 210, 215, 0.85);
  line-height: 1.45;
}

.home-chat-card .home-chat-placeholder {
  margin-top: 0;
}

.home-chat-mock {
  margin: 10px 0;
  padding: 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px dashed rgba(255, 255, 255, 0.12);
  max-height: 160px;
  overflow-y: auto;
}

.home-chat__msg {
  font-size: 0.82rem;
  margin-bottom: 8px;
  color: rgba(210, 218, 222, 0.88);
}

.home-chat__msg--sys span {
  display: block;
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(108, 247, 130, 0.65);
  margin-bottom: 4px;
}

.home-chat-input-wrap {
  display: block;
  margin-top: 8px;
}

.home-chat-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.4);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.88rem;
}

/* --- Įgūdžių skydelis --- */
.btn--compact {
  padding: 8px 12px;
  min-height: 40px;
  font-size: 0.75rem;
}

.skills-panel__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.skills-panel__title {
  margin: 0;
}

.skills-panel__season {
  margin: 0 0 12px;
  font-size: 0.72rem;
  color: rgba(190, 205, 210, 0.82);
  line-height: 1.4;
}

.skills-panel__caps-hint {
  display: block;
  margin-top: 4px;
  font-size: 0.64rem;
  opacity: 0.75;
}

.skills-panel__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.skill-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.skill-row__icon {
  font-size: 1.6rem;
  line-height: 1;
  flex-shrink: 0;
}

.skill-row__icon--tiny {
  font-size: 1.1rem;
}

.skill-row__body {
  flex: 1;
  min-width: 0;
}

.skill-row__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 6px;
}

.skill-row__name {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text);
}

.skill-row__lvl {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: #a9f5b6;
  flex-shrink: 0;
}

.skill-row__lvl-cap {
  opacity: 0.55;
  font-size: 0.72rem;
}

.skill-row__xp-label {
  display: block;
  font-size: 0.62rem;
  color: rgba(180, 195, 200, 0.78);
  margin: 2px 0 4px;
}

.skill-row__bar {
  height: 8px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.skill-row__bar--xp {
  margin-bottom: 4px;
}

.skill-row__fill {
  height: 100%;
  border-radius: inherit;
  transition: width 0.5s cubic-bezier(0.33, 1, 0.68, 1);
  position: relative;
  overflow: hidden;
}

.skill-row__fill--xp {
  background: linear-gradient(90deg, #4a5c6e, #9ecfff);
  box-shadow: 0 0 10px rgba(158, 207, 255, 0.35);
}

.skill-row__fill--lvl {
  background: linear-gradient(90deg, #1a4d2e, #6cf782, #c1ffce);
  animation: skill-lvl-glow 2.4s ease-in-out infinite;
}

@keyframes skill-lvl-glow {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.12); }
}

.skills-panel--compact .skill-row {
  padding: 8px;
  gap: 8px;
}

.skills-panel--compact .skill-row__bar--xp {
  display: none;
}

.skills-panel--compact .skill-row__xp-label {
  display: none;
}

.modal-loot-list {
  margin: 8px 0 0;
  padding-left: 18px;
  text-align: left;
  font-size: 0.8rem;
  line-height: 1.4;
}

/* Pagarba sistemos nustatymams — sumažink judesį. */
@media (prefers-reduced-motion: reduce) {
  .passport-xp__fill::after,
  .passport-stat__track > div::after,
  .passport-stat__track--hp.passport-stat__track--low > div,
  .passport-stat__track--energy > div,
  .passport-stat__track--mood > div,
  .passport-xp__fill,
  .survivor-passport__stamp,
  .survivor-passport__avatar::before,
  .survivor-passport__avatar .scan-bar,
  .bottom-nav__btn--active::after,
  .brand__logo,
  .card,
  .skill-row__fill,
  .skill-row__fill--lvl {
    animation: none !important;
  }
}

@media (min-width: 480px) {
  .brand__title {
    font-size: 1.25rem;
  }
}
