/* Asistente Rodaregio — tema amarillo y oscuro */
.rra-root {
  --rra-yellow: #f5b800;
  --rra-yellow-d: #d99f00;
  --rra-dark: #16181d;
  --rra-dark-2: #23262e;
  --rra-text: #1d1f24;
  --rra-muted: #6b7079;
  --rra-bg: #ffffff;
  --rra-bg-2: #f4f5f7;
  --rra-line: #e3e5e9;
  position: fixed; right: 20px; bottom: 20px; z-index: 99999;
  font: 15px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--rra-text);
}
.rra-root *, .rra-root *::before, .rra-root *::after { box-sizing: border-box; }
.rra-root button, .rra-root input, .rra-root textarea { font-family: inherit; }

.rra-fab {
  height: 56px; padding: 0 22px 0 18px; border-radius: 28px; border: 0; cursor: pointer;
  background: var(--rra-yellow); color: var(--rra-dark);
  box-shadow: 0 6px 20px rgba(0,0,0,.25); display: flex; align-items: center; gap: 9px;
  margin-left: auto; transition: transform .15s;
  font-family: inherit; font-weight: 800; font-size: 14px; line-height: 1; letter-spacing: .06em;
}
.rra-fab:hover { transform: scale(1.04); }
.rra-fab svg { width: 26px; height: 26px; flex: none; }
.rra-fab-l { white-space: nowrap; }
.rra-fab.is-x { width: 56px; padding: 0; justify-content: center; }
.rra-fab.is-x svg { width: 22px; height: 22px; }

.rra-panel {
  display: none; flex-direction: column; width: 380px; height: min(620px, calc(100vh - 110px));
  background: var(--rra-bg); border-radius: 14px; overflow: hidden; margin-bottom: 12px;
  box-shadow: 0 12px 40px rgba(0,0,0,.28); border: 1px solid var(--rra-line);
}
.rra-root.is-open .rra-panel { display: flex; }

.rra-hd {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  background: var(--rra-dark); color: #fff; padding: 14px 16px;
  border-bottom: 4px solid var(--rra-yellow);
}
.rra-hd-t { display: flex; flex-direction: column; }
.rra-hd-t strong { font-size: 15px; }
.rra-hd-t span { font-size: 12px; color: var(--rra-yellow); }
.rra-x { background: none; border: 0; color: #fff; font-size: 26px; line-height: 1; cursor: pointer; padding: 0 4px; }

.rra-lang { padding: 28px 22px; display: flex; flex-direction: column; gap: 12px; }
.rra-lang p { margin: 0 0 8px; font-weight: 600; }
.rra-lang p span { font-weight: 400; color: var(--rra-muted); font-size: 14px; }

.rra-btn {
  background: var(--rra-yellow); color: var(--rra-dark); border: 0; border-radius: 8px;
  padding: 11px 16px; font-weight: 700; font-size: 15px; cursor: pointer;
}
.rra-btn:hover { background: var(--rra-yellow-d); }
.rra-btn:disabled { opacity: .6; cursor: default; }

.rra-log { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; background: var(--rra-bg-2); }
.rra-msg { max-width: 88%; padding: 10px 13px; border-radius: 12px; word-wrap: break-word; }
.rra-msg p { margin: 0 0 8px; }
.rra-msg p:last-child { margin-bottom: 0; }
.rra-msg ul, .rra-msg ol { margin: 4px 0 8px; padding-left: 20px; }
.rra-msg .rra-h { font-weight: 700; }
.rra-a { background: var(--rra-bg); border: 1px solid var(--rra-line); align-self: flex-start; border-top-left-radius: 4px; }
.rra-u { background: var(--rra-dark-2); color: #fff; align-self: flex-end; border-top-right-radius: 4px; }
.rra-wait { color: var(--rra-muted); font-style: italic; }
.rra-err { color: #b32d2e; }
.rra-spec { align-self: stretch; background: #fff8e1; border: 1px solid var(--rra-yellow); border-radius: 10px; padding: 10px 12px; }
.rra-spec p { margin: 0 0 8px; font-size: 14px; }
.rra-spec .rra-btn { padding: 8px 14px; font-size: 14px; }
.rra-tw { overflow-x: auto; margin: 6px 0; }
.rra-msg table { border-collapse: collapse; font-size: 13px; min-width: 100%; }
.rra-msg th, .rra-msg td { border: 1px solid var(--rra-line); padding: 5px 7px; text-align: left; vertical-align: top; }
.rra-msg th { background: var(--rra-dark); color: #fff; }
.rra-msg code { background: var(--rra-bg-2); padding: 0 4px; border-radius: 4px; }

.rra-tools { display: flex; justify-content: space-between; padding: 6px 12px; border-top: 1px solid var(--rra-line); background: var(--rra-bg); }
.rra-link { background: none; border: 0; color: var(--rra-dark); font-weight: 700; cursor: pointer; padding: 4px; font-size: 13px; text-decoration: underline; text-decoration-color: var(--rra-yellow); text-decoration-thickness: 2px; }
.rra-link:disabled { opacity: .4; cursor: default; }
.rra-muted { color: var(--rra-muted); font-weight: 400; }

.rra-in { display: flex; gap: 8px; padding: 10px 12px 12px; background: var(--rra-bg); }
.rra-in textarea {
  flex: 1; resize: none; border: 1px solid var(--rra-line); border-radius: 8px; padding: 9px 10px;
  font: inherit; max-height: 120px; color: var(--rra-text); background: #fff;
}
.rra-in textarea:focus, .rra-quote input:focus, .rra-quote textarea:focus { outline: 2px solid var(--rra-yellow); border-color: transparent; }
.rra-send { background: var(--rra-dark); color: var(--rra-yellow); border: 0; border-radius: 8px; padding: 0 14px; font-weight: 700; cursor: pointer; }
.rra-send:disabled { opacity: .5; }

.rra-quote { padding: 12px 14px 14px; background: var(--rra-bg); border-top: 1px solid var(--rra-line); }
.rra-quote p { margin: 0 0 8px; font-size: 13px; color: var(--rra-muted); }
.rra-quote form { display: flex; flex-direction: column; gap: 7px; }
.rra-quote input, .rra-quote textarea { border: 1px solid var(--rra-line); border-radius: 7px; padding: 8px 10px; font: inherit; font-size: 14px; color: var(--rra-text); background: #fff; }
.rra-row { display: flex; align-items: center; gap: 12px; }
.rra-fmsg { color: #b32d2e; font-size: 13px; min-height: 1em; }
.rra-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }

@media (max-width: 480px) {
  .rra-root { right: 12px; bottom: 12px; left: 12px; }
  .rra-fab { height: 50px; padding: 0 16px 0 13px; font-size: 13px; }
  .rra-fab.is-x { width: 50px; }
  .rra-panel { width: 100%; height: calc(100vh - 100px); }
}
