/* SAWWA.AI 7.3.0 — stable chat viewport and browseable journal archive. */
/* Override v7.2.x intentionally: do not expand the chat with its history. */
#conversationsView .chat-layout { align-items:start!important; }
#conversationsView .v2-chat-card {
  position:relative!important;
  display:flex!important;
  flex-direction:column!important;
  height:clamp(490px,calc(100dvh - 235px),850px)!important;
  min-height:0!important;
  max-height:850px!important;
  align-self:start!important;
  overflow:hidden!important;
}
#conversationsView .message-feed {
  position:relative;
  height:auto!important;
  flex:1 1 auto!important;
  min-height:0!important;
  max-height:none!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  overscroll-behavior-y:contain!important;
  scrollbar-width:thin!important;
  scrollbar-color:#d2c1a7 transparent;
  scroll-behavior:auto;
}
#conversationsView .message-feed::-webkit-scrollbar {width:7px}
#conversationsView .message-feed::-webkit-scrollbar-thumb {background:#d2c1a7;border-radius:7px}
#conversationsView .chat-heading,#conversationsView .chat-compose,#conversationsView .chat-note {flex:0 0 auto!important}
#conversationsView .chat-compose {position:relative!important;bottom:auto!important;z-index:2}
#conversationsView .conversation-list {max-height:clamp(490px,calc(100dvh - 235px),850px)!important;overflow-y:auto!important;scrollbar-width:thin!important}
#conversationsView .chat-context {max-height:clamp(490px,calc(100dvh - 235px),850px)!important;overflow-y:auto!important;scrollbar-width:thin!important}
#conversationsView .chat-latest-button {
  position:absolute;right:26px;bottom:91px;z-index:5;
  padding:9px 13px;border:1px solid #d9cbb6;border-radius:22px;
  background:rgba(255,253,249,.97);box-shadow:0 8px 20px rgba(35,32,28,.13);
  color:#72502a;font-size:12px;font-weight:700;cursor:pointer;
}
#conversationsView .chat-latest-button[hidden]{display:none!important}
#conversationsView .message-feed .v73-chat-history-more {
  display:block;margin:0 auto 18px;padding:9px 16px;border-radius:18px;
  border:1px solid #e7dfd5;background:#f9f7f3;color:#6c604f;font-size:12px;
}
#conversationsView .message-feed .v73-chat-history-more:hover{background:#f1eae0}
#conversationsView .message-feed .v73-chat-history-more[hidden]{display:none!important}
#conversationsView .chat-bubble[hidden]{display:none!important}
/* Month archive and non-infinite journal. The main diary search remains available. */
.v73-month-card .eyebrow {display:block;margin-bottom:12px}
.v73-month-archive{display:grid;gap:3px}
.v73-month-archive button{width:100%;display:flex;justify-content:space-between;gap:8px;align-items:center;padding:10px 11px;
  border:0;border-radius:9px;background:transparent;color:var(--ui-ink,#293344);font-size:12px;text-align:left}
.v73-month-archive button:hover{background:var(--ui-soft,#f3f2ef)}
.v73-month-archive button.active{background:#f0e9de;color:#815a2b;font-weight:700}
.v73-month-archive button span:last-child{color:#8c8e95;font-variant-numeric:tabular-nums}
.v73-mobile-month-label{display:none!important}
.v73-pagination[hidden]{display:none!important}
.v73-pagination{display:flex;flex-wrap:wrap;gap:7px;align-items:center;justify-content:center;padding:22px 8px 6px}
.v73-pagination button{min-width:36px;min-height:36px;padding:6px 11px;border:1px solid #dddfe3;border-radius:9px;background:#fff;
  color:#364252;font-size:12px;font-weight:650}
.v73-pagination button.current{border-color:#aa8150;background:#f1e7d8;color:#775027}
.v73-pagination button:disabled{opacity:.4;cursor:default}
.v73-pagination .v73-page-summary{color:#6d7784;font-size:12px;margin-right:10px}
@media(max-width:1280px){
 #conversationsView .chat-context{max-height:none!important;overflow:visible!important}
}
@media(max-width:980px){
 .v73-mobile-month-label{display:flex!important;flex-direction:column;gap:5px;margin:0 0 10px!important;font-size:12px!important}
 .v73-mobile-month-label select{margin:0;padding:10px 12px;border-radius:9px;border:1px solid #dfe1e5;background:#fff;color:#2b3442;font-size:14px}
}
@media(max-width:800px){
 #conversationsView .v2-chat-card{height:clamp(360px,calc(100dvh - 255px),650px)!important;max-height:none!important;min-height:0!important}
 #conversationsView .conversation-list{max-height:72px!important;overflow-x:auto!important;overflow-y:hidden!important}
 #conversationsView .chat-latest-button{right:14px;bottom:81px}
}
@media(max-height:560px) and (min-width:801px){#conversationsView .v2-chat-card{height:420px!important}}
html[data-theme='dark'] .v73-month-archive button.active{background:#394153;color:#f4e1bd}
html[data-theme='dark'] .v73-pagination button,html[data-theme='dark'] #conversationsView .chat-latest-button,
html[data-theme='dark'] #conversationsView .message-feed .v73-chat-history-more{background:#273141;color:#f3f1eb;border-color:#46505b}

.v73-page-gap{align-self:center;color:#848b93;padding:0 4px}
