/* ===========================================================================
   Home page.
   Loaded only by index.html, so nothing here can disturb the rest of the site.
   Colours come from the tokens in style.css — this file introduces no new ones.
   =========================================================================== */

/* ------------------------------------------------------------------- hero */

.h-hero {
  position: relative;
  min-height: 420px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: #120a24;
}
.h-hero-bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .9s ease;
}
.h-hero-bg.on { opacity: 1; }

/* Dark enough on the left for white text, clear on the right for the photo. */
.h-hero::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(14,8,28,.92) 0%, rgba(14,8,28,.75) 45%, rgba(14,8,28,.35) 100%);
}
.h-hero-inner { position: relative; z-index: 2; width: 100%; padding: 56px 0; }

/* ------------------------------------------------- the strip at the bottom */
/*
 * The slide's button on the left, its dots on the right, sitting on the
 * picture itself rather than in the column of copy.
 */
.h-controls {
  position: absolute; left: 0; right: 0; bottom: 26px; z-index: 3;
  pointer-events: none;            /* the bar is a rail; only its contents take clicks */
}
.h-controls-row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.h-controls-row > * { pointer-events: auto; }

/*
 * Room for that strip, added once by renderHero() when there is something to
 * put in it. Were it reserved per slide, the hero would grow and shrink as the
 * slides turned and shove the rest of the page up and down with it.
 */
#hero.has-controls .h-hero-inner { padding-bottom: 110px; }

.h-dots { display: flex; gap: 10px; margin-left: auto; }
.h-dot {
  width: 11px; height: 11px; padding: 0; border-radius: 50%;
  background: rgba(255,255,255,.42);
  border: 1px solid rgba(255,255,255,.55);
  cursor: pointer; transition: background .2s, transform .2s, width .2s;
}
.h-dot:hover { background: rgba(255,255,255,.75); }
.h-dot.on {
  background: #fff; border-color: #fff;
  width: 30px; border-radius: 6px;     /* the current one stretches, so it reads at a glance */
}
.h-dot:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }

/* The button is positioned by the bar now, not by a margin of its own. */
.h-hero .h-cta { margin-top: 0; }

@media (max-width: 560px) {
  /* Stacked: a full-width button with the dots centred under it. Side by side
     at this width leaves the button too narrow to read comfortably. */
  .h-controls { bottom: 18px; }
  .h-controls-row { flex-direction: column; align-items: stretch; gap: 12px; }
  .h-dots { margin-left: 0; justify-content: center; }
  #hero.has-controls .h-hero-inner { padding-bottom: 150px; }
}

.h-eyebrow {
  display: inline-block;
  font-size: .75rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: #ffd9cf; margin-bottom: 14px;
}
.h-hero h1 {
  color: #fff; font-size: clamp(2rem, 4.6vw, 3.1rem); line-height: 1.1;
  margin: 0 0 14px; max-width: 16ch;
}
.h-hero p {
  color: #ded9ea; font-size: 1.0625rem; line-height: 1.55;
  margin: 0 0 26px; max-width: 46ch;
}

/* --------------------------------------------------------- the search bar */

.h-search {
  display: flex; align-items: center; gap: 8px;
  background: #fff; border-radius: 999px; padding: 7px 7px 7px 18px;
  max-width: 620px; box-shadow: 0 10px 34px rgba(0,0,0,.28);
}
.h-search .h-field { display: flex; align-items: center; gap: 9px; flex: 1 1 auto; min-width: 0; }
.h-search .h-field + .h-field {
  flex: 0 0 auto; border-left: 1px solid var(--line); padding-left: 14px;
}
.h-search svg { width: 18px; height: 18px; color: var(--muted); flex: none; }
.h-search input,
.h-search select {
  border: 0; outline: 0; background: none; font: inherit; color: var(--ink);
  padding: 8px 0; width: 100%; min-width: 0;
}
.h-search select { cursor: pointer; padding-right: 6px; }
.h-search input::placeholder { color: var(--muted); }
.h-search button {
  flex: none; border: 0; cursor: pointer; font: inherit; font-weight: 600;
  background: var(--brand-ink); color: #fff;
  padding: 11px 26px; border-radius: 999px;
}
.h-search button:hover { background: var(--brand-dark); }

