/* Early Bird voucher banner (Baumel, 2026-11-09)
 * ============================================================================
 * The strip under the header on the browsing pages, for signed-out visitors:
 * "Early Bird Voucher · Sign up · Use on your first purchase". Built by
 * early-bird-banner.js. Colours come from Baumel's two banner designs (navy
 * band + sky-blue bird for dark, pale-blue band + navy type for light); the
 * light set is the default and html[data-theme="dark"] swaps it.
 * ============================================================================ */

.ss-eb {
  --eb-bg: linear-gradient(100deg, #DDF0FC 0%, #F6FBFE 32%, #F6FBFE 68%, #E1F2FC 100%);
  --eb-line: #D6E8F8;
  --eb-title: #0B1F3F;
  --eb-sub: #0B1F3F;
  --eb-dot: #1FA2EE;
  --eb-cta-bg: #0B1F3F;
  --eb-cta-ink: #FFFFFF;
  --eb-cta-hover: #16346A;
  --eb-focus: #2457C5;
  --eb-swoosh: rgba(255, 255, 255, 0.95);
  --eb-swoosh-2: rgba(31, 162, 238, 0.16);
  --eb-confetti: #1FA2EE;
  --eb-close: #33507F;
  --eb-close-hover-bg: rgba(11, 31, 63, 0.08);
  --eb-feet: #0B1F3F;

  position: relative;
  overflow: hidden;
  background: var(--eb-bg);
  border-bottom: 1px solid var(--eb-line);
  color: var(--eb-title);
  isolation: isolate;
}

html[data-theme="dark"] .ss-eb {
  --eb-bg: linear-gradient(100deg, #04213F 0%, #001428 30%, #001428 70%, #052749 100%);
  --eb-line: #0E2E57;
  --eb-title: #FFFFFF;
  --eb-sub: #E3ECFF;
  --eb-dot: #45C2F5;
  --eb-cta-bg: #45C2F5;
  --eb-cta-ink: #0B1F3F;
  --eb-cta-hover: #74D3F8;
  --eb-focus: #9BBAFF;
  --eb-swoosh: rgba(59, 120, 255, 0.22);
  --eb-swoosh-2: rgba(69, 194, 245, 0.14);
  --eb-confetti: #2E9BF0;
  --eb-close: #CFDCFF;
  --eb-close-hover-bg: rgba(255, 255, 255, 0.10);
  --eb-feet: #7FA8E6;
}

/* Background swooshes and confetti: decoration only. */
.ss-eb-deco {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.ss-eb-deco .ss-eb-sw1 { fill: var(--eb-swoosh); }
.ss-eb-deco .ss-eb-sw2 { fill: var(--eb-swoosh-2); }
.ss-eb-deco .ss-eb-cf { fill: var(--eb-confetti); }

.ss-eb-inner {
  box-sizing: border-box;
  max-width: 1180px;
  min-height: 112px;
  margin: 0 auto;
  padding: 12px 64px 12px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(14px, 2.6vw, 36px);
}

.ss-eb-bird {
  flex: none;
  width: clamp(84px, 9vw, 124px);
  height: auto;
  overflow: visible;
  animation: ss-eb-float 3.4s ease-in-out infinite;
}
.ss-eb-bird .eb-feet { fill: var(--eb-feet); }

.ss-eb-copy {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 0;
  text-align: center;
}

.ss-eb-title {
  margin: 0;
  font-family: var(--font-display, "Bricolage Grotesque", "Arial Black", Arial, sans-serif);
  font-weight: 800;
  font-size: clamp(22px, 3.5vw, 46px);
  line-height: 0.98;
  letter-spacing: 0.005em;
  text-transform: uppercase;
  color: var(--eb-title);
}

.ss-eb-sub {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  column-gap: 0.55em;
  row-gap: 2px;
  font-family: var(--font-body, "Plus Jakarta Sans", Arial, Helvetica, sans-serif);
  font-weight: 700;
  font-size: clamp(13px, 1.6vw, 21px);
  line-height: 1.25;
  color: var(--eb-sub);
}
.ss-eb-dot {
  flex: none;
  width: 0.38em;
  height: 0.38em;
  border-radius: 50%;
  background: var(--eb-dot);
}

.ss-eb-cta {
  flex: none;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 clamp(26px, 3.2vw, 48px);
  border-radius: 999px;
  background: var(--eb-cta-bg);
  color: var(--eb-cta-ink);
  font-family: var(--font-display, "Bricolage Grotesque", "Arial Black", Arial, sans-serif);
  font-weight: 800;
  font-size: clamp(15px, 1.7vw, 22px);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.15s ease, transform 0.15s ease;
}
.ss-eb-cta:hover { background: var(--eb-cta-hover); color: var(--eb-cta-ink); text-decoration: none; }
.ss-eb-cta:active { transform: translateY(1px); }
.ss-eb-cta:focus-visible,
.ss-eb-close:focus-visible {
  outline: 3px solid var(--eb-focus);
  outline-offset: 3px;
}

.ss-eb-close {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  box-sizing: border-box;
  width: 40px;
  height: 40px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--eb-close);
  cursor: pointer;
}
.ss-eb-close:hover { background: var(--eb-close-hover-bg); }
.ss-eb-close svg { width: 18px; height: 18px; }

/* Hiding: a short collapse, then early-bird-banner.js removes the node. */
.ss-eb.is-leaving {
  transition: opacity 0.18s ease, max-height 0.22s ease;
  max-height: 0 !important;
  opacity: 0;
}

@keyframes ss-eb-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

/* Tablet: one row still, tighter. */
@media (max-width: 900px) {
  .ss-eb-inner { min-height: 96px; padding-right: 56px; }
  .ss-eb-cta { min-height: 44px; }
}

/* Phone: bird on the left, the words and the button stacked beside it. */
@media (max-width: 640px) {
  .ss-eb-inner {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-areas:
      "bird copy"
      "bird cta";
    justify-content: stretch;
    align-items: center;
    column-gap: 12px;
    row-gap: 10px;
    min-height: 0;
    padding: 14px 44px 14px 16px;
  }
  .ss-eb-bird { grid-area: bird; width: 72px; align-self: center; }
  .ss-eb-copy { grid-area: copy; align-items: flex-start; text-align: left; gap: 4px; }
  /* One line down to 320 px: the title is about 10.9 × its font size wide. */
  .ss-eb-title { font-size: clamp(16px, 5.2vw, 26px); }
  .ss-eb-sub { font-size: clamp(12px, 3.5vw, 15px); }
  .ss-eb-sub { justify-content: flex-start; }
  .ss-eb-cta { grid-area: cta; justify-self: start; min-height: 44px; padding: 0 26px; }
  .ss-eb-close { top: 8px; right: 4px; transform: none; width: 44px; height: 44px; }
}

@media (max-width: 360px) {
  .ss-eb-bird { width: 60px; }
  .ss-eb-inner { column-gap: 10px; padding-left: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .ss-eb-bird { animation: none; }
  .ss-eb-cta, .ss-eb.is-leaving { transition: none; }
}

@media print {
  .ss-eb { display: none !important; }
}
