:root {
  color-scheme: dark;
  --bg: #080104;
  --night: #100208;
  --wine: #300615;
  --ruby: #b70f37;
  --hot: #ff2f70;
  --gold: #f5b45e;
  --champagne: #ffe5c7;
  --cream: #fff6ef;
  --ink: #fff5ef;
  --ink-dark: #251019;
  --muted: #d8aeb0;
  --muted-dark: #805464;
  --line: rgba(255, 229, 199, 0.22);
  --glass: rgba(13, 2, 8, 0.72);
  --glass-strong: rgba(13, 2, 8, 0.92);
  --panel: rgba(255, 246, 239, 0.97);
  --danger: #ff4a5e;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.48);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    linear-gradient(90deg, rgba(3, 0, 2, 0.86), rgba(35, 3, 14, 0.56) 42%, rgba(4, 0, 2, 0.82)),
    linear-gradient(180deg, rgba(183, 15, 55, 0.18), rgba(8, 1, 4, 0.95)),
    url("./assets/pecado-lounge-bg.png") center / cover fixed,
    var(--bg);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 229, 199, 0.045) 1px, transparent 1px),
    linear-gradient(rgba(255, 229, 199, 0.035) 1px, transparent 1px),
    linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.42));
  background-size: 54px 54px, 54px 54px, auto;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 72% 18%, rgba(255, 47, 112, 0.2), transparent 28%);
}

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  min-height: 100vh;
}

.shell.logged-out {
  grid-template-columns: minmax(320px, 560px) minmax(360px, 640px);
  align-items: center;
  justify-content: center;
  gap: 34px;
  padding: 34px;
}

.shell.logged-out .sidebar {
  width: 100%;
  max-height: none;
  padding: 24px;
  border: 1px solid rgba(255, 229, 199, 0.26);
  border-radius: 8px;
  box-shadow: var(--shadow), 0 0 90px rgba(255, 47, 112, 0.18);
}

.shell.logged-out .brand {
  padding-bottom: 12px;
}

.shell.logged-out .brand strong {
  font-size: 25px;
}

.shell.logged-out .brand small {
  font-size: 15px;
  line-height: 1.45;
}

.shell.logged-out .nav,
.shell.logged-out .content {
  display: none;
}

.shell.logged-out .auth-panel {
  gap: 9px;
  padding-top: 14px;
}

.shell.logged-out .auth-panel h2 {
  font-size: 25px;
}

.shell.logged-in .login-copy {
  display: none;
}

.sidebar {
  max-height: 100vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 24px;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(14, 2, 8, 0.96), rgba(42, 5, 18, 0.93)),
    rgba(12, 2, 7, 0.9);
  border-right: 1px solid rgba(255, 229, 199, 0.18);
  box-shadow: 18px 0 60px rgba(0, 0, 0, 0.36);
  backdrop-filter: blur(18px);
}

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

.brand-mark {
  display: grid;
  width: 50px;
  height: 50px;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 8px;
  color: #27040d;
  font-weight: 950;
  background: linear-gradient(135deg, var(--champagne), var(--gold) 44%, var(--hot));
  box-shadow: 0 16px 42px rgba(255, 47, 112, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.52);
}

.brand strong {
  display: block;
  font-size: 19px;
  line-height: 1.1;
}

.brand small,
.user-panel small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}

.login-copy {
  display: grid;
  gap: 10px;
  padding: 14px 0 0;
  border-top: 1px solid rgba(255, 229, 199, 0.14);
}

