/* BenBoat — Momenti Speciali */

/* CTA banner — piena larghezza viewport, sfondo marino */
.bb-momenti-cta {
  box-sizing: border-box;
  clear: both;
  display: block;
  margin: 0;
  max-width: 100vw;
  overflow: hidden;
  padding: clamp(2.5rem, 6vw, 4.5rem) clamp(1rem, 4vw, 2rem);
  position: relative;
  width: 100%;
  z-index: 2;
}

.bb-momenti-cta--full {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  width: 100vw;
}

.bb-momenti-cta__bg {
  background:
    radial-gradient(ellipse 80% 55% at 50% 0%, rgba(125, 211, 252, 0.45) 0%, transparent 70%),
    radial-gradient(ellipse 60% 40% at 85% 80%, rgba(34, 211, 238, 0.25) 0%, transparent 65%),
    linear-gradient(165deg, #012a43 0%, #0369a1 38%, #0891b2 68%, #06b6d4 100%);
  inset: 0;
  position: absolute;
  z-index: 0;
}

.bb-momenti-cta__shimmer {
  animation: bb-sea-shimmer 9s ease-in-out infinite;
  background: linear-gradient(
    105deg,
    transparent 30%,
    rgba(255, 255, 255, 0.07) 48%,
    rgba(255, 255, 255, 0.14) 52%,
    transparent 70%
  );
  inset: 0;
  position: absolute;
}

.bb-momenti-cta__waves {
  background-repeat: repeat-x;
  bottom: 0;
  height: 88px;
  left: 0;
  opacity: 0.55;
  position: absolute;
  width: 200%;
}

.bb-momenti-cta__waves--back {
  animation: bb-sea-wave 14s linear infinite;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 88' preserveAspectRatio='none'%3E%3Cpath fill='%2301557a' fill-opacity='0.55' d='M0,44 C150,88 350,0 600,44 C850,88 1050,0 1200,44 L1200,88 L0,88 Z'/%3E%3C/svg%3E");
  background-size: 50% 100%;
  bottom: 0;
  height: 72px;
  opacity: 0.7;
}

.bb-momenti-cta__waves--front {
  animation: bb-sea-wave 9s linear infinite reverse;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 88' preserveAspectRatio='none'%3E%3Cpath fill='%23ffffff' fill-opacity='0.14' d='M0,55 C200,20 400,80 600,55 C800,30 1000,75 1200,55 L1200,88 L0,88 Z'/%3E%3C/svg%3E");
  background-size: 50% 100%;
  bottom: -4px;
  height: 56px;
  opacity: 1;
}

@keyframes bb-sea-wave {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@keyframes bb-sea-shimmer {
  0%, 100% { opacity: 0.35; transform: translateX(-8%); }
  50% { opacity: 0.65; transform: translateX(8%); }
}

.bb-momenti-cta__inner {
  margin: 0 auto;
  max-width: 920px;
  position: relative;
  text-align: center;
  z-index: 1;
}

.bb-momenti-cta__badge {
  background: #ffb703;
  border: 2px solid #ffe08a;
  border-radius: 999px;
  box-shadow: 0 4px 18px rgba(255, 183, 3, 0.45);
  color: #0b1f3a;
  display: inline-block;
  font-size: 0.88rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  margin-bottom: 1.1rem;
  padding: 0.5rem 1.15rem;
  text-transform: uppercase;
}

.bb-momenti-cta__title {
  color: #ffffff;
  font-size: clamp(1.75rem, 3.8vw, 2.55rem);
  font-weight: 900;
  line-height: 1.15;
  margin: 0 0 0.9rem;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.35), 0 8px 28px rgba(0, 0, 0, 0.45);
}

.bb-momenti-cta__text {
  color: #f8fbff;
  font-size: clamp(1.05rem, 2.1vw, 1.22rem);
  font-weight: 500;
  line-height: 1.7;
  margin: 0 auto 1.85rem;
  max-width: 680px;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.35);
}

.bb-momenti-cta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  justify-content: center;
}

