/* The helper's chat screen. From artboard 4a in "herkesesite Artboards.dc.html". */
body { margin: 0; background: #dedbd4; color: #161513; font-family: var(--brand-font); }
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
button { font-family: var(--brand-font); }

.chat-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.phone {
  width: 390px; height: 844px; border: 10px solid #161513; border-radius: 48px; overflow: hidden;
  background: #f4f2ed; display: flex; flex-direction: column;
}
/* Inside the overview canvas: no page padding, just the artboard. */
.framed body { background: transparent; }
.framed .chat-page { min-height: 0; display: block; padding: 0; }

.status { height: 40px; flex: none; display: flex; align-items: center; justify-content: space-between; padding: 0 24px; font-weight: 700; font-size: 15px; background: #fff; }
.bar { flex: none; display: flex; align-items: center; gap: 10px; padding: 8px 12px 12px; background: #fff; border-bottom: 1px solid #dedad2; }
.back { width: 44px; height: 44px; border: 0; background: none; font-weight: 700; font-size: 30px; color: #161513; cursor: pointer; }
.avatar { width: 44px; height: 44px; border-radius: 12px; background: #c2410c; color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 22px; flex: none; }
.bar-text { min-width: 0; }
.bar-title { font-weight: 800; font-size: 17px; }
.bar-sub { font-size: 14px; color: #4a4740; }

.msgs { flex: 1; overflow-y: auto; padding: 16px 14px 20px; display: flex; flex-direction: column; gap: 12px; }
/* Messages keep their full height; the list scrolls instead of squeezing them. */
.msgs > * { flex-shrink: 0; }
.day { align-self: center; font-size: 13px; font-weight: 700; color: #4a4740; background: #e6e2d9; padding: 4px 12px; border-radius: 12px; }
.out { align-self: flex-end; background: #161513; color: #fff; border-radius: 20px 20px 6px 20px; }
.voice { max-width: 82%; padding: 10px 14px 8px; display: flex; flex-direction: column; gap: 4px; }
.voice-row { display: flex; align-items: center; gap: 10px; }
.play { flex: none; width: 44px; height: 44px; border-radius: 50%; background: #fff; color: #161513; display: flex; align-items: center; justify-content: center; font-size: 16px; }
.wave { display: flex; align-items: center; gap: 3px; height: 32px; }
.wave i { width: 3px; background: #fff; border-radius: 2px; }
.wave i.rest { background: #8a867e; }
.meta { display: flex; justify-content: space-between; font-size: 13px; color: #d6d2ca; }
.photo-msg { width: 62%; padding: 6px; display: flex; flex-direction: column; gap: 6px; }
.photo-box { position: relative; aspect-ratio: 3/4; border-radius: 15px; overflow: hidden; }
.photo-time { font-size: 13px; color: #d6d2ca; text-align: right; padding: 0 6px 2px; }
.out.text { padding: 10px 16px; font-size: 17px; font-weight: 700; }

.in {
  align-self: flex-start; max-width: 86%; background: #fff; border: 1px solid #dedad2; border-radius: 20px 20px 20px 6px;
  padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; font-size: 17px; line-height: 1.45;
}
.transcript { font-size: 15px; color: #4a4740; border-bottom: 1px solid #ece9e2; padding-bottom: 8px; }
.transcript strong { color: #161513; }
.time { font-size: 13px; color: #4a4740; text-align: right; }
.hint { font-size: 15px; color: #4a4740; }
.open-site {
  min-height: 48px; display: flex; align-items: center; justify-content: center; border-radius: 12px;
  border: 2px solid #161513; color: #161513; font-weight: 800; font-size: 16px; text-decoration: none;
}
.open-site:hover { color: #c2410c; border-color: #c2410c; }

.preview { align-self: flex-start; width: 92%; background: #fff; border: 2px solid #161513; border-radius: 20px; overflow: hidden; display: flex; flex-direction: column; }
.preview-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 14px; background: #161513; color: #fff; font-size: 14px; font-weight: 700; }
.preview-head span + span { font-weight: 600; color: #e6e2d9; }
.preview-body { padding: 14px; background: #f6f0e6; font-family: Georgia, serif; display: flex; flex-direction: column; gap: 2px; }
.preview-title { font-size: 20px; font-weight: 700; color: #2a1d14; margin-bottom: 6px; }
.preview-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px dashed #d8c7ae; font-size: 16px; color: #2a1d14; }
.preview-new { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 8px 10px; margin: 4px -10px 0; background: #fff4cf; border-radius: 10px; font-size: 16px; color: #2a1d14; }
.preview-new > span { display: flex; align-items: center; gap: 8px; }
.badge { font-family: var(--brand-font); font-size: 12px; font-weight: 800; background: #c2410c; color: #fff; padding: 2px 7px; border-radius: 6px; }
.change { padding: 12px 14px; font-size: 15px; color: #3b3935; border-top: 1px solid #ece9e2; }
.choices { display: flex; gap: 10px; padding: 0 14px 14px; }
.btn-ok, .btn-undo { flex: 1; min-height: 56px; border-radius: 14px; font-weight: 800; font-size: 19px; cursor: pointer; }
.btn-ok { border: 0; background: #c2410c; color: #fff; }
.btn-undo { border: 2px solid #161513; background: #fff; color: #161513; }
.result { margin: 0 14px 14px; min-height: 48px; display: flex; align-items: center; justify-content: center; border-radius: 14px; font-weight: 800; font-size: 16px; }
.result.ok { background: #e3efe4; color: #1d4d2b; }
.result.undo { background: #ece9e2; color: #3b3935; }

.inputbar { flex: none; display: flex; align-items: center; gap: 8px; padding: 10px 10px 22px; background: #fff; border-top: 1px solid #dedad2; }
.plus { flex: none; width: 48px; height: 48px; border-radius: 50%; border: 2px solid #161513; background: #fff; font-weight: 700; font-size: 24px; color: #161513; cursor: pointer; }
.field { flex: 1; min-width: 0; height: 48px; border-radius: 24px; background: #f4f2ed; display: flex; align-items: center; padding: 0 16px; font-size: 16px; color: #4a4740; }
.mic { flex: none; width: 52px; height: 52px; border-radius: 50%; border: 0; background: #c2410c; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.mic i { width: 12px; height: 20px; border-radius: 6px; background: #fff; }
.reset { align-self: flex-start; min-height: 48px; padding: 0 18px; border-radius: 12px; border: 2px solid #161513; background: transparent; font-weight: 700; font-size: 16px; color: #161513; cursor: pointer; }

/* Empty photo slot on the dark bubble. */
.slot {
  position: absolute; inset: 0; border-radius: inherit; background: rgba(127, 127, 127, .08);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; padding: 12px;
  font: 500 13px/1.3 system-ui, -apple-system, sans-serif; cursor: pointer;
}
.slot::after { content: ""; position: absolute; inset: 0; border: 1.5px dashed currentColor; opacity: .35; border-radius: inherit; pointer-events: none; }
.slot svg { opacity: .45; }
.slot-cap { max-width: 90%; opacity: .75; }
.slot-sub { font-size: 11px; opacity: .75; }
.slot.is-over { outline: 2px solid #c96442; outline-offset: -2px; }
.slot.is-filled::after, .slot.is-filled > :not(img) { display: none; }
.slot > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.demo-toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 50; width: max-content; max-width: min(92vw, 440px);
  background: #161513; color: #fff; border-radius: 12px; padding: 12px 16px; font: 600 15px/1.4 system-ui, sans-serif;
}

/* On a phone the page is the phone: no frame, no fake status bar. */
@media (max-width: 479px) {
  html:not(.framed) .chat-page { padding: 0; display: block; }
  html:not(.framed) .stack { gap: 8px; padding-bottom: 8px; }
  html:not(.framed) .phone { width: 100%; height: calc(100vh - 64px); height: calc(100dvh - 64px); border: 0; border-radius: 0; }
  html:not(.framed) .status { display: none; }
  html:not(.framed) .reset { margin-left: 10px; }
}