.eyebrow,
.empty-state span {
  width: fit-content;
  padding: 6px 9px;
  border-radius: 999px;
  color: #2b0712;
  background: linear-gradient(135deg, var(--champagne), var(--gold));
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.login-copy h1 {
  margin: 0;
  max-width: 440px;
  font-size: 38px;
  line-height: 0.96;
}

.login-copy p,
.form-note {
  margin: 0;
  color: var(--champagne);
  line-height: 1.55;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.trust-row span {
  padding: 8px 10px;
  border: 1px solid rgba(255, 229, 199, 0.18);
  border-radius: 999px;
  color: var(--cream);
  background: rgba(255, 255, 255, 0.07);
  font-size: 12px;
  font-weight: 850;
}

.nav {
  display: grid;
  gap: 8px;
  padding-top: 8px;
}

.nav-item,
.secondary,
.primary,
.price-card {
  border: 0;
  border-radius: 8px;
}

.nav-item {
  position: relative;
  padding: 13px 12px 13px 16px;
  color: #ecd1d0;
  background: transparent;
  text-align: left;
  font-weight: 900;
}

.nav-item.active,
.nav-item:hover {
  color: white;
  background: linear-gradient(135deg, rgba(183, 15, 55, 0.4), rgba(245, 180, 94, 0.14));
  box-shadow: inset 0 0 0 1px rgba(255, 229, 199, 0.16);
}

.nav-item.active::before {
  content: "";
  position: absolute;
  inset: 9px auto 9px 0;
  width: 4px;
  border-radius: 999px;
  background: var(--gold);
}

.auth-panel,
.user-panel {
  display: grid;
  gap: 11px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 229, 199, 0.15);
}

.auth-panel h2,
.panel h2 {
  margin: 0 0 2px;
  font-size: 18px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

input,
textarea {
  width: 100%;
  border: 1px solid rgba(255, 229, 199, 0.28);
  border-radius: 8px;
  padding: 11px 12px;
  color: var(--ink);
  background: rgba(255, 244, 239, 0.11);
  outline-color: var(--gold);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

input:focus,
textarea:focus {
  border-color: rgba(245, 180, 94, 0.78);
  box-shadow: 0 0 0 3px rgba(245, 180, 94, 0.15);
}

input::placeholder,
textarea::placeholder {
  color: rgba(255, 229, 199, 0.58);
}

textarea {
  min-height: 108px;
  resize: vertical;
}

.primary,
.secondary {
  padding: 11px 15px;
  font-weight: 950;
  transition: transform 140ms ease, box-shadow 140ms ease, filter 140ms ease;
}

.primary {
  color: white;
  background: linear-gradient(135deg, #8a0b26, var(--ruby) 46%, var(--hot));
  box-shadow: 0 18px 38px rgba(183, 15, 55, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.secondary {
  color: #2c0710;
  background: linear-gradient(135deg, var(--cream), var(--gold));
  box-shadow: 0 14px 30px rgba(245, 180, 94, 0.25);
}

.primary:hover,
.secondary:hover,
.price-card:hover {
  transform: translateY(-1px);
  filter: saturate(1.08);
}

.content {
  min-width: 0;
  padding: 32px;
  background:
    linear-gradient(180deg, rgba(10, 1, 5, 0.18), rgba(8, 1, 4, 0.52)),
    rgba(5, 0, 3, 0.08);
}

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  max-width: 1180px;
  margin: 0 auto 20px;
}

.topbar h1 {
  margin: 0;
  font-size: 58px;
  line-height: 0.96;
  color: var(--ink);
  text-shadow: 0 16px 42px rgba(0, 0, 0, 0.62);
}

.topbar p {
  max-width: 760px;
  margin: 8px 0 0;
  color: var(--champagne);
  font-size: 16px;
  line-height: 1.45;
}

.pill {
  padding: 8px 11px;
  border-radius: 999px;
  background: rgba(255, 229, 199, 0.13);
  color: var(--champagne);
  border: 1px solid rgba(255, 229, 199, 0.25);
  font-size: 13px;
  font-weight: 950;
  white-space: nowrap;
  backdrop-filter: blur(12px);
}

.view {
  display: none;
}

.view.active {
  display: grid;
  gap: 16px;
  max-width: 1180px;
  margin: 0 auto;
}

.mood-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.mood-strip article {
  min-height: 112px;
  padding: 16px;
  border: 1px solid rgba(255, 229, 199, 0.16);
  border-radius: 8px;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(255, 246, 239, 0.12), rgba(183, 15, 55, 0.12)),
    rgba(10, 1, 5, 0.56);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(14px);
}

.mood-strip strong {
  display: block;
  margin-bottom: 8px;
  color: var(--champagne);
  font-size: 17px;
}

.mood-strip span {
  color: var(--muted);
  line-height: 1.45;
}

.toolbar {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

#room-info {
  color: var(--champagne);
  font-weight: 850;
}

.card-stage {
  min-height: 520px;
  display: grid;
  place-items: center;
  padding: 22px;
  border: 1px solid rgba(255, 229, 199, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 246, 239, 0.1), rgba(255, 47, 112, 0.1)),
    rgba(9, 1, 5, 0.46);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.empty-state {
  display: grid;
  justify-items: center;
  gap: 12px;
  max-width: 480px;
  text-align: center;
}

.empty-state h2 {
  margin: 0;
  color: var(--ink);
  font-size: 34px;
  line-height: 1.06;
}

.empty-state p {
  margin: 0;
  color: var(--champagne);
  font-size: 17px;
  line-height: 1.5;
}

.profile-card,
.panel {
  width: 100%;
  background: var(--panel);
  border: 1px solid rgba(255, 229, 199, 0.28);
  border-radius: 8px;
  box-shadow: var(--shadow);
  color: var(--ink-dark);
}

.profile-card {
  max-width: 520px;
  overflow: hidden;
  position: relative;
}

.profile-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 34%, rgba(138, 15, 43, 0.24));
}

.profile-card::after {
  content: "perfil em destaque";
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 7px 10px;
  border-radius: 999px;
  color: #2c0710;
  background: linear-gradient(135deg, var(--cream), var(--gold));
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.profile-photo {
  height: 350px;
  width: 100%;
  display: grid;
  place-items: center;
  object-fit: cover;
  color: rgba(255, 229, 199, 0.86);
  font-size: 60px;
  font-weight: 950;
  background:
    linear-gradient(135deg, rgba(20, 1, 8, 0.18), rgba(255, 47, 112, 0.4)),
    url("./assets/pecado-lounge-bg.png") center / cover;
}

.profile-photo span {
  display: grid;
  width: 96px;
  height: 96px;
  place-items: center;
  border: 1px solid rgba(255, 229, 199, 0.34);
  border-radius: 999px;
  background: rgba(8, 1, 4, 0.42);
  backdrop-filter: blur(8px);
}

.profile-body {
  display: grid;
  gap: 9px;
  padding: 20px;
}

.profile-body h2 {
  margin: 0;
  font-size: 29px;
  color: var(--ink-dark);
}

.profile-meta {
  color: var(--muted-dark);
  font-weight: 800;
}

.profile-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 0 20px 20px;
}

.danger {
  color: white;
  background: linear-gradient(135deg, #4b0714, var(--danger));
}

.messages {
  min-height: 430px;
  max-height: 58vh;
  overflow: auto;
  padding: 14px;
  color: var(--ink);
  background: rgba(12, 2, 7, 0.72);
  border: 1px solid rgba(255, 229, 199, 0.17);
  border-radius: 8px;
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
}

.message {
  width: fit-content;
  max-width: 78%;
  margin: 7px 0;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--ink-dark);
  background: #fff2ec;
  border: 1px solid rgba(183, 15, 55, 0.16);
}

.message.mine {
  margin-left: auto;
  color: white;
  background: linear-gradient(135deg, #8a0b26, var(--hot));
}

.composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.panel {
  display: grid;
  gap: 12px;
  padding: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 240, 232, 0.97));
}

.panel label {
  color: var(--muted-dark);
}

.panel input,
.panel textarea {
  color: var(--ink-dark);
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(138, 15, 43, 0.18);
}

.list {
  display: grid;
  gap: 8px;
}

.list-item,
.stat-item {
  padding: 11px;
  border: 1px solid rgba(138, 15, 43, 0.14);
  border-radius: 8px;
  background: rgba(255, 244, 239, 0.86);
}

.stats {
  display: grid;
  gap: 8px;
}

.pricing {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.price-card {
  position: relative;
  display: grid;
  gap: 10px;
  min-height: 174px;
  padding: 20px;
  color: var(--ink);
  text-align: left;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(255, 229, 199, 0.16), rgba(183, 15, 55, 0.18)),
    rgba(16, 2, 8, 0.86);
  border: 1px solid rgba(255, 229, 199, 0.2);
  box-shadow: var(--shadow);
}

.price-card::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 5px;
  background: linear-gradient(90deg, var(--ruby), var(--gold), var(--hot));
}