.bb-momenti-btn {
  align-items: center;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  display: inline-flex;
  font-size: 1.08rem;
  font-weight: 800;
  gap: 0.45rem;
  justify-content: center;
  letter-spacing: 0.02em;
  line-height: 1.3;
  min-height: 58px;
  padding: 0.95rem 1.85rem;
  text-decoration: none !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.bb-momenti-btn:hover {
  transform: translateY(-3px) scale(1.02);
}

/* CTA homepage — pulsanti molto evidenti */
.bb-momenti-cta .bb-momenti-btn--primary {
  animation: bb-cta-pulse 2.8s ease-in-out infinite;
  background: linear-gradient(180deg, #ffc93d 0%, #ffb703 55%, #f59e0b 100%);
  border: 2px solid #fff4cc;
  box-shadow:
    0 0 0 3px rgba(255, 183, 3, 0.35),
    0 14px 36px rgba(255, 152, 0, 0.55);
  color: #0b1f3a !important;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.bb-momenti-cta .bb-momenti-btn--primary:hover {
  animation: none;
  background: linear-gradient(180deg, #ffd54f 0%, #ffc107 100%);
  box-shadow:
    0 0 0 4px rgba(255, 193, 7, 0.45),
    0 18px 42px rgba(255, 152, 0, 0.6);
  color: #061428 !important;
}

.bb-momenti-cta .bb-momenti-btn--ghost {
  background: #ffffff;
  border: 2px solid #ffffff;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
  color: #003d7a !important;
}

.bb-momenti-cta .bb-momenti-btn--ghost:hover {
  background: #e8f4ff;
  color: #002a54 !important;
}

@keyframes bb-cta-pulse {
  0%, 100% {
    box-shadow:
      0 0 0 3px rgba(255, 183, 3, 0.35),
      0 14px 36px rgba(255, 152, 0, 0.55);
  }
  50% {
    box-shadow:
      0 0 0 7px rgba(255, 183, 3, 0.22),
      0 18px 44px rgba(255, 152, 0, 0.65);
  }
}

/* Pulsanti pagina galleria — stile più sobrio */
.bb-momenti-page .bb-momenti-btn--primary,
.bb-momenti-upload .bb-momenti-btn--primary {
  animation: none;
  background: #0056b3;
  border: 2px solid #004494;
  box-shadow: 0 8px 24px rgba(0, 86, 179, 0.35);
  color: #fff !important;
}

.bb-momenti-page .bb-momenti-btn--primary:hover,
.bb-momenti-upload .bb-momenti-btn--primary:hover {
  background: #004494;
  color: #fff !important;
}

/* Pagina dedicata */
.bb-momenti-page {
  margin: 0 auto;
  max-width: 1180px;
  padding: 1.5rem 1rem 0;
}

.bb-momenti-hero {
  margin-bottom: 2rem;
  text-align: center;
}

.bb-momenti-hero__eyebrow {
  color: #0056b3;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  margin: 0 0 0.5rem;
  text-transform: uppercase;
}

.bb-momenti-hero__title {
  color: #0b2d4f;
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 800;
  margin: 0 0 0.75rem;
}

.bb-momenti-hero__lead {
  color: #4a5568;
  font-size: 1.08rem;
  line-height: 1.7;
  margin: 0 auto;
  max-width: 720px;
}

.bb-momenti-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}

@media (min-width: 560px) {
  .bb-momenti-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .bb-momenti-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Card — foto morbide, senza riquadri rigidi */
.bb-momenti-card {
  background: transparent;
  border-radius: 0;
  box-shadow: none;
  margin: 0;
  overflow: visible;
  transition: transform 0.3s ease;
}

.bb-momenti-card:hover {
  transform: translateY(-4px);
}

.bb-momenti-card__media {
  background: linear-gradient(145deg, #dbeafe 0%, #cffafe 100%);
  border: none;
  border-radius: 28px;
  box-shadow:
    0 16px 38px rgba(0, 60, 120, 0.14),
    0 0 0 1px rgba(255, 255, 255, 0.65) inset;
  cursor: zoom-in;
  display: block;
  line-height: 0;
  overflow: hidden;
  padding: 0;
  position: relative;
  width: 100%;
}

.bb-momenti-card__media::after {
  background: linear-gradient(180deg, transparent 45%, rgba(1, 42, 67, 0.28) 100%);
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.bb-momenti-card__media img {
  border-radius: 28px;
  display: block;
  height: auto;
  min-height: 180px;
  object-fit: cover;
  transition: transform 0.45s ease, filter 0.45s ease;
  width: 100%;
}

.bb-momenti-card:hover .bb-momenti-card__media img {
  filter: saturate(1.05);
  transform: scale(1.03);
}

.bb-momenti-card__body {
  background: transparent;
  padding: 0.85rem 0.4rem 0;
}

.bb-momenti-card__title {
  color: #0b2d4f;
  font-size: 1.02rem;
  font-weight: 700;
  margin: 0 0 0.35rem;
}

.bb-momenti-card__meta {
  color: #64748b;
  display: flex;
  flex-wrap: wrap;
  font-size: 0.82rem;
  gap: 0.5rem;
  margin-bottom: 0.65rem;
}

.bb-momenti-card__tag {
  background: linear-gradient(135deg, rgba(0, 86, 179, 0.1), rgba(6, 182, 212, 0.14));
  border-radius: 999px;
  color: #0369a1;
  font-weight: 600;
  padding: 0.2rem 0.65rem;
}

.bb-momenti-card__author {
  opacity: 0.9;
}

.bb-momenti-card__reactions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.55rem;
}

/* Reaction — leggere, senza box colorati */
.bb-momenti-react {
  align-items: center;
  background: transparent;
  border: none;
  border-radius: 18px;
  box-shadow: none;
  cursor: pointer;
  display: inline-flex;
  font-size: 0.8rem;
  gap: 0.3rem;
  min-height: auto;
  min-width: auto;
  padding: 0.2rem 0.35rem;
  touch-action: manipulation;
  transition: transform 0.2s ease, opacity 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.bb-momenti-react:hover {
  opacity: 0.85;
  transform: scale(1.08);
}

.bb-momenti-react.is-active {
  background: transparent;
  opacity: 1;
  transform: scale(1.12);
}

.bb-momenti-react__emoji {
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.12));
  font-size: 1.15rem;
  line-height: 1;
}

.bb-momenti-react__count {
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 600;
  min-width: 0.6rem;
}

.bb-momenti-react.is-active .bb-momenti-react__count {
  color: #0369a1;
}

.bb-momenti-empty {
  color: #64748b;
  padding: 2rem 1rem;
  text-align: center;
}

/* Upload form */
.bb-momenti-upload {
  background: linear-gradient(180deg, #f8fbff 0%, #eef5fc 100%);
  border-radius: 20px;
  margin: 2.5rem 0;
  padding: 2rem 1.25rem;
}

.bb-momenti-upload__inner {
  margin: 0 auto;
  max-width: 760px;
}

.bb-momenti-upload h2 {
  color: #0b2d4f;
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  margin: 0 0 0.5rem;
  text-align: center;
}

.bb-momenti-upload p {
  color: #4a5568;
  line-height: 1.65;
  margin: 0 0 1.5rem;
  text-align: center;
}

.bb-momenti-form__grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
  margin-bottom: 1rem;
}

@media (min-width: 640px) {
  .bb-momenti-form__grid {
    grid-template-columns: 1fr 1fr;
  }
}

.bb-momenti-form__full {
  grid-column: 1 / -1;
}

.bb-momenti-form label {
  color: #334155;
  display: flex;
  flex-direction: column;
  font-size: 0.92rem;
  font-weight: 600;
  gap: 0.35rem;
}

.bb-momenti-form input[type="file"] {
  background: linear-gradient(180deg, #f8fbff 0%, #eef6fc 100%);
  border: none;
  border-radius: 20px;
  box-shadow: 0 8px 24px rgba(0, 86, 179, 0.08);
  min-height: auto;
  padding: 0.9rem;
}

.bb-momenti-form__thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 0.85rem;
}

.bb-momenti-form__thumbs[hidden] {
  display: none !important;
}

.bb-momenti-form__thumb {
  border-radius: 18px;
  box-shadow: 0 10px 24px rgba(0, 60, 120, 0.12);
  height: 88px;
  object-fit: cover;
  width: 88px;
}

.bb-momenti-form__hint {
  color: #64748b;
  font-size: 0.88rem;
  font-weight: 400;
  line-height: 1.5;
}

.bb-momenti-form__preview {
  color: #0056b3;
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  margin-top: 0.35rem;
}

.bb-momenti-form input,
.bb-momenti-form select {
  background: #fff;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  font: inherit;
  font-weight: 400;
  min-height: 46px;
  padding: 0.55rem 0.75rem;
}

.bb-momenti-form input:focus,
.bb-momenti-form select:focus {
  border-color: #0056b3;
  outline: 2px solid rgba(0, 86, 179, 0.15);
}

.bb-momenti-hp {
  display: none !important;
}

.bb-momenti-form .bb-momenti-btn--primary {
  width: 100%;
}

.bb-momenti-form__status {
  margin: 0.85rem 0 0;
  min-height: 1.25rem;
  text-align: center;
}

.bb-momenti-form__status.is-ok {
  color: #047857;
  font-weight: 600;
}

.bb-momenti-form__status.is-error {
  color: #b91c1c;
  font-weight: 600;
}

.bb-momenti-reviews {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  width: 100vw;
}

/* Lightbox */
.bb-momenti-lightbox {
  align-items: center;
  background: rgba(0, 0, 0, 0.88);
  display: flex;
  inset: 0;
  justify-content: center;
  padding: 1.5rem;
  position: fixed;
  z-index: 99999;
}

.bb-momenti-lightbox[hidden] {
  display: none !important;
}

.bb-momenti-lightbox__img {
  border-radius: 12px;
  max-height: 90vh;
  max-width: min(1100px, 100%);
  object-fit: contain;
}

.bb-momenti-lightbox__close {
  background: rgba(255, 255, 255, 0.15);
  border: none;
  border-radius: 999px;
  color: #fff;
  cursor: pointer;
  font-size: 2rem;
  height: 44px;
  line-height: 1;
  position: fixed;
  right: 1rem;
  top: 1rem;
  width: 44px;
}

@media (prefers-reduced-motion: reduce) {
  .bb-momenti-cta .bb-momenti-btn--primary,
  .bb-momenti-cta__waves,
  .bb-momenti-cta__shimmer {
    animation: none !important;
  }
}

/* ——— Mobile ——— */
@media (max-width: 768px) {
  .bb-momenti-cta {
    padding: 2.25rem 1rem 2.5rem;
  }

  .bb-momenti-cta__title {
    font-size: clamp(1.45rem, 6.5vw, 1.9rem);
    hyphens: auto;
  }

  .bb-momenti-cta__text {
    font-size: 1rem;
    margin-bottom: 1.5rem;
    padding: 0 0.15rem;
  }

  .bb-momenti-cta__badge {
    font-size: 0.78rem;
    padding: 0.45rem 0.9rem;
  }

  .bb-momenti-cta .bb-momenti-btn {
    font-size: 1rem;
    min-height: 52px;
    padding: 0.85rem 1.25rem;
    width: 100%;
  }

  .bb-momenti-cta .bb-momenti-btn--primary,
  .bb-momenti-cta .bb-momenti-btn--primary span {
    background: linear-gradient(180deg, #ffc93d 0%, #ffb703 55%, #f59e0b 100%) !important;
    border: 2px solid #fff4cc !important;
    color: #0b1f3a !important;
    -webkit-text-fill-color: #0b1f3a;
  }

  .bb-momenti-cta .bb-momenti-btn--ghost,
  .bb-momenti-cta .bb-momenti-btn--ghost span {
    background: #ffffff !important;
    border: 2px solid #ffffff !important;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22) !important;
    color: #003d7a !important;
    -webkit-text-fill-color: #003d7a;
  }

  .bb-momenti-page .bb-momenti-btn--primary,
  .bb-momenti-upload .bb-momenti-btn--primary,
  .bb-momenti-form .bb-momenti-btn--primary {
    background: #0056b3 !important;
    border: 2px solid #004494 !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff;
  }

  .bb-momenti-cta__actions {
    align-items: stretch;
    flex-direction: column;
    gap: 0.75rem;
    padding: 0 0.25rem;
  }

  .bb-momenti-page {
    padding: 1rem 0.75rem 0;
  }

  .bb-momenti-grid {
    gap: 0.85rem;
    grid-template-columns: 1fr;
  }

  .bb-momenti-card {
    margin-bottom: 0;
  }

  .bb-momenti-card__reactions {
    gap: 0.35rem 0.65rem;
  }

  .bb-momenti-react {
    flex: 0 0 auto;
    justify-content: flex-start;
    padding: 0.35rem 0.25rem;
  }

  .bb-momenti-form__thumb {
    height: 72px;
    width: 72px;
  }

  .bb-momenti-upload {
    border-radius: 16px;
    margin: 2rem 0;
    padding: 1.5rem 1rem;
  }

  .bb-momenti-form input,
  .bb-momenti-form select {
    font-size: 16px;
    min-height: 48px;
  }

  .bb-momenti-lightbox {
    padding: 0.75rem;
  }

  .bb-momenti-lightbox__close {
    height: 48px;
    right: 0.75rem;
    top: 0.75rem;
    width: 48px;
  }

  .bb-momenti-reviews {
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    width: 100vw;
  }
}

@media (max-width: 600px) {
  .bb-momenti-cta__actions {
    align-items: stretch;
    flex-direction: column;
  }

  .bb-momenti-btn {
    width: 100%;
  }
}

/* Vista solo foto — da slider galleria (?v=foto) */
body.bb-momenti-foto-only,
body.bb-momenti-foto-only #kubio,
body.bb-momenti-foto-only #kubio .wp-block-kubio-section,
body.bb-momenti-foto-only #page,
body.bb-momenti-foto-only main {
  background: linear-gradient(180deg, #f0f7ff 0%, #e8f2fb 100%) !important;
}

body.bb-momenti-foto-only #kubio .wp-block-kubio-navigation-section,
body.bb-momenti-foto-only #kubio .h-navigation,
body.bb-momenti-foto-only .custom-onda-footer,
body.bb-momenti-foto-only .site-footer,
body.bb-momenti-foto-only .bb-momenti-hero,
body.bb-momenti-foto-only .bb-momenti-upload,
body.bb-momenti-foto-only .bb-momenti-reviews,
body.bb-momenti-foto-only #bb-momenti-cta,
body.bb-momenti-foto-only #recensioni-benboat {
  display: none !important;
}

body.bb-momenti-foto-only .bb-momenti-page {
  margin: 0;
  max-width: none;
  padding: 0.35rem 0.35rem 1rem;
}

body.bb-momenti-foto-only .bb-momenti-gallery {
  background: transparent;
  margin: 0;
  min-height: 100vh;
  padding: 0.35rem;
}

body.bb-momenti-foto-only .bb-momenti-grid {
  gap: 0.85rem;
  margin: 0;
}

body.bb-momenti-foto-only .bb-momenti-card {
  background: transparent;
  border: none;
  box-shadow: none;
}

body.bb-momenti-foto-only .bb-momenti-card__title,
body.bb-momenti-foto-only .bb-momenti-card__meta {
  display: none !important;
}

body.bb-momenti-foto-only .bb-momenti-card__body {
  display: block !important;
  padding: 0.55rem 0.25rem 0.15rem;
}

body.bb-momenti-foto-only .bb-momenti-card__reactions {
  gap: 0.35rem 0.55rem;
  justify-content: center;
}

body.bb-momenti-foto-only .bb-momenti-react {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(0, 86, 179, 0.12);
  border-radius: 999px;
  box-shadow: 0 2px 10px rgba(0, 86, 179, 0.1);
  padding: 0.4rem 0.6rem;
}

body.bb-momenti-foto-only .bb-momenti-react__count {
  color: #334155;
}

body.bb-momenti-foto-only .bb-momenti-react.is-active .bb-momenti-react__count {
  color: #0369a1;
}

body.bb-momenti-foto-only .bb-momenti-card__media {
  border-radius: 10px;
}

body.bb-momenti-foto-only .bb-momenti-card__media img {
  border-radius: 10px;
}

@media (max-width: 640px) {
  body.bb-momenti-foto-only .bb-momenti-page {
    padding: 0.25rem 0.25rem 1rem;
  }

  body.bb-momenti-foto-only .bb-momenti-grid {
    gap: 1rem;
  }

  body.bb-momenti-foto-only .bb-momenti-card__reactions {
    gap: 0.4rem 0.5rem;
  }

  body.bb-momenti-foto-only .bb-momenti-react {
    min-height: 40px;
    padding: 0.45rem 0.65rem;
  }

  body.bb-momenti-foto-only .bb-momenti-react__emoji {
    font-size: 1.25rem;
  }

  body.bb-momenti-foto-only .bb-momenti-react__count {
    color: #1e293b;
    font-size: 0.82rem;
  }
}