@media (max-width: 640px) {
  .h-search { flex-wrap: wrap; border-radius: 16px; padding: 12px; gap: 10px; }
  .h-search .h-field { width: 100%; flex: 1 0 100%; }
  .h-search .h-field + .h-field { border-left: 0; border-top: 1px solid var(--line); padding: 8px 0 0; }
  .h-search button { width: 100%; }
}

/* ------------------------------------------------------------ categories */

/* The category strip lives in style.css under .cat-band / .cat-rail /
   .cat-item / .cat-icon, because Find events shows the same component and the
   two were drifting apart. Nothing category-specific is left here. */

/* ---------------------------------------------------------------- blocks */

.h-block { padding: 34px 0; }
.h-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 16px; margin-bottom: 18px;
}
.h-head h2 { margin: 0; font-size: 1.5rem; }
.h-head a { font-weight: 600; font-size: .9375rem; white-space: nowrap; }

/* ------------------------------------------------------------ event card */

.h-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 1040px) { .h-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .h-grid { grid-template-columns: 1fr; } }

.h-card {
  display: flex; flex-direction: column;
  border: 1px solid var(--line); border-radius: 14px; overflow: hidden;
  background: #fff; text-decoration: none; color: inherit;
  transition: box-shadow .16s ease, transform .16s ease;
}
.h-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); text-decoration: none; }

.h-card-media { position: relative; aspect-ratio: 16 / 10; background: var(--bg-soft); }
.h-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* The torn-off calendar corner. */
.h-date {
  position: absolute; top: 12px; left: 12px;
  background: #fff; border-radius: 8px; padding: 5px 9px; text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,.2); line-height: 1.1;
}
/* 10px on white is the smallest text on the page — it needs the darker
   orange far more than the large shapes do. */
.h-date b { display: block; font-size: .625rem; letter-spacing: .06em; color: var(--brand-ink); }
.h-date i { display: block; font-size: .9375rem; font-weight: 800; font-style: normal; color: var(--ink); }

.h-save {
  position: absolute; top: 12px; right: 12px;
  width: 32px; height: 32px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(255,255,255,.92); color: var(--body);
  display: flex; align-items: center; justify-content: center;
}
.h-save svg { width: 17px; height: 17px; }
.h-save.saved { color: var(--brand); }
.h-save.saved svg { fill: currentColor; }

.h-tag {
  position: absolute; top: 12px; left: 12px;
  border-radius: 999px; padding: 3px 10px;
  font-size: .6875rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase;
  color: #fff; background: var(--brand-ink);
}
.h-tag.new { background: var(--blue); }

