#trip-plan {
  background: var(--paper);
  color: var(--ink);
  padding: max(calc(var(--trip-header-height, 100px) + 18px), 6vw) max(5vw, 22px) clamp(94px, 8vw, 140px);
  border-bottom: 1px solid color-mix(in srgb, var(--ink) 16%, transparent);
  overflow-anchor: none;
}
#trip-plan[hidden], .trip-reopen[hidden] { display: none; }
/* A reply can resize the planner and move the browser's anchor in the section below it. */
html:has(#trip-plan:not([hidden])) { overflow-anchor: none; }
.trip-wrap { max-width: 1180px; margin: 0 auto; }
.trip-intro { max-width: 780px; margin-bottom: clamp(26px, 3.2vw, 52px); }
.trip-intro h2 { font-size: clamp(50px, 6.2vw, 92px); line-height: .98; }
.trip-intro h2:focus { outline: 0; }
.trip-reply { margin-top: 15px; font-size: clamp(17px, 1.45vw, 21px); line-height: 1.55; white-space: pre-line; }
.trip-reply[data-full-reply] { display: grid; }
.trip-reply[data-full-reply]::before { content: attr(data-full-reply); visibility: hidden; }
.trip-reply[data-full-reply]::before, .trip-reply[data-full-reply] > span { grid-area: 1 / 1; }
.trip-layout { display: grid; grid-template-columns: minmax(0,1.15fr) minmax(330px,.85fr); gap: clamp(35px,6vw,94px); align-items: start; }
.trip-layout.is-saved { align-items: stretch; }
.trip-tabs { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.trip-tabs button { min-height: 44px; padding: 7px 18px; border-radius: 99px; font-size: 16px; font-weight: 500; background: transparent; color: var(--ink); }
.trip-tabs button[aria-pressed=true] { background: var(--ink); color: var(--paper); }
.trip-tabs button[aria-pressed=false]:hover { background: color-mix(in srgb, var(--ink) 7%, transparent); }
.trip-choice { width: 100%; text-align: left; display: grid; grid-template-columns: 1fr 42px; align-items: center; gap: 18px; padding: 16px 2px; border-top: 1px solid color-mix(in srgb, var(--ink) 22%, transparent); }
.trip-choice:last-child { border-bottom: 1px solid color-mix(in srgb, var(--ink) 22%, transparent); }
.trip-choice strong, .trip-choice small { display: block; }
.trip-choice strong { font-size: clamp(18px, 1.5vw, 22px); line-height: 1.28; font-weight: 600; }
.trip-choice small { margin-top: 4px; font-size: 15px; line-height: 1.5; color: var(--muted); }
.trip-choice-mark { display: grid; place-items: center; width: 38px; height: 38px; border: 1px solid color-mix(in srgb, var(--ink) 30%, transparent); border-radius: 50%; font-size: 23px; line-height: 1; }
.trip-choice[aria-pressed=true] .trip-choice-mark, .trip-choice:hover .trip-choice-mark { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.trip-choice[aria-pressed=true] .trip-choice-mark { font-size: 17px; }
.trip-inline { display: inline-flex; align-items: center; min-height: 44px; padding: 5px 0; color: var(--ink); font-weight: 500; font-size: 15px; text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.trip-catalog > .trip-inline { margin-top: 6px; }
.trip-summary { min-width: 0; padding: clamp(20px, 2.5vw, 40px); background: var(--wash, var(--surface)); }
.trip-summary h3 { font-size: clamp(37px, 3.4vw, 53px); line-height: 1.05; }
.trip-items { margin: 18px 0 2px; padding: 0; list-style: none; }
.trip-items li { display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); padding: 4px 0; min-height: 42px; font-size: 16px; }
.trip-items li button { min-width: 38px; min-height: 38px; font-size: 24px; line-height: 1; }
.trip-empty, .trip-ref, .trip-saved-dates { font-size: 16px; line-height: 1.5; margin: 15px 0 0; }
.trip-ref { color: var(--muted); }
.trip-details { margin-top: 18px; }
.trip-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px 12px; }
.trip-fields label { min-width: 0; display: flex; flex-direction: column; gap: 5px; font-size: 15px; line-height: 1.5; }
.trip-fields input { display: block; appearance: none; width: 100%; min-width: 0; height: 46px; border: 1px solid color-mix(in srgb, var(--ink) 30%, transparent); border-radius: 4px; padding: 8px; background: var(--paper); color: var(--ink); font: inherit; font-size: 16px; color-scheme: light; }
.trip-solid { min-height: 48px; padding: 11px 18px; border: 0; border-radius: 4px; background: var(--ink); color: var(--paper); font-weight: 500; font-size: 16px; line-height: 1.35; }
.trip-solid:hover { filter: brightness(1.22); }
.trip-details .trip-solid { display: block; width: 100%; margin-top: 18px; }
.trip-tools { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 22px; margin-top: 22px; }
#trip-plan button:focus-visible, #trip-plan input:focus-visible, .trip-reopen:focus-visible { box-shadow: 0 0 0 2px var(--paper), 0 0 0 4px var(--ink); outline: 0; }
@media (max-width: 760px) {
  .trip-layout { grid-template-columns: minmax(0,1fr); gap: 26px; }
  .trip-intro { margin-bottom: 23px; }
  .trip-summary h3 { font-size: 37px; }
  .trip-choice { padding: 12px 0; gap: 10px; }
  .trip-fields { gap: 12px 8px; }
  #trip-plan[data-focus="summary"] .trip-summary, #trip-plan[data-focus="dates"] .trip-summary, #trip-plan[data-focus="guests"] .trip-summary { order: -1; }
}
@media (max-width: 370px) {
  .trip-fields { grid-template-columns: 1fr; }
  .trip-tabs button { padding-inline: 13px; }
}
.trip-cover { min-width: 0; position: relative; min-height: 240px; }
.trip-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.trip-field-error { font-size: 15px; line-height: 1.4; margin-top: 12px; color: #8b341e; }
.trip-field-error:empty { display: none; }
@media (max-width: 760px) {
  .trip-layout.is-saved { gap: 16px; }
  .trip-cover { order: 2; min-height: 185px; }
}

.trip-facts { margin-top: 12px; color: var(--ink); font-size: clamp(18px, 1.7vw, 24px); font-weight: 600; }
.trip-facts:empty { display: none; }

.trip-assistant {
  --dock-base: #222820;
  --composer-idle: rgba(30, 35, 29, .62);
  --dock-glass: rgba(30, 35, 29, .85);
  --dock-text: #fffaf0;
  --dock-edge: rgba(255, 250, 240, .26);
}
@media (prefers-color-scheme: dark) {
  .trip-assistant {
    --dock-base: #faf7ef;
    --composer-idle: rgba(255, 252, 244, .58);
    --dock-glass: rgba(255, 252, 244, .86);
    --dock-text: #242821;
    --dock-edge: rgba(45, 48, 40, .24);
  }
}
.trip-announcement {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}
.trip-reply[hidden], .conversation-panel[hidden] { display: none; }
.conversation-dock { color: var(--dock-text); pointer-events: none; }
.conversation-controls { display: grid; grid-template-columns: 1fr 60px 1fr; align-items: center; gap: 4px; margin-bottom: 4px; }
.conversation-controls button, .conversation-panel {
  background: var(--dock-glass); color: var(--dock-text);
  border: 1px solid var(--dock-edge); box-shadow: 0 3px 12px #0002;
  -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); pointer-events: auto;
}
.conversation-controls button {
  display: inline-flex; align-items: center; justify-content: center;
  height: 40px; min-width: 44px; border-radius: 30px; cursor: pointer;
}
.conversation-controls button:hover { background: var(--dock-base); }
.conversation-controls .trip-reopen { grid-column: 1; grid-row: 1; justify-self: end; height: 28px; padding: 0 12px; font: 500 14px Manrope,sans-serif; }
.conversation-controls svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.conversation-controls .conversation-action {
  grid-row: 1; display: grid; place-items: center;
  width: 60px; height: 26px; min-height: 26px; padding: 0; border: 0;
  border-radius: 20px; background: transparent; color: #bbc5b8; box-shadow: none;
  backdrop-filter: none; -webkit-backdrop-filter: none; transition: color .2s, background-color .2s;
}
.conversation-controls .conversation-action:hover { background: #ffffff0b; }
.conversation-controls .me-history-handle { grid-column: 2; }
.conversation-controls .conversation-reset { grid-column: 3; justify-self: start; width: 36px; min-width: 36px; }
.conversation-reset svg { width: 16px; height: 16px; stroke-width: 2; }
.conversation-controls .conversation-action[hidden], .conversation-controls:not(:has(button:not([hidden]))) { display: none; }
.conversation-controls .me-history-handle svg { width: 20px; height: 20px; stroke-width: 2; transition: transform .24s; }
.conversation-handle[aria-expanded="true"] svg { transform: rotate(180deg); }
.conversation-panel {
  width: min(100%, 640px); margin: 0 auto 8px; padding: 16px 20px;
  border-radius: 20px; text-align: left; background: var(--dock-base);
}
.conversation-panel header { display: flex; align-items: center; justify-content: space-between; }
.conversation-panel h2 { font: 600 18px/1.4 Manrope,sans-serif; color: inherit; }
.conversation-panel header button { width: 40px; height: 40px; color: inherit; font-size: 25px; }
.conversation-panel ol { list-style: none; margin: 4px 0; padding: 0; max-height: min(38dvh, 320px); overflow: auto; overscroll-behavior: contain; }
.conversation-panel li { font: 400 16px/1.45 Manrope,sans-serif; white-space: pre-wrap; overflow-wrap: anywhere; }
.conversation-panel li + li { margin-top: 14px; }
.conversation-panel strong { display: block; font-weight: 600; }
.conversation-dock button:focus-visible { outline: 2px solid var(--dock-text); outline-offset: -4px; }
@media (prefers-reduced-motion: reduce) { .conversation-controls .me-history-handle svg { transition: none; } }
@media (prefers-reduced-transparency: reduce) {
  .conversation-controls button { background: var(--dock-base); backdrop-filter: none; }
}
