/* ============================================================
   CorfuDiscovery  -  single listing options (Settings -> Single Listing)
   Gallery layouts, amenities as tags, a section nav that does not stick, and the review pieces.
   ============================================================ */

/* "Listing sticky header": off = the section nav scrolls away with the page */
.cdf-lnav[data-sticky="off"] { position: static; }

/* "Gallery on top": a row of four */
.gallery.gallery--top { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; height: clamp(180px, 22vw, 300px); border-radius: var(--r-lg); overflow: hidden; }
.gallery.gallery--top .g { position: relative; display: block; overflow: hidden; }
.gallery.gallery--top .g img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s; }
.gallery.gallery--top .g:hover img { transform: scale(1.04); }
.gallery.gallery--top .g-main { grid-row: auto; grid-column: auto; }
@media (max-width: 760px) { .gallery.gallery--top { grid-template-columns: 1fr 1fr; height: auto; } .gallery.gallery--top .g { aspect-ratio: 4/3; } }

/* "Fullwidth photo": one wide photo, as tall as the option allows, inset or edge to edge */
.gallery.gallery--full { display: block; position: relative; height: min(var(--cdf-full-h, 760px), 62vh); min-height: 240px; overflow: hidden; border-radius: var(--r-lg); }
.gallery.gallery--full .g { position: absolute; inset: 0; display: block; }
.gallery.gallery--full .g[hidden] { display: none; }
.gallery.gallery--full .g img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (min-width: 1201px) {
  .gallery.gallery--full:not(.gallery--inset) { border-radius: 0; }
  .gallery.gallery--full.gallery--inset { margin: 0 20px 10px; border-radius: 10px; }
}

/* "Gallery in content": every photo a thumbnail in the page */
.gallery.gallery--content { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; height: auto; border-radius: 0; }
.gallery.gallery--content .g { display: block; aspect-ratio: 4/3; overflow: hidden; border-radius: 10px; }
.gallery.gallery--content .g img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.gallery.gallery--content .g:hover img { transform: scale(1.05); }

/* "Show taxonomies as list of checkboxes": off = tags */
.amen-grid[data-style="tags"] { display: flex; flex-wrap: wrap; gap: 8px; }
.amen-grid[data-style="tags"] .amenity { padding: 7px 14px; border-radius: var(--pill); background: var(--sand-2); font-weight: 600; }
.amen-grid[data-style="tags"] .ai { display: none; }

/* ============================================================
   Reviews written on the site (partials/site/native-reviews)
   ============================================================ */
