/* Treflyn Barn — icons, polish & motion */

/* —— Icon system —— */
.promise-icon,
.cat-icon,
.rule-icon,
.tb-icon,
.feature-list .icon,
.btn-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.promise-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(201, 166, 107, 0.16), rgba(201, 166, 107, 0.06));
  border: 1px solid rgba(201, 166, 107, 0.28);
  color: var(--champagne-deep);
  margin-bottom: 1rem;
  transition: transform 0.4s var(--ease), background 0.3s, box-shadow 0.35s;
}

.promise-icon svg {
  width: 22px;
  height: 22px;
}

.promise-card:hover .promise-icon {
  transform: translateY(-3px) scale(1.06);
  background: linear-gradient(145deg, rgba(201, 166, 107, 0.28), rgba(201, 166, 107, 0.12));
  box-shadow: 0 10px 24px rgba(201, 166, 107, 0.2);
}

.cat-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid var(--line);
}

.cat-head h3 {
  margin: 0;
  padding: 0;
  border: none;
}

.cat-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--ivory);
  border: 1px solid var(--line-strong);
  color: var(--forest-soft);
  transition: 0.35s var(--ease);
}

.cat-icon svg {
  width: 18px;
  height: 18px;
}

.amenity-cat:hover .cat-icon {
  background: var(--forest);
  border-color: var(--forest);
  color: var(--champagne-soft);
  transform: rotate(-6deg) scale(1.05);
}

.rule-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(145deg, var(--ivory), var(--ivory-2));
  border: 1px solid var(--line);
  color: var(--champagne-deep);
  margin-bottom: 0.95rem;
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  transition: 0.35s var(--ease);
}

.rule-icon svg {
  width: 20px;
  height: 20px;
}

.rule-card:hover .rule-icon {
  background: var(--forest);
  border-color: var(--forest);
  color: var(--champagne-soft);
  transform: scale(1.08);
}

.feature-list .icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1.5px solid var(--champagne);
  color: var(--champagne-deep);
  background: rgba(201, 166, 107, 0.08);
}

.feature-list .icon svg {
  width: 12px;
  height: 12px;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feature-list li:hover .icon {
  background: var(--champagne);
  color: var(--forest);
  border-color: var(--champagne);
  animation: checkPop 0.45s var(--ease);
}

@keyframes checkPop {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}

.tb-icon {
  width: 28px;
  height: 28px;
  margin: 0 auto 0.45rem;
  color: var(--champagne-soft);
  opacity: 0.9;
}

.tb-icon svg {
  width: 100%;
  height: 100%;
}

.btn-ico {
  width: 16px;
  height: 16px;
  transition: transform 0.3s var(--ease);
}

.btn:hover .btn-ico {
  transform: translateX(3px);
}

.btn.is-press {
  transform: translateY(1px) scale(0.98) !important;
}

/* —— Button polish —— */
.btn {
  position: relative;
  overflow: hidden;
}

.btn-gold::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 40%,
    rgba(255, 255, 255, 0.35) 50%,
    transparent 60%
  );
  transform: translateX(-120%);
  transition: none;
}

.btn-gold:hover::before {
  animation: shimmer 0.85s ease;
}

@keyframes shimmer {
  to {
    transform: translateX(120%);
  }
}

.btn-primary::after,
.btn-gold::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
  pointer-events: none;
}

/* —— Card motion —— */
.promise-card {
  position: relative;
  overflow: hidden;
}

.promise-card::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 0;
  background: linear-gradient(90deg, var(--champagne), transparent);
  transition: width 0.45s var(--ease);
}

.promise-card:hover::after {
  width: 100%;
}

.promise-card:hover {
  transform: translateY(-4px);
}

.amenity-cat {
  transition: transform 0.35s var(--ease), box-shadow 0.35s, border-color 0.3s;
}

.amenity-cat:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: rgba(201, 166, 107, 0.35);
}

.amenity-chips li {
  transition: transform 0.25s var(--ease), background 0.25s, border-color 0.25s,
    color 0.25s;
}

.amenity-chips li:hover {
  transform: translateY(-2px);
  background: var(--forest);
  border-color: var(--forest);
  color: var(--paper);
}

.review-topics .topic {
  transition: transform 0.3s var(--ease), border-color 0.25s, box-shadow 0.3s;
}

.review-topics .topic:hover {
  transform: translateY(-2px) scale(1.03);
  border-color: rgba(201, 166, 107, 0.45);
  box-shadow: 0 8px 20px rgba(15, 28, 22, 0.08);
}

