:root {
  --tp-ink: #263b3a;
  --tp-muted: #71817b;
  --tp-line: #dfe8df;
  --tp-paper: #f6f8f1;
  --tp-card: #fffefa;
  --tp-green: #426c5b;
  --tp-green-dark: #315747;
  --tp-pale: #e9f1e9;
  --tp-coral: #b45f4c;
  --tp-serif: var(--font-display, 'Cormorant Garamond', Georgia, serif);
  --tp-sans: var(--font-ui, 'Inter', system-ui, sans-serif);
}

.tp-section, .tp-accommodation, .tp-modal {
  color: var(--tp-ink);
  font-family: var(--tp-sans);
  min-width: 0;
}
.tp-section {
  position: relative;
  margin: 28px 0;
  padding: 23px 0 4px;
  border-top: 1px solid var(--tp-line);
}
.tp-section-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 19px;
}
.tp-section-header h3, .tp-accommodation h3 {
  margin: 1px 0 4px;
  color: var(--tp-ink);
  font: 400 29px/1 var(--tp-serif);
}
.tp-eyebrow {
  margin: 0 0 7px;
  color: var(--tp-green);
  font: 500 10px/1.2 var(--tp-sans);
  letter-spacing: .14em;
  text-transform: uppercase;
}
.tp-intro {
  margin: 7px 0 0;
  max-width: 440px;
  color: var(--tp-muted);
  font-size: 13px;
  line-height: 1.5;
}
.tp-add, .tp-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 16px;
  border: 0;
  border-radius: 4px;
  background: var(--tp-green);
  color: #fffdf8;
  font: 500 13px var(--tp-sans);
  cursor: pointer;
  transition: background .18s ease, transform .18s ease;
}
.tp-add:hover, .tp-primary:hover { background: var(--tp-green-dark); transform: translateY(-1px); }
.tp-add > span { font-size: 20px; line-height: 0; font-weight: 400; }
.tp-controls { display: grid; gap: 12px; margin-bottom: 14px; }
.tp-search {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  min-height: 43px;
  padding: 0 13px;
  border: 1px solid var(--tp-line);
  border-radius: 4px;
  background: var(--tp-card);
  box-sizing: border-box;
}
.tp-search svg { width: 17px; height: 17px; flex: 0 0 auto; fill: none; stroke: #84958b; stroke-width: 1.6; }
.tp-search input { width: 100%; min-width: 0; border: 0; outline: 0; color: var(--tp-ink); background: transparent; font: 13px var(--tp-sans); }
.tp-search input::placeholder { color: #9aa79f; }
.tp-chip-row { display: flex; gap: 7px; overflow-x: auto; padding: 1px 0 4px; scrollbar-width: thin; }
.tp-chip {
  flex: 0 0 auto;
  border: 1px solid var(--tp-line);
  border-radius: 99px;
  padding: 6px 11px;
  color: #63766c;
  background: transparent;
  font: 500 11px var(--tp-sans);
  cursor: pointer;
}
.tp-chip:hover, .tp-chip.is-active { color: var(--tp-green-dark); border-color: #a9c2af; background: var(--tp-pale); }
.tp-category-chips { margin-top: -6px; }
.tp-place-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
.tp-place-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--tp-line);
  border-radius: 5px;
  background: var(--tp-card);
  transition: border-color .2s ease, transform .2s ease;
}
.tp-place-card:hover { border-color: #b7cbb9; transform: translateY(-1px); }
.tp-card-photo { height: 136px; overflow: hidden; background: #edf1e9; }
.tp-card-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tp-card-body { min-width: 0; padding: 13px 14px 14px; }
.tp-card-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.tp-place-name {
  min-width: 0;
  padding: 0;
  border: 0;
  color: var(--tp-ink);
  background: none;
  text-align: left;
  font: 400 21px/1.12 var(--tp-serif);
  overflow-wrap: anywhere;
  cursor: pointer;
}
.tp-place-name:hover { color: var(--tp-green); }
.tp-more, .tp-text-action {
  flex: 0 0 auto;
  border: 0;
  padding: 3px 0;
  color: var(--tp-green);
  background: transparent;
  font: 500 11px var(--tp-sans);
  cursor: pointer;
}
.tp-card-meta { margin: 5px 0 9px; color: var(--tp-muted); font-size: 11px; }
.tp-status {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 2px;
  color: #476e5b;
  background: #edf4ec;
  font: 500 10px var(--tp-sans);
}
.tp-status-booked { color: #735d35; background: #f5f0df; }
.tp-status-visited { color: #42665d; background: #e6f0eb; }
.tp-status-skipped { color: #797b72; background: #efefea; }
.tp-card-note { margin: 8px 0 0; color: #687870; font-size: 12px; line-height: 1.45; overflow-wrap: anywhere; }
.tp-text-action { display: block; margin-top: 8px; text-align: left; }
.tp-empty {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  min-height: 112px;
  padding: 18px;
  border: 1px dashed #cbd9cc;
  border-radius: 5px;
  color: var(--tp-muted);
  background: rgba(233, 241, 233, .36);
}
.tp-empty p { margin: 0; color: var(--tp-ink); font: 400 20px var(--tp-serif); }
.tp-empty > span:not(.tp-empty-mark) { margin-top: 5px; font-size: 12px; line-height: 1.5; }
.tp-empty-mark { margin-bottom: 4px; color: var(--tp-green); font: 400 19px var(--tp-sans); }
.tp-photo-unavailable { display: block; padding: 18px; color: var(--tp-muted); font-size: 11px; }

.tp-accommodation {
  margin: 24px 0;
  padding: 17px 18px;
  border-left: 3px solid #91aa93;
  background: #f0f4ec;
}
.tp-accommodation h3 { font-size: 24px; }
.tp-accommodation-link, .tp-accommodation-name {
  display: inline-block;
  margin: 9px 0 0;
  padding: 0;
  border: 0;
  color: var(--tp-ink);
  background: transparent;
  font: 400 21px var(--tp-serif);
  text-align: left;
}
.tp-accommodation-link { cursor: pointer; }
.tp-accommodation-link span { color: var(--tp-green); font: 14px var(--tp-sans); }
.tp-accommodation-meta { margin: 5px 0; color: var(--tp-muted); font-size: 12px; }

.tp-modal { width: 100%; max-width: 620px; margin: 0 auto; padding: 6px 0 12px; box-sizing: border-box; }
.tp-modal-title { margin: 0 0 6px; color: var(--tp-ink); font: 400 38px/1 var(--tp-serif); overflow-wrap: anywhere; }
.tp-back {
  display: inline-block;
  margin: 0 0 21px;
  padding: 5px 0;
  border: 0;
  color: var(--tp-green);
  background: transparent;
  font: 500 12px var(--tp-sans);
  cursor: pointer;
}
.tp-detail-photo { width: 100%; max-height: 260px; margin: 0 0 20px; overflow: hidden; border-radius: 4px; background: #edf1e9; }
.tp-detail-photo img { display: block; width: 100%; max-height: 260px; object-fit: cover; }
.tp-detail-meta { margin: 5px 0 12px; color: var(--tp-muted); font-size: 13px; }
.tp-detail-note { margin: 18px 0 8px; color: #53665d; font-size: 14px; line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.tp-detail-address { color: var(--tp-muted); font-size: 13px; line-height: 1.5; }
.tp-link-row, .tp-tag-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 15px 0; }
.tp-detail-link { display: inline-block; color: var(--tp-green); font: 500 12px var(--tp-sans); text-decoration-thickness: 1px; text-underline-offset: 3px; overflow-wrap: anywhere; }
.tp-tag { padding: 5px 9px; border-radius: 2px; color: #64766b; background: #edf2eb; font-size: 11px; }
.tp-hotel-note, .tp-help { color: var(--tp-muted); font-size: 12px; line-height: 1.5; }
.tp-modal-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 23px; padding-top: 16px; border-top: 1px solid var(--tp-line); }
.tp-secondary, .tp-danger {
  min-height: 39px;
  padding: 0 13px;
  border: 1px solid #ccd9cd;
  border-radius: 4px;
  color: var(--tp-green-dark);
  background: transparent;
  font: 500 12px var(--tp-sans);
  cursor: pointer;
}
.tp-secondary:hover { background: var(--tp-pale); }
.tp-danger { color: #9b5849; border-color: #e4c7bf; }
.tp-inline-error { min-height: 0; margin: 8px 0; color: #9f493e; font-size: 12px; line-height: 1.5; }

.tp-editor form { display: grid; gap: 12px; margin-top: 18px; }
.tp-field { display: grid; gap: 6px; color: #53675e; font: 500 11px var(--tp-sans); }
.tp-field input, .tp-field select, .tp-field textarea {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  min-height: 42px;
  padding: 10px 11px;
  border: 1px solid #dce5db;
  border-radius: 3px;
  outline: none;
  color: var(--tp-ink);
  background: var(--tp-card);
  font: 400 13px var(--tp-sans);
}
.tp-field textarea { min-height: 82px; resize: vertical; line-height: 1.5; }
.tp-field input:focus, .tp-field select:focus, .tp-field textarea:focus { border-color: #8ea995; box-shadow: 0 0 0 2px rgba(66,108,91,.1); }
.tp-required { margin-left: 5px; color: #9b7166; font-weight: 500; }
.tp-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
.tp-optional { border-top: 1px solid var(--tp-line); padding-top: 11px; }
.tp-optional summary { display: flex; justify-content: space-between; gap: 10px; color: var(--tp-ink); font: 500 13px var(--tp-sans); cursor: pointer; list-style: none; }
.tp-optional summary::-webkit-details-marker { display: none; }
.tp-optional summary::before { content: '+'; margin-right: 2px; color: var(--tp-green); }
.tp-optional[open] summary::before { content: '−'; }
.tp-optional summary span { margin-left: auto; color: #94a098; font: 500 10px var(--tp-sans); }
.tp-optional[open] > .tp-field, .tp-optional[open] > .tp-form-grid, .tp-optional[open] > .tp-check { margin-top: 12px; }
.tp-check { display: flex; align-items: flex-start; gap: 9px; color: #53675e; font: 500 12px/1.5 var(--tp-sans); }
.tp-check input { accent-color: var(--tp-green); margin: 2px 0 0; }
.tp-replace { margin-top: 12px; padding: 10px; border-radius: 3px; background: #f5f0e4; }
.tp-file-preview { color: var(--tp-muted); font-size: 11px; line-height: 1.4; }
.tp-file-preview img { display: block; width: 100%; max-height: 190px; object-fit: cover; margin-bottom: 6px; border-radius: 3px; }
.tp-save { width: 100%; margin-top: 6px; }
.tp-save:disabled { opacity: .65; cursor: wait; }
.tp-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

@media (max-width: 560px) {
  .tp-section { margin-top: 22px; padding-top: 19px; }
  .tp-section-header { align-items: center; gap: 9px; }
  .tp-section-header h3 { font-size: 27px; }
  .tp-section-header .tp-intro { max-width: 235px; font-size: 12px; }
  .tp-add { flex: 0 0 auto; min-height: 39px; padding: 0 11px; font-size: 12px; }
  .tp-place-list { grid-template-columns: minmax(0, 1fr); gap: 9px; }
  .tp-place-card { display: grid; grid-template-columns: 88px minmax(0, 1fr); min-height: 118px; }
  .tp-place-card:has(.tp-card-photo) { grid-template-columns: 100px minmax(0, 1fr); }
  .tp-card-photo { height: 100%; min-height: 118px; }
  .tp-card-body { padding: 11px 12px; }
  .tp-place-name { font-size: 20px; }
  .tp-card-note { font-size: 11px; }
  .tp-form-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .tp-modal { padding-left: 1px; padding-right: 1px; }
  .tp-modal-title { font-size: 34px; }
  .tp-modal-actions > * { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: reduce) {
  .tp-add, .tp-primary, .tp-place-card { transition: none; }
}
