.hero .hero__title {
  max-width: 16em;
}

.topbar {
  max-width: 1080px;
  margin: 0 auto;
  padding: 1.25rem 1.5rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.topbar__links {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.topbar__links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: 0;
  border-radius: 999px;
  padding: 0.85rem 1.2rem;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  color: #0a0f1f;
  background: var(--whatsapp);
}

.btn--ghost {
  color: var(--text);
  background: transparent;
  border: 1px solid var(--card-border);
}

.page {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 1.5rem 3rem;
}

.section-title {
  text-align: center;
  margin: 3.5rem 0 1.25rem;
}

.section-title h2 {
  margin: 0;
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  background: linear-gradient(90deg, #cdd7ff, #b28bff 60%, #ff9ecb);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.section-title p {
  color: var(--muted);
  margin: 0.6rem auto 0;
  max-width: 52ch;
  line-height: 1.6;
}

.panel {
  position: relative;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 1.5rem;
  overflow: hidden;
}

.panel::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--whatsapp);
}

.panel h2,
.panel h3 {
  margin: 0.4rem 0;
}

.muted {
  color: var(--muted);
  line-height: 1.6;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: #0a0f1f;
  background: var(--whatsapp);
  border-radius: 999px;
  padding: 0.25rem 0.6rem;
}

.checks {
  display: grid;
  gap: 0.6rem;
  margin-top: 1rem;
  padding: 0;
  list-style: none;
}

.checks li {
  padding: 0.75rem 0.9rem;
  border-radius: 14px;
  border: 1px solid var(--card-border);
  background: rgba(0, 0, 0, 0.18);
}

.split {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 1.25rem;
  align-items: center;
}

.proof {
  border-radius: 14px;
  border: 1px solid var(--card-border);
  width: 100%;
  background: rgba(0, 0, 0, 0.25);
}

.compare {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.compare th,
.compare td {
  text-align: left;
  padding: 0.9rem 0.8rem;
  border-bottom: 1px solid var(--card-border);
  vertical-align: top;
}

.compare th {
  color: var(--muted);
  font-size: 0.75rem;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.bad {
  color: #ffb4c8;
}

.good {
  color: #b7f7cf;
}

.plans {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.price {
  font-size: 2.4rem;
  margin: 0.8rem 0 0.2rem;
}

.plan--pick {
  box-shadow: 0 18px 40px -18px rgba(37, 211, 102, 0.65);
}

.form {
  display: grid;
  gap: 0.85rem;
}

.form label {
  display: grid;
  gap: 0.35rem;
  font-size: 0.92rem;
  font-weight: 600;
}

.form input,
.form select,
.form textarea {
  width: 100%;
  font: inherit;
  color: var(--text);
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 0.8rem 0.9rem;
}

.pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

.actions {
  display: flex;
  gap: 0.75rem;
}

.actions .btn {
  flex: 1;
}

.bank {
  margin: 1rem 0;
  padding: 1rem;
  border-radius: 14px;
  border: 1px solid var(--card-border);
  background: rgba(0, 0, 0, 0.2);
}

.chat-launcher {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 20;
}

.chat-box {
  display: none;
  position: absolute;
  right: 0;
  bottom: 3.6rem;
  width: min(360px, calc(100vw - 2rem));
  height: 460px;
  flex-direction: column;
  background: #131734;
  border: 1px solid var(--card-border);
  border-radius: 18px;
  overflow: hidden;
}

.chat-box header,
.chat-box form {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.8rem;
  border-bottom: 1px solid var(--card-border);
}

.chat-box form {
  border-bottom: 0;
  border-top: 1px solid var(--card-border);
}

.chat-box input {
  flex: 1;
  font: inherit;
  color: var(--text);
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 0.7rem 0.8rem;
}

#chat-messages {
  flex: 1;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding: 0.9rem;
}

.bubble {
  max-width: 85%;
  padding: 0.7rem 0.85rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--card-border);
}

.bubble--me {
  align-self: flex-end;
  background: color-mix(in srgb, var(--whatsapp) 22%, transparent);
}

.login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1.5rem;
}

