/* ═══════════════════════════════════════════════════════
   VOID PACK — LAYOUT
   Shell, navigation, vues, responsive
═══════════════════════════════════════════════════════ */

/* ── Shell principal ─────────────────────────────────── */
.app-shell {
  width: 100%;
  min-height: 100svh;
}

.void-app-home-v16 {
  width: var(--shell-width);
  min-height: calc(100svh - 84px);
  margin: 0 auto;
  padding: 18px 16px 112px;
  display: grid;
}

.v16-phone-shell {
  min-height: calc(100svh - 128px);
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  gap: 14px;
}

/* ── Status bar ──────────────────────────────────────── */
.v16-statusbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.v16-profile-mini,
.v16-streak-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 8px 12px;
  border: 1px solid var(--void-border);
  border-radius: var(--radius-full);
  background: rgba(10, 12, 20, .58);
  backdrop-filter: blur(16px);
}

.v16-profile-mini strong {
  display: block;
  font-size: .8rem;
  line-height: 1;
  color: var(--void-text);
}

.v16-profile-mini span,
.v16-streak-pill {
  color: var(--void-muted);
  font-size: .72rem;
}

.v16-avatar-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--void-cyan), var(--void-purple));
  box-shadow: 0 0 18px rgba(123, 43, 255, .34);
  flex-shrink: 0;
}

.v16-statusbar__right {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Auth button */
.v16-auth-btn {
  min-height: 38px;
  padding: 0 16px;
  border-radius: var(--radius-full);
  border: 1px solid var(--void-border);
  background: rgba(88, 28, 255, .22);
  color: var(--void-text);
  font-size: .78rem;
  font-weight: 600;
  transition: background .15s;
}
.v16-auth-btn:hover { background: rgba(88, 28, 255, .38); }

/* ── XP Bar ──────────────────────────────────────────── */
.v16-xp-track {
  height: 9px;
  overflow: hidden;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .05);
}
.v16-xp-track span {
  display: block;
  width: var(--xp-progress, 0%);
  height: 100%;
  background: linear-gradient(90deg, var(--void-cyan), var(--void-purple));
  box-shadow: 0 0 24px rgba(123, 43, 255, .42);
  border-radius: var(--radius-full);
  transition: width .6s ease;
}

/* ── Bottom navigation ───────────────────────────────── */
.v16-bottom-nav {
  position: fixed !important;
  left: 50%;
  bottom: calc(12px + max(0px, env(safe-area-inset-bottom)));
  transform: translateX(-50%);
  width: min(calc(100% - 24px), 520px);
  z-index: 500 !important;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--void-border);
  border-radius: 26px;
  background: rgba(8, 10, 18, .74);
  backdrop-filter: blur(22px);
  box-shadow: 0 16px 50px rgba(0, 0, 0, .42);
}

.v16-bottom-nav button {
  min-height: 54px;
  border-radius: 18px;
  color: rgba(255, 255, 255, .45);
  background: transparent;
  display: grid;
  place-items: center;
  gap: 3px;
  transition: color .15s, background .15s;
}
.v16-bottom-nav button strong {
  font-size: .68rem;
  font-weight: 600;
}
.v16-bottom-nav button.is-active {
  color: #fff;
  background: rgba(255, 255, 255, .07);
  box-shadow: inset 0 0 22px rgba(123, 43, 255, .12);
}

/* ── App views ───────────────────────────────────────── */
.app-view { display: block; }
.app-view[hidden] { display: none; }

.app-view__inner {
  padding: 16px 16px 100px;
  max-width: var(--shell-width);
  margin: 0 auto;
}

.app-view__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.app-view__header h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--void-text);
  letter-spacing: .02em;
}

/* ── Bannières (daily + Twitch) ──────────────────────── */
.v16-daily-banner,
.v16-twitch-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(123, 43, 255, .28);
  background: rgba(10, 8, 22, .82);
}

[hidden].v16-daily-banner,
[hidden].v16-twitch-banner,
.v16-daily-banner[hidden],
.v16-twitch-banner[hidden] { display: none; }

.v16-daily-banner__label,
.v16-twitch-banner__text strong {
  font-size: .8rem;
  font-weight: 600;
  color: var(--void-text);
  flex: 1;
}

.v16-daily-banner__btn,
.v16-twitch-banner__btn {
  flex-shrink: 0;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid rgba(123, 43, 255, .45);
  border-radius: var(--radius-sm);
  background: rgba(123, 43, 255, .25);
  color: #fff;
  font-size: .76rem;
  font-weight: 700;
  transition: background .15s;
}
.v16-daily-banner__btn:hover,
.v16-twitch-banner__btn:hover {
  background: rgba(123, 43, 255, .45);
}

.v16-twitch-banner__icon { font-size: 1.2rem; flex-shrink: 0; }
.v16-twitch-banner__text { display: flex; flex-direction: column; gap: 2px; }
.v16-twitch-banner__text span { font-size: .68rem; color: var(--void-muted); }

/* ── Responsive desktop ──────────────────────────────── */
@media (min-width: 768px) {
  :root { --shell-width: min(100vw, 520px); }

  #view-collection,
  #view-communaute,
  #view-profil {
    width: 100%;
    max-width: 100%;
  }

  #view-collection .app-view__inner,
  #view-communaute .app-view__inner,
  #view-profil .app-view__inner {
    width: min(1100px, calc(100vw - 48px));
    max-width: 100%;
    margin: 0 auto;
    padding: 24px 32px 120px;
  }
}

@media (min-width: 1024px) {
  #view-collection .app-view__inner,
  #view-communaute .app-view__inner,
  #view-profil .app-view__inner {
    padding: 32px 48px 120px;
  }
}
