/* IslandTravelAtlas Premium Experience
 * Shared mega menu, destination-first tools, image system, and footer.
 */
:root {
  --pm-ocean-950: #062b3a;
  --pm-ocean-900: #083747;
  --pm-ocean-800: #0d4a5e;
  --pm-lagoon-600: #0f8f8b;
  --pm-lagoon-500: #19a7a1;
  --pm-coral-600: #b84c39;
  --pm-ink: #152f38;
  --pm-muted: #5c7077;
  --pm-canvas: #f6f4ef;
  --pm-paper: #fff;
  --pm-line: #dfe7e6;
  --pm-dark-text: #e5eff1;
  --pm-dark-muted: #c6d5d9;
  --pm-dark-link: #bdf2ed;
  --pm-shadow: 0 22px 65px rgba(6, 43, 58, .18);
  --pm-radius-lg: 24px;
  --pm-radius-md: 16px;
}

html.pm-nav-open,
html.pm-nav-open body { overflow: hidden; }

/* Shared header */
.pm-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100%;
  color: var(--pm-ink);
  background: rgba(255, 255, 255, .94);
  border-bottom: 1px solid rgba(8, 55, 71, .1);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.pm-header-inner {
  width: min(1240px, calc(100% - 40px));
  min-height: 78px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

.pm-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  min-width: max-content;
  color: var(--pm-ink) !important;
  text-decoration: none !important;
}

.pm-brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--pm-ocean-900);
  border-radius: 50%;
}

.pm-brand-mark svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 2; }
.pm-brand-copy { display: grid; gap: 2px; }
.pm-brand-copy strong { color: var(--pm-ink) !important; font-size: 1rem !important; line-height: 1.1 !important; letter-spacing: -.02em; }
.pm-brand-copy small { color: var(--pm-muted) !important; font-size: .64rem !important; line-height: 1.25 !important; letter-spacing: .06em; text-transform: uppercase; }