.login form {
  width: min(420px, 100%);
}

.demo-banner {
  max-width: 1080px;
  margin: 1rem auto 0;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, #f0c36a 50%, transparent);
  background: color-mix(in srgb, #f0c36a 14%, transparent);
  color: #f6e7c1;
  line-height: 1.45;
}

.states {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

.state {
  padding: 0.9rem;
  border-radius: 14px;
  border: 1px solid var(--card-border);
  background: rgba(0, 0, 0, 0.18);
}

.state strong,
.state span {
  display: block;
}

.state span {
  color: var(--muted);
  margin-top: 0.25rem;
  font-size: 0.88rem;
}

.shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 1rem 1rem 2rem;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 1rem;
}

.nav {
  position: relative;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 1rem 0.75rem 0.9rem;
  overflow: hidden;
}

.nav::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--whatsapp);
}

.nav-brand strong,
.nav-brand p {
  margin: 0.15rem 0.7rem;
}

.nav-links {
  display: flex;
  flex-direction: column;
}

.nav a {
  display: block;
  color: var(--muted);
  text-decoration: none;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
}

.phone-bar {
  display: none;
}

.thread-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  width: 100%;
  text-align: left;
  font: inherit;
  color: var(--text);
  background: transparent;
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 0.7rem 0.8rem;
  cursor: pointer;
}

.thread-item small {
  color: var(--muted);
}

.thread-item.is-on {
  color: #fff;
  border-color: transparent;
  background: #6d5efc;
}

.thread-item.is-on small {
  color: rgba(255, 255, 255, 0.86);
  background: transparent;
}

.nav a.is-on {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

@media (hover: hover) and (pointer: fine) {
  .nav a:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
  }
}

.inbox {
  display: grid;
  grid-template-columns: 240px 1fr 220px;
  gap: 0.75rem;
  min-height: 420px;
}

.thread,
.msgs {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.msg {
  padding: 0.65rem 0.75rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
}

.msg--staff {
  align-self: flex-end;
  background: color-mix(in srgb, #8b7cff 28%, transparent);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 0.8rem;
}

.field input,
.field select,
.field textarea {
  font: inherit;
  color: var(--text);
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 0.7rem 0.8rem;
}

.error {
  color: #ffb4b4;
  font-size: 0.88rem;
}

.os-kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

.os-kpi strong,
.os-kpi span {
  display: block;
}

.os-kpi span {
  color: var(--muted);
  margin-top: 0.35rem;
  font-size: 0.82rem;
  line-height: 1.45;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.75rem 0;
}

.chips .is-on {
  color: #fff;
  background: #6d5efc;
  border-color: transparent;
}

.os-table {
  width: 100%;
  border-collapse: collapse;
}

.os-table th,
.os-table td {
  text-align: left;
  padding: 0.6rem 0.35rem;
  border-bottom: 1px solid var(--card-border);
  vertical-align: top;
}

.record-steps {
  margin: 0.4rem 0 1rem;
  padding-left: 1.25rem;
  display: grid;
  gap: 0.55rem;
}

.record-steps li {
  line-height: 1.5;
}

.record-screen h2,
.page .panel h2 {
  margin-top: 1.35rem;
  font-size: 1.15rem;
}

.record-screen h2:first-of-type,
.page .panel h2:first-child {
  margin-top: 0.2rem;
}

.record-screen code,
.page code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.86em;
  word-break: break-word;
}

.record-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.75rem 0;
}

.copy-block {
  white-space: pre-wrap;
  line-height: 1.55;
  padding: 1rem;
  border-radius: 14px;
  border: 1px solid var(--card-border);
  background: rgba(0, 0, 0, 0.18);
}

.page .panel + .panel {
  margin-top: 1rem;
}

.steps {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.75rem 0 1rem;
}

