/**
 * Pillar / landing pages — premium spacing, section bands, readable prose.
 * Scoped under .gt-pillar-page where needed to avoid global bleed.
 */

.gt-pillar-page {
  --pillar-section-pad-y: clamp(3rem, 6vw, 5.5rem);
  --pillar-section-pad-x: clamp(1.25rem, 4vw, 2.5rem);
  --pillar-prose-max: 42rem;
  --pillar-content-max: 72rem;
  --pillar-radius: 16px;
  --pillar-radius-lg: 20px;
  --pillar-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
  --pillar-shadow-hover: 0 12px 40px rgba(15, 23, 42, 0.1);
  --pillar-surface: #ffffff;
  --pillar-muted: #f4f6f9;
  --pillar-border: rgba(15, 23, 42, 0.09);
}

/* ---- Section bands (vertical rhythm) ---- */
.gt-pillar-section {
  padding: var(--pillar-section-pad-y) var(--pillar-section-pad-x);
  box-sizing: border-box;
}

.gt-pillar-section--surface {
  background: var(--pillar-surface);
}

.gt-pillar-section--alt {
  background: var(--pillar-muted);
  border-block: 1px solid var(--pillar-border);
}

.gt-pillar-section--offers {
  background: linear-gradient(180deg, #fafbfc 0%, #ffffff 48%);
}

.gt-pillar-section--cta-band {
  background: linear-gradient(180deg, var(--pillar-muted) 0%, #eef1f6 100%);
  border-top: 1px solid var(--pillar-border);
  padding-bottom: clamp(3.5rem, 8vw, 6rem);
}

.gt-pillar-inner {
  max-width: var(--pillar-content-max);
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

.gt-pillar-inner--wide {
  max-width: min(var(--pillar-content-max), 56rem);
}

.gt-pillar-inner--full {
  max-width: 1200px;
}

/* ---- Listing + filters (Omra, Maroc, Monde) ---- */
.listing-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 24px;
  align-items: start;
  box-sizing: border-box;
}

main.gt-pillar-page > .listing-layout {
  padding: 32px clamp(20px, 4vw, 40px);
}

.filters-panel {
  background: #fff;
  border: 1px solid var(--border, rgba(15, 23, 42, 0.09));
  border-radius: 12px;
  padding: 20px;
  height: fit-content;
  position: sticky;
  top: 88px;
  box-sizing: border-box;
}

.filters-panel h3 {
  font-family: "Dancing Script", cursive;
  font-size: 22px;
  margin: 0;
}

.filter-clear {
  float: right;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  margin-top: 4px;
}

.filter-group {
  margin-top: 16px;
  border-top: 1px solid var(--border, rgba(15, 23, 42, 0.09));
  padding-top: 12px;
}

.filter-group h4 {
  font-size: 13px;
  font-weight: 700;
  margin: 0 0 8px;
}

.filter-item {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 7px;
  font-size: 13px;
  cursor: pointer;
}

.filter-item label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.filter-item input {
  accent-color: var(--red);
}

.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  flex-wrap: wrap;
  gap: 10px;
}

.results-count {
  font-size: 14px;
  color: var(--muted);
}

.sort-sel {
  font-size: 13px;
  padding: 6px 12px;
  border: 1px solid var(--border, rgba(15, 23, 42, 0.09));
  border-radius: 8px;
  font-family: var(--font-body, "Outfit", system-ui, sans-serif);
  background: #fff;
}

.filter-toggle-btn {
  display: none;
  width: 100%;
  padding: 12px 16px;
  background: #fff;
  border: 1px solid var(--border, rgba(15, 23, 42, 0.09));
  border-radius: 10px;
  font-family: var(--font-body, "Outfit", system-ui, sans-serif);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  margin-bottom: 16px;
  align-items: center;
  justify-content: space-between;
}

.filter-toggle-btn .filter-toggle-chevron {
  font-size: 12px;
  opacity: 0.65;
  transition: transform 0.3s ease;
  display: inline-block;
}

.filter-toggle-btn.open .filter-toggle-chevron {
  transform: rotate(180deg);
}

@media (max-width: 768px) {
  .listing-layout {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 16px !important;
  }

  .filter-toggle-btn {
    display: flex;
  }

  .filters-panel {
    position: static;
    margin-bottom: 16px;
    display: none;
    border-radius: 10px;
  }

  .filters-panel.open {
    display: block;
  }

  .results-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 12px;
  }

  .sort-sel {
    width: 100%;
  }

  .listing-layout .cards-grid-3 {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
}

@media (min-width: 480px) and (max-width: 768px) {
  .listing-layout .cards-grid-3 {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* Offers “showcase” band — glassy depth + warm/cool accents */
.gt-pillar-section--offers.gt-pillar-offers-showcase {
  position: relative;
  overflow: hidden;
  background: transparent;
  border-bottom: 1px solid var(--pillar-border);
}

.gt-pillar-section--offers.gt-pillar-offers-showcase::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 110% 75% at 50% -25%, var(--showcase-glow-top, rgba(196, 30, 58, 0.08)), transparent 58%),
    radial-gradient(ellipse 55% 45% at 95% 15%, var(--showcase-glow-side, rgba(212, 175, 55, 0.1)), transparent 52%),
    linear-gradient(165deg, rgba(255, 252, 248, 0.97) 0%, #ffffff 38%, #f5f2ed 100%);
}

.gt-pillar-section--offers.gt-pillar-offers-showcase::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.35;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
}

.gt-pillar-section--offers.gt-pillar-offers-showcase > .gt-pillar-inner {
  position: relative;
  z-index: 1;
}

.gt-pillar-offers-showcase--maroc {
  --showcase-glow-top: rgba(196, 30, 58, 0.11);
  --showcase-glow-side: rgba(201, 145, 60, 0.14);
}

.gt-pillar-offers-showcase--monde {
  --showcase-glow-top: rgba(45, 85, 150, 0.12);
  --showcase-glow-side: rgba(196, 30, 58, 0.07);
}

.gt-pillar-eyebrow {
  text-align: center;
  font-family: var(--font-body, "Outfit", system-ui, sans-serif);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--red);
  margin: 0 0 0.5rem;
}

