:root {
  color-scheme: light;
  --paper: #f3cf00;
  --text: #4e4d50;
  --muted: rgba(78, 77, 80, 0.76);
  --line: rgba(78, 77, 80, 0.14);
  --card: #ffffff;
  --shadow: 0 18px 44px rgba(74, 63, 7, 0.16);
  --assistant: #f5f5f5;
  --user: #4e4d50;
  --button: #4e4d50;
  --button-text: #f8d400;
  font-family: "Avenir Next", "Montserrat", "IBM Plex Sans", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(rgba(243, 207, 0, 0.18), rgba(243, 207, 0, 0.18)),
    url('/brand/textura-papel-amarillo-1920x1080.png') center center / cover no-repeat,
    var(--paper);
  color: var(--text);
}

.experience-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(260px, 38vw) minmax(420px, 1fr);
  align-items: center;
  gap: 2vw;
  padding: clamp(24px, 4vw, 48px);
}

.brand-stage {
  position: relative;
  min-height: min(76vh, 720px);
  display: grid;
  align-content: start;
  justify-items: center;
}

.brand-logo {
  width: min(360px, 78%);
  margin-top: 10%;
  align-self: start;
}

.brand-mascot {
  width: min(470px, 96%);
  margin-top: auto;
  margin-bottom: 4%;
  align-self: end;
}

.chat-card-wrap {
  display: grid;
  justify-items: center;
}

.chat-card {
  width: min(100%, 658px);
  min-height: min(72vh, 560px);
  max-height: min(78vh, 720px);
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 16px;
  padding: clamp(18px, 2vw, 28px);
  border-radius: 18px;
  background: var(--card);
  box-shadow: var(--shadow);
}

h1,
p {
  margin: 0;
}

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

input,
textarea {
  width: 100%;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
}

textarea {
  resize: none;
  min-height: 74px;
  outline: none;
}

.card-header,
.profile-inline,
.composer-footer,
.card-actions {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.card-header,
.composer-footer {
  justify-content: space-between;
}

.card-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.eyebrow {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}

h1 {
  font-size: clamp(24px, 2.2vw, 34px);
  line-height: 1.05;
}

.status-chip,
.ghost-link,
.ghost-button {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.ghost-button {
  cursor: pointer;
}

.profile-inline {
  justify-content: flex-end;
}

.conversation-meta {
  min-width: 122px;
  display: grid;
  gap: 4px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.messages {
  display: grid;
  align-content: start;
  gap: 12px;
  overflow: auto;
  padding: 2px 6px 2px 2px;
}

.message {
  display: grid;
  gap: 6px;
  max-width: min(88%, 520px);
}

.message.user {
  justify-self: end;
}

.meta,
.hint {
  color: var(--muted);
  font-size: 12px;
}

.message .bubble {
  padding: 13px 15px;
  border-radius: 18px;
  border: 1px solid var(--line);
  line-height: 1.45;
  white-space: pre-wrap;
  background: var(--assistant);
}

.message.user .bubble {
  background: var(--user);
  color: #fff;
}

.composer-shell {
  padding-top: 4px;
}

.composer {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: #fafafa;
}

button[type="submit"] {
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  border: 0;
  background: var(--button);
  color: var(--button-text);
  cursor: pointer;
  font-weight: 700;
}

@media (max-width: 960px) {
  .experience-shell {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .brand-stage {
    min-height: auto;
    gap: 12px;
  }

  .brand-logo {
    width: min(300px, 72vw);
    margin-top: 0;
  }

  .brand-mascot {
    width: min(340px, 82vw);
    margin: 0;
  }

  .chat-card {
    width: 100%;
    min-height: min(68vh, 620px);
  }

  .profile-inline {
    display: grid;
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .card-header,
  .composer-footer {
    display: grid;
    gap: 10px;
  }

  .card-actions {
    justify-content: start;
  }
}