/* /anteprima/ booking-style experiment. Scoped to its own pages. */
.anteprima-body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; color: var(--ap-ink, #182629); background: var(--ap-cream, #f6f1e8); }
.anteprima-body * { box-sizing: border-box; }
.anteprima-body h1, .anteprima-body h2, .anteprima-body h3 { margin: 0; }

/* Header */
.ap-header { position: sticky; top: 0; z-index: 500; background: #fff; border-bottom: 1px solid #e9edf2; }
.ap-header-inner { max-width: 1180px; margin: 0 auto; padding: 0 1rem; height: 64px; display: flex; align-items: center; justify-content: space-between; }
.ap-logo img { height: 38px; }
.ap-logo span { font-weight: 800; color: var(--brand); }
.ap-nav { display: flex; align-items: center; gap: 1.25rem; }
.ap-nav > a { color: #344; text-decoration: none; font-weight: 600; font-size: .95rem; }
.ap-nav > a:hover { color: var(--brand); }
.ap-login { background: var(--brand); color: #fff !important; padding: .5rem .9rem; border-radius: 8px; }
.ap-nav-dd { position: relative; }
.ap-nav-dd-btn { background: none; border: none; font-weight: 600; color: #344; cursor: pointer; font-size: .95rem; }
.ap-nav-dd-menu { position: absolute; top: 130%; right: 0; min-width: 260px; max-height: 380px; overflow-y: auto; background: #fff; border: 1px solid #e9edf2; border-radius: 10px; box-shadow: 0 14px 34px rgba(15,23,42,.16); padding: .4rem; display: none; }
.ap-nav-dd:hover .ap-nav-dd-menu { display: block; }
.ap-nav-dd-menu a { display: flex; justify-content: space-between; gap: .5rem; padding: .5rem .6rem; border-radius: 7px; color: #344; text-decoration: none; font-size: .9rem; }
.ap-nav-dd-menu a:hover { background: #f4f6f9; }
.ap-nav-dd-menu a em { color: #94a3b8; font-style: normal; }
.ap-dd-loading { display: block; padding: .6rem; color: #94a3b8; font-size: .85rem; }

/* Hero */
.ap-hero { position: relative; min-height: 480px; display: flex; align-items: center; justify-content: center;
    background: var(--ap-navy, #0b3439) center/cover no-repeat; color: #fff; padding: 4rem 1rem; }
.ap-hero-inner { position: relative; max-width: 1040px; width: 100%; text-align: center; }
.ap-hero h1 { font-size: 2.9rem; font-weight: 800; line-height: 1.12; letter-spacing: -.01em; text-shadow: 0 2px 6px rgba(3,18,22,.45), 0 4px 26px rgba(3,18,22,.5); }
.ap-hero h1 span { color: var(--ap-hero-accent, #ffd23f); text-shadow: 0 2px 6px rgba(3,18,22,.5), 0 4px 22px rgba(3,18,22,.45); }  /* warm gold reads better on the photo than the CTA orange */
.ap-hero p { font-size: 1.18rem; font-weight: 600; opacity: 1; margin: .7rem 0 1.8rem; text-shadow: 0 1px 4px rgba(3,18,22,.55), 0 2px 16px rgba(3,18,22,.55); }
.ap-hero-search { display: flex; gap: .6rem; background: #fff; padding: .65rem; border-radius: 16px; box-shadow: 0 24px 60px rgba(0,0,0,.35); align-items: flex-end; }
.ap-field { text-align: left; }
.ap-field-grow { flex: 1; }
.ap-field label { display: block; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: #64748b; margin: 0 0 .25rem .2rem; }
.ap-field select, .ap-field input { width: 100%; border: 1px solid #e2e8f0; border-radius: 9px; padding: .65rem .75rem; font-size: .95rem; color: #1a1a2e; }
.ap-hero-stats { margin-top: 1.6rem; display: flex; gap: 1.8rem; justify-content: center; flex-wrap: wrap; }
.ap-hero-stats span { font-size: .95rem; opacity: 1; text-shadow: 0 1px 3px rgba(3,18,22,.5), 0 2px 12px rgba(3,18,22,.5); }
.ap-hero-stats strong { color: var(--ap-hero-accent, #ffd23f); font-weight: 800; margin-right: .25rem; }

/* Buttons */
.ap-btn { border: none; cursor: pointer; border-radius: 9px; padding: .6rem 1rem; font-weight: 700; font-size: .92rem; display: inline-flex; align-items: center; gap: .45rem; }
.ap-btn-hero { background: var(--brand); color: #fff; padding: .7rem 1.4rem; font-size: 1rem; }
.ap-btn-block { width: 100%; justify-content: center; }
.ap-btn-info { background: linear-gradient(135deg, #3b82f6, #2563eb); color: #fff; width: 100%; justify-content: center; }
.ap-btn-ghost { background: #fff; color: #334; border: 1.5px solid #d8dee6; }
.ap-btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
.ap-link { background: none; border: none; color: var(--brand); cursor: pointer; font-weight: 600; font-size: .85rem; }
/* Search-bar actions (Reset + Cerca) — bottom-aligned with the fields; reset
   matches the Cerca button's height. */
.ap-search-actions { display: flex; gap: .5rem; align-items: flex-end; }
.ap-search-reset { padding: .7rem 1.1rem; font-size: 1rem; }

/* Strips */
.ap-strip-section { max-width: 1280px; margin: 3rem auto; padding: 0 1rem; }
.ap-section-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 1.2rem; }
.ap-section-eyebrow { display: block; font-size: .74rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); margin-bottom: .2rem; }
.ap-section-head h2 { font-size: 1.7rem; font-weight: 800; }
.ap-seeall { color: var(--brand); font-weight: 700; text-decoration: none; font-size: .92rem; white-space: nowrap; }
.ap-seeall:hover { text-decoration: underline; }
.ap-strip-loading { color: #94a3b8; padding: 2rem 0; }

/* Card */
.ap-card { background: #fff; border: 1px solid #e9edf2; border-radius: 14px; overflow: hidden; cursor: pointer; transition: box-shadow .15s, transform .15s; }
.ap-card:hover { box-shadow: 0 12px 28px rgba(15,23,42,.14); transform: translateY(-2px); }
.ap-card-img { height: 150px; background: #dde3ea center/cover no-repeat; position: relative; }
.ap-badge { position: absolute; top: .5rem; padding: .2rem .5rem; border-radius: 6px; font-size: .7rem; font-weight: 800; color: #fff; }
.ap-badge-lm { left: .5rem; background: #ef4444; }
.ap-badge-on { right: .5rem; background: #10b981; }
.ap-card-body { padding: .75rem .85rem; }
.ap-card-tip { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: var(--brand); }
.ap-card-title { font-size: .98rem; font-weight: 700; margin: .25rem 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ap-card-foot { display: flex; justify-content: space-between; align-items: center; margin-top: .4rem; }
.ap-card-price { font-weight: 800; color: #1a1a2e; }

/* Carousel (Offerte Speciali) — exactly 3 cards per view */
.ap-carousel { display: flex; align-items: stretch; gap: .8rem; }
.ap-carousel-viewport { flex: 1; min-width: 0; overflow-x: auto; scroll-snap-type: x mandatory; -ms-overflow-style: none; scrollbar-width: none; }
.ap-carousel-viewport::-webkit-scrollbar { display: none; }
.ap-carousel-track { display: flex; gap: 1.2rem; padding: .4rem; }
.ap-carousel-track .ap-bc { flex: 0 0 calc((100% - 2.4rem) / 3); scroll-snap-align: start; }
.ap-carousel-arrow { flex: 0 0 auto; align-self: center; width: 44px; height: 44px; border-radius: 50%; border: 1px solid #e2e8f0; background: #fff; color: #334; cursor: pointer; box-shadow: 0 6px 16px rgba(15,23,42,.12); font-size: 1rem; transition: all .15s; }
.ap-carousel-arrow:hover { color: var(--brand); border-color: var(--brand); transform: scale(1.06); }

/* Rich carousel card */
.ap-bc { box-sizing: border-box; display: flex; flex-direction: column; background: #fff; border: 1px solid #e9edf2; border-radius: 16px; overflow: hidden; cursor: pointer; transition: box-shadow .15s ease, transform .15s ease, border-color .15s ease; }
.ap-bc:hover { box-shadow: 0 16px 36px rgba(15,23,42,.16); transform: translateY(-3px); border-color: #dbe3ec; }
.ap-bc-img { position: relative; height: 180px; background: #dde3ea center/cover no-repeat; }

/* ===== In-card image carousel (only when an offer has >1 image) ===== */
.ap-cimg-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 4;
  width: 30px; height: 30px; border-radius: 50%; border: none; cursor: pointer;
  background: rgba(15,23,42,.42); color: #fff; display: flex; align-items: center; justify-content: center;
  font-size: .78rem; opacity: 0; transition: opacity .15s, background .15s; }
.ap-cimg-prev { left: 8px; }
.ap-cimg-next { right: 8px; }
.ap-cimg-arrow:hover { background: rgba(15,23,42,.7); }
.ap-card-img:hover .ap-cimg-arrow,
.ap-bc-img:hover .ap-cimg-arrow,
.ap-row-img:hover .ap-cimg-arrow { opacity: 1; }
.ap-cimg-dots { position: absolute; bottom: 8px; left: 0; right: 0; z-index: 4; display: flex; gap: 5px; justify-content: center; pointer-events: none; }
.ap-cimg-dot { width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,.55); box-shadow: 0 0 2px rgba(0,0,0,.45); transition: background .15s; }
.ap-cimg-dot.on { background: #fff; }
/* Touch devices have no hover — keep the arrows visible. */
@media (hover: none) { .ap-cimg-arrow { opacity: 1; } }
.ap-bc-badge { position: absolute; top: .6rem; padding: .26rem .55rem; border-radius: 7px; font-size: .72rem; font-weight: 800; color: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.18); }
.ap-bc-badge-lm { left: .6rem; background: #ef4444; }
.ap-bc-badge-disc { right: .6rem; top: auto; bottom: .6rem; background: #059669; }
.ap-bc-body { padding: .95rem 1rem 1.05rem; display: flex; flex-direction: column; flex: 1; }
.ap-bc-tip { display: block; font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .03em; color: var(--brand); }
.ap-bc-book { font-size: .76rem; font-weight: 700; display: inline-flex; align-self: flex-start; align-items: center; gap: .4rem; padding: .3rem .65rem; border-radius: 999px; margin-bottom: .6rem; line-height: 1.2; }
.ap-bc-book i { flex-shrink: 0; }
.ap-bc-book.on { color: #047857; background: #ecfdf5; }
.ap-bc-book.off { color: #b45309; background: #fffbeb; }
.ap-bc-title { font-size: 1.05rem; font-weight: 800; line-height: 1.25; margin: .3rem 0 .2rem; color: #1a1a2e; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ap-bc-dest { color: #475569; font-size: .85rem; margin-bottom: .3rem; }
.ap-bc-dest i { color: var(--brand); margin-right: .2rem; }
.ap-bc-desc { color: #64748b; font-size: .86rem; line-height: 1.45; margin: 0 0 .55rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ap-bc-meta { display: flex; flex-wrap: wrap; gap: .35rem .9rem; color: #64748b; font-size: .8rem; margin-bottom: .6rem; }
.ap-bc-meta span { display: inline-flex; align-items: center; white-space: nowrap; }
.ap-bc-meta i { color: #94a3b8; margin-right: .2rem; }
.ap-bc-foot { margin-top: auto; display: flex; align-items: flex-end; justify-content: space-between; gap: .5rem; }
.ap-bc-price { display: flex; flex-direction: column; line-height: 1.1; }
.ap-bc-orig { color: #94a3b8; text-decoration: line-through; font-size: .82rem; }
.ap-bc-lbl { color: #94a3b8; font-size: .68rem; text-transform: uppercase; letter-spacing: .03em; }
.ap-bc-amt { font-size: 1.4rem; font-weight: 800; color: #1a1a2e; }
.ap-bc-cta { color: var(--brand); font-weight: 700; font-size: .85rem; white-space: nowrap; }
@media (max-width: 980px) { .ap-carousel-track .ap-bc { flex: 0 0 calc((100% - 1.2rem) / 2); } }
@media (max-width: 640px) { .ap-carousel-track .ap-bc { flex: 0 0 86%; } }

/* Skeletons — keep the card/row shape so there's no layout jump */
.ap-bc-skel, .ap-row-skel { cursor: default; }
.sk { background: linear-gradient(90deg, #eef1f5 25%, #f6f8fb 50%, #eef1f5 75%); background-size: 200% 100%; animation: apShimmer 1.2s ease-in-out infinite; }
@keyframes apShimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.sk-line { height: 12px; border-radius: 6px; margin: .65rem 0; }
.w30 { width: 30%; } .w40 { width: 40%; } .w50 { width: 50%; } .w60 { width: 60%; }
.w70 { width: 70%; } .w80 { width: 80%; } .w90 { width: 90%; } .w100 { width: 100%; }
.sk-btn { height: 38px; border-radius: 9px; margin-top: .6rem; }
.ap-bc-skel .ap-bc-img.sk { background-color: #eef1f5; }
.ap-bc-skel .sk-foot { height: 32px; border-radius: 8px; margin-top: 1rem; }
/* Results row skeleton */
.ap-row-skel .ap-row-img.sk { background-color: #eef1f5; }
.ap-row-skel .ap-row-main { padding: 1.2rem 1.25rem; }
.ap-row-skel .ap-row-side { gap: 0; }

.ap-accent { color: var(--brand); }

/* ===== Perché viaggiare con noi (the core) ===== */
.ap-why { background: linear-gradient(180deg, var(--ap-cream-200), var(--ap-cream)); padding: 4rem 1rem; margin-top: 1rem; }
.ap-why-inner { max-width: 1100px; margin: 0 auto; text-align: center; }
.ap-why-inner h2 { font-size: 2.3rem; font-weight: 800; line-height: 1.15; margin: .2rem 0 .5rem; }
.ap-why-sub { color: #5b6676; font-size: 1.15rem; margin: 0 auto 2.6rem; max-width: 640px; }
.ap-why-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.4rem; text-align: left; }
.ap-why-card { display: flex; flex-direction: column; gap: .2rem; background: #fff; border: 1px solid #e6ecf3; border-radius: 18px; padding: 1.8rem 1.9rem; box-shadow: 0 8px 24px rgba(15,23,42,.05); }
.ap-why-ic { width: 56px; height: 56px; border-radius: 16px; background: color-mix(in srgb, var(--brand) 12%, #fff); color: var(--brand); font-size: 1.5rem; display: flex; align-items: center; justify-content: center; margin-bottom: 1rem; }
.ap-why-card h3 { font-size: 1.45rem; font-weight: 800; color: #1a1a2e; margin: 0 0 .4rem; line-height: 1.2; }
.ap-why-card p { color: #5b6676; font-size: 1rem; line-height: 1.55; margin: 0; }

/* ===== Come funziona (spacious vertical flow) ===== */
.ap-how { max-width: 900px; margin: 4.5rem auto; padding: 0 1rem; text-align: center; }
.ap-how-head { margin-bottom: 2.8rem; }
.ap-how h2 { font-size: 2.1rem; font-weight: 800; margin: .2rem 0 0; }
.ap-flow { display: flex; flex-direction: column; gap: 1.4rem; text-align: left; }
.ap-flow-row { display: flex; align-items: center; gap: 1.8rem; background: #fff; border: 1px solid #e9edf2; border-radius: 18px; padding: 1.8rem 2rem; box-shadow: 0 6px 20px rgba(15,23,42,.05); }
.ap-flow-row:nth-child(even) { flex-direction: row-reverse; }
.ap-flow-visual { position: relative; flex: 0 0 auto; }
.ap-flow-num { width: 76px; height: 76px; border-radius: 22px; background: linear-gradient(135deg, var(--brand), color-mix(in srgb, var(--brand) 60%, #000)); color: #fff; font-size: 2.1rem; font-weight: 800; display: flex; align-items: center; justify-content: center; box-shadow: 0 10px 24px color-mix(in srgb, var(--brand) 35%, transparent); }
.ap-flow-ic { position: absolute; right: -10px; bottom: -10px; width: 38px; height: 38px; border-radius: 50%; background: #fff; border: 1px solid #e9edf2; color: var(--brand); font-size: 1rem; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 10px rgba(15,23,42,.1); }
.ap-flow-text { flex: 1; }
.ap-flow-text h3 { font-size: 1.55rem; font-weight: 800; color: #1a1a2e; margin: 0 0 .4rem; line-height: 1.2; }
.ap-flow-text p { color: #5b6676; font-size: 1.05rem; line-height: 1.55; margin: 0; }

/* Closing band */
.ap-how-band { margin-top: 3rem; background: linear-gradient(135deg, var(--ap-navy), var(--ap-navy-600)); color: #fff; border-radius: 20px; padding: 2.4rem 2.6rem; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; text-align: left; flex-wrap: wrap; box-shadow: 0 18px 40px rgba(11,52,57,.28); }
.ap-how-band h3 { font-size: 1.7rem; font-weight: 800; margin: 0 0 .3rem; }
.ap-how-band p { margin: 0; opacity: .9; }
.ap-how-band .ap-btn-hero { background: var(--ap-gold); color: #fff; font-size: 1.05rem; padding: .85rem 1.6rem; }
.ap-how-band .ap-btn-hero:hover { background: #f7895f; }
@media (max-width: 880px) {
  .ap-why-grid { grid-template-columns: 1fr; }
  .ap-why-inner h2 { font-size: 1.9rem; }
  .ap-flow-row, .ap-flow-row:nth-child(even) { flex-direction: row; gap: 1.2rem; padding: 1.3rem 1.4rem; }
  .ap-flow-num { width: 60px; height: 60px; font-size: 1.7rem; border-radius: 18px; }
  .ap-flow-text h3 { font-size: 1.3rem; }
  .ap-how-band { flex-direction: column; text-align: center; }
}

/* Tipologia widget (reuses .dest-picker look) */
.ap-tip .dp-row { display: flex; align-items: center; }
.ap-tip .ap-tip-count { margin-left: auto; color: #94a3b8; font-size: .8rem; padding-left: .5rem; }
#apHeroTipMount, #apEditTipMount, .ap-tip { width: 100%; }
/* Span the full width of the trigger bar above (never clipped off the left edge). */
.ap-tip .dest-picker-panel { left: 0; right: 0; width: auto; max-width: 90vw; z-index: 1300; }

/* 2-level macro → sub rows — always expanded, indentation only (no chevrons). */
.ap-tip .ap-tip-mrow { font-weight: 700; }
.ap-tip .ap-tip-child { padding-left: 1.6rem; font-weight: 500; }
.ap-tip .ap-tip-child .dp-name { color: var(--ap-ink-soft, #475569); }
.ap-tip .ap-tip-child-flat { padding-left: 1.1rem; }
/* Curvy sub-item arrow (↳) before each sub-category so the hierarchy is obvious. */
.ap-tip .ap-tip-child .dp-name::before {
  content: "\21B3";
  margin-right: .4rem;
  color: var(--dp-accent, var(--brand, #e6007e));
  font-weight: 700;
  opacity: .7;
}
.ap-tip .ap-tip-empty { padding: .6rem .8rem; color: #94a3b8; font-size: .85rem; }

/* Destination cascade: break the (wide, multi-column) panel out of its narrow
   trigger and span the whole search bar so it never overflows the viewport. */
.ap-hero-search, .ap-results-edit { position: relative; }
.ap-hero-search #destPicker, .ap-results-edit #destPicker { position: static; }
.ap-hero-search #destPickerPanel,
.ap-results-edit #destPickerPanel { left: 0; right: 0; width: auto; top: calc(100% + 8px); }

/* "Tutto il mondo" — a selectable root entry standing for the whole-world
   scope, styled like any cascade row but with an accent globe glyph. */
#destPicker .dp-row-world .dp-ico i { color: var(--dp-accent, #e6007e); }
#destPicker .dp-row-world .dp-name { font-weight: 600; }

/* Always-open results top bar */
.ap-results-edit { align-items: flex-end; flex-wrap: wrap; padding-top: .85rem; }
.ap-edit-field { display: flex; flex-direction: column; gap: .25rem; }
.ap-edit-field > label { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: #64748b; }
.ap-edit-field-tip { flex: 0 0 240px; }
.ap-edit-field-grow { flex: 1; min-width: 220px; }

/* 0-count filter — greyed out, not clickable */
.ap-check.is-disabled { opacity: .42; cursor: not-allowed; }
.ap-check.is-disabled input { cursor: not-allowed; }

/* Loading veil while resolving + opening an offer's page */
#ap-nav-loading { position: fixed; inset: 0; z-index: 5000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; background: rgba(246,241,232,.78); backdrop-filter: blur(2px); opacity: 0; pointer-events: none; transition: opacity .15s ease; }
#ap-nav-loading.on { opacity: 1; pointer-events: all; }
.ap-nl-spin { width: 48px; height: 48px; border-radius: 50%; border: 4px solid rgba(14,92,99,.18); border-top-color: rgb(14,92,99); animation: apSpin .8s linear infinite; }
@keyframes apSpin { to { transform: rotate(360deg); } }
.ap-nl-txt { color: var(--ap-ink-soft, #405256); font-weight: 700; font-size: 1rem; }

/* Offer modal presented as a right-side sliding PAGE on anteprima (offers that
   aren't published /idee pages). Same content, page-like feel + back button. */
.anteprima-body #redirectModalLogin .modal-dialog,
.anteprima-body #redirectModalLogin .modal-dialog-centered {
  margin: 0 0 0 auto; max-width: 960px; width: 96vw; min-height: 100%; align-items: stretch;
}
.anteprima-body #redirectModalLogin .modal-content { min-height: 100vh; border-radius: 0; border: none; }
.anteprima-body #redirectModalLogin.modal.fade .modal-dialog { transform: translateX(64px); transition: transform .32s ease; }
.anteprima-body #redirectModalLogin.modal.show .modal-dialog { transform: translateX(0); }
/* Make the "Ritorna alla ricerca" action read as the primary back button. */
.anteprima-body #redirectModalLogin .offer-modal-back { background: rgb(14,92,99); border-color: rgb(14,92,99); color: #fff; }
.anteprima-body #redirectModalLogin .offer-modal-back:hover { background: rgb(21,118,126); color: #fff; }

/* Footer */
.ap-footer { background: var(--ap-navy); color: #cbd5e1; margin-top: 3rem; }
.ap-footer-inner { max-width: 1180px; margin: 0 auto; padding: 1.2rem 1rem; display: flex; justify-content: space-between; font-size: .9rem; }
.ap-footer a { color: #ffd23f; text-decoration: none; }

/* ===== Results page ===== */
/* Reuse the exact hero search card. A cream sticky band hosts it so the white
   card floats just like on the landing hero. */
.ap-results-topbar { background: var(--ap-cream, #f6f1e8); border-bottom: 1px solid #e7e0d2; position: sticky; top: 0; z-index: 480; padding: .9rem 1rem; }
.ap-results-topbar .ap-hero-search { max-width: 1280px; margin: 0 auto; }
.ap-results-topbar-inner { max-width: 1280px; margin: 0 auto; padding: .8rem 1rem; display: flex; justify-content: space-between; align-items: center; }
.ap-top-summary { display: flex; gap: .5rem; flex-wrap: wrap; }
.ap-top-chip { background: #f1f5f9; border-radius: 999px; padding: .35rem .8rem; font-weight: 600; font-size: .9rem; color: #334; }
.ap-results-edit { max-width: 1280px; margin: 0 auto; padding: 0 1rem .8rem; display: flex; gap: .6rem; align-items: center; }
.ap-results-edit select, .ap-results-edit input { border: 1px solid #e2e8f0; border-radius: 9px; padding: .6rem .7rem; }
.ap-results-edit input { flex: 1; }

.ap-results-layout { max-width: 1280px; margin: 1.4rem auto; padding: 0 1rem; display: grid; grid-template-columns: 280px 1fr; gap: 1.4rem; align-items: start; }
.ap-filters { background: #fff; border: 1px solid #e9edf2; border-radius: 14px; padding: 1rem 1.1rem; position: sticky; top: 132px; }
.ap-filters-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: .6rem; }
.ap-filters-head h3 { font-size: 1.1rem; }
.ap-filter-group { border-top: 1px solid #eef2f6; padding: .85rem 0; }
.ap-filter-group h4 { font-size: .82rem; text-transform: uppercase; letter-spacing: .03em; color: #64748b; margin-bottom: .55rem; }
.ap-price-row { display: flex; align-items: center; gap: .4rem; }
.ap-price-row input { width: 100%; border: 1px solid #e2e8f0; border-radius: 8px; padding: .5rem; }
.ap-check { display: flex; align-items: center; gap: .5rem; padding: .3rem 0; font-size: .92rem; cursor: pointer; }
.ap-check em { margin-left: auto; color: #94a3b8; font-style: normal; font-size: .8rem; }
.ap-facet-list { max-height: 260px; overflow-y: auto; }

.ap-results-main { min-width: 0; }
.ap-results-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .9rem; flex-wrap: wrap; }
.ap-results-count { font-weight: 700; color: #334; }
.ap-orderby { font-size: .85rem; color: var(--ap-ink-soft, #405256); font-weight: 600; display: inline-flex; align-items: center; gap: .5rem; }
.ap-orderby select { border: 1px solid #d8dee6; border-radius: 9px; padding: .5rem .7rem; font-size: .9rem; font-weight: 600; color: var(--ap-ink, #182629); background: #fff; cursor: pointer; }
.ap-results-list { display: flex; flex-direction: column; gap: 1rem; }

/* List row (booking.com-style) — larger, fuller */
.ap-row { display: grid; grid-template-columns: 340px 1fr 260px; background: #fff; border: 1px solid #e9edf2; border-radius: 16px; overflow: hidden; transition: box-shadow .15s ease, transform .15s ease, border-color .15s ease; }
.ap-row:hover { box-shadow: 0 16px 36px rgba(15, 23, 42, .13); transform: translateY(-2px); border-color: #dbe3ec; }
.ap-row-img { position: relative; background: #dde3ea center/cover no-repeat; min-height: 310px; overflow: hidden; }
/* Category pills overlaid top-left on the image */
.ap-row-img .ap-tip-pills { position: absolute; top: .7rem; left: .7rem; right: auto; margin: 0; z-index: 2; max-width: calc(100% - 7rem); }
.ap-row-img .ap-tip-pill { box-shadow: 0 2px 8px rgba(0,0,0,.22); }
/* Last-minute / speciale badges top-right */
.ap-rbadge { position: absolute; right: .7rem; padding: .3rem .6rem; border-radius: 8px; font-size: .74rem; font-weight: 800; color: #fff; letter-spacing: .02em; box-shadow: 0 2px 6px rgba(0,0,0,.18); z-index: 2; }
/* Promo badges move to the bottom-right so the ID pill owns the top-right. */
.ap-rbadge-lm { bottom: .7rem; background: #ef4444; }
.ap-rbadge-sp { bottom: 2.5rem; background: #7c3aed; }
/* Tour operator at the bottom of the image, over a scrim */
.ap-row-op { position: absolute; left: .7rem; right: auto; bottom: .7rem; max-width: calc(100% - 1.4rem);
  padding: .34rem .7rem; background: rgba(15, 23, 42, .72); color: #fff; font-size: .8rem; font-weight: 700;
  border-radius: 999px; display: inline-flex; align-items: center; gap: .4rem; z-index: 1;
  box-shadow: 0 3px 10px rgba(0,0,0,.25); backdrop-filter: blur(2px); }
.ap-row-op i { color: #fff; opacity: .85; flex: 0 0 auto; }
.ap-row-op span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ap-row-main { padding: 1.7rem 1.9rem; min-width: 0; display: flex; flex-direction: column; gap: .55rem; }
.ap-row-tip { font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--brand); }
.ap-row-title { font-size: 1.52rem; font-weight: 800; line-height: 1.2; color: #1a1a2e; }
.ap-row-visiting { color: var(--ap-ink-soft, #475569); font-size: .95rem; }
.ap-row-visiting strong { color: var(--ap-ink, #1a1a2e); }
.ap-row-when { color: var(--ap-ink-soft, #475569); font-size: .92rem; }
.ap-row-when i { color: var(--brand); margin-right: .3rem; }
.ap-row-meta { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .35rem; }
.ap-chip { display: inline-flex; align-items: center; gap: .35rem; background: #f3f6f9; border: 1px solid #e6ecf2; border-radius: 999px; padding: .3rem .7rem; font-size: .82rem; font-weight: 600; color: #475569; }
.ap-chip i { color: var(--brand); }
.ap-chip[data-desc] { cursor: help; }
.ap-chip-muted { color: #94a3b8; }
.ap-chip-muted i { color: #b6c0cc; }

/* Rich-content icons (inclusions / exclusions / notes) — sit in the price
   column, above "Maggiori informazioni". Hover → styled popover. */
.ap-row-extras { display: flex; justify-content: flex-end; gap: .5rem; width: 100%; margin: .15rem 0 .7rem; }
.ap-di { display: inline-flex; align-items: center; justify-content: center; width: 2rem; height: 2rem;
  border-radius: 999px; background: #f3f6f9; border: 1px solid #e6ecf2; cursor: help; font-size: .92rem;
  transition: background .12s ease, border-color .12s ease, transform .12s ease; }
.ap-di:hover { transform: translateY(-1px); background: #eef2f7; border-color: #d7dee7; }
.ap-di-inc i { color: var(--ap-success, #22865f); }
.ap-di-exc i { color: #c2410c; }
.ap-di-note i { color: var(--ap-gold, #f26b43); }

/* Styled rich popover (body-appended, fixed). */
.ap-rich-pop { position: fixed; z-index: 4000; width: 300px; max-width: calc(100vw - 24px);
  background: #fff; border: 1px solid #e6ecf2; border-radius: 12px; box-shadow: 0 18px 44px rgba(15,23,42,.2);
  padding: .75rem .9rem; opacity: 0; transform: translateY(4px); pointer-events: none;
  transition: opacity .12s ease, transform .12s ease; }
.ap-rich-pop.on { opacity: 1; transform: none; }
.ap-rich-pop-h { font-weight: 800; font-size: .86rem; color: var(--ap-ink, #1a1a2e); margin-bottom: .55rem;
  display: flex; align-items: center; gap: .45rem; }
.ap-rich-inc .ap-rich-pop-h i { color: var(--ap-success, #22865f); }
.ap-rich-exc .ap-rich-pop-h i { color: #c2410c; }
.ap-rich-note .ap-rich-pop-h i { color: var(--ap-gold, #f26b43); }
.ap-rich-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .4rem;
  max-height: 280px; overflow: auto; }
.ap-rich-list li { display: flex; align-items: flex-start; gap: .5rem; font-size: .85rem; line-height: 1.35;
  color: var(--ap-ink-soft, #475569); }
.ap-rich-list li i { margin-top: .15rem; font-size: .8rem; flex: 0 0 auto; }
.ap-rich-inc .ap-rich-list li i { color: var(--ap-success, #22865f); }
.ap-rich-exc .ap-rich-list li i { color: #c2410c; }
.ap-rich-note { font-size: .85rem; line-height: 1.45; color: var(--ap-ink-soft, #475569); white-space: pre-wrap; }
/* Tipologia pills (primary + secondary) */
.ap-tip-pills { display: flex; flex-wrap: wrap; gap: .35rem; margin-bottom: .3rem; }
.ap-tip-pill { display: inline-block; font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .03em; color: var(--brand); background: color-mix(in srgb, var(--brand) 12%, #fff); padding: .22rem .55rem; border-radius: 999px; }
.ap-tip-pill-2 { color: var(--ap-gold, #f26b43); background: color-mix(in srgb, var(--ap-gold, #f26b43) 14%, #fff); }
/* Title block: the (i) is anchored top-right and out of the text flow so a
   wrapping title never pushes it onto its own line. */
.ap-row-titlewrap { position: relative; padding-right: 1.7rem; }
.ap-row-i { color: var(--brand); cursor: help; font-size: .95rem; }
.ap-row-titlewrap .ap-row-i { position: absolute; top: .2rem; right: 0; margin: 0; }
.ap-row-i:hover { opacity: .8; }
.ap-info-bubble { position: fixed; z-index: 4000; max-width: 320px; background: #1a1a2e; color: #fff; padding: .65rem .8rem; border-radius: 9px; font-size: .85rem; font-weight: 400; line-height: 1.45; box-shadow: 0 12px 30px rgba(15,23,42,.3); opacity: 0; pointer-events: none; transition: opacity .12s ease; }
.ap-info-bubble.on { opacity: 1; }
.ap-row-book { display: flex; justify-content: flex-end; margin: .2rem 0 .7rem; }
.ap-row-datelink { margin-top: .7rem; background: none; border: none; padding: 0; cursor: pointer; color: var(--brand); font-weight: 700; font-size: .85rem; display: inline-flex; align-items: center; gap: .4rem; }
.ap-row-datelink:hover { text-decoration: underline; }

/* Departures ("altre date e tariffe") modal */
#ap-dep-modal { position: fixed; inset: 0; z-index: 5200; display: flex; align-items: center; justify-content: center; padding: 1rem; background: rgba(11,52,57,.45); backdrop-filter: blur(2px); opacity: 0; pointer-events: none; transition: opacity .15s ease; }
#ap-dep-modal.on { opacity: 1; pointer-events: all; }
.ap-dep-card { position: relative; background: #fff; border-radius: 16px; max-width: 720px; width: 100%; max-height: 82vh; overflow: auto; padding: 1.4rem 1.5rem; box-shadow: 0 24px 60px rgba(15,23,42,.3); }
.ap-dep-x { position: absolute; top: .7rem; right: .8rem; background: none; border: none; font-size: 1.5rem; line-height: 1; color: #94a3b8; cursor: pointer; }
.ap-dep-x:hover { color: #334; }
.ap-dep-title { font-size: 1.25rem; font-weight: 800; margin: 0 1.5rem .9rem 0; color: var(--ap-ink, #182629); }
.ap-dep-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.ap-dep-table th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .03em; color: #94a3b8; padding: .5rem .6rem; border-bottom: 2px solid #eef2f6; }
.ap-dep-table td { padding: .6rem; border-bottom: 1px solid #f1f5f9; color: #334; }
.ap-dep-ret { color: #94a3b8; }
.ap-dep-orig { color: #94a3b8; text-decoration: line-through; font-size: .82rem; }
.ap-dep-price { text-align: right; white-space: nowrap; }
.ap-dep-av { font-size: .78rem; font-weight: 700; color: #94a3b8; }
.ap-dep-av.on { color: #059669; }
.ap-book { font-size: .76rem; font-weight: 700; display: inline-flex; align-items: center; gap: .35rem; padding: .34rem .6rem; border-radius: 8px; line-height: 1.25; text-align: right; }
.ap-book-on { color: #047857; background: #ecfdf5; }
.ap-book-off { color: #b45309; background: #fffbeb; }
.ap-row-side { border-left: 1px solid #eef2f6; padding: 1.3rem 1.2rem; display: flex; flex-direction: column; justify-content: center; align-items: flex-end; gap: .15rem; background: #fcfdff; text-align: right; }
.ap-row-disc { background: #ecfdf5; color: #059669; border: 1px solid #a7f3d0; font-weight: 800; font-size: .78rem; padding: .15rem .5rem; border-radius: 6px; }
.ap-row-orig { color: #94a3b8; text-decoration: line-through; font-size: .9rem; }
.ap-row-price-label { color: #94a3b8; font-size: .72rem; text-transform: uppercase; letter-spacing: .03em; }
.ap-row-price { font-size: 1.75rem; font-weight: 800; color: #1a1a2e; line-height: 1.05; }
.ap-row-perp { color: #94a3b8; font-size: .74rem; }
.ap-row-side .ap-btn { width: 100%; justify-content: center; }

/* Pagination */
.ap-pagination { display: flex; justify-content: center; align-items: center; gap: 1rem; margin: 1.6rem 0; }
.ap-page-btn { width: 40px; height: 40px; border-radius: 9px; border: 1px solid #d8dee6; background: #fff; cursor: pointer; font-size: 1.2rem; }
.ap-page-btn:disabled { opacity: .4; cursor: default; }
.ap-page-info { font-weight: 700; color: #334; }

/* Responsive */
@media (max-width: 880px) {
  .ap-results-layout { grid-template-columns: 1fr; }
  .ap-filters { position: static; }
  .ap-row { grid-template-columns: 1fr; }
  .ap-row-img { min-height: 190px; }
  .ap-row-side { border-left: none; border-top: 1px solid #eef2f6; align-items: stretch; }
  .ap-hero-search { flex-direction: column; align-items: stretch; }
  .ap-search-actions { align-items: stretch; }
  .ap-search-actions .ap-btn { flex: 1; justify-content: center; }
  .ap-how-grid { grid-template-columns: 1fr; }
  .ap-nav > a:not(.ap-login) { display: none; }
}

/* Collection cards (layout_type='collection') — operator/theme summaries with
   no price/dates/transport. A "Collezione" badge marks them; the price column
   reads "Scopri il prezzo" since there's no per-customer price. */
.ap-bc-badge-coll { left: .6rem; background: #1a1a2e; }
.ap-rbadge-coll { bottom: .7rem; background: #1a1a2e; }
.ap-row-price-discover { font-size: 1.15rem; font-weight: 700; color: var(--brand, #e6007e); line-height: 1.15; }
.ap-bc-amt.ap-bc-discover { font-size: 1.05rem; color: var(--brand, #e6007e); }

/* Numeric offer id (offer_number) — a colourful pill that overflows the
   top-right corner of the whole card. This is the reference people quote when
   asking for help, so it's high-contrast and unmissable. */
.ap-row-wrap { position: relative; }
.ap-row-idpill, .ap-bc-idpill {
  position: absolute; z-index: 6; color: #fff;
  background: linear-gradient(135deg, var(--brand, #e6007e), #06b6d4);
  font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: .01em;
  border-radius: 999px; border: 2px solid #fff;
  box-shadow: 0 5px 14px rgba(0,0,0,.30);
}
/* Row card: overflow the top-right corner (the wrapper isn't clipped). */
.ap-row-idpill { top: -.9rem; right: -.9rem; font-size: .95rem; padding: .34rem .85rem; }
/* Carousel card: kept just inside the image — the carousel viewport clips overflow. */
.ap-bc-idpill { top: .55rem; right: .55rem; font-size: .85rem; padding: .28rem .72rem; }

/* ===================== Header — white bar + coloured bottom border ====================== */
/* A clean, solid white bar that sits above the hero (in normal flow on every page —
   no overlap, so a missing hero image can never make it look grey). Dark ink text;
   the brand accent (teal → gold → orange) lives in the bottom border. Rules are
   prefixed with .ap-header to outrank the legacy generic header rules at the top. */
.ap-header {
  position: relative; z-index: 500; padding: 0;
  background: #fff;
  border-bottom: 1px solid var(--hair, #e9edf2);
  box-shadow: 0 2px 16px rgba(15,23,42,.06);
}
/* Brand accent thread in the bottom border. */
.ap-header::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; z-index: 1;
  background: linear-gradient(90deg, var(--brand), var(--ap-hero-accent, #ffd23f) 55%, var(--ap-gold, #fe4209)); }

.ap-header-bar { max-width: 1440px; margin: 0 auto; padding: 0 clamp(.8rem, 1.8vw, 1.75rem); min-height: clamp(76px, 6.6vw, 108px); display: flex; align-items: center; gap: clamp(.55rem, 1.2vw, 1.6rem); }

/* Logo sits directly on the frosted bar (the brand logos are made for light bg). */
.ap-header .ap-logo { display: inline-flex; align-items: center; flex: 0 0 auto; }
.ap-header .ap-logo img { height: clamp(46px, 4.4vw, 66px); width: auto; display: block; }
.ap-header .ap-logo span { font-size: 1.35rem; font-weight: 800; color: var(--brand); }

/* Nav links + right-side utility links + dropdown share ONE hover style: dark ink
   with an animated brand underline. No colour-fill on hover — the underline IS the
   feedback. The active page link is brand-coloured. */
.ap-header .ap-nav { display: flex; align-items: center; gap: clamp(.5rem, 1.25vw, 1.9rem); margin-left: clamp(.1rem, .4vw, .5rem); }
.ap-header .ap-nav-link,
.ap-header .ap-act-link,
.ap-header .ap-nav-dd-btn { position: relative; display: inline-flex; align-items: center; line-height: 1; gap: clamp(.3rem, .5vw, .5rem); background: none; border: none; cursor: pointer; font-family: inherit; color: var(--ap-ink, #1c2b2e); text-decoration: none; font-weight: 600; font-size: clamp(.82rem, .9vw, 1.02rem); white-space: nowrap; padding: .5rem 0; transition: color .15s; }
.ap-header .ap-nav-link i,
.ap-header .ap-act-link i,
.ap-header .ap-nav-dd-btn > i:first-child { color: var(--brand); opacity: .85; font-size: .9em; }
.ap-header .ap-nav-link::after,
.ap-header .ap-act-link::after,
.ap-header .ap-nav-dd-btn::after { content: ""; position: absolute; left: 0; right: 100%; bottom: -2px; height: 2px; background: var(--brand); border-radius: 2px; transition: right .22s ease; }
.ap-header .ap-nav-link:hover::after,
.ap-header .ap-act-link:hover::after,
.ap-header .ap-nav-dd:hover .ap-nav-dd-btn::after,
.ap-header .ap-nav-dd.open .ap-nav-dd-btn::after,
.ap-header .ap-nav-link.active::after { right: 0; }
.ap-header .ap-nav-link.active { color: var(--brand); }

/* Hotel e Trasporti dropdown. */
.ap-header .ap-nav-dd { position: relative; }
.ap-dd-caret { font-size: .68em; opacity: .8; transition: transform .15s; }
.ap-nav-dd:hover .ap-dd-caret, .ap-nav-dd.open .ap-dd-caret { transform: rotate(180deg); }
.ap-header .ap-nav-dd-menu { position: absolute; left: 0; right: auto; top: calc(100% + .6rem); min-width: 252px; background: #fff; border: 1px solid #e9edf2; border-radius: 12px; padding: .4rem; box-shadow: 0 18px 40px rgba(15,23,42,.22); display: none; z-index: 50; }
/* Invisible bridge over the gap between the button and the menu — anchored on the
   wrapper itself so moving the cursor down to pick an item never leaves the
   hovered element and snaps the menu shut. Only "live" while open. */
.ap-header .ap-nav-dd::after { content: ""; position: absolute; left: 0; top: 100%; width: 264px; height: .8rem; display: none; background: none; }
.ap-header .ap-nav-dd:hover::after, .ap-header .ap-nav-dd.open::after { display: block; }
.ap-header .ap-nav-dd:hover .ap-nav-dd-menu,
.ap-header .ap-nav-dd.open .ap-nav-dd-menu { display: block; }
.ap-header .ap-nav-dd-menu a { display: flex; align-items: center; justify-content: flex-start; gap: .6rem; padding: .55rem .65rem; border-radius: 8px; color: #2a3b3e; text-decoration: none; font-size: .92rem; font-weight: 600; }
.ap-header .ap-nav-dd-menu a i { color: var(--brand); width: 1.2rem; text-align: center; }
.ap-header .ap-nav-dd-menu a:hover { background: color-mix(in srgb, var(--brand) 8%, #fff); color: var(--brand); }

/* Right-side actions: orange CTA + utility links + brand "Accedi". */
.ap-header-actions { margin-left: auto; display: flex; align-items: center; gap: clamp(.4rem, .9vw, 1.25rem); }
.ap-header .ap-nav-cta { display: inline-flex; align-items: center; line-height: 1; gap: clamp(.3rem, .5vw, .5rem); background: var(--ap-gold, #fe4209); color: #fff !important; text-decoration: none; font-weight: 800; font-size: clamp(.82rem, .9vw, 1rem); padding: clamp(.5rem, .8vw, .72rem) clamp(.7rem, 1.1vw, 1.3rem); border-radius: 999px; white-space: nowrap; box-shadow: 0 8px 20px color-mix(in srgb, var(--ap-gold, #fe4209) 38%, transparent); transition: transform .15s, filter .15s; }
.ap-header .ap-nav-cta:hover { transform: translateY(-1px); filter: brightness(1.05); }
.ap-act-sep { width: 1px; height: 30px; background: rgba(8,30,34,.16); }
.ap-header .ap-act-ghost { display: inline-flex; align-items: center; line-height: 1; gap: clamp(.3rem, .45vw, .45rem); color: #fff; background: var(--brand); border: none; font-weight: 800; font-size: clamp(.8rem, .86vw, .98rem); padding: clamp(.45rem, .75vw, .62rem) clamp(.65rem, 1vw, 1.2rem); border-radius: 999px; white-space: nowrap; text-decoration: none; transition: filter .15s; }
.ap-header .ap-act-ghost:hover { filter: brightness(1.08); }

/* Burger + mobile slide-down menu (hidden on desktop). White bars on dark. */
.ap-burger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: .4rem; margin-left: auto; }
.ap-burger span { width: 26px; height: 3px; background: var(--ap-ink, #1c2b2e); border-radius: 2px; transition: .2s; }
.ap-burger.on span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.ap-burger.on span:nth-child(2) { opacity: 0; }
.ap-burger.on span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
.ap-mobile-menu { display: none; position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-top: 1px solid #e9edf2; box-shadow: 0 18px 34px rgba(15,23,42,.16); padding: .6rem; max-height: calc(100vh - 98px); overflow-y: auto; z-index: 510; }
.ap-mobile-menu.on { display: block; }
.ap-mm-item { display: flex; align-items: center; gap: .7rem; padding: .7rem .8rem; border-radius: 9px; color: #2a3b3e; text-decoration: none; font-weight: 600; font-size: .98rem; }
.ap-mm-item i { color: var(--brand); width: 1.2rem; text-align: center; }
.ap-mm-item:hover { background: #f4f6f9; }
.ap-mm-cta { background: var(--ap-gold, #fe4209); color: #fff; font-weight: 800; }
.ap-mm-cta i { color: #fff; }
.ap-mm-group-title { font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: #94a3b8; padding: .7rem .8rem .25rem; }
.ap-mm-divider { height: 1px; background: #eef1f5; margin: .4rem .4rem; }

/* Collapse to a burger only once the fluid nav can no longer shrink to fit. */
@media (max-width: 1180px) {
  .ap-header .ap-nav, .ap-header-actions { display: none; }
  .ap-burger { display: flex; }
  .ap-header .ap-logo img { height: 52px; }
  .ap-header-bar { min-height: 84px; }
}

/* ===== "Scrivici" chooser modal — one entry, two routes ===== */
.ap-choose-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.ap-choose-card { display: flex; flex-direction: column; align-items: flex-start; gap: .5rem; text-align: left; background: #fff; border: 1.5px solid #e7eaf0; border-radius: 16px; padding: 1.4rem 1.3rem; cursor: pointer; transition: border-color .15s, box-shadow .15s, transform .15s; }
.ap-choose-card:hover { border-color: var(--brand); box-shadow: 0 14px 30px rgba(15,23,42,.12); transform: translateY(-2px); }
.ap-choose-ic { width: 52px; height: 52px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; font-size: 1.35rem; color: var(--brand); background: color-mix(in srgb, var(--brand) 12%, #fff); }
.ap-choose-card:nth-child(2) .ap-choose-ic { color: var(--ap-gold, #fe4209); background: color-mix(in srgb, var(--ap-gold, #fe4209) 14%, #fff); }
.ap-choose-card h4 { margin: .2rem 0 0; font-size: 1.08rem; font-weight: 800; color: var(--ap-ink, #182629); }
.ap-choose-card p { margin: 0; font-size: .9rem; line-height: 1.45; color: var(--ap-ink-soft, #46585c); }
.ap-choose-card .ap-choose-go { margin-top: .4rem; font-weight: 800; font-size: .88rem; color: var(--brand); display: inline-flex; align-items: center; gap: .4rem; }
.ap-choose-card:nth-child(2) .ap-choose-go { color: var(--ap-gold, #fe4209); }
/* "Diventa Partner" — full-width banner card below the two contact routes,
   with a brand-tinted accent so it reads as a distinct value prop. */
.ap-choose-card.ap-choose-partner { grid-column: 1 / -1; background: color-mix(in srgb, var(--brand) 6%, #fff); border-color: color-mix(in srgb, var(--brand) 26%, #e7eaf0); }
@media (max-width: 560px) { .ap-choose-grid { grid-template-columns: 1fr; } }

/* ============================ Fornitori page ============================ */
/* width:100% is required because .anteprima-body is a flex column (sticky
   footer); without it the `margin:0 auto` suppresses flex stretch and the wrap
   shrink-wraps to ~2 cards. */
.ap-forn-wrap { width: 100%; max-width: 1280px; margin: 2rem auto 4rem; padding: 0 1rem; }
.ap-forn-head { text-align: center; margin-bottom: 2.6rem; }
.ap-forn-eyebrow { display: inline-flex; align-items: center; gap: .45rem; font-size: .74rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--brand); background: color-mix(in srgb, var(--brand) 10%, #fff); border: 1px solid color-mix(in srgb, var(--brand) 22%, transparent); padding: .4rem .9rem; border-radius: 999px; margin-bottom: 1rem; }
.ap-forn-wrap .ap-forn-head h1 { font-size: 2.5rem; font-weight: 800; letter-spacing: -.015em; color: var(--ap-ink, #182629); line-height: 1.1; }
.ap-forn-head p { color: var(--ap-ink-soft, #405256); margin: .8rem auto 0; max-width: 640px; font-size: 1.05rem; line-height: 1.55; }

.ap-forn-section { margin-bottom: 2.8rem; }
/* Section title — icon chip + dark heading + count badge over a soft divider
   (the heading has explicit overrides so no stray rule tints it). */
.ap-forn-section-head { display: flex; align-items: center; gap: .75rem; margin: 0 0 1.4rem; padding-bottom: .85rem; border-bottom: 1px solid color-mix(in srgb, var(--brand) 16%, #e9edf2); }
.ap-forn-section-ic { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 11px; background: color-mix(in srgb, var(--brand) 12%, #fff); color: var(--brand); font-size: 1.05rem; flex-shrink: 0; }
.ap-forn-section-ic-off { background: #eef1f5; color: #64748b; }
.ap-forn-wrap .ap-forn-section-head h2 { font-size: 1.45rem; font-weight: 800; color: var(--ap-ink, #182629) !important; background: none !important; padding: 0 !important; margin: 0 !important; }
.ap-forn-section-head .ap-forn-badge { font-size: .76rem; font-weight: 800; padding: .28rem .72rem; border-radius: 999px; color: #fff; }
.ap-forn-badge-on { background: var(--ap-success, #22865f); }
.ap-forn-badge-off { background: #64748b; }
.ap-forn-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 1.1rem; }

/* Flip card: front = logo + name; back (hover/focus) = products + count + CTA. */
.ap-forn-card { height: 250px; perspective: 1200px; cursor: pointer; outline: none; }
.ap-forn-flip { position: relative; width: 100%; height: 100%; transition: transform .55s cubic-bezier(.22,.61,.36,1); transform-style: preserve-3d; }
.ap-forn-card:hover .ap-forn-flip, .ap-forn-card:focus-within .ap-forn-flip { transform: rotateY(180deg); }
.ap-forn-face { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; border-radius: 16px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 1.3rem 1.2rem; text-align: center; overflow: hidden; }
/* Front */
.ap-forn-front { background: #fff; border: 1px solid #e9edf2; box-shadow: 0 6px 18px rgba(15,23,42,.06); gap: .85rem; transition: box-shadow .2s, transform .2s; }
.ap-forn-card:hover .ap-forn-front { box-shadow: 0 14px 30px rgba(15,23,42,.12); }
.ap-forn-logo { height: 96px; width: 100%; display: flex; align-items: center; justify-content: center; }
.ap-forn-logo img { max-width: 78%; max-height: 96px; object-fit: contain; }
.ap-forn-logo.ap-forn-noimg::before, .ap-forn-initial { display: inline-flex; align-items: center; justify-content: center; width: 72px; height: 72px; border-radius: 50%; background: color-mix(in srgb, var(--brand) 12%, #fff); color: var(--brand); font-size: 2rem; font-weight: 800; }
.ap-forn-logo.ap-forn-noimg::before { content: attr(data-i); }
.ap-forn-name { font-size: 1.02rem; font-weight: 800; color: var(--ap-ink, #182629); line-height: 1.2; }
.ap-forn-online-tag { display: inline-flex; align-items: center; gap: .35rem; font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .02em; color: var(--ap-success, #22865f); }
/* Back — brand-coloured to match the header/footer, gold CTA. */
.ap-forn-back { transform: rotateY(180deg); color: #fff; gap: .55rem;
  background:
    radial-gradient(120% 120% at 0% 0%, color-mix(in srgb, var(--brand) 60%, #10151c), transparent 60%),
    linear-gradient(135deg, var(--ap-navy, var(--brand)), #11161d);
  box-shadow: 0 14px 30px rgba(15,23,42,.2); }
.ap-forn-back-name { font-size: 1rem; font-weight: 800; line-height: 1.2; }
.ap-forn-prods { color: rgba(255,255,255,.82); font-size: .82rem; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.ap-forn-count-b { font-size: .76rem; font-weight: 700; color: var(--ap-gold, #fe4209); }
.ap-forn-btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; background: var(--ap-gold, #fe4209); color: #fff; text-decoration: none; font-weight: 800; font-size: .88rem; padding: .55rem 1.05rem; border-radius: 999px; margin-top: .25rem; box-shadow: 0 6px 16px color-mix(in srgb, var(--ap-gold, #fe4209) 40%, transparent); }
.ap-forn-btn:hover { filter: brightness(1.06); color: #fff; transform: translateY(-1px); }
.ap-forn-empty { color: #94a3b8; padding: 1rem 0; }

/* Ispirazione tiles — suggested tipologie (image + name overlay → category search) */
.ap-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.ap-tile { position: relative; aspect-ratio: 4 / 3; border-radius: 16px; overflow: hidden; background: #dde3ea center/cover no-repeat; display: flex; align-items: flex-end; text-decoration: none; box-shadow: 0 6px 18px rgba(15,23,42,.08); transition: transform .18s ease, box-shadow .18s ease; }
.ap-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,16,24,0) 36%, rgba(8,16,24,.74)); }
.ap-tile:hover { transform: translateY(-3px); box-shadow: 0 16px 34px rgba(15,23,42,.18); }
.ap-tile-name { position: relative; z-index: 1; color: #fff; font-weight: 800; font-size: 1.05rem; line-height: 1.2; padding: 1rem 1.1rem; text-shadow: 0 2px 8px rgba(0,0,0,.45); }
/* CTA band sits below the value cards in the merged "Perché sceglierci" section. */
.ap-why-inner .ap-how-band { margin-top: 2.6rem; text-align: left; }
@media (max-width: 900px) { .ap-tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .ap-tiles { grid-template-columns: 1fr 1fr; gap: .7rem; } .ap-tile-name { font-size: .92rem; padding: .7rem .8rem; } }

/* Sticky footer — on short pages (e.g. 1–2 results) keep the footer pinned to
   the bottom of the viewport instead of floating mid-screen. */
.anteprima-body { display: flex; flex-direction: column; min-height: 100vh; }
.anteprima-body .footer-modern { margin-top: auto; }

/* Fallback "no curated package" header above the always-available service cards. */
.ap-fallback-note { background: #fff; border: 1px solid #e9edf2; border-left: 4px solid var(--brand); border-radius: 14px; padding: 1.1rem 1.4rem; margin-bottom: 1.1rem; }
.ap-fallback-note h3 { font-size: 1.2rem; font-weight: 800; color: var(--ap-ink, #182629); display: flex; align-items: center; gap: .55rem; }
.ap-fallback-note h3 i { color: var(--brand); }
.ap-fallback-note p { color: var(--ap-ink-soft, #405256); margin-top: .35rem; font-size: .95rem; line-height: 1.5; }
/* Free-text destination row ("Cerca 'Arezzo'") + its chip. */
.dp-free .dp-name { color: var(--brand); font-weight: 700; }
.dp-free .dp-check i, .dp-free .dp-ico i { color: var(--brand); }
.dp-chip-free i { margin-right: .15rem; }