.gt-pillar-offers-showcase .gt-pillar-eyebrow::after {
  content: "";
  display: block;
  width: 56px;
  height: 2px;
  margin: 0.75rem auto 0;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, var(--gold, #c9a23c), transparent);
}

.gt-pillar-offers-heading--inline {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.2rem, 2.2vw, 1.45rem);
  font-weight: 600;
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
  text-align: left;
  color: var(--ink, #0f172a);
}

.gt-pillar-offers-showcase .filters-panel {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  border: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow:
    0 4px 28px rgba(15, 23, 42, 0.07),
    0 1px 0 rgba(255, 255, 255, 0.95) inset;
}

.gt-pillar-offers-showcase .filter-toggle-btn {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
}

.gt-pillar-offers-showcase .cards-grid-3 .trip-card {
  transition:
    transform 0.4s cubic-bezier(0.34, 1.15, 0.64, 1),
    box-shadow 0.35s ease;
}

.gt-pillar-offers-showcase .cards-grid-3 .trip-card:hover {
  transform: translateY(-6px);
}

/* Legacy wrap (fallback if any page still uses it) */
.gt-pillar-wrap {
  max-width: var(--pillar-content-max);
  margin: 0 auto;
  padding: var(--pillar-section-pad-y) var(--pillar-section-pad-x);
  box-sizing: border-box;
}

/* ---- SEO article (prose) ---- */
.gt-pillar-seo {
  background: var(--pillar-surface);
  border: 1px solid var(--pillar-border);
  border-radius: var(--pillar-radius-lg);
  padding: clamp(1.75rem, 4vw, 2.75rem) clamp(1.5rem, 4vw, 3rem);
  box-shadow: var(--pillar-shadow);
  line-height: 1.75;
  font-size: 1.0625rem;
  color: var(--text, #1a1a1a);
  max-width: min(100%, 52rem);
  margin: 0 auto;
}

.gt-pillar-seo h2 {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.75rem, 3.5vw, 2.35rem);
  font-weight: 600;
  margin: 0 0 1.25rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--ink, #0f172a);
}

/* Lead / intro: first paragraph after H2 */
.gt-pillar-seo .gt-pillar-locale > h2 + p {
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--muted);
  margin-bottom: 1.75rem;
  max-width: var(--pillar-prose-max);
}