.pm-desktop-nav { margin-left: auto; display: flex; align-items: stretch; gap: 4px; }
.pm-nav-item { position: static; display: flex; align-items: stretch; }
.pm-nav-link,
.pm-nav-trigger {
  min-height: 48px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 0;
  border-radius: 10px;
  color: var(--pm-ink) !important;
  background: transparent;
  font: inherit;
  font-size: .88rem !important;
  font-weight: 680;
  line-height: 1.2;
  text-decoration: none !important;
  cursor: pointer;
}
.pm-nav-link:hover,
.pm-nav-trigger:hover,
.pm-nav-trigger[aria-expanded="true"] { background: #edf5f4; color: var(--pm-ocean-900) !important; }
.pm-nav-trigger svg { width: 13px; transition: transform .18s ease; }
.pm-nav-trigger[aria-expanded="true"] svg { transform: rotate(180deg); }

.pm-mega {
  position: absolute;
  top: calc(100% + 1px);
  left: 50%;
  width: min(1180px, calc(100vw - 42px));
  padding: 24px;
  color: var(--pm-ink);
  background: var(--pm-paper);
  border: 1px solid rgba(8, 55, 71, .12);
  border-radius: 0 0 24px 24px;
  box-shadow: var(--pm-shadow);
  transform: translateX(-50%);
}
.pm-mega[hidden] { display: none !important; }
.pm-mega-grid { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; }
.pm-mega-intro { padding: 22px; color: #fff; background: linear-gradient(145deg, var(--pm-ocean-950), var(--pm-ocean-800)); border-radius: 18px; }
.pm-mega-intro span { color: #9ee7df; font-size: .68rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.pm-mega-intro h2 { margin: .55rem 0 .75rem !important; color: #fff !important; font-size: clamp(1.35rem, 2vw, 1.9rem) !important; line-height: 1.05 !important; }
.pm-mega-intro p { margin: 0 0 1rem; color: var(--pm-dark-muted) !important; font-size: .86rem !important; line-height: 1.55 !important; }
.pm-mega-intro a { color: var(--pm-dark-link) !important; font-size: .82rem; font-weight: 760; }

.pm-destination-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; }
.pm-destination-card {
  min-width: 0;
  overflow: hidden;
  color: var(--pm-ink) !important;
  background: #f7faf9;
  border: 1px solid var(--pm-line);
  border-radius: 16px;
  text-decoration: none !important;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.pm-destination-card:hover { transform: translateY(-3px); border-color: rgba(15, 143, 139, .4); box-shadow: 0 14px 28px rgba(8, 55, 71, .12); }
.pm-destination-card img { width: 100%; aspect-ratio: 4 / 2.3; display: block; object-fit: cover; }
.pm-destination-card div { padding: 13px 14px 15px; }
.pm-destination-card span { color: var(--pm-lagoon-600); font-size: .64rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.pm-destination-card strong { display: block; margin-top: 4px; color: var(--pm-ink) !important; font-size: .95rem !important; line-height: 1.2 !important; }
.pm-destination-card small { display: block; margin-top: 4px; color: var(--pm-muted) !important; font-size: .72rem !important; line-height: 1.4 !important; }

.pm-mega-columns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.pm-mega-column { min-width: 0; padding: 4px 10px; }
.pm-mega-column h2 { margin: 0 0 9px !important; color: var(--pm-ocean-900) !important; font-family: inherit !important; font-size: .7rem !important; font-weight: 820 !important; line-height: 1.2 !important; letter-spacing: .1em !important; text-transform: uppercase; }
.pm-mega-column a { display: block; padding: 8px 0; color: var(--pm-ink) !important; font-size: .84rem !important; font-weight: 620; line-height: 1.35; text-decoration: none !important; }
.pm-mega-column a:hover { color: var(--pm-lagoon-600) !important; }
.pm-mega-column a span { display: block; margin-top: 2px; color: var(--pm-muted) !important; font-size: .7rem; font-weight: 450; }

.pm-header-cta {
  min-width: max-content;
  padding: 11px 15px;
  color: #fff !important;
  background: var(--pm-coral-600);
  border-radius: 999px;
  font-size: .82rem !important;
  font-weight: 760;
  text-decoration: none !important;
}
.pm-header-cta:hover { background: #9e3f31; }

.pm-menu-button { display: none; width: 44px; height: 44px; padding: 10px; border: 1px solid var(--pm-line); border-radius: 12px; background: #fff; }
.pm-menu-button i { display: block; height: 2px; margin: 5px 0; background: var(--pm-ink); border-radius: 2px; }
.pm-mobile-nav { display: none; }

/* Destination-first tools */
.pm-tools-hero { padding: clamp(56px, 8vw, 96px) 0; background: var(--pm-canvas); }
.pm-tools-hero-grid { width: min(1180px, calc(100% - 40px)); margin: 0 auto; display: grid; grid-template-columns: minmax(0, .9fr) minmax(360px, 1.1fr); gap: clamp(32px, 6vw, 72px); align-items: center; }
.pm-tools-hero h1 { max-width: 12ch; margin: .6rem 0 1rem !important; font-size: clamp(2.65rem, 5.6vw, 5rem) !important; line-height: .95 !important; letter-spacing: -.055em; }
.pm-tools-hero p { max-width: 60ch; color: var(--pm-muted); font-size: 1rem; line-height: 1.7; }
.pm-tools-hero img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--pm-radius-lg); box-shadow: var(--pm-shadow); }
.pm-kicker { color: var(--pm-lagoon-600); font-size: .7rem; font-weight: 820; letter-spacing: .12em; text-transform: uppercase; }
.pm-section { padding: clamp(58px, 8vw, 96px) 0; }
.pm-shell { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.pm-section-heading { max-width: 760px; margin-bottom: 32px; }
.pm-section-heading h2 { margin: .55rem 0 .8rem !important; font-size: clamp(2rem, 4vw, 3.5rem) !important; line-height: 1 !important; letter-spacing: -.04em; }
.pm-section-heading p { color: var(--pm-muted); line-height: 1.65; }
.pm-tools-destinations { background: #fff; }
.pm-tool-choice-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.pm-tool-choice { min-width: 0; padding: 20px; color: var(--pm-ink) !important; background: #fff; border: 1px solid var(--pm-line); border-radius: var(--pm-radius-md); text-decoration: none !important; }
.pm-tool-choice span { color: var(--pm-lagoon-600); font-size: .68rem; font-weight: 820; letter-spacing: .08em; text-transform: uppercase; }
.pm-tool-choice strong { display: block; margin: 7px 0 6px; color: var(--pm-ink) !important; font-size: 1.02rem !important; line-height: 1.25 !important; }
.pm-tool-choice p { margin: 0; color: var(--pm-muted); font-size: .82rem; line-height: 1.5; }
.pm-tool-choice:hover { border-color: rgba(15,143,139,.45); box-shadow: 0 14px 32px rgba(8,55,71,.09); }

.pm-destination-tools { margin-top: clamp(54px, 8vw, 88px); padding: clamp(46px, 6vw, 72px) 0; color: var(--pm-dark-text); background: linear-gradient(140deg, var(--pm-ocean-950), var(--pm-ocean-800)); }
.pm-destination-tools-grid { width: min(1120px, calc(100% - 40px)); margin: 0 auto; display: grid; grid-template-columns: minmax(0, .95fr) minmax(360px, 1.05fr); gap: 46px; align-items: center; }
.pm-destination-tools h2 { margin: .55rem 0 .8rem !important; color: #fff !important; font-size: clamp(2rem, 4vw, 3.4rem) !important; line-height: 1 !important; letter-spacing: -.04em; }
.pm-destination-tools p { color: var(--pm-dark-muted) !important; line-height: 1.65; }
.pm-destination-tools img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 18px; }
.pm-destination-tool-links { margin-top: 22px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.pm-destination-tool-links a { min-width: 0; padding: 14px 15px; color: #fff !important; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); border-radius: 12px; font-size: .82rem !important; font-weight: 700; text-decoration: none !important; }
.pm-destination-tool-links a:hover { background: rgba(255,255,255,.15); }

.pm-tool-destination-strip { padding: 56px 0; background: #f2f7f6; }
.pm-tool-destination-strip .pm-destination-grid { margin-top: 24px; }

/* Real-image handling */
img.pm-real-image { background: #dfe9e7; }
.pm-image-frame { overflow: hidden; border-radius: var(--pm-radius-lg); }
.pm-image-frame img { width: 100%; height: 100%; object-fit: cover; }

/* Shared premium footer; headings are component sized, not page h2 sized. */
.pm-footer { color: var(--pm-dark-text); background: var(--pm-ocean-950); }
.pm-footer-main { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 58px 0 42px; display: grid; grid-template-columns: minmax(280px, 1.5fr) repeat(3, minmax(150px, .72fr)); gap: 40px; }
.pm-footer .pm-brand { color: #fff !important; }
.pm-footer .pm-brand-copy strong { color: #fff !important; }
.pm-footer .pm-brand-copy small { color: var(--pm-dark-muted) !important; }
.pm-footer-brand p { max-width: 42ch; margin: 18px 0 0; color: var(--pm-dark-muted) !important; font-size: .88rem !important; line-height: 1.65 !important; }
.pm-footer-heading { margin: 0 0 10px !important; color: #fff !important; font-family: inherit !important; font-size: .72rem !important; font-weight: 820 !important; line-height: 1.25 !important; letter-spacing: .11em !important; text-transform: uppercase; }
.pm-footer-column { min-width: 0; }
.pm-footer-column a { display: block; padding: 5px 0; color: var(--pm-dark-muted) !important; font-size: .84rem !important; line-height: 1.45 !important; text-decoration: none !important; }
.pm-footer-column a:hover { color: var(--pm-dark-link) !important; }
.pm-footer-bottom { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 20px 0 28px; display: flex; justify-content: space-between; gap: 24px; border-top: 1px solid rgba(255,255,255,.13); }
.pm-footer-bottom p,
.pm-footer-bottom a,
.pm-footer-bottom button { color: var(--pm-dark-muted) !important; font-size: .69rem !important; line-height: 1.5 !important; }
.pm-footer-bottom p { margin: 0; max-width: 62ch; }
.pm-footer-bottom div { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px 14px; }
.pm-footer-bottom button { padding: 0; border: 0; background: none; cursor: pointer; }

@media (max-width: 1080px) {
  .pm-desktop-nav, .pm-header-cta { display: none; }
  .pm-menu-button { display: block; margin-left: auto; }
  .pm-mobile-nav { padding: 14px 20px 26px; background: #fff; border-top: 1px solid var(--pm-line); max-height: calc(100vh - 78px); overflow-y: auto; }
  .pm-mobile-nav:not([hidden]) { display: block; }
  .pm-mobile-nav details { border-bottom: 1px solid var(--pm-line); }
  .pm-mobile-nav summary { padding: 16px 0; color: var(--pm-ink); font-size: .94rem; font-weight: 760; cursor: pointer; list-style: none; }
  .pm-mobile-nav summary::-webkit-details-marker { display: none; }
  .pm-mobile-links { padding: 0 0 14px 14px; display: grid; gap: 2px; }
  .pm-mobile-links a { padding: 9px 0; color: var(--pm-muted) !important; font-size: .86rem; text-decoration: none; }
  .pm-mobile-direct { display: block; padding: 16px 0; color: var(--pm-ink) !important; border-bottom: 1px solid var(--pm-line); font-size: .94rem; font-weight: 760; text-decoration: none; }
  .pm-mobile-cta { display: block; margin-top: 18px; padding: 13px 16px; color: #fff !important; background: var(--pm-coral-600); border-radius: 999px; text-align: center; font-weight: 760; text-decoration: none; }
  .pm-footer-main { grid-template-columns: 1.4fr repeat(2, 1fr); }
  .pm-footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .pm-header-inner { width: min(100% - 28px, 1240px); min-height: 70px; gap: 12px; }
  .pm-brand-copy small { display: none; }
  .pm-brand-mark { width: 36px; height: 36px; }
  .pm-tools-hero-grid,
  .pm-destination-tools-grid { grid-template-columns: 1fr; }
  .pm-tools-hero-grid { width: min(100% - 28px, 1180px); }
  .pm-tools-hero h1 { font-size: clamp(2.45rem, 13vw, 4rem) !important; }
  .pm-tool-choice-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pm-destination-tool-links { grid-template-columns: 1fr; }
  .pm-footer-main { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 22px; }
  .pm-footer-brand { grid-column: 1 / -1; }
  .pm-footer-bottom { flex-direction: column; }
  .pm-footer-bottom div { justify-content: flex-start; }
}

@media (max-width: 520px) {
  .pm-brand-copy strong { font-size: .91rem !important; }
  .pm-tool-choice-grid { grid-template-columns: 1fr; }
  .pm-footer-main { grid-template-columns: 1fr 1fr; }
  .pm-footer-column:last-child { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  .pm-destination-card, .pm-nav-trigger svg { transition: none; }
}