.rule-card {
  transition: transform 0.35s var(--ease), box-shadow 0.35s, border-color 0.3s;
}

.rule-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-sm);
  border-color: rgba(201, 166, 107, 0.35);
}

/* —— Gallery polish —— */
.gallery-item {
  transition: box-shadow 0.4s var(--ease);
}

.gallery-item:hover {
  box-shadow: 0 16px 40px rgba(15, 20, 16, 0.18);
  z-index: 1;
}

.gallery-zoom {
  display: inline-flex !important;
  align-items: center;
  gap: 0.3rem;
  transition: opacity 0.3s, transform 0.35s var(--ease) !important;
  transform: translateY(-4px) scale(0.92);
}

.gallery-zoom svg {
  flex-shrink: 0;
}

.gallery-item:hover .gallery-zoom {
  transform: translateY(0) scale(1);
}

/* —— Hero extras —— */
.hero-trust {
  animation: heroIn 1s 0.1s var(--ease) both;
}

.hero-card {
  position: relative;
}

.hero-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    145deg,
    rgba(224, 196, 154, 0.55),
    transparent 40%,
    transparent 60%,
    rgba(224, 196, 154, 0.25)
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0.8;
  animation: borderGlow 4s ease-in-out infinite alternate;
}

@keyframes borderGlow {
  from {
    opacity: 0.45;
  }
  to {
    opacity: 0.95;
  }
}

.hc-badge {
  animation: pulseSoft 2.8s ease-in-out infinite;
}

@keyframes pulseSoft {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(201, 166, 107, 0.35);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(201, 166, 107, 0);
  }
}

/* —— Trust bar float icons —— */
.tb-item {
  transition: transform 0.35s var(--ease);
}

.tb-item:hover {
  transform: translateY(-3px);
}

.tb-item:hover .tb-icon {
  animation: iconBob 0.6s var(--ease);
}

@keyframes iconBob {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

/* —— Experience cards —— */
.exp-card {
  position: relative;
}

.exp-body span {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.exp-body span::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--champagne);
  box-shadow: 0 0 0 0 rgba(201, 166, 107, 0.4);
  animation: dotPulse 2s ease-in-out infinite;
}

@keyframes dotPulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(201, 166, 107, 0.45);
  }
  50% {
    box-shadow: 0 0 0 6px rgba(201, 166, 107, 0);
  }
}

/* —— Scroll reveal upgrades (no blur — blur + opacity hid photos) —— */
.reveal {
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  filter: none;
}

.reveal.visible {
  filter: none;
}

.reveal-scale {
  opacity: 0;
  transform: scale(0.94);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal-scale.visible {
  opacity: 1;
  transform: scale(1);
}

/* Stagger amenity chips when parent visible */
.amenity-cat.visible .amenity-chips li,
.amenity-cats.visible .amenity-chips li {
  animation: chipIn 0.5s var(--ease) both;
}

.amenity-chips li:nth-child(1) {
  animation-delay: 0.02s;
}
.amenity-chips li:nth-child(2) {
  animation-delay: 0.05s;
}
.amenity-chips li:nth-child(3) {
  animation-delay: 0.08s;
}
.amenity-chips li:nth-child(4) {
  animation-delay: 0.11s;
}
.amenity-chips li:nth-child(5) {
  animation-delay: 0.14s;
}
.amenity-chips li:nth-child(6) {
  animation-delay: 0.17s;
}
.amenity-chips li:nth-child(7) {
  animation-delay: 0.2s;
}
.amenity-chips li:nth-child(8) {
  animation-delay: 0.23s;
}
.amenity-chips li:nth-child(9) {
  animation-delay: 0.26s;
}
.amenity-chips li:nth-child(n + 10) {
  animation-delay: 0.3s;
}

@keyframes chipIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Only animate chips when amenity section is visible */
.amenity-cats:not(.visible) .amenity-chips li {
  animation: none;
  opacity: 1;
}

/* —— FAQ chevron spin polish —— */
.faq-q .chev {
  transition: transform 0.4s var(--ease), background 0.25s, color 0.25s,
    border-color 0.25s !important;
}

.faq-item.open .faq-q {
  background: rgba(15, 28, 22, 0.03);
}

/* —— Floating page progress —— */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  z-index: 200;
  background: linear-gradient(90deg, var(--champagne), var(--champagne-soft));
  box-shadow: 0 0 12px rgba(201, 166, 107, 0.5);
  pointer-events: none;
  transition: width 0.08s linear;
}

