.front-door-place-thumbnail{width:88px;height:112px;object-fit:cover;flex:0 0 88px;border-radius:3px}
.front-door-record:has(.front-door-place-thumbnail){display:flex;align-items:flex-start;gap:16px}
.front-door-record-info{min-width:0}
@media(max-width:600px){.front-door-place-thumbnail{width:68px;height:92px;flex-basis:68px}.front-door-record:has(.front-door-place-thumbnail){gap:12px}}
:is(#todayThoughtAnswer,.foru-conversation-history-answer) .capture-engine-options {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  background: none;
  border: 0;
  box-shadow: none;
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer) .capture-engine-options > button {
  display: inline-flex;
  flex: 0 1 auto;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  background: transparent;
  border: 0;
  box-shadow: none;
  color: var(--atelier-ink, #161918);
}
#detailModal .record-private-badge {
  display:inline-block; padding:4px 8px; border:1px solid var(--atelier-line, #cdc9bf);
  color:var(--atelier-soft, var(--soft)); font-size:11px; letter-spacing:.08em;
}
#detailModal .record-flight-summary { font-size:17px; line-height:1.6; overflow-wrap:break-word; }
#detailModal .record-document-kind { font-size:12px; color:var(--atelier-soft, var(--soft)); }
#detailModal .front-door-fields { grid-template-columns:minmax(0,2fr) minmax(0,3fr); }
#detailModal :is(.front-door-fields dt,.front-door-fields dd,.wtu-facts dt,.wtu-facts dd) {
  min-width:0; white-space:normal; word-break:normal; overflow-wrap:break-word;
}
#detailModal [data-record-ticket-actions] button { min-height:44px; }
#detailModal .front-door-record-photo[hidden] { display:none; }
@media(max-width:767px) {
  #detailModal .front-door-fields { display:block; }
  #detailModal .front-door-fields dt { margin:14px 0 3px; font-size:11px; }
  #detailModal .front-door-fields dd { margin:0; padding-bottom:12px; border-bottom:1px solid var(--atelier-line, var(--line)); }
  #detailModal .wtu-facts > div { display:block; }
  #detailModal .wtu-facts dt { margin-bottom:4px; }
}
.front-door-documents{display:grid;gap:24px;margin:20px 0}
.front-door-document{border-top:1px solid var(--line,#cdc9bf);padding:20px 0}
.front-door-document h3{font:400 26px/1.2 "Cormorant Garamond",serif;margin:0 0 8px}
.front-door-document-soft{color:var(--muted,#5f625e);font:400 13px/1.5 Inter,sans-serif}
.front-door-document-preview{max-width:100%;width:auto;max-height:280px;object-fit:contain;border:1px solid var(--line,#cdc9bf);border-radius:2px}
.front-door-document .front-door-actions{flex-wrap:wrap}
.front-door-document button{min-width:44px;min-height:44px}
#detailModal .front-door-passport {min-height:44px;display:flex;align-items:center;}
/* Today retrieval — a quiet editorial answer layer for Atelier. */
#detailModal:not(.hidden):has(#fieldPlacementForm) {
  z-index: 11000;
  display: grid;
  place-items: center;
  padding: 16px;
}
#detailModal:has(#fieldPlacementForm) > .modal-card {
  width: min(560px, 100%);
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
}
#fieldPlacementForm {
  display: grid;
  gap: 16px;
}
#fieldPlacementForm blockquote {
  margin: 0;
  border-left: 1px solid var(--line, #cdc9bf);
  padding-left: 16px;
}
.field-placement-suggestion {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  padding: 12px 0;
}
.field-placement-suggestion > span {
  flex: 1 1 240px;
  font: 400 13px/1.5 Inter, sans-serif;
  color: var(--muted, #5f625e);
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer) {
  --fd-paper: var(--atelier-paper, var(--paper, #fbfaf6));
  --fd-ink: var(--atelier-ink, var(--ink, #20231f));
  --fd-muted: var(--atelier-soft, var(--muted, #686b62));
  --fd-line: var(--atelier-line, var(--line, #d8d4c9));
  --fd-olive: var(--atelier-olive, var(--olive, #566454));
  --fd-olive-ink: var(--atelier-paper, var(--paper, #fbfaf6));
  box-sizing: border-box;
  min-width: 0;
  margin-top: 16px;
  color: var(--fd-ink);
}

:is(#todayThoughtAnswer,.foru-conversation-history-answer):empty {
  display: none;
}

.front-door-answer {
  min-width: 0;
  padding: clamp(16px, 2.4vw, 24px);
  border: 1px solid var(--fd-line, var(--atelier-line, var(--line)));
  background: var(--fd-paper, var(--atelier-paper, var(--paper)));
  color: var(--fd-ink, var(--atelier-ink, var(--ink)));
}

.front-door-answer-line {
  max-width: 70ch;
  margin: 0;
  color: var(--atelier-ink, var(--ink));
  font: 400 clamp(19px, 2.3vw, 25px)/1.4 var(--font-display, "Cormorant Garamond"), Georgia, serif;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.front-door-candidates {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  align-items: stretch;
  gap: 10px;
  min-width: 0;
  margin-top: 17px;
}

.front-door-record {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: start;
  gap: 13px;
  min-width: 0;
  padding: 11px;
  border: 1px solid var(--atelier-line, var(--line));
  background: var(--atelier-paper, var(--paper));
  color: var(--atelier-ink, var(--ink));
}

.front-door-record-photo {
  display: block;
  width: 72px;
  height: 72px;
  object-fit: cover;
  background: color-mix(in srgb, var(--atelier-paper, var(--paper)) 88%, var(--atelier-line, var(--line)));
}

.front-door-record-info {
  display: grid;
  align-content: start;
  gap: 7px;
  min-width: 0;
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-record-info{grid-column:2;grid-row:1}
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-record-info:only-child{grid-column:1 / -1}
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-record-photo{grid-column:1;grid-row:1}

.front-door-record-info > :first-child {
  margin: 0;
  color: var(--atelier-ink, var(--ink));
  font: 500 14px/1.35 var(--font-ui, system-ui, sans-serif);
  overflow-wrap: anywhere;
}

:is(#todayThoughtAnswer,.foru-conversation-history-answer) .front-door-record-info > [data-front^="open:"] {
  justify-self: start;
  justify-content: flex-start;
  text-align: left;
  min-height: 44px;
  max-width: 100%;
  padding-inline: 0;
  margin: 0;
  font: 400 20px/1.25 var(--font-display, "Cormorant Garamond", Georgia, serif);
}

.front-door-fields {
  display: grid;
  grid-template-columns: minmax(64px, auto) minmax(0, 1fr);
  gap: 4px 10px;
  min-width: 0;
  margin: 0;
  font: 400 12px/1.45 var(--font-ui, system-ui, sans-serif);
}

.front-door-fields dt {
  min-width: 0;
  color: var(--atelier-soft, var(--muted));
  overflow-wrap: anywhere;
}

.front-door-fields dd {
  min-width: 0;
  margin: 0;
  color: var(--atelier-ink, var(--ink));
  overflow-wrap: anywhere;
}

/* Keep labels bounded: auto-sized labels previously squeezed values to a letter. */
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-record {
  display: flex;
  flex-direction: row-reverse;
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-record-info {
  flex: 1 1 0;
  min-width: 0;
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-record-photo {
  flex: 0 0 72px;
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-record-photo[hidden] {
  display: none;
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-fields {
  width: 100%;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-fields :is(dt, dd) {
  min-width:0;
  max-width:none;
  white-space: normal;
  word-break: normal;
  overflow-wrap: break-word;
}
@media(max-width:767px){
 :is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-fields{display:block;width:100%}
 :is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-fields dt,
 :is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-fields dd{display:block;width:auto;float:none;margin:0}
 :is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-fields dt{margin-top:12px}
 :is(#todayThoughtAnswer,.foru-conversation-history-answer).front-door-answer .front-door-fields dd{margin-top:3px;line-height:1.5}
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer) [data-service-actions] a{min-height:44px;display:inline-flex;align-items:center}
/* Contact links share the same quiet, high-contrast Atelier treatment as actions. */
.front-door-contact-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--atelier-olive, var(--olive));
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--atelier-olive, var(--olive)) 45%, transparent);
  text-underline-offset: 2px;
  overflow-wrap: anywhere;
}
.front-door-contact-link:hover { text-decoration-color: currentColor; }
.front-door-contact-link:focus-visible { outline: 2px solid var(--atelier-brass, var(--focus)); outline-offset: 2px; }
:is(#todayThoughtAnswer,.foru-conversation-history-answer) .front-door-stock-note {
  margin: 14px 0 0;
  padding-top: 11px;
  border-top: 1px solid var(--atelier-line, var(--line));
  color: var(--atelier-soft, var(--muted));
  font: 400 13px/1.55 var(--font-ui, system-ui, sans-serif);
}
:is(#todayThoughtAnswer,.foru-conversation-history-answer) .front-door-actions:has([data-service-call]) { gap: 2px 10px; }
:is(#todayThoughtAnswer,.foru-conversation-history-answer) [data-service-actions] { gap: 2px 10px; }
:is(#todayThoughtAnswer,.foru-conversation-history-answer) [data-service-actions] { margin-top: 0; }
.front-door-related-lines {
  padding: 0;
  list-style: none;
  color: var(--atelier-soft, var(--muted));
  font: 400 13px/1.6 var(--font-ui, Inter, sans-serif);
}
.front-door-related-lines li { padding: 6px 0; border-bottom: 1px solid var(--atelier-line, var(--line)); }

.front-door-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 14px;
  min-width: 0;
  margin-top: 14px;
}

.front-door-actions :is(a, button, [role="button"]) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 8px 4px;
  border: 0;
  background: transparent;
  color: var(--atelier-soft, var(--muted));
  font: 500 12px/1.35 var(--font-ui, system-ui, sans-serif);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.front-door-actions :is(a, button, [role="button"]):hover {
  color: var(--atelier-ink, var(--ink));
  text-decoration: underline;
  text-underline-offset: 3px;
}

.front-door-actions :is(a, button, [role="button"]):focus-visible,
.front-door-sheet :is(button, a[href], input, select, textarea, [tabindex]):focus-visible {
  outline: 2px solid var(--atelier-brass, var(--focus, var(--atelier-olive, var(--olive))));
  outline-offset: 2px;
  box-shadow: none;
}

/* The result detail modal keeps the shared modal mechanics but reads as a
   contained, paper-toned sheet. Its viewport height leaves the mobile tab bar clear. */
#detailModal.front-door-sheet {
  z-index: 1000;
  place-items: center;
  padding: clamp(12px, 3vw, 30px);
  background: color-mix(in srgb, var(--atelier-ink, var(--ink)) 28%, transparent);
}

#detailModal.front-door-sheet .modal-card {
  display: flex;
  flex-direction: column;
  width: min(100%, 720px);
  max-height: min(88dvh, 860px);
  overflow: auto;
  overscroll-behavior: contain;
  padding: clamp(20px, 3vw, 30px);
  border: 1px solid var(--atelier-line, var(--line));
  border-radius: 4px;
  background: var(--atelier-paper, var(--paper));
  color: var(--atelier-ink, var(--ink));
  box-shadow: none;
  scrollbar-color: var(--atelier-line, var(--line)) transparent;
}

#detailModal.front-door-sheet #detailContent {
  min-width: 0;
}

.front-door-sheet .front-door-record {
  grid-template-columns: 84px minmax(0, 1fr);
  padding: 13px;
}

.front-door-sheet .front-door-record-photo {
  width: 84px;
  height: 84px;
}

.front-door-sheet :is(.capture-record-form, .meal-form) {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: 12px 15px;
  min-width: 0;
}

.front-door-sheet .edit-field {
  display: grid;
  align-content: start;
  gap: 5px;
  min-width: 0;
  color: var(--atelier-soft, var(--muted));
  font: 500 11px/1.4 var(--font-ui, system-ui, sans-serif);
}

.front-door-sheet .edit-field :is(input, select, textarea) {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 9px 11px;
  border: 1px solid var(--atelier-line, var(--line));
  border-radius: 3px;
  background: var(--atelier-paper, var(--paper));
  color: var(--atelier-ink, var(--ink));
  font: 400 14px/1.4 var(--font-ui, system-ui, sans-serif);
}

.front-door-sheet .edit-field textarea {
  min-height: 88px;
  resize: vertical;
}

.front-door-sheet .edit-field :is(input, textarea)::placeholder {
  color: var(--atelier-soft, var(--muted));
  opacity: .78;
}

.front-door-sheet .front-door-actions {
  justify-content: flex-end;
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid var(--atelier-line, var(--line));
}

.front-door-sheet .front-door-actions .primary-btn,
.front-door-sheet button.front-door-choice.primary,
.front-door-sheet .front-door-choice[data-primary="true"] {
  min-width: 112px;
  min-height: 46px;
  padding: 10px 20px;
  border: 1px solid var(--atelier-olive, var(--olive));
  border-radius: 999px;
  background: var(--atelier-olive, var(--olive));
  color: var(--atelier-paper, var(--paper));
  font: 500 12px/1.2 var(--font-ui, system-ui, sans-serif);
  cursor: pointer;
}

.front-door-sheet .front-door-actions .primary-btn:hover,
.front-door-sheet button.front-door-choice.primary:hover,
.front-door-sheet .front-door-choice[data-primary="true"]:hover {
  filter: brightness(1.08);
}

.front-door-share-preview {
  min-width: 0;
  margin: 14px 0;
  padding: 14px;
  border: 1px solid var(--atelier-line, var(--line));
  background: color-mix(in srgb, var(--atelier-paper, var(--paper)) 92%, var(--atelier-line, var(--line)));
  color: var(--atelier-ink, var(--ink));
  overflow-wrap: anywhere;
}

.front-door-waiting {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.front-door-waiting :is(input, select, textarea) {
  min-height: 44px;
}

.front-door-also {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
  gap: 4px 12px;
  min-width: 0;
  margin: 12px 0 0;
  padding: 11px 0 0;
  border-top: 1px solid var(--atelier-line, var(--line));
}

.front-door-also label {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  min-height: 44px;
  padding: 4px 2px;
  color: var(--atelier-soft, var(--muted));
  font: 400 12px/1.4 var(--font-ui, system-ui, sans-serif);
  cursor: pointer;
}

.front-door-also input[type="checkbox"] {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  accent-color: var(--atelier-olive, var(--olive));
}

.front-door-choice {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 9px 13px;
  border: 1px solid var(--atelier-line, var(--line));
  border-radius: 999px;
  background: var(--atelier-paper, var(--paper));
  color: var(--atelier-soft, var(--muted));
  font: 500 12px/1.3 var(--font-ui, system-ui, sans-serif);
  text-decoration: none;
  cursor: pointer;
}

.front-door-choice:hover {
  border-color: var(--atelier-olive, var(--olive));
  color: var(--atelier-ink, var(--ink));
}

.front-door-choice[aria-pressed="true"],
.front-door-choice.is-selected {
  border-color: var(--atelier-olive, var(--olive));
  background: color-mix(in srgb, var(--atelier-olive, var(--olive)) 14%, var(--atelier-paper, var(--paper)));
  color: var(--atelier-ink, var(--ink));
}

@media (min-width: 768px) {
  :is(#todayThoughtAnswer,.foru-conversation-history-answer) {
    max-width: 880px;
    margin-top: 20px;
  }

  .front-door-record {
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 11px;
    padding: 10px;
  }

  .front-door-record-photo {
    width: 64px;
    height: 64px;
  }
}

@media (max-width: 767px) {
  :is(#todayThoughtAnswer,.foru-conversation-history-answer) {
    margin-top: 12px;
  }

  .front-door-answer {
    padding: 15px 13px;
  }

  .front-door-candidates {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
    margin-top: 12px;
  }

  .front-door-record {
    grid-template-columns: 60px minmax(0, 1fr);
    gap: 10px;
    padding: 9px;
  }

  .front-door-record-photo {
    width: 60px;
    height: 60px;
  }

  .front-door-fields {
    grid-template-columns: minmax(56px, auto) minmax(0, 1fr);
    gap: 3px 8px;
    font-size: 11px;
  }

  #detailModal.front-door-sheet {
    place-items: end center;
    padding: 0;
    padding-bottom: calc(60px + env(safe-area-inset-bottom));
  }

  #detailModal.front-door-sheet .modal-card {
    width: 100%;
    max-height: calc(100dvh - 84px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    padding: 20px 16px 18px;
    border-radius: 9px 9px 0 0;
  }

  .front-door-sheet .front-door-record {
    grid-template-columns: 64px minmax(0, 1fr);
    padding: 10px;
  }

  .front-door-sheet .front-door-record-photo {
    width: 64px;
    height: 64px;
  }

  .front-door-sheet :is(.capture-record-form, .meal-form) {
    grid-template-columns: minmax(0, 1fr);
    gap: 11px;
  }

  .front-door-sheet .front-door-actions {
    justify-content: stretch;
    gap: 4px 8px;
  }

  .front-door-sheet .front-door-actions .primary-btn {
    flex: 1 1 auto;
    order: 0;
  }

  .front-door-actions {
    gap: 2px 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .front-door-actions *,
  .front-door-choice {
    scroll-behavior: auto;
    transition-duration: .01ms;
  }
}
