/* ==========================================================================
   Modo controle — janelas dos apps no computador do agente (/painel).
   Janelas no estilo macOS (semáforo, sombra, foco) com a interface simplificada
   de cada app. Fora do controle as janelas somem, mas guardam o estado.
   ========================================================================== */

.wins {
  position: fixed;
  z-index: 4;
  top: var(--wall);
  left: var(--wall);
  right: calc(var(--wall) + var(--cover-x));
  bottom: calc(var(--wall) + var(--cover-y));
  overflow: hidden;
  border-radius: var(--frame-r);
  pointer-events: none;
}

.ctl-toast {
  position: absolute;
  z-index: 999;
  top: calc(2.4rem + (4.3rem - 34px) / 2);
  left: 50%;
  display: flex;
  align-items: center;
  gap: 9px;
  height: 34px;
  margin: 0;
  padding: 0 15px 0 13px;
  translate: -50% 0;
  border-radius: 17px;
  background: rgba(255, 255, 255, 0.84);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  backdrop-filter: blur(20px) saturate(1.5);
  box-shadow: 0 0 0 1px rgba(22, 127, 246, 0.22), 0 14px 30px -18px rgba(22, 127, 246, 0.6);
  font-size: 13px;
  font-weight: 500;
  color: #1d2230;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(-8px) scale(0.97);
  transition: opacity 0.3s var(--ease), transform 0.5s var(--spring-soft);
}
.ctl-toast.is-on {
  opacity: 1;
  transform: none;
}
.ctl-toast i {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--blue);
  animation: breathe-dot 1.4s ease-in-out infinite;
  animation-play-state: var(--ep-play, running);
}
/* aviso oculto: o ponto para de pulsar depois do fade (0.3s) */
.ctl-toast:not(.is-on) {
  --ep-play: paused;
  transition: opacity 0.3s var(--ease), transform 0.5s var(--spring-soft), --ep-play 0s linear 0.3s;
  transition-behavior: normal, normal, allow-discrete;
}

/* ---- janela: a mesma da home (public/css/windows.css) + o que é do modo controle ---- */

.aw {
  min-width: 30rem;
  transform-origin: 50% 50%; /* o "gênio" calcula a partir do centro */
  font-family: var(--ui);
  color: #1d2230;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: scale(0.985);
  transition: opacity 0.28s var(--ease), transform 0.4s var(--ease), visibility 0s linear 0.4s, filter 0.4s var(--ease);
}
body.is-control .aw {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: none;
  transition: opacity 0.3s var(--ease), transform 0.45s var(--ease), visibility 0s, filter 0.4s var(--ease);
}
.aw[hidden] {
  display: none;
}
/* janela de trás: o mesmo tom da janela de trás na cena da home */
.aw:not(.is-focus) {
  filter: saturate(0.85) brightness(0.98);
}
.aw.is-dragging {
  transition: none;
}
.aw button {
  font: inherit;
  color: inherit;
}
.aw .dwin-title {
  cursor: default;
  user-select: none;
}
.aw .aw-x {
  display: grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  margin: 0 -0.5rem 0 auto;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: #fff;
  transition: background-color 0.2s var(--ease);
}
.aw .aw-x:hover {
  background: rgba(255, 255, 255, 0.22);
}
.aw .aw-x .i {
  margin: 0;
}
.aw-app {
  font-size: 1.2rem;
}
/* o conteúdo da home ganha vida no modo controle */
.aw .rf-btn,
.aw .gm-actions span,
.aw .gm-send {
  pointer-events: auto;
  cursor: pointer;
}
.aw .gm-actions span:hover {
  background: #f1f3f4;
}
/* escondido (resposta aberta), o "Responder" não pode ficar por cima do "Enviar" */
.aw .gm-actions:not(.is-in),
.aw .gm-actions:not(.is-in) span {
  pointer-events: none;
}

/* ---- e-mail ---- */