.gt-pillar-seo h3 {
  font-family: var(--font-body, "Outfit", system-ui, sans-serif);
  font-size: 1.0625rem;
  font-weight: 700;
  margin: 2.25rem 0 0.75rem;
  letter-spacing: 0.02em;
  color: var(--ink, #0f172a);
}

.gt-pillar-seo h3:first-of-type {
  margin-top: 1.5rem;
}

.gt-pillar-seo p {
  margin: 0 0 1.125rem;
  max-width: var(--pillar-prose-max);
}

.gt-pillar-seo p:last-child {
  margin-bottom: 0;
}

.gt-pillar-locale {
  display: none;
}

.gt-pillar-locale.is-active {
  display: block;
}

/* ---- Section headings (Guides, FAQ, Offers) ---- */
.gt-pillar-heading {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  margin: 0 0 0.35rem;
  line-height: 1.2;
  color: var(--ink, #0f172a);
  letter-spacing: -0.02em;
}

.gt-pillar-heading-sub {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 0 0 1.75rem;
  max-width: 36rem;
}

.gt-pillar-guides-panel {
  background: var(--pillar-surface);
  border: 1px solid var(--pillar-border);
  border-radius: var(--pillar-radius-lg);
  padding: clamp(1.5rem, 3vw, 2.25rem);
  box-shadow: var(--pillar-shadow);
}

.gt-pillar-guides {
  margin: 0;
}

.gt-pillar-guides .gt-pillar-heading,
.gt-pillar-guides .section-title {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  margin: 0 0 1.25rem;
  line-height: 1.2;
  color: var(--ink, #0f172a);
  text-align: left;
}

.gt-pillar-guides-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

@media (min-width: 640px) {
  .gt-pillar-guides-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }
}

.gt-pillar-guide-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 1rem 1.15rem;
  background: var(--pillar-muted);
  border: 1px solid var(--pillar-border);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink, #0f172a);
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1.4;
  transition: background 0.2s, border-color 0.2s, box-shadow 0.25s, transform 0.2s;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.gt-pillar-guide-link:hover {
  background: #fff;
  border-color: rgba(196, 30, 58, 0.25);
  box-shadow: var(--pillar-shadow-hover);
  transform: translateY(-2px);
  color: var(--red);
}

.gt-pillar-guide-link__text {
  flex: 1;
  min-width: 0;
}

.gt-pillar-guide-link__arrow {
  flex-shrink: 0;
  font-size: 1.125rem;
  opacity: 0.55;
  transition: transform 0.2s, opacity 0.2s;
}

.gt-pillar-guide-link:hover .gt-pillar-guide-link__arrow {
  transform: translateX(4px);
  opacity: 1;
}

.gt-pillar-guides-empty {
  margin: 0.5rem 0 0;
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.65;
}

/* ---- Offers / listing ---- */
.gt-pillar-offers-heading,
.gt-pillar-page .section-title.gt-pillar-offers-heading {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
}

/* Omra-style listing (Maroc/Monde): left-aligned “Nos offres” — beats global .section-title center */
main.gt-pillar-page > .listing-layout .section-title.gt-pillar-offers-heading {
  text-align: left;
}

.gt-pillar-page .section-subtitle {
  margin-bottom: 1.75rem;
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--muted);
  max-width: 40rem;
}

.gt-pillar-section--offers .section-title,
.gt-pillar-section--offers .section-subtitle,
.gt-pillar-section--offers .gt-pillar-offers-heading {
  text-align: left;
  margin-left: 0;
  margin-right: 0;
}

/* Offers block: override global .section-title / .section-subtitle (center + tiny caps) */
.gt-pillar-section--offers .section-title {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.75rem, 3.2vw, 2.35rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.gt-pillar-section--offers .section-subtitle {
  font-size: 1.0625rem;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0.01em;
  line-height: 1.65;
  margin-bottom: 1.75rem;
  max-width: 42rem;
}

/* Listing inside a pillar band: vertical rhythm only (section supplies horizontal pad) */
.gt-pillar-section .listing-layout {
  padding: clamp(0.75rem, 2vw, 1.25rem) 0 0;
}

.gt-pillar-page .cards-grid-3 {
  gap: clamp(1.25rem, 2.5vw, 1.75rem);
}

.gt-pillar-page .trip-card {
  border-radius: var(--pillar-radius);
  box-shadow: 0 2px 16px rgba(15, 23, 42, 0.06);
}

.gt-pillar-page .trip-card:hover {
  box-shadow: var(--pillar-shadow-hover);
}

.gt-pillar-page .filters-panel {
  border-radius: var(--pillar-radius);
  box-shadow: var(--pillar-shadow);
}

.gt-pillar-page .results-header {
  margin-bottom: 1.25rem;
}

/* ---- FAQ ---- */
.gt-pillar-faq-panel {
  max-width: 48rem;
  margin: 0 auto;
}

.gt-pillar-faq .gt-pillar-heading,
.gt-pillar-faq .section-title {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  margin: 0 0 1.5rem;
  text-align: center;
  color: var(--ink, #0f172a);
}

.gt-pillar-faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.gt-pillar-faq-item {
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--pillar-border);
  background: var(--pillar-surface);
  box-shadow: 0 2px 12px rgba(15, 23, 42, 0.05);
  transition: box-shadow 0.25s;
}

.gt-pillar-faq-item:hover {
  box-shadow: 0 6px 24px rgba(15, 23, 42, 0.08);
}

.gt-pillar-faq-item details {
  border: none;
  border-radius: 0;
  padding: 0;
  margin: 0;
  background: transparent;
}

.gt-pillar-faq-item summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.45;
  padding: 1.15rem 1.25rem;
  list-style: none;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.gt-pillar-faq-item summary::-webkit-details-marker {
  display: none;
}

.gt-pillar-faq-item summary::after {
  content: "";
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  margin-top: 0.35rem;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(45deg);
  transition: transform 0.2s;
  opacity: 0.6;
}

.gt-pillar-faq-item details[open] summary::after {
  transform: rotate(-135deg);
  margin-top: 0.5rem;
}

.gt-pillar-faq-item details[open] summary {
  border-bottom: 1px solid var(--pillar-border);
  background: rgba(244, 246, 249, 0.6);
}

.gt-pillar-faq .gt-pillar-faq-a {
  font-size: 0.96875rem;
  color: var(--muted);
  line-height: 1.75;
  margin: 0;
  padding: 1rem 1.25rem 1.2rem;
}

/* ---- CTA ---- */
.gt-pillar-section--cta-band .gt-pillar-cta {
  margin-top: 0;
}

.gt-pillar-cta {
  display: grid;
  gap: clamp(1.5rem, 3vw, 2rem);
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  padding: clamp(1.75rem, 4vw, 2.75rem);
  border-radius: var(--pillar-radius-lg);
  border: 1px solid var(--pillar-border);
  background: var(--pillar-surface);
  box-shadow: var(--pillar-shadow-hover);
  max-width: min(100%, 56rem);
  margin-left: auto;
  margin-right: auto;
}

@media (min-width: 768px) {
  .gt-pillar-cta {
    grid-template-columns: 1fr 1fr;
    align-items: start;
    gap: 2.5rem;
  }
}

.gt-pillar-cta-intro .section-title,
.gt-pillar-cta-intro .gt-pillar-heading {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  font-weight: 600;
  margin: 0 0 0.65rem;
  line-height: 1.2;
}

/* CTA: override global huge centered .section-title */
.gt-pillar-cta h2.section-title {
  text-align: left;
  letter-spacing: -0.02em;
}

.gt-pillar-cta-sub {
  margin: 0 0 1.25rem;
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.7;
  max-width: 28rem;
}

.gt-pillar-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.gt-pillar-lead-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.gt-pillar-lead-form label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink, #0f172a);
  letter-spacing: 0.02em;
}

.gt-pillar-lead-form input,
.gt-pillar-lead-form textarea {
  margin-top: 6px;
  padding: 12px 14px;
  border: 1px solid var(--pillar-border);
  border-radius: 12px;
  font-family: inherit;
  font-size: 0.9375rem;
  transition: border-color 0.2s, box-shadow 0.2s;
  width: 100%;
  box-sizing: border-box;
}

.gt-pillar-lead-form input:focus,
.gt-pillar-lead-form textarea:focus {
  outline: none;
  border-color: rgba(196, 30, 58, 0.35);
  box-shadow: 0 0 0 3px rgba(196, 30, 58, 0.12);
}

.gt-pillar-lead-form textarea {
  min-height: 100px;
  resize: vertical;
  line-height: 1.55;
}

/* Hero + guide band — richer separation (Maroc, Monde, Omra pillars) */
body[data-gt-pillar="maroc"] .page-hero,
body[data-gt-pillar="monde"] .page-hero,
body[data-gt-pillar="omra"] .page-hero {
  box-shadow:
    0 14px 48px rgba(8, 12, 22, 0.2),
    inset 0 -3px 0 rgba(201, 162, 39, 0.4);
}

body[data-gt-pillar="maroc"] .gt-pillar-section--surface,
body[data-gt-pillar="monde"] .gt-pillar-section--surface,
body[data-gt-pillar="omra"] .gt-pillar-section--surface {
  background: linear-gradient(
    180deg,
    rgba(255, 253, 248, 0.99) 0%,
    #ffffff 42%,
    rgba(245, 241, 234, 0.55) 100%
  );
}

/* Maroc / Monde: remove default .section padding — bands handle rhythm */
main.section.gt-pillar-page {
  padding: 0;
}

main.gt-pillar-page > .gt-pillar-section:last-child,
main.section.gt-pillar-page > .gt-pillar-section:last-child {
  padding-bottom: clamp(3rem, 6vw, 4.5rem);
}

/* Maroc / Monde: first offers band — restore classic centered section title & uppercase subtitle */
.gt-pillar-section--offers.gt-pillar-offers-legacy .section-title {
  text-align: center;
  font-family: var(--font-display, "Cormorant Garamond", serif);
  font-size: clamp(2rem, 4.5vw, 2.75rem);
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 10px;
}

.gt-pillar-section--offers.gt-pillar-offers-legacy .section-subtitle {
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
  margin-bottom: 40px;
  max-width: none;
  line-height: 1.5;
}

@media (max-width: 768px) {
  .gt-pillar-section {
    padding-top: clamp(2.25rem, 5vw, 3rem);
    padding-bottom: clamp(2.25rem, 5vw, 3rem);
  }

  .gt-pillar-cta-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .gt-pillar-cta-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .gt-pillar-guides-list {
    grid-template-columns: 1fr;
  }

  .gt-pillar-faq .section-title,
  .gt-pillar-faq .gt-pillar-heading {
    text-align: left;
  }
}