.steps button {
  font: inherit;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--card-border);
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
}

.steps .is-on {
  color: #fff;
  background: #6d5efc;
  border-color: transparent;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(0, 0, 0, 0.55);
}

.modal .panel {
  width: min(440px, 100%);
}

button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.nav-tools {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-top: 0.8rem;
}

.nav-tools select {
  font: inherit;
  color: var(--text);
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 0.45rem 0.5rem;
}

html[data-theme="cerah"] body {
  --bg: #f6f7fb;
  --bg-2: #ffffff;
  --text: #12141c;
  --muted: #5c6478;
  --card: #ffffff;
  --card-border: rgba(18, 20, 28, 0.1);
  background: #f6f7fb;
  color: #12141c;
}

html[data-theme="cerah"] .demo-banner {
  color: #6b4e00;
  background: #fff6df;
}

html[data-theme="cerah"] .nav a.is-on {
  color: #3c2eb8;
  background: rgba(109, 94, 252, 0.12);
}

@media (hover: hover) and (pointer: fine) {
  html[data-theme="cerah"] .nav a:hover {
    color: #3c2eb8;
    background: rgba(109, 94, 252, 0.12);
  }
}

@media (hover: none) {
  .nav a:hover:not(.is-on),
  html[data-theme="cerah"] .nav a:hover:not(.is-on) {
    color: var(--muted);
    background: transparent;
  }
}

html[data-theme="cerah"] .copy-block,
html[data-theme="cerah"] .state,
html[data-theme="cerah"] .msg,
html[data-theme="cerah"] .field input,
html[data-theme="cerah"] .field select,
html[data-theme="cerah"] .field textarea,
html[data-theme="cerah"] .nav-tools select {
  background: #f3f5fb;
}

@media (max-width: 800px) {
  .split,
  .plans,
  .pair,
  .states,
  .shell,
  .inbox,
  .os-kpis {
    grid-template-columns: 1fr;
  }

  .topbar {
    align-items: center;
    flex-direction: row;
    padding: 0.85rem 1rem 0;
  }

  .topbar__links {
    margin-left: auto;
  }

  .shell {
    padding: 0.75rem 0.75rem 2rem;
  }

  .nav {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    padding: 0.75rem;
  }

  .nav-brand {
    display: none;
  }

  .nav-links {
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 0.35rem;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 28px), transparent);
    mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 28px), transparent);
  }

  .nav-links::-webkit-scrollbar {
    display: none;
  }

  .nav-links a {
    flex: 0 0 auto;
    white-space: nowrap;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }

  .nav-tools {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-between;
    margin-top: 0;
    gap: 0.5rem;
  }

  .nav-tools label,
  .nav-tools .btn {
    white-space: nowrap;
  }

  .nav-tools label {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    margin: 0;
    font-size: 0.82rem;
  }

  .nav-tools .btn {
    padding: 0.5rem 0.75rem;
  }

  .inbox-screen[data-screen="talk"] > h1,
  .inbox-screen[data-screen="profile"] > h1,
  .inbox-screen[data-screen="talk"] .inbox-find,
  .inbox-screen[data-screen="profile"] .inbox-find {
    display: none;
  }

  .demo-banner {
    margin: 0 0 0.75rem;
  }

  .phone-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
  }

  .phone-bar .btn {
    min-height: 44px;
    padding: 0.55rem 0.85rem;
  }

  .record-screen .states {
    grid-template-columns: 1fr 1fr;
  }

  .record-actions .btn {
    width: 100%;
    min-height: 44px;
  }

  .os-table {
    display: block;
    overflow-x: auto;
  }

  .inbox[data-pane="list"] .pane-talk,
  .inbox[data-pane="list"] .pane-profile,
  .inbox[data-pane="talk"] .pane-list,
  .inbox[data-pane="talk"] .pane-profile,
  .inbox[data-pane="profile"] .pane-list,
  .inbox[data-pane="profile"] .pane-talk {
    display: none;
  }
}