.ap-mail {
  display: grid;
  grid-template-columns: 16.3rem minmax(20.37rem, 26.85rem) minmax(0, 1fr);
  height: 100%;
}
.ap-rail {
  display: grid;
  align-content: start;
  gap: 2px;
  padding: 1.11rem 0.93rem 1.11rem 0;
  background: #f6f8fc;
}
.ap-compose {
  display: flex;
  align-items: center;
  gap: 0.93rem;
  width: max-content;
  height: 4.26rem;
  margin: 0 0 1.11rem 0.93rem;
  padding: 0 1.67rem;
  border: 0;
  border-radius: 1.48rem;
  background: #c2e7ff;
  font-size: 1.3rem !important;
  font-weight: 500;
}
.ap-compose .i {
  width: 1.48rem;
  height: 1.48rem;
}
.ap-folder {
  display: flex;
  align-items: center;
  gap: 1.11rem;
  height: 2.96rem;
  padding: 0 1.11rem 0 1.85rem;
  border-radius: 0 1.48rem 1.48rem 0;
  font-size: 1.2rem;
  color: #3c4043;
}
.ap-folder .i {
  flex: none;
  width: 1.39rem;
  height: 1.39rem;
}
.ap-folder span {
  flex: 1;
}
.ap-folder b {
  font-size: 1.11rem;
}
.ap-folder.is-on {
  background: #d3e3fd;
  font-weight: 600;
  color: #041e49;
}
.ap-inbox {
  overflow: auto;
  border-right: 1px solid #eceef1;
}
.ap-search {
  display: flex;
  align-items: center;
  gap: 0.74rem;
  height: 3.15rem;
  margin: 0.93rem;
  padding: 0 1.11rem;
  border-radius: 1.57rem;
  background: #eef2f8;
  font-size: 1.2rem;
  color: #6b7079;
}
.ap-search .i {
  width: 1.3rem;
  height: 1.3rem;
}
.ap-mrow {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1px 0.74rem;
  width: 100%;
  padding: 0.93rem 1.3rem 0.93rem 1.67rem;
  border: 0;
  border-bottom: 1px solid #f1f2f4;
  background: none;
  text-align: left;
  transition: background-color 0.15s;
}
.ap-mrow:hover {
  background: #f5f7fb;
}
.ap-mrow.is-on {
  background: #e8f0fe;
}
.ap-mrow b {
  overflow: hidden;
  font-size: 1.2rem;
  font-weight: 500;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.ap-mrow time {
  font-size: 1.06rem;
  color: #6b7079;
}
.ap-mrow-s,
.ap-mrow-p {
  grid-column: 1 / -1;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.ap-mrow-s {
  font-size: 1.16rem;
}
.ap-mrow-p {
  font-size: 1.11rem;
  color: #7a7f8a;
}
.ap-mrow.is-unread b,
.ap-mrow.is-unread .ap-mrow-s {
  font-weight: 700;
}
.ap-mrow.is-unread::before {
  content: "";
  position: absolute;
  top: 1.39rem;
  left: 0.65rem;
  width: 0.56rem;
  height: 0.56rem;
  border-radius: 50%;
  background: #1a73e8;
}
.ap-read {
  overflow-x: hidden;
  overflow-y: auto;
  padding: 1.85rem 2.22rem;
}
.ap-msg {
  display: none;
}
.ap-msg.is-on {
  display: block;
  animation: fadeup 0.35s var(--ease) both;
}
.ap-msg h2 {
  margin: 0;
  font-size: 1.67rem;
  font-weight: 500;
}
.ap-from {
  display: flex;
  align-items: center;
  gap: 0.93rem;
  margin: 1.3rem 0;
}
.ap-from b {
  display: block;
  font-size: 1.25rem;
}
.ap-from small {
  font-size: 1.11rem;
  color: #6b7079;
}
.ap-from time {
  margin-left: auto;
  font-size: 1.11rem;
  color: #6b7079;
}
.ap-av {
  flex: none;
  display: grid;
  place-items: center;
  width: 3.15rem;
  height: 3.15rem;
  border-radius: 50%;
  background: #7aa7ff;
  font-size: 1.3rem;
  font-weight: 600;
  color: #fff;
}
.ap-msg-b p {
  margin: 0 0 0.93rem;
  font-size: 1.25rem;
  line-height: 1.55;
  color: #2b3140;
}
.ap-file {
  display: inline-flex;
  align-items: center;
  gap: 0.74rem;
  margin: 0.56rem 0 0.37rem;
  padding: 0.74rem 1.11rem;
  border: 1px solid #e3e5e8;
  border-radius: 0.74rem;
  font-size: 1.16rem;
}
.ap-file .i {
  width: 1.39rem;
  height: 1.39rem;
  color: #d93025;
}
/* Outlook */
.ap-mail--outlook .ap-rail {
  background: #f5f5f5;
}
.ap-mail--outlook .ap-compose {
  border-radius: 0.37rem;
  background: #0f6cbd;
  color: #fff !important;
}
.ap-mail--outlook .ap-folder {
  border-radius: 0.37rem;
  margin-left: 0.74rem;
  padding-left: 1.11rem;
}
.ap-mail--outlook .ap-folder.is-on {
  background: #e1ecf7;
  color: #0f548c;
}
.ap-mail--outlook .ap-search {
  border-radius: 0.37rem;
  background: #f0f0f0;
}
.ap-mail--outlook .ap-mrow.is-on {
  background: #deecf9;
  box-shadow: inset 0.28rem 0 #0f6cbd;
}
.ap-mail--outlook .ap-mrow.is-unread::before {
  background: #0f6cbd;
}
.ap-mail--outlook .ap-av {
  background: #0f6cbd;
}

/* ---- conversas ---- */

.ap-chat {
  display: grid;
  grid-template-columns: 23.15rem 1fr;
  height: 100%;
}
.ap-threads {
  overflow: auto;
  border-right: 1px solid #e9edef;
  background: #fff;
}
.ap-threads-h {
  padding: 1.3rem 1.48rem 0.74rem;
  font-size: 1.48rem;
  font-weight: 700;
}
.ap-thread {
  display: flex;
  align-items: center;
  gap: 0.93rem;
  width: 100%;
  padding: 0.93rem 1.3rem;
  border: 0;
  background: none;
  text-align: left;
  transition: background-color 0.15s;
}
.ap-thread:hover {
  background: #f5f6f6;
}
.ap-thread.is-on {
  background: #f0f2f5;
}
.ap-thread-t {
  flex: 1;
  min-width: 0;
}
.ap-thread-t b,
.ap-thread-t small {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.ap-thread-t b {
  font-size: 1.25rem;
  font-weight: 600;
}
.ap-thread-t small {
  font-size: 1.11rem;
  color: #667781;
}
.ap-thread time {
  align-self: flex-start;
  margin-top: 0.28rem;
  font-size: 1.02rem;
  color: #667781;
}
.ap-convs {
  position: relative;
  min-width: 0;
  background: #efeae2;
}
.ap-conv {
  display: none;
  flex-direction: column;
  height: 100%;
}
.ap-conv.is-on {
  display: flex;
}
.ap-conv-h {
  flex: none;
  display: flex;
  align-items: center;
  gap: 0.93rem;
  height: 5rem;
  padding: 0 1.48rem;
  background: #f0f2f5;
}
.ap-conv-h .ap-av {
  width: 2.96rem;
  height: 2.96rem;
}
.ap-conv-h b {
  font-size: 1.3rem;
}
.ap-bubbles {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.74rem;
  overflow: auto;
  padding: 1.48rem;
}
.ap-bub {
  align-self: flex-start;
  max-width: 74%;
  padding: 0.65rem 0.93rem 0.46rem 1.02rem;
  border-radius: 0.93rem;
  background: #fff;
  box-shadow: 0 1px 0.5px rgba(11, 20, 26, 0.13);
  font-size: 1.25rem;
  line-height: 1.45;
  animation: fadeup 0.35s var(--ease) both;
}
.ap-bub time {
  display: block;
  margin-top: 1px;
  font-size: 0.97rem;
  text-align: right;
  color: #667781;
}
.ap-bub--me {
  align-self: flex-end;
  background: #d9fdd3;
}
.ap-bub--file {
  display: flex;
  align-items: center;
  gap: 0.74rem;
  flex-wrap: wrap;
}
.ap-bub--file .i {
  width: 1.48rem;
  height: 1.48rem;
  color: #d93025;
}
.ap-bub--file time {
  width: 100%;
}
.ap-bot {
  display: block;
  margin-bottom: 2px;
  font-size: 1.11rem;
  font-weight: 700;
  color: #06a77d;
}
.ap-compose-bar {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 3.7rem;
  margin: 0.74rem 1.3rem 1.11rem;
  padding: 0 1.48rem;
  border-radius: 1.85rem;
  background: #fff;
  box-shadow: inset 0 0 0 1px #e6e8eb;
  font-size: 1.25rem;
  color: #8696a0;
}
.ap-compose-bar .i {
  width: 1.48rem;
  height: 1.48rem;
}
.ap-chat--whatsapp .ap-av {
  background: #25d366;
}
/* Telegram */
.ap-chat--telegram .ap-convs {
  background: linear-gradient(160deg, #cfe5c0, #b6d7a6);
}
.ap-chat--telegram .ap-thread.is-on {
  background: #3390ec;
  color: #fff;
}
.ap-chat--telegram .ap-thread.is-on small,
.ap-chat--telegram .ap-thread.is-on time {
  color: rgba(255, 255, 255, 0.8);
}
.ap-chat--telegram .ap-av {
  background: linear-gradient(#72d5fd, #2a9ef1);
}
.ap-chat--telegram .ap-conv-h {
  background: #fff;
}
.ap-chat--telegram .ap-bub--me {
  background: #effdde;
}
.ap-chat--telegram .ap-bot {
  color: #3390ec;
}
/* Teams */
.ap-chat--teams .ap-threads {
  background: #f5f5f5;
}
.ap-chat--teams .ap-thread.is-on {
  background: #fff;
  box-shadow: inset 0.28rem 0 #5b5fc7;
}
.ap-chat--teams .ap-convs {
  background: #fafafa;
}
.ap-chat--teams .ap-conv-h {
  background: #fff;
  border-bottom: 1px solid #ebebeb;
}
.ap-chat--teams .ap-av {
  background: #5b5fc7;
}
.ap-chat--teams .ap-bub--me {
  background: #e8ebfa;
}
.ap-chat--teams .ap-bot {
  color: #5b5fc7;
}
/* Slack */
.ap-chat--slack .ap-threads {
  background: #3f0e40;
  color: #fff;
}
.ap-chat--slack .ap-thread:hover {
  background: rgba(255, 255, 255, 0.06);
}
.ap-chat--slack .ap-thread.is-on {
  background: #1164a3;
}
.ap-chat--slack .ap-thread-t small,
.ap-chat--slack .ap-thread time {
  color: rgba(255, 255, 255, 0.65);
}
.ap-chat--slack .ap-av {
  border-radius: 0.56rem;
  background: #611f69;
}
.ap-chat--slack .ap-convs {
  background: #fff;
}
.ap-chat--slack .ap-conv-h {
  background: #fff;
  border-bottom: 1px solid #ebebeb;
}
.ap-chat--slack .ap-bub,
.ap-chat--slack .ap-bub--me {
  align-self: stretch;
  max-width: 100%;
  padding: 2px 0;
  background: none;
  box-shadow: none;
}
.ap-chat--slack .ap-bub time {
  text-align: left;
}
.ap-chat--slack .ap-bot {
  color: #1d1c1d;
}
.ap-chat--slack .ap-compose-bar {
  border-radius: 0.74rem;
}

/* ---- arquivos ---- */

.ap-files {
  height: 100%;
  overflow: auto;
  padding: 1.48rem 1.85rem;
}
.ap-files-h {
  display: flex;
  align-items: center;
  gap: 0.74rem;
  font-size: 1.3rem;
  color: #5f6368;
}
.ap-files-h b {
  font-size: 1.67rem;
  font-weight: 500;
  color: #1f1f1f;
}
.ap-files-new {
  display: flex;
  align-items: center;
  gap: 0.56rem;
  height: 3.33rem;
  margin-left: auto;
  padding: 0 1.48rem;
  border-radius: 1.67rem;
  background: #fff;
  box-shadow: 0 1px 0.28rem rgba(60, 64, 67, 0.3);
  font-size: 1.2rem;
  font-weight: 500;
  color: #1f1f1f;
}
.ap-files-new .i {
  width: 1.3rem;
  height: 1.3rem;
}
.ap-files-sub {
  margin: 1.67rem 0 0.93rem;
  font-size: 1.2rem;
  font-weight: 500;
  color: #5f6368;
}
.ap-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(13.89rem, 1fr));
  gap: 0.93rem;
}
.ap-fileit {
  display: grid;
  justify-items: start;
  gap: 0.37rem;
  padding: 1.11rem;
  border-radius: 1.11rem;
  background: #f0f4f9;
  min-width: 0;
  animation: fadeup 0.4s var(--ease) both;
}
.ap-fileit span,
.ap-fileit small {
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.ap-fileit span {
  font-size: 1.2rem;
  font-weight: 500;
}
.ap-fileit small {
  font-size: 1.06rem;
  color: #5f6368;
}
.ap-ficon {
  display: grid;
  place-items: center;
  width: 3.15rem;
  height: 2.41rem;
  margin-bottom: 0.56rem;
  border-radius: 0.46rem;
  font-size: 0.83rem;
  font-style: normal;
  font-weight: 800;
  color: #fff;
}
.ap-fileit--folder .ap-ficon {
  position: relative;
  border-radius: 2px 0.46rem 0.46rem 0.46rem;
  background: #5f6368;
}
.ap-fileit--folder .ap-ficon::before {
  content: "";
  position: absolute;
  top: -0.37rem;
  left: 0;
  width: 1.3rem;
  height: 0.56rem;
  border-radius: 0.28rem 0.28rem 0 0;
  background: inherit;
}
.ap-fileit--pdf .ap-ficon {
  background: #ea4335;
}
.ap-fileit--xls .ap-ficon {
  background: #1e7145;
}
.ap-files--dropbox .ap-fileit {
  background: #f7f5f2;
}
.ap-files--dropbox .ap-fileit--folder .ap-ficon {
  background: #6ea7ff;
}
.ap-files--dropbox .ap-files-new {
  border-radius: 0.56rem;
  background: #0061fe;
  box-shadow: none;
  color: #fff;
}

/* ---- planilha ---- */

.ap-xl {
  display: flex;
  flex-direction: column;
  height: 100%;
  font-size: 1.16rem;
}
.ap-xl-ribbon {
  flex: none;
  display: flex;
  gap: 0.37rem;
  height: 3.33rem;
  padding: 0 0.93rem;
  background: #107c41;
}
.ap-xl-ribbon span {
  display: flex;
  align-items: center;
  padding: 0 1.11rem;
  color: rgba(255, 255, 255, 0.85);
}
.ap-xl-ribbon span.is-on {
  margin-top: 0.56rem;
  border-radius: 0.56rem 0.56rem 0 0;
  background: #f3f2f1;
  color: #107c41;
  font-weight: 600;
}
.ap-xl-fx {
  flex: none;
  display: flex;
  align-items: center;
  gap: 0.93rem;
  height: 2.96rem;
  padding: 0 0.93rem;
  border-bottom: 1px solid #e1e1e1;
  background: #f3f2f1;
}
.ap-xl-fx b {
  width: 4.63rem;
  padding: 0.28rem 0.56rem;
  border-radius: 0.28rem;
  background: #fff;
  font-weight: 500;
}
.ap-xl-fx i {
  color: #8a8886;
}
.ap-xl-fx span {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 1.11rem;
}
.ap-xl-grid {
  flex: 1;
  overflow: auto;
}
.ap-xl-r {
  display: grid;
  grid-template-columns: 3.52rem 5.93rem minmax(13.89rem, 1.6fr) repeat(2, minmax(8.33rem, 1fr)) minmax(8.89rem, 1fr) 3.7rem;
  min-width: 51.85rem;
}
.ap-xl-r span {
  display: flex;
  align-items: center;
  height: 2.41rem;
  padding: 0 0.74rem;
  overflow: hidden;
  border-right: 1px solid #e1e1e1;
  border-bottom: 1px solid #e1e1e1;
  white-space: nowrap;
}
.ap-xl-r span:first-child,
.ap-xl-r--h span {
  justify-content: center;
  background: #f3f2f1;
  color: #605e5c;
}
.ap-xl-r.is-head span:not(:first-child) {
  font-weight: 600;
}
.ap-xl-r span.num {
  justify-content: flex-end;
  font-variant-numeric: tabular-nums;
}
.ap-xl-r span.ok {
  color: #107c41;
}
.ap-xl-r span.bad {
  background: #fde7e9;
  font-weight: 600;
  color: #c42b1c;
}
.ap-xl-r span.is-sel {
  box-shadow: inset 0 0 0 2px #107c41;
}
.ap-xl-tabs {
  flex: none;
  display: flex;
  height: 2.78rem;
  border-top: 1px solid #e1e1e1;
  background: #f3f2f1;
}
.ap-xl-tabs span {
  display: flex;
  align-items: center;
  padding: 0 1.3rem;
  color: #605e5c;
}
.ap-xl-tabs span.is-on {
  background: #fff;
  box-shadow: inset 0 -2px #107c41;
  font-weight: 600;
  color: #107c41;
}

/* ---- documento ---- */

.ap-doc {
  display: grid;
  grid-template-columns: 18.15rem 1fr;
  height: 100%;
}
.ap-doc-side {
  display: grid;
  align-content: start;
  gap: 1px;
  padding: 1.3rem 0.74rem;
  background: #f7f7f5;
  font-size: 1.25rem;
  color: #5f5e5b;
}
.ap-doc-side b {
  padding: 0.37rem 0.74rem 0.93rem;
  color: #37352f;
}
.ap-doc-side span {
  padding: 0.46rem 0.74rem;
  border-radius: 0.56rem;
}
.ap-doc-side span.is-on {
  background: #ebebea;
  color: #37352f;
}
.ap-doc-page {
  overflow: auto;
  padding: 3.15rem 5.19rem;
  color: #37352f;
}
.ap-doc-emoji {
  font-size: 3.89rem;
}
.ap-doc-page h1 {
  margin: 0.74rem 0 1.11rem;
  font-size: 2.78rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.ap-doc-props {
  display: grid;
  grid-template-columns: 10.19rem 1fr;
  gap: 0.56rem;
  font-size: 1.25rem;
}
.ap-doc-props span {
  color: #9b9a97;
}
.ap-doc-props b {
  font-weight: 500;
}
.ap-callout {
  display: flex;
  gap: 0.93rem;
  margin: 1.67rem 0;
  padding: 1.3rem 1.48rem;
  border-radius: 0.56rem;
  background: #f1f1ef;
  font-size: 1.3rem;
  line-height: 1.5;
}
.ap-doc-page h2 {
  margin: 2.04rem 0 0.56rem;
  font-size: 1.67rem;
  font-weight: 600;
}
.ap-doc-page ul {
  margin: 0;
  padding-left: 2.04rem;
  font-size: 1.34rem;
  line-height: 1.75;
}
.ap-todo {
  display: flex;
  align-items: center;
  gap: 0.74rem;
  margin: 0.46rem 0;
  font-size: 1.34rem;
}
.ap-todo input {
  accent-color: #2383e2;
}
.ap-todo input:checked + span {
  color: #9b9a97;
  text-decoration: line-through;
}

/* ---- agenda ---- */

.ap-cal {
  --hh: 3.89rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  font-size: 1.16rem;
}
.ap-cal-h {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.11rem 1.48rem;
}
.ap-cal-h b {
  font-size: 1.67rem;
  font-weight: 400;
}
.ap-cal-days {
  flex: none;
  display: grid;
  grid-template-columns: 5.19rem repeat(5, 1fr);
  border-bottom: 1px solid #eceef1;
}
.ap-cal-days span {
  padding: 0.74rem 0;
  text-align: center;
  color: #70757a;
}
.ap-cal-days .is-today {
  font-weight: 600;
  color: #1a73e8;
}
.ap-cal-body {
  flex: 1;
  padding-top: 0.74rem;
  display: grid;
  grid-template-columns: 5.19rem repeat(5, 1fr);
  overflow: auto;
}
.ap-cal-hours {
  display: grid;
  grid-auto-rows: var(--hh);
}
.ap-cal-hours span {
  padding-right: 0.74rem;
  font-size: 1.02rem;
  text-align: right;
  color: #70757a;
  translate: 0 -0.56rem;
}
.ap-cal-col {
  position: relative;
  height: calc(var(--hh) * 12);
  border-left: 1px solid #eceef1;
  background: repeating-linear-gradient(to bottom, transparent 0 calc(var(--hh) - 1px), #eceef1 calc(var(--hh) - 1px) var(--hh));
}
.ap-ev {
  position: absolute;
  top: calc(var(--t) * var(--hh) + 1px);
  left: 0.28rem;
  right: 0.28rem;
  height: calc(var(--h) * var(--hh) - 0.28rem);
  padding: 0.37rem 0.65rem;
  overflow: hidden;
  border-radius: 0.56rem;
  font-size: 1.06rem;
  color: #fff;
  animation: fadeup 0.4s var(--ease) both;
}
.ap-ev b,
.ap-ev small {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.ap-ev small {
  opacity: 0.85;
}
.ap-ev--b {
  background: #1a73e8;
}
.ap-ev--r {
  background: #d93025;
}
.ap-ev--g {
  background: #188038;
}
.ap-ev--p {
  background: #8430ce;
}
.ap-ev--o {
  background: #e37400;
}

/* ---- celular: janelas em tela cheia, uma coluna ---- */

@media (max-width: 760px), (orientation: portrait) and (max-width: 1100px) {
  .ctl-toast {
    top: 64px;
    max-width: calc(100% - 24px);
    height: auto;
    padding: 8px 14px 8px 12px;
    white-space: normal;
  }
  .aw {
    min-width: 0;
  }
  .ap-mail {
    grid-template-columns: 1fr;
  }
  .ap-rail,
  .ap-read {
    display: none;
  }
  .ap-chat {
    grid-template-columns: 1fr;
  }
  .ap-threads {
    display: none;
  }
  .ap-doc {
    grid-template-columns: 1fr;
  }
  .ap-doc-side {
    display: none;
  }
  .ap-doc-page {
    padding: 2.2rem;
  }
  /* Receita e Gmail (conteúdo da home) numa coluna só */
  .aw .rf-side,
  .aw .win-ext,
  .aw .gm-nav,
  .aw .gm-rail,
  .aw .gm-tools,
  .aw .gm-burger {
    display: none;
  }
  .aw .win-body--desk {
    grid-template-columns: 1fr;
  }
  .aw .rf-main {
    padding-left: 1.6rem;
  }
  .aw .gm-logo {
    width: auto;
  }
  .aw .gm-search {
    min-width: 0;
  }
  .aw .gm-main {
    left: 0.8rem;
    right: 0.8rem;
  }
}

/* celular: resposta do Gmail no modo controle — o anexo fica numa linha própria
   (antes o "Enviar" era desenhado por cima dele) e o "Enviar" escondido não rouba o toque do "Responder" */
@media (max-width: 760px), (orientation: portrait) and (max-width: 1100px) {
  .aw .gm-reply {
    height: auto;
    bottom: 0.8rem;
  }
  .aw .gm-reply-foot {
    position: static;
    margin-top: 0.8rem;
  }
  .aw .gm-reply:not(.is-open) .gm-send {
    pointer-events: none;
  }
}
/* o aviso "Mensagem enviada" escondido não pode roubar o toque do "Responder" */
.aw .gm-toast:not(.is-in) {
  pointer-events: none;
}