.price-card strong {
  font-size: 22px;
}

.price-card span {
  color: var(--gold);
  font-size: 18px;
  font-weight: 950;
}

.price-card small {
  color: var(--champagne);
  line-height: 1.45;
}

.empty {
  max-width: 420px;
  margin: 0;
  color: var(--champagne);
  text-align: center;
  font-size: 18px;
  line-height: 1.5;
}

.hidden {
  display: none;
}

.toast {
  position: fixed;
  z-index: 5;
  right: 18px;
  bottom: 18px;
  max-width: min(420px, calc(100vw - 36px));
  padding: 13px 15px;
  border-radius: 8px;
  color: white;
  background: linear-gradient(135deg, #1d030c, #8a0b26 45%, var(--ruby));
  border: 1px solid rgba(255, 229, 199, 0.22);
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: 180ms ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  body {
    background-attachment: scroll;
  }

  .shell,
  .shell.logged-out {
    grid-template-columns: 1fr;
  }

  .shell.logged-out {
    align-content: center;
    padding: 20px;
  }

  .sidebar {
    position: static;
    max-height: none;
  }

  .shell.logged-in .sidebar {
    gap: 12px;
    padding: 16px;
  }

  .shell.logged-in .brand small {
    display: none;
  }

  .shell.logged-in .nav {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .shell.logged-in .nav-item {
    min-height: 42px;
    padding: 9px 6px;
    text-align: center;
    font-size: 12px;
    line-height: 1.15;
  }

  .shell.logged-in .nav-item.active::before {
    inset: auto 18px 0;
    width: auto;
    height: 3px;
  }

  .shell.logged-in .user-panel {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding-top: 12px;
  }

  .shell.logged-in .user-panel .secondary {
    min-width: 110px;
  }

  .content {
    padding: 20px;
  }

  .topbar,
  .split,
  .composer,
  .mood-strip {
    grid-template-columns: 1fr;
  }

  .topbar {
    display: grid;
  }

  .topbar h1,
  .login-copy h1 {
    font-size: 38px;
  }

  .pill {
    width: fit-content;
  }

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

@media (max-width: 520px) {
  .shell.logged-out {
    padding: 14px;
  }

  .sidebar,
  .content {
    padding: 18px;
  }

  .brand-mark {
    width: 44px;
    height: 44px;
  }

  .login-copy h1,
  .topbar h1 {
    font-size: 34px;
  }

  .card-stage {
    min-height: 420px;
    padding: 16px;
  }

  .empty-state h2 {
    font-size: 28px;
  }
}