/* —— Section head line draw —— */
.section-head.visible::after {
  animation: lineGrow 0.8s var(--ease) both;
}

@keyframes lineGrow {
  from {
    width: 0;
    opacity: 0;
  }
  to {
    width: 42px;
    opacity: 0.9;
  }
}

/* —— Floor plan hover —— */
.floor-plan > div {
  transition: transform 0.3s var(--ease), border-color 0.3s, box-shadow 0.3s;
}

.floor-plan > div:hover {
  transform: translateY(-2px);
  border-color: rgba(201, 166, 107, 0.4);
  box-shadow: var(--shadow-sm);
}

/* —— Host photo ring pulse —— */
.host-photo {
  transition: transform 0.4s var(--ease), box-shadow 0.4s;
}

.host-card:hover .host-photo {
  transform: scale(1.05);
  box-shadow: 0 0 0 4px rgba(201, 166, 107, 0.25),
    0 12px 28px rgba(15, 28, 22, 0.18);
}

/* —— Final CTA gentle zoom —— */
.final-cta-bg {
  transition: transform 8s ease-out;
}

.final-cta:hover .final-cta-bg {
  transform: scale(1.08);
}

/* —— Form field focus lift —— */
.field input,
.field select,
.field textarea {
  transition: border-color 0.2s, box-shadow 0.25s, background 0.2s,
    transform 0.25s var(--ease);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  transform: translateY(-1px);
}

/* —— Mobile book bar glow —— */
.mobile-book-bar.show .btn-gold {
  animation: pulseSoft 2.5s ease-in-out infinite;
}

/* =========================================================
   v1.4 — Homepage elevate
   ========================================================= */

/* Trust bar: property-led labels (not platform scores) */
.trust-bar {
  background:
    radial-gradient(ellipse 70% 120% at 10% 50%, rgba(201, 166, 107, 0.12), transparent 55%),
    radial-gradient(ellipse 50% 100% at 90% 40%, rgba(201, 166, 107, 0.08), transparent 50%),
    linear-gradient(180deg, #0c1611 0%, var(--forest) 100%);
  padding: 2.1rem 0;
  border-bottom: 1px solid rgba(201, 166, 107, 0.12);
}

.trust-bar .tb-item strong {
  font-size: clamp(1.15rem, 2.2vw, 1.45rem);
  letter-spacing: 0.01em;
}

.trust-bar .tb-item span {
  opacity: 0.72;
  letter-spacing: 0.12em;
}

.trust-bar .tb-icon {
  width: 32px;
  height: 32px;
  margin-bottom: 0.55rem;
  color: var(--champagne-soft);
  opacity: 1;
}

/* Promise cards: deeper lift on the overlapping strip */
.promise-grid {
  box-shadow:
    0 28px 60px rgba(15, 20, 16, 0.1),
    0 0 0 1px rgba(201, 166, 107, 0.08);
}

.promise-card {
  background: linear-gradient(180deg, var(--paper) 0%, #fbf8f3 100%);
}

.promise-card .p-num {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  opacity: 0.85;
}

/* Soft band rhythm between major sections */
.gallery-section,
.sleep-section,
.amenities-section,
#amenities.section {
  position: relative;
}

.about-section {
  background:
    linear-gradient(180deg, transparent 0%, rgba(240, 235, 227, 0.45) 100%);
}

.about-images .main {
  box-shadow: 0 24px 50px rgba(15, 20, 16, 0.12);
  border-radius: calc(var(--radius-lg) + 2px);
  overflow: hidden;
}

.about-images .side {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 14px 32px rgba(15, 20, 16, 0.1);
}

/* Gallery: richer hover + caption */
.gallery-grid {
  gap: 0.75rem;
}

.gallery-item {
  border-radius: 14px;
  box-shadow: 0 2px 0 rgba(15, 28, 22, 0.03);
}

.gallery-item img {
  transition: transform 0.7s var(--ease), filter 0.5s ease;
  filter: saturate(0.94) contrast(1.03);
}

.gallery-item:hover img {
  transform: scale(1.05);
  filter: saturate(1.05) contrast(1.05);
}

.gallery-caption {
  background: linear-gradient(transparent, rgba(8, 14, 11, 0.72));
  letter-spacing: 0.04em;
}

/* Experience cards: deeper cinema frames */
.exp-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid rgba(15, 28, 22, 0.06);
}

.exp-visual {
  transition: transform 0.8s var(--ease);
}

.exp-card:hover .exp-visual {
  transform: scale(1.06);
}