.h-card-body { padding: 14px; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.h-card-body h3 {
  margin: 0; font-size: 1rem; line-height: 1.35; color: var(--ink);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.h-meta {
  display: flex; align-items: center; gap: 6px;
  font-size: .8125rem; color: var(--muted); min-width: 0;
}
.h-meta svg { width: 14px; height: 14px; flex: none; }
.h-meta span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.h-card-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-top: auto; padding-top: 10px;
}
.h-price { font-size: .875rem; color: var(--body); }
.h-price b { color: var(--ink); font-weight: 700; }
.h-get {
  background: var(--blue); color: #fff; border: 0; border-radius: 999px;
  padding: 8px 16px; font: inherit; font-size: .8125rem; font-weight: 600;
  cursor: pointer; white-space: nowrap; text-decoration: none;
}
.h-get:hover { background: #1a4fae; color: #fff; text-decoration: none; }

/* ------------------------------------------------------------ promo band */

.h-promos { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 18px; }
@media (max-width: 900px) { .h-promos { grid-template-columns: 1fr; } }

.h-promo {
  position: relative; min-height: 210px; border-radius: 14px; overflow: hidden;
  display: flex; align-items: flex-end; text-decoration: none; color: #fff;
  background: #2a2140;
}
.h-promo img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; transition: transform .4s ease;
}
.h-promo:hover img { transform: scale(1.05); }
.h-promo::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(16,10,30,.15) 30%, rgba(16,10,30,.85) 100%);
}
.h-promo-in { position: relative; z-index: 2; padding: 20px; }
.h-promo .kicker {
  font-size: .6875rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: #ffd9cf; display: block; margin-bottom: 6px;
}
.h-promo h3 { margin: 0 0 4px; color: #fff; font-size: 1.375rem; }
.h-promo p { margin: 0 0 12px; color: #e4e0ee; font-size: .875rem; }
.h-promo .pill {
  display: inline-block; background: rgba(255,255,255,.16); backdrop-filter: blur(3px);
  border: 1px solid rgba(255,255,255,.3); color: #fff;
  border-radius: 999px; padding: 7px 15px; font-size: .8125rem; font-weight: 600;
}
.h-promo:hover .pill { background: rgba(255,255,255,.26); }

/* ---------------------------------------------------------- trending rail */

.h-rail-wrap { position: relative; }
.h-rail {
  display: flex; gap: 16px; overflow-x: auto; scroll-behavior: smooth;
  scrollbar-width: none; padding: 4px;
}
.h-rail::-webkit-scrollbar { display: none; }
.h-rail .h-card { flex: 0 0 236px; }
.h-rail .h-card-media { aspect-ratio: 4 / 3; }

.h-rail-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 38px; height: 38px; border-radius: 50%; z-index: 3;
  border: 1px solid var(--line); background: #fff; cursor: pointer;
  box-shadow: var(--shadow-sm); color: var(--ink); font-size: 18px; line-height: 1;
}
.h-rail-arrow.prev { left: -14px; }
.h-rail-arrow.next { right: -14px; }
.h-rail-arrow:hover { border-color: var(--ink); }
@media (max-width: 720px) { .h-rail-arrow { display: none; } }

/* --------------------------------------------------------------- reasons */

.h-why { background: var(--bg-soft); padding: 44px 0; }
.h-why-head { text-align: center; margin-bottom: 30px; }
.h-why-head h2 { margin: 0 0 6px; font-size: 1.5rem; }
.h-why-head p { margin: 0; color: var(--muted); }

.h-reasons { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
@media (max-width: 900px) { .h-reasons { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .h-reasons { grid-template-columns: 1fr; } }

.h-reason { display: flex; gap: 12px; align-items: flex-start; }
.h-reason-icon {
  flex: none; width: 42px; height: 42px; border-radius: 11px;
  background: #e3f0ff; color: var(--blue);
  display: flex; align-items: center; justify-content: center;
}
.h-reason-icon svg { width: 20px; height: 20px; }
.h-reason h4 { margin: 0 0 3px; font-size: .9375rem; color: var(--ink); }
.h-reason p { margin: 0; font-size: .8125rem; color: var(--muted); line-height: 1.5; }

/* ------------------------------------------------------------ newsletter */

.h-news {
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
  border-radius: 16px; padding: 26px 30px;
  background: linear-gradient(100deg, #4a3aff 0%, #7b3fe4 55%, #a23bd0 100%);
  color: #fff;
}
.h-news-txt { display: flex; align-items: center; gap: 14px; min-width: 260px; }
.h-news-txt svg { width: 26px; height: 26px; flex: none; }
.h-news h3 { margin: 0 0 2px; color: #fff; font-size: 1.1875rem; }
.h-news p { margin: 0; color: #e7e2ff; font-size: .875rem; }

.h-news form {
  display: flex; gap: 8px; background: #fff; border-radius: 999px;
  padding: 5px 5px 5px 16px; flex: 1 1 320px; max-width: 460px;
}
.h-news input {
  border: 0; outline: 0; background: none; font: inherit; flex: 1; min-width: 0;
  color: var(--ink); padding: 9px 0;
}
.h-news button {
  border: 0; cursor: pointer; font: inherit; font-weight: 600;
  background: var(--blue); color: #fff; border-radius: 999px; padding: 9px 20px;
}
.h-news button:hover { background: #1a4fae; }
.h-news .note { flex-basis: 100%; margin: 0; font-size: .8125rem; color: #ece8ff; }

/* ------------------------------------------------------------ skeletons */

.h-skel { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.h-skel .bar { background: var(--bg-soft); animation: hpulse 1.4s ease-in-out infinite; }
.h-skel .media { aspect-ratio: 16 / 10; }
.h-skel .line { height: 11px; margin: 12px 14px; border-radius: 6px; }
.h-skel .line.short { width: 55%; }
@keyframes hpulse { 0%, 100% { opacity: 1; } 50% { opacity: .55; } }

@media (prefers-reduced-motion: reduce) {
  .h-skel .bar { animation: none; }
  .h-hero-bg, .h-promo img, .h-card { transition: none; }
}
