/* =========================================================
   LEVEL UP — FINAL PRESENTATION UI
========================================================= */

:root {
  --bg-1: #020611;
  --bg-2: #071429;
  --bg-3: #0c2244;

  --card: rgba(7, 24, 52, 0.82);
  --card-soft: rgba(255,255,255,.055);

  --white: #fff;
  --text: #edf5ff;
  --muted: #9eb2cf;

  --blue: #5b9cff;
  --blue-light: #a7d2ff;
  --blue-deep: #234f9a;

  --danger: #ff7088;
  --success: #7be7bd;

  --border: rgba(151,198,255,.23);

  --shadow: 0 20px 60px rgba(0,0,0,.38);
  --glow: 0 0 24px rgba(82,150,255,.25);

  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 15px;
}


/* RESET */

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;

  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Arial,
    sans-serif;

  color: var(--text);

  background:
    radial-gradient(circle at top, #123260 0%, transparent 35%),
    linear-gradient(145deg, var(--bg-1), var(--bg-2));

  overflow-x: hidden;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

img {
  max-width: 100%;
}

.hidden {
  display: none !important;
}

.screen {
  display: none;
  min-height: 100vh;
}

.screen.active-screen {
  display: flex;
}


/* INPUTS */

input,
textarea,
select {
  width: 100%;

  padding: 13px 14px;

  border: 1px solid rgba(150,195,255,.22);
  border-radius: 13px;

  color: var(--text);

  background: rgba(255,255,255,.06);

  outline: none;
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(82,150,255,.12);
}

select option {
  color: #0b1830;
}


/* BUTTONS */

.primary-button,
.secondary-button,
.danger-button {
  border-radius: 13px;
  padding: 12px 18px;
  font-weight: 800;
}

.primary-button {
  border: 0;
  color: white;

  background:
    linear-gradient(135deg, #2d69d7, #5b9cff);

  box-shadow:
    0 9px 26px rgba(59,126,239,.28);
}

.secondary-button {
  color: #d9eaff;

  background:
    rgba(255,255,255,.06);

  border:
    1px solid rgba(150,195,255,.2);
}

.danger-button {
  color: #ffdbe1;

  background:
    rgba(255,95,121,.12);

  border:
    1px solid rgba(255,112,136,.24);
}

.text-button {
  border: 0;
  color: var(--blue-light);
  background: transparent;
}

.icon-button {
  border: 0;

  min-width: 42px;
  min-height: 42px;

  color: inherit;
  background: transparent;

  border-radius: 12px;
}


/* LOADING */

.splash-screen {
  align-items: center;
  justify-content: center;

  padding: 20px;

  background:
    radial-gradient(circle at center, #123264 0%, transparent 42%),
    linear-gradient(145deg, #01050e, #07152b);
}

.splash-content {
  width: min(900px, 94vw);
  text-align: center;
}

.splash-main-image {
  width: 100%;
  max-height: 68vh;

  object-fit: contain;
  border-radius: 24px;

  filter:
    drop-shadow(0 25px 50px rgba(0,0,0,.35));
}

.loading-track {
  width: min(560px, 86%);
  height: 8px;

  margin: 24px auto 0;

  background:
    rgba(255,255,255,.1);

  border:
    1px solid rgba(255,255,255,.14);

  border-radius: 999px;
  overflow: hidden;
}

.loading-bar {
  width: 0%;
  height: 100%;

  border-radius: inherit;

  background:
    linear-gradient(
      90deg,
      #ffffff,
      #73b3ff,
      #ffffff
    );

  box-shadow:
    0 0 18px rgba(91,156,255,.8);
}

#loadingText {
  color: var(--muted);
  margin-top: 12px;
}


/* LANGUAGE */

.language-screen {
  align-items: center;
  justify-content: center;

  padding: 24px;

  background:
    radial-gradient(circle at top right, #15386f, transparent 40%),
    linear-gradient(145deg, #020711, #07152c);
}

.language-title {
  text-align: center;
  margin-bottom: 22px;
}

.language-logo {
  width: 80px;
  height: 80px;

  object-fit: contain;
  border-radius: 18px;

  margin-bottom: 12px;
}

.language-list {
  display: grid;
  gap: 8px;

  max-height: 370px;
  overflow-y: auto;

  margin: 14px 0 20px;
}

.language-option {
  width: 100%;

  padding: 12px 14px;

  color: var(--text);

  text-align: left;

  background:
    rgba(255,255,255,.045);

  border:
    1px solid transparent;

  border-radius: 12px;
}

.language-option:hover,
.language-option.selected {
  background:
    rgba(75,137,232,.16);

  border-color:
    rgba(104,170,255,.48);
}


/* LOGIN */

.auth-screen {
  position: relative;

  align-items: center;
  justify-content: center;

  padding: 30px;

  overflow: hidden;
}

.auth-background {
  position: absolute;
  inset: 0;

  background:
    url("images/backgrounds/login-bg.png")
    center / cover no-repeat;
}

.auth-card {
  position: relative;
  z-index: 2;

  width: min(470px, 94vw);

  padding: 30px;

  color: #13233e;

  background:
    rgba(255,255,255,.94);

  border:
    1px solid rgba(40,86,151,.15);

  border-radius: var(--radius-xl);

  box-shadow:
    0 28px 70px rgba(20,55,110,.28);

  backdrop-filter: blur(18px);
}

.auth-logo {
  text-align: center;
  margin-bottom: 16px;
}

.auth-logo img {
  width: 70px;
  height: 70px;

  object-fit: contain;

  border-radius: 18px;
}

.auth-tabs {
  display: flex;
  gap: 7px;

  padding: 5px;

  margin-bottom: 22px;

  background:
    #edf3fb;

  border-radius: 13px;
}

.auth-tab {
  flex: 1;

  border: 0;
  padding: 10px;

  color: #667792;
  background: transparent;

  border-radius: 10px;

  font-weight: 700;
}

.auth-tab.active {
  color: white;

  background:
    linear-gradient(
      135deg,
      #0d2854,
      #1d5195
    );
}

.form-field {
  display: grid;
  gap: 7px;

  margin: 15px 0;
}

.form-field label {
  color: #3b4f6d;

  font-size: 13px;
  font-weight: 800;
}

.auth-card input {
  color: #14233c;

  background: white;

  border:
    1px solid #d7e1ef;
}

.password-field {
  display: flex;
  align-items: center;
  gap: 8px;
}

.password-field input {
  flex: 1;
}


/* GLASS */

.setup-card,
.glass-card,
.page-panel,
.admin-panel,
.admin-stat,
.chat-panel,
.intro-dialogue {
  background:
    linear-gradient(
      145deg,
      rgba(9,29,63,.84),
      rgba(4,16,38,.79)
    );

  border:
    1px solid var(--border);

  box-shadow:
    var(--shadow);

  backdrop-filter:
    blur(22px);
}


/* INTRO */

.intro-screen {
  align-items: center;
  justify-content: center;

  padding: 28px;

  background:
    radial-gradient(circle at center, #14376d 0%, transparent 44%),
    linear-gradient(145deg, #020711, #081831);
}

.intro-stage {
  width: min(1300px, 96vw);

  display: grid;

  grid-template-columns:
    minmax(200px,1fr)
    minmax(320px,540px)
    minmax(200px,1fr);

  gap: 22px;

  align-items: end;
}

.intro-character {
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.intro-character img {
  max-height: 76vh;

  object-fit: contain;

  filter:
    drop-shadow(0 24px 35px rgba(0,0,0,.36));
}

.intro-dialogue {
  align-self: center;

  padding: 27px;

  border-radius:
    var(--radius-xl);
}

.speaker-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.speaker-row img {
  width: 55px;
  height: 55px;

  object-fit: cover;

  border-radius: 50%;

  border:
    2px solid rgba(111,175,255,.55);
}

#introMessage {
  min-height: 110px;

  line-height: 1.8;

  font-size: 17px;
}

.intro-actions {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}


/* ONBOARDING */

.onboarding-screen {
  align-items: center;
  justify-content: center;

  padding: 28px;

  background:
    radial-gradient(circle at top right, #153b77, transparent 40%),
    linear-gradient(145deg, #020711, #07162e);
}

.setup-card {
  width: min(790px, 95vw);

  max-height: 92vh;

  overflow-y: auto;

  padding: 32px;

  border-radius:
    var(--radius-xl);
}

.setup-progress-track {
  height: 7px;

  margin-top: 8px;

  background:
    rgba(255,255,255,.08);

  border-radius: 999px;

  overflow: hidden;
}

#setupProgressBar {
  width: 20%;
  height: 100%;

  background:
    linear-gradient(
      90deg,
      #ffffff,
      #69abff
    );
}

.setup-step {
  display: none;
}

.setup-step.active-setup-step {
  display: block;
}

.setup-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;

  margin-top: 28px;
}


/* PROFILE PHOTO */

.profile-choice-grid {
  display: grid;

  grid-template-columns:
    repeat(3, minmax(0,1fr));

  gap: 14px;

  margin: 20px 0;
}

.profile-choice {
  min-height: 150px;

  display: flex;
  flex-direction: column;

  align-items: center;
  justify-content: center;

  gap: 8px;

  padding: 13px;

  color: var(--text);

  background:
    rgba(255,255,255,.04);

  border:
    1px solid rgba(150,194,255,.16);

  border-radius: 18px;
}

.profile-choice:hover,
.profile-choice.selected {
  background:
    rgba(68,134,235,.14);

  border-color:
    rgba(104,169,255,.54);
}

.profile-choice img {
  width: 90px;
  height: 90px;

  object-fit: cover;

  border-radius: 50%;
}

.gallery-symbol {
  width: 88px;
  height: 88px;

  display: grid;
  place-items: center;

  border-radius: 50%;

  font-size: 38px;

  color: #a8caf8;

  background:
    rgba(255,255,255,.07);

  border:
    1px dashed rgba(145,194,255,.35);
}

.profile-preview {
  display: flex;
  justify-content: center;

  margin: 22px 0;
}

.anonymous-avatar,
.profile-preview img {
  width: 120px;
  height: 120px;

  display: grid;
  place-items: center;

  object-fit: cover;

  border-radius: 50%;

  color: #7589a8;

  font-size: 42px;

  background:
    white;

  border:
    3px solid rgba(113,174,255,.5);
}


/* COMPANIONS */

.companion-grid {
  display: grid;

  grid-template-columns:
    repeat(2,minmax(0,1fr));

  gap: 18px;
}

.companion-card {
  position: relative;

  overflow: hidden;

  padding: 18px;

  color: white;

  background:
    rgba(255,255,255,.04);

  border:
    1px solid rgba(147,194,255,.18);

  border-radius: 22px;
}

.companion-card.selected {
  border-color:
    rgba(105,169,255,.8);

  box-shadow:
    0 0 28px rgba(69,142,255,.28);
}

.companion-card img {
  width: 100%;
  height: 330px;

  object-fit: contain;
}

.companion-card strong {
  display: block;

  font-size: 22px;

  margin-top: 8px;
}

.companion-selected-mark {
  position: absolute;

  top: 15px;
  right: 15px;

  width: 34px;
  height: 34px;

  display: none;
  place-items: center;

  border-radius: 50%;

  color: #06162d;

  background:
    #cde6ff;
}

.companion-card.selected
.companion-selected-mark {
  display: grid;
}


/* MAIN APP */

.app-screen {
  flex-direction: column;

  background:
    linear-gradient(
      rgba(1,8,20,.72),
      rgba(2,10,25,.84)
    ),
    url("images/backgrounds/age-15-plus/home-bg.png")
    center / cover fixed;
}

.app-header {
  position: sticky;

  top: 0;

  z-index: 30;

  min-height: 74px;

  display: flex;
  align-items: center;

  gap: 18px;

  padding: 11px 26px;

  background:
    rgba(3,13,31,.8);

  border-bottom:
    1px solid rgba(143,190,255,.14);

  backdrop-filter:
    blur(22px);
}

.app-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.app-brand img {
  width: 40px;
  height: 40px;

  object-fit: contain;

  border-radius: 10px;
}

.top-nav {
  flex: 1;

  display: flex;
  justify-content: center;

  gap: 4px;
}

.nav-button {
  border: 0;

  padding: 10px 13px;

  color: #a7b9d2;

  background:
    transparent;

  border-radius: 11px;
}

.nav-button:hover,
.nav-button.active {
  color: white;

  background:
    rgba(73,137,236,.14);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 9px;
}

.comments-trigger {
  border:
    1px solid rgba(139,188,255,.2);

  padding: 9px 13px;

  color: white;

  background:
    rgba(255,255,255,.05);

  border-radius: 13px;
}

#unreadCommentsCount {
  display: inline-grid;
  place-items: center;

  min-width: 23px;
  height: 23px;

  margin-inline-start: 5px;

  padding: 0 6px;

  border-radius: 999px;

  font-size: 11px;

  background:
    #4f86e8;
}

.profile-button {
  border: 0;
  padding: 0;

  background:
    transparent;
}

.small-anonymous-avatar,
.profile-button img {
  width: 43px;
  height: 43px;

  display: grid;
  place-items: center;

  object-fit: cover;

  border-radius: 50%;

  color: #8193ae;

  background:
    white;

  border:
    2px solid rgba(116,176,255,.48);
}


/* DASHBOARD */

.app-page {
  display: none;

  width: 100%;

  padding: 28px;
}

.app-page.active-page {
  display: block;
}

.dashboard-grid {
  width: min(1480px,100%);

  margin: auto;

  display: grid;

  grid-template-columns:
    repeat(12,minmax(0,1fr));

  gap: 20px;
}

.glass-card {
  position: relative;

  overflow: hidden;

  border-radius:
    var(--radius-lg);
}

.card-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;

  margin-bottom: 18px;

  font-size: 17px;
  font-weight: 800;
}

.timer-card {
  grid-column: span 4;
  padding: 24px;
}

.weekly-card {
  grid-column: span 5;
  padding: 24px;
}

.level-card {
  grid-column: span 3;
  padding: 24px;
}

.stats-card {
  grid-column: span 4;
  padding: 24px;
}

.streak-card {
  grid-column: span 3;
  padding: 24px;
}

.companion-home-card {
  grid-column: span 5;

  min-height: 330px;

  display: flex;
  align-items: center;

  padding: 20px;
}

.achievements-card {
  grid-column: span 5;
  padding: 24px;
}

.activities-card {
  grid-column: span 7;
  padding: 24px;
}


/* TIMER */

.timer-ring {
  --timer-progress: 0deg;

  width: 240px;
  height: 240px;

  margin: 14px auto 22px;

  display: grid;
  place-items: center;

  padding: 10px;

  border-radius: 50%;

  background:
    conic-gradient(
      #80baff var(--timer-progress),
      rgba(70,109,173,.18) var(--timer-progress)
    );
}

.timer-ring::before {
  content: "";

  grid-area: 1 / 1;

  width: 100%;
  height: 100%;

  border-radius: 50%;

  background:
    radial-gradient(
      circle,
      #07162e 52%,
      #06132a 78%
    );
}

.timer-center {
  position: relative;

  z-index: 2;

  grid-area: 1 / 1;

  display: grid;

  gap: 7px;

  text-align: center;
}

.timer-center strong {
  font-size: 42px;
  font-weight: 500;
}

.timer-center span {
  color: var(--muted);
  font-size: 13px;
}

.timer-actions {
  display: grid;

  grid-template-columns:
    repeat(2,1fr);

  gap: 10px;

  margin-top: 13px;
}


/* LEVEL */

.level-card {
  text-align: center;
}

.level-badge {
  width: 135px;
  height: 135px;

  margin: 12px auto 15px;

  display: grid;
  place-items: center;

  clip-path:
    polygon(
      50% 0,
      90% 23%,
      90% 75%,
      50% 100%,
      10% 75%,
      10% 23%
    );

  background:
    linear-gradient(
      145deg,
      #193e77,
      #071831
    );
}

.level-badge strong {
  font-size: 48px;
}

#rankName {
  display: block;

  margin-bottom: 15px;

  color: #b9d6ff;
}

.xp-track {
  height: 9px;

  overflow: hidden;

  background:
    rgba(255,255,255,.08);

  border-radius: 999px;
}

#xpBar {
  width: 0%;
  height: 100%;

  background:
    linear-gradient(
      90deg,
      #4d84ff,
      #d2ecff
    );
}


/* STATS */

.stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;

  padding: 15px 0;

  border-bottom:
    1px solid rgba(255,255,255,.07);
}

.stat-row span {
  color: var(--muted);
}


/* STREAK */

.streak-number strong {
  font-size: 52px;
}

.streak-week {
  display: grid;

  grid-template-columns:
    repeat(7,1fr);

  gap: 6px;
}

.streak-check {
  width: 27px;
  height: 27px;

  display: grid;
  place-items: center;

  border-radius: 50%;

  background:
    rgba(255,255,255,.07);
}


/* WEEKLY */

.weekly-chart {
  position: relative;

  min-height: 210px;

  border-left:
    1px solid rgba(255,255,255,.08);

  border-bottom:
    1px solid rgba(255,255,255,.08);
}

.week-bar {
  position: absolute;

  bottom: 0;

  width: 10px;

  border-radius:
    8px 8px 0 0;

  background:
    linear-gradient(
      to top,
      #315fbd,
      #8cc7ff
    );
}

.weekly-summary {
  display: grid;

  grid-template-columns:
    repeat(2,1fr);

  gap: 10px;

  margin-top: 18px;
}


/* COMPANION HOME */

.companion-home-card img {
  width: 48%;
  height: 310px;

  object-fit: contain;
}

.companion-home-card > div {
  flex: 1;
}

.companion-home-card strong {
  display: block;

  margin-top: 7px;

  font-size: 27px;
}


/* ACHIEVEMENTS */

.achievement-item {
  display: flex;
  align-items: center;

  gap: 12px;

  padding: 13px 0;

  border-bottom:
    1px solid rgba(255,255,255,.07);
}

.achievement-item.locked {
  opacity: .42;
}

.achievement-icon {
  width: 46px;
  height: 46px;

  display: grid;
  place-items: center;

  border-radius: 14px;

  background:
    linear-gradient(
      145deg,
      #173b73,
      #071936
    );
}

.achievement-grid {
  display: grid;

  grid-template-columns:
    repeat(auto-fill,minmax(260px,1fr));

  gap: 14px;
}


/* ACTIVITIES */

.activity-row {
  display: grid;

  grid-template-columns:
    minmax(150px,1fr)
    auto
    auto
    auto;

  align-items: center;

  gap: 11px;

  padding: 13px;

  margin-bottom: 9px;

  background:
    rgba(255,255,255,.035);

  border:
    1px solid rgba(141,188,255,.12);

  border-radius: 14px;
}


/* PAGES */

.page-panel {
  width: min(1050px,100%);

  margin: auto;

  padding: 30px;

  border-radius:
    var(--radius-lg);
}

.settings-grid {
  display: grid;

  grid-template-columns:
    repeat(2,minmax(0,1fr));

  gap: 16px;

  margin: 22px 0;
}


/* COMMENTS */

.drawer-overlay {
  position: fixed;

  inset: 0;

  z-index: 90;

  display: none;

  background:
    rgba(0,5,15,.5);
}

.drawer-overlay.open {
  display: block;
}

.comments-drawer {
  position: fixed;

  top: 0;
  right: 0;
  bottom: 0;

  z-index: 100;

  width: min(450px,94vw);

  display: flex;
  flex-direction: column;

  padding: 20px;

  transform:
    translateX(105%);

  background:
    rgba(4,17,40,.98);

  border-left:
    1px solid rgba(127,182,255,.25);

  transition:
    transform .28s ease;
}

.comments-drawer.open {
  transform:
    translateX(0);
}

#commentsList {
  flex: 1;
  overflow-y: auto;
}

.comment {
  padding: 14px;

  margin-bottom: 10px;

  background:
    rgba(255,255,255,.045);

  border-radius: 15px;
}

.comment-actions,
.chat-message-actions {
  display: flex;
  flex-wrap: wrap;

  gap: 5px;

  margin-top: 8px;
}

.comment-action,
.message-action {
  border: 0;

  padding: 6px 9px;

  color: #9bb3d4;

  background: transparent;

  border-radius: 8px;
}


/* CHAT */

.chat-screen {
  position: fixed;

  inset: 0;

  z-index: 200;

  flex-direction: column;

  background:
    linear-gradient(
      rgba(1,9,22,.7),
      rgba(2,10,26,.88)
    ),
    url("images/backgrounds/age-15-plus/chat-bg.png")
    center / cover;
}

.chat-header {
  min-height: 73px;

  display: flex;
  align-items: center;

  gap: 17px;

  padding: 11px 23px;

  background:
    rgba(3,14,32,.83);
}

.chat-layout {
  flex: 1;

  min-height: 0;

  display: grid;

  grid-template-columns:
    minmax(260px,34%)
    minmax(0,1fr);

  gap: 20px;

  padding: 20px;
}

.chat-character {
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.chat-character img {
  width: 100%;
  height: 100%;

  object-fit: contain;
}

.chat-panel {
  min-height: 0;

  display: flex;
  flex-direction: column;

  padding: 18px;

  border-radius: 23px;
}

.chat-messages {
  flex: 1;

  overflow-y: auto;
}

.chat-message {
  width: fit-content;

  max-width: 82%;

  padding: 13px 15px;

  margin: 8px 0;

  border-radius: 17px;
}

.chat-message.user {
  margin-inline-start: auto;

  background:
    linear-gradient(
      135deg,
      #255cb7,
      #3e7ee8
    );
}

.chat-message.assistant {
  background:
    rgba(255,255,255,.065);
}

#chatForm {
  display: flex;

  gap: 9px;

  padding-top: 12px;
}


/* ADMIN */

.admin-screen {
  flex-direction: column;

  background:
    radial-gradient(circle at top right, #112b55, transparent 40%),
    linear-gradient(145deg, #030712, #09182e);
}

.admin-header {
  min-height: 76px;

  display: flex;
  justify-content: space-between;
  align-items: center;

  padding: 13px 26px;

  background:
    rgba(3,12,27,.9);
}

.admin-layout {
  flex: 1;

  display: grid;

  grid-template-columns:
    230px
    minmax(0,1fr);
}

.admin-sidebar {
  padding: 20px 13px;

  background:
    rgba(3,12,28,.72);
}

.admin-tab {
  width: 100%;

  border: 0;

  padding: 12px 14px;

  margin-bottom: 6px;

  text-align: left;

  color: #a8bad3;

  background:
    transparent;

  border-radius: 12px;
}

.admin-tab.active,
.admin-tab:hover {
  color: white;

  background:
    rgba(77,139,236,.14);
}

.admin-content {
  overflow-y: auto;

  padding: 24px;
}

.admin-page {
  display: none;
}

.admin-page.active-admin-page {
  display: block;
}

.admin-stat-grid {
  display: grid;

  grid-template-columns:
    repeat(4,minmax(0,1fr));

  gap: 14px;
}

.admin-stat,
.admin-panel {
  padding: 20px;

  border-radius: 18px;
}

.admin-stat strong {
  display: block;

  margin-top: 8px;

  font-size: 34px;
}


/* RTL */

html[dir="rtl"] body {
  text-align: right;
}

html[dir="rtl"] .language-option,
html[dir="rtl"] .admin-tab {
  text-align: right;
}

html[dir="rtl"] .comments-drawer {
  right: auto;
  left: 0;

  transform:
    translateX(-105%);
}

html[dir="rtl"] .comments-drawer.open {
  transform:
    translateX(0);
}


/* MOBILE */

@media (max-width: 1100px) {

  .timer-card,
  .weekly-card,
  .level-card,
  .stats-card,
  .streak-card,
  .companion-home-card,
  .achievements-card,
  .activities-card {
    grid-column: span 6;
  }

  .admin-stat-grid {
    grid-template-columns:
      repeat(2,1fr);
  }
}

@media (max-width: 820px) {

  .app-header {
    flex-wrap: wrap;
  }

  .top-nav {
    order: 3;

    width: 100%;

    overflow-x: auto;
  }

  .dashboard-grid {
    display: block;
  }

  .glass-card {
    margin-bottom: 14px;
  }

  .companion-grid,
  .settings-grid {
    grid-template-columns: 1fr;
  }

  .chat-layout {
    grid-template-columns: 1fr;
  }

  .chat-character {
    display: none;
  }

  .admin-layout {
    grid-template-columns: 1fr;
  }

  .admin-sidebar {
    display: flex;
    overflow-x: auto;
  }
}

@media (max-width: 560px) {

  .profile-choice-grid {
    grid-template-columns: 1fr;
  }

  .timer-ring {
    width: 210px;
    height: 210px;
  }

  .admin-stat-grid {
    grid-template-columns: 1fr;
  }
}