/* Reviews: quote-only luxury grid */
.reviews-section {
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(201, 166, 107, 0.08), transparent 55%),
    var(--ivory);
}

.reviews-grid-quotes {
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.reviews-grid-quotes .review-card {
  position: relative;
  padding: 1.85rem 1.6rem 1.55rem;
  background:
    linear-gradient(165deg, #fffcf8 0%, #f7f2ea 100%);
  border-color: rgba(15, 28, 22, 0.07);
  box-shadow: 0 10px 28px rgba(15, 20, 16, 0.04);
}

.reviews-grid-quotes .review-card::before {
  content: "“";
  position: absolute;
  top: 0.55rem;
  right: 1.1rem;
  font-family: var(--font-display);
  font-size: 3.4rem;
  line-height: 1;
  color: rgba(201, 166, 107, 0.28);
  pointer-events: none;
}

.reviews-grid-quotes .review-card blockquote {
  font-size: clamp(1.12rem, 1.6vw, 1.28rem);
}

.reviews-grid-quotes .review-card footer strong {
  display: inline;
  margin: 0;
}

.review-topics {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.55rem;
  margin-bottom: 2.25rem;
}

.review-topics .topic {
  padding: 0.45rem 0.95rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--forest-soft);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.review-topics .topic strong {
  color: var(--champagne-deep);
  margin-right: 0.25rem;
}

/* Season cards */
.season-card {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, var(--paper), var(--ivory));
  transition: transform 0.35s var(--ease), box-shadow 0.35s, border-color 0.3s;
}

.season-card:hover {
  transform: translateY(-4px);
  border-color: rgba(201, 166, 107, 0.4);
  box-shadow: var(--shadow-sm);
}

/* Booking aside SO link */
.aside-so {
  margin-top: 1rem;
  font-size: 0.82rem;
  line-height: 1.45;
}

.aside-so a {
  color: var(--champagne-soft);
  text-decoration: underline;
  text-underline-offset: 0.18em;
  text-decoration-color: rgba(224, 196, 154, 0.45);
  transition: color 0.2s, text-decoration-color 0.2s;
}

.aside-so a:hover {
  color: #fff;
  text-decoration-color: rgba(255, 252, 248, 0.7);
}

.booking-aside .aside-trust {
  margin-top: 1.15rem;
  padding: 0.95rem 1rem;
  border-radius: 12px;
  background: rgba(255, 252, 248, 0.08);
  border: 1px solid rgba(255, 252, 248, 0.12);
}

.booking-aside .aside-trust strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--champagne-soft);
  margin-bottom: 0.2rem;
}

.booking-aside .aside-trust span {
  font-size: 0.8rem;
  opacity: 0.75;
}

/* Host band refinement */
.host-card {
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  background: linear-gradient(135deg, var(--paper) 0%, #f6f1e8 100%);
}

.host-badges .pill {
  background: rgba(15, 28, 22, 0.04);
  border: 1px solid var(--line);
  letter-spacing: 0.06em;
}

/* Pull quote gold line */
.pull-quote::after {
  content: "";
  display: block;
  width: 48px;
  height: 1px;
  margin: 1.35rem auto 0;
  background: linear-gradient(90deg, transparent, var(--champagne), transparent);
}

/* Sleep cards */
.sleep-card {
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(15, 20, 16, 0.05);
}

.sleep-img {
  overflow: hidden;
}

.sleep-img img {
  transition: transform 0.7s var(--ease);
}

.sleep-card:hover .sleep-img img {
  transform: scale(1.06);
}

/* Hero meta / trust fine-tune */
.hero-trust {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.hero-meta span {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

/* Location map frame */
.location-map {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

.location-map iframe {
  display: block;
  width: 100%;
  min-height: 340px;
  border: 0;
  filter: grayscale(0.15) contrast(1.05);
}

/* Responsive: quote grid */
@media (max-width: 960px) {
  .reviews-grid-quotes {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .reviews-grid-quotes {
    grid-template-columns: 1fr;
  }

  .trust-bar .tb-item strong {
    font-size: 1.1rem;
  }
}

/* —— Reduced motion —— */
@media (prefers-reduced-motion: reduce) {
  .reveal {
    filter: none;
  }

  .btn-gold::before,
  .hc-badge,
  .hero-card::before,
  .exp-body span::before,
  .amenity-chips li,
  .final-cta-bg,
  .host-photo,
  .mobile-book-bar.show .btn-gold {
    animation: none !important;
    transition: none !important;
  }

  .promise-card:hover,
  .amenity-cat:hover,
  .rule-card:hover {
    transform: none;
  }
}