.cdf-rv { margin-top: 8px; }
.cdf-rv-note { margin: 0 0 18px; padding: 12px 16px; border-radius: var(--r); font-size: 14.5px; font-weight: 600; }
.cdf-rv-note p { margin: 0; }
.cdf-rv-note.is-ok { background: var(--tc-listing-extras-eaf6ee,#eaf6ee); color: var(--tc-listing-extras-1f7a44,#1f7a44); border: 1px solid var(--tc-listing-extras-c9e8d4,#c9e8d4); }
.cdf-rv-note.is-err { background: var(--tc-listing-extras-fdecea,#fdecea); color: var(--tc-listing-extras-a8321f,#a8321f); border: 1px solid var(--tc-listing-extras-f5c9c2,#f5c9c2); }
.cdf-rv-muted { margin: 22px 0 0; color: var(--body); font-size: 15px; }
.cdf-rv-muted a { color: var(--coral); font-weight: 700; }

.cdf-rv-avgs { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 10px 28px; margin: 0 0 22px; }
.cdf-rv-avg { display: grid; grid-template-columns: 1fr 90px 30px; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; color: var(--body); }
.cdf-rv-avg i { height: 6px; border-radius: 3px; background: var(--sand-2); position: relative; overflow: hidden; }
.cdf-rv-avg i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--coral); border-radius: 3px; }
.cdf-rv-avg b { text-align: right; color: var(--ink); }

.cdf-rv-photos { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.cdf-rv-photos img { width: 84px; height: 84px; object-fit: cover; border-radius: 10px; display: block; }
.cdf-rv-reply { margin-top: 14px; padding: 12px 16px; border-left: 3px solid var(--coral); background: var(--sand); border-radius: 0 var(--r) var(--r) 0; font-size: 14.5px; }
.cdf-rv-reply b { display: block; font-size: 13px; color: var(--coral-deep); margin-bottom: 4px; }
.cdf-rv-reply p { margin: 0; }
.cdf-rv-actions { margin-top: 10px; }
.cdf-rv-helpful { font-size: 13px; font-weight: 700; color: var(--muted); padding: 5px 12px; border: 1px solid var(--line-strong); border-radius: var(--pill); background: var(--tc-listing-extras-ffffff,#fff); cursor: pointer; }
.cdf-rv-helpful:hover, .cdf-rv-helpful.is-on { border-color: var(--coral); color: var(--coral); }

.cdf-rv-form { margin-top: 26px; padding: clamp(18px, 3vw, 28px); border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--tc-listing-extras-ffffff,#fff); }
.cdf-rv-form h3 { margin: 0 0 16px; font-size: 20px; font-family: var(--serif); font-weight: 600; }
.cdf-rv-crit { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.cdf-rv-label { font-weight: 700; font-size: 15px; cursor: help; }
.cdf-rv-stars { display: inline-flex; flex-direction: row-reverse; gap: 2px; }
.cdf-rv-stars input { position: absolute; opacity: 0; pointer-events: none; }
.cdf-rv-stars label { font-size: 26px; line-height: 1; color: var(--line-strong); cursor: pointer; transition: color .12s; }
.cdf-rv-stars label:hover, .cdf-rv-stars label:hover ~ label, .cdf-rv-stars input:checked ~ label { color: var(--tc-listing-extras-f5a623,#f5a623); }
.cdf-rv-stars input:focus-visible + label { outline: 2px solid var(--coral); outline-offset: 2px; border-radius: 4px; }
.cdf-rv-field { display: block; margin-top: 18px; }
.cdf-rv-field > span { display: block; margin-bottom: 7px; font-size: 13px; font-weight: 800; letter-spacing: .02em; }
.cdf-rv-field small { font-weight: 500; color: var(--muted); }
.cdf-rv-field textarea { width: 100%; border: 1.5px solid var(--line-strong); border-radius: var(--r); padding: 12px 15px; font: inherit; background: var(--sand); resize: vertical; }
.cdf-rv-field textarea:focus { outline: none; border-color: var(--coral); background: var(--tc-listing-extras-ffffff,#fff); box-shadow: 0 0 0 4px var(--coral-soft); }
.cdf-rv-form .auth-captcha { margin: 16px 0 0; }
.cdf-rv-form .btn { margin-top: 18px; }
.cdf-rv-mine { margin-top: 26px; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px 20px; background: var(--tc-listing-extras-ffffff,#fff); }
.cdf-rv-mine > summary { cursor: pointer; font-weight: 700; color: var(--ink); }
.cdf-rv-mine .cdf-rv-form { border: 0; padding: 14px 0 0; margin-top: 0; }
.cdf-rv-delete { margin-top: 8px; }

/* "Report this listing" */
.cdf-report { position: fixed; inset: 0; margin: auto; width: min(480px, calc(100vw - 32px)); height: fit-content; padding: 26px 28px; border: 0; border-radius: var(--r-lg); box-shadow: var(--shadow-lg); }
.cdf-report::backdrop { background: var(--tc-listing-extras-0a1e2b8c,rgba(10, 30, 43, .55)); backdrop-filter: blur(3px); }
.cdf-report h3 { margin: 0 0 6px; font-family: var(--serif); font-size: 24px; font-weight: 600; }
.cdf-report select { width: 100%; border: 1.5px solid var(--line-strong); border-radius: var(--r); padding: 11px 14px; font: inherit; background: var(--sand); }
.cdf-report textarea { width: 100%; border: 1.5px solid var(--line-strong); border-radius: var(--r); padding: 12px 15px; font: inherit; background: var(--sand); resize: vertical; }
.cdf-report [data-cdf-report-msg] { margin: 12px 0 0; font-size: 14px; font-weight: 600; }
.cdf-report__btns { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; }

/* Optional sections: pricing menu, video, FAQ */
.cdf-menu__group + .cdf-menu__group { margin-top: 22px; }
.cdf-menu__group h3 { font-size: 1.05rem; margin: 0 0 8px; }
.cdf-menu__items { list-style: none; margin: 0; padding: 0; }
.cdf-menu__items li { align-items: baseline; border-bottom: 1px dashed var(--line, #e3dccf); display: flex; gap: 16px; justify-content: space-between; padding: 10px 0; }
.cdf-menu__text { display: grid; gap: 2px; }
.cdf-menu__text span { color: var(--muted, #6b5f4d); font-size: .92rem; }
.cdf-menu__price { font-weight: 700; white-space: nowrap; }
.cdf-video__frame { aspect-ratio: 16 / 9; background: var(--tc-listing-extras-14202b,#14202b); border-radius: 16px; overflow: hidden; position: relative; }
.cdf-video__frame iframe { border: 0; height: 100%; inset: 0; position: absolute; width: 100%; }
.cdf-video__play { align-items: center; background: none; border: 0; color: var(--tc-listing-extras-ffffff,#fff); cursor: pointer; display: flex; flex-direction: column; font: inherit; font-weight: 700; gap: 10px; height: 100%; justify-content: center; width: 100%; }
.cdf-video__play svg { background: var(--tc-listing-extras-ffffff29,rgba(255, 255, 255, .16)); border-radius: 50%; height: 72px; padding: 18px; width: 72px; }
.cdf-video__play:hover svg, .cdf-video__play:focus-visible svg { background: var(--tc-listing-extras-ffffff4d,rgba(255, 255, 255, .3)); }
.cdf-faq {
  background: radial-gradient(circle at 100% 0, var(--coral-soft, #fdebe7) 0, var(--tc-listing-extras-fdebe700,rgba(253, 235, 231, 0)) 46%), linear-gradient(180deg, var(--sand, #faf6f0), var(--sand-2, #f4efe6));
  border: 1px solid var(--line, #e8dfd2); border-radius: 24px; padding: 28px 22px 24px; border-top-width: 1px;
}
.cdf-faq > h2 { margin-bottom: 20px; }
.cdf-faq__list { display: grid; gap: 10px; }
.cdf-faq__item {
  background: var(--paper, #fff); border: 1px solid var(--line, #e8dfd2); border-radius: 16px; box-shadow: 0 1px 2px var(--tc-listing-extras-0f2a3b0a,rgba(15, 42, 59, .04));
  transition: border-color .15s, box-shadow .15s;
}
.cdf-faq__item:hover { border-color: var(--tc-listing-extras-e5503a59,rgba(229, 80, 58, .35)); }
.cdf-faq__item[open] { border-color: var(--tc-listing-extras-e5503a73,rgba(229, 80, 58, .45)); box-shadow: 0 10px 26px var(--tc-listing-extras-0f2a3b14,rgba(15, 42, 59, .08)); }
.cdf-faq__item summary {
  align-items: center; color: var(--navy, #0f2a3b); cursor: pointer; display: flex; font-family: var(--serif, Georgia, serif); font-size: 18px; font-weight: 500;
  gap: 14px; justify-content: space-between; letter-spacing: -.005em; line-height: 1.3; list-style: none; padding: 16px 16px 16px 20px;
}
.cdf-faq__item summary::-webkit-details-marker { display: none; }
.cdf-faq__item summary:focus-visible { outline: 3px solid var(--coral-soft, #fdebe7); outline-offset: -3px; border-radius: 16px; }
.cdf-faq__item summary::after {
  align-items: center; background: var(--coral-soft, #fdebe7); border-radius: 50%; color: var(--coral-deep, #c53f2b); content: "+"; display: inline-flex; flex: none;
  font-family: var(--sans, system-ui, sans-serif); font-size: 20px; font-weight: 400; height: 32px; justify-content: center; line-height: 1; transition: background .15s, color .15s, transform .2s; width: 32px;
}
.cdf-faq__item[open] summary::after { background: var(--coral, #e5503a); color: var(--tc-listing-extras-ffffff,#fff); content: "\2212"; }
.cdf-faq__answer { border-top: 1px solid var(--line, #e8dfd2); color: var(--body, #3d4f5c); font-size: 15.5px; line-height: 1.7; margin: 0 20px; padding: 14px 0 18px; }
@media (max-width: 640px) {
  .cdf-faq { border-radius: 20px; padding: 22px 14px 16px; }
  .cdf-faq > h2 { padding-left: 6px; }
  .cdf-faq__item summary { font-size: 17px; padding: 14px 12px 14px 16px; }
  .cdf-faq__answer { margin: 0 16px; }
}

/* Custom fields on a listing page */
.cdf-details__list { display: grid; gap: 0; margin: 0; }
.cdf-details__row { border-bottom: 1px dashed var(--line, #e3dccf); display: flex; gap: 16px; justify-content: space-between; padding: 10px 0; }
.cdf-details__row dt { color: var(--muted, #6b5f4d); font-weight: 600; }
.cdf-details__row dd { margin: 0; text-align: right; }
