* { box-sizing: border-box; }

body {
  min-width: 320px;
  margin: 0;
  color: var(--text-primary, #172536);
  background: var(--background, #f4f7fa);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

.events-header {
  position: relative;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 82% -20%, rgba(227, 38, 47, .3), transparent 42%),
    linear-gradient(120deg, var(--navy-deep, #081f33), #102f4b 72%, #183c58);
}

.events-header::after {
  position: absolute;
  right: -90px;
  bottom: -155px;
  width: 430px;
  height: 230px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 50%;
  content: "";
  transform: rotate(-8deg);
}

.events-header-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  width: min(1320px, calc(100% - 48px));
  min-height: 220px;
  margin: 0 auto;
  padding: 30px 0;
}

.events-hero-branding {
  display: flex;
  align-items: center;
  gap: 32px;
  min-width: 0;
}

.events-brand {
  position: relative;
  display: block;
  flex: 0 0 300px;
  height: 116px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .22);
}

.events-brand img {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 315px;
  max-width: none;
  transform: translate(-50%, -50%);
}

.events-hero-copy span,
.events-section-heading span {
  color: #ff7b81;
  font-size: .75rem;
  font-weight: 900;
  letter-spacing: .14em;
}

.events-hero-copy h1 {
  margin: 4px 0 6px;
  color: #fff;
  font-size: clamp(2.25rem, 5vw, 4rem);
  line-height: 1;
  letter-spacing: -.045em;
}

.events-hero-copy p {
  max-width: 560px;
  margin: 0;
  color: #cad7e2;
  font-size: 1rem;
  line-height: 1.55;
}

.events-main {
  width: min(1320px, calc(100% - 48px));
  margin: 44px auto 72px;
}

.events-section { margin-top: 42px; }
.events-section:first-of-type { margin-top: 0; }

.events-section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--border, #dbe3ea);
}

.events-section-heading h2 {
  margin: 4px 0 0;
  color: var(--navy, #102a43);
  font-size: clamp(1.4rem, 2vw, 1.75rem);
  letter-spacing: -.025em;
}

.events-section-heading strong {
  display: grid;
  place-items: center;
  min-width: 38px;
  height: 32px;
  padding: 0 11px;
  color: var(--text-secondary, #5d6f81);
  border: 1px solid var(--border, #dbe3ea);
  border-radius: 999px;
  background: #fff;
  font-size: .8125rem;
}

.events-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 20px;
}

.event-card {
  display: grid;
  grid-template-rows: 134px minmax(0, 1fr);
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--border, #dbe3ea);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 12px 32px rgba(8, 31, 51, .07);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.event-card:only-child { grid-column: 1 / -1; }

.event-card:hover {
  border-color: #c8d2db;
  box-shadow: 0 18px 42px rgba(8, 31, 51, .12);
  transform: translateY(-3px);
}

.event-card-logo {
  display: grid;
  place-items: center;
  min-width: 0;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border, #dbe3ea);
  background: linear-gradient(145deg, #fff, var(--surface-secondary, #f0f4f7));
}

.event-card-logo img {
  width: min(260px, 100%);
  height: 98px;
  object-fit: contain;
}

.event-card-content {
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  min-width: 0;
  padding: 21px;
}

.event-card-state {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  color: #53677b;
  border: 1px solid #e0e6ec;
  border-radius: 999px;
  background: #f2f5f8;
  font-size: .75rem;
  font-weight: 850;
}

.event-card-state.live {
  color: var(--live, #0d8c63);
  border-color: #bfe5d6;
  background: #e9f8f2;
}

.event-card h3 {
  margin: 13px 0 14px;
  color: var(--navy, #102a43);
  font-size: 1.25rem;
  line-height: 1.25;
  letter-spacing: -.02em;
}

.event-card dl {
  display: grid;
  gap: 9px;
  width: 100%;
  margin: 0 0 20px;
}

.event-card dl div {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 9px;
}

.event-card dt { color: #8593a1; font-size: .8125rem; }

.event-card dd {
  overflow: hidden;
  margin: 0;
  color: #40556a;
  font-size: .8125rem;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.event-card-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  margin-top: auto;
  padding: 0 16px;
  color: #fff;
  border-radius: 10px;
  background: var(--brand-primary, #b5121b);
  font-size: .8125rem;
  font-weight: 850;
  text-decoration: none;
}

.event-card-action:hover,
.event-card-action:focus-visible { background: var(--brand-primary-hover, #941018); }

.events-empty {
  grid-column: 1 / -1;
  display: grid;
  place-content: center;
  min-height: 128px;
  padding: 26px;
  color: var(--text-secondary, #5d6f81);
  text-align: center;
  border: 1px dashed #c8d2dc;
  border-radius: 16px;
  background: rgba(255, 255, 255, .72);
}

.events-empty strong { color: #40556a; font-size: .9375rem; }
.events-empty p { margin: 5px 0 0; font-size: .8125rem; }
.events-error { padding: 13px 15px; color: #92323a; border: 1px solid #efcbd0; border-radius: 10px; background: #fff1f2; font-size: .8125rem; }
.is-hidden { display: none; }
.events-footer { padding: 28px; color: #718196; text-align: center; border-top: 1px solid var(--border, #dbe3ea); background: #fff; font-size: .8125rem; }

@media (min-width: 1080px) {
  .event-card:only-child {
    grid-template-columns: 250px minmax(0, 1fr);
    grid-template-rows: minmax(250px, auto);
  }

  .event-card:only-child .event-card-logo {
    border-right: 1px solid var(--border, #dbe3ea);
    border-bottom: 0;
  }
}

@media (max-width: 1024px) {
  .events-header-inner { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 680px) {
  .events-header-inner { width: min(100% - 28px, 1320px); min-height: 0; padding: 22px 0 25px; }
  .events-hero-branding { align-items: flex-start; flex-direction: column; gap: 18px; width: 100%; }
  .events-brand { flex-basis: 92px; width: min(270px, 100%); height: 92px; }
  .events-brand img { width: 285px; }
  .events-hero-copy h1 { font-size: 2.25rem; }
  .events-hero-copy p { font-size: .875rem; }
  .events-main { width: min(100% - 24px, 1320px); margin: 28px auto 50px; }
  .events-section { margin-top: 34px; }
  .events-grid { grid-template-columns: 1fr; gap: 14px; }
  .event-card { grid-template-rows: 116px minmax(0, 1fr); }
  .event-card-logo { padding: 12px 18px; }
  .event-card-logo img { height: 86px; }
  .event-card-content { padding: 18px; }
}

@media (max-width: 390px) {
  .events-header-inner { width: calc(100% - 20px); }
  .events-brand { width: 230px; height: 84px; }
  .events-brand img { width: 245px; }
  .events-main { width: calc(100% - 20px); }
  .events-section-heading h2 { font-size: 1.25rem; }
  .event-card h3 { font-size: 1.125rem; }
  .event-card dl div { grid-template-columns: 68px minmax(0, 1fr); }
  .event-card dd { white-space: normal; }
  .event-card-action { width: 100%; }
}

@media (prefers-reduced-motion: reduce) { .event-card { transition: none; } }
