:root {
  --bg: #f4f5f7;
  --card: #ffffff;
  --text: #222;
  --muted: #666;

  --messe: #2563eb;   /* blau */
  --arena: #059669;   /* grün */
}

:root {
  --rb: #d00000;
}

.badge-rb {
  background: var(--rb);
}

.event-rb {
  border-left: 4px solid var(--rb);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
}

/* Header */
.app-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 1rem;
  background: white;
  border-bottom: 1px solid #e0e0e0;
}

.app-header h1 {
  margin: 0;
  font-size: 1.3rem;
  font-weight: 700;
}

.week-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .95rem;
}

.nav-btn {
  color: #2563eb;
  text-decoration: none;
  font-weight: 500;
}

.week-label {
  font-weight: 600;
}

/* Kalender */
.calendar {
  padding: 1rem;
}

.day {
  margin-bottom: 1.6rem;
}

.day h2 {
  font-size: 0.9rem;
  margin-bottom: .6rem;
  color: #111;
}

/* Event Card */
.event {
  display: flex;
  gap: .8rem;
  background: var(--card);
  padding: .7rem;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,.05);
  margin-bottom: .6rem;
}

.event img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  background: #ddd;
  flex-shrink: 0;
}

.event-info {
  flex: 1;
  font-size: .95rem;
}

.event-info small {
  color: var(--muted);
}

/* Titel + Badge */
.event-header {
  display: flex;
  justify-content: space-between;
  gap: .5rem;
}

.event-header strong {
  font-size: .95rem;
  line-height: 1.3;
}

/* Badges */
.badge {
  font-size: .7rem;
  font-weight: 600;
  padding: .2rem .45rem;
  border-radius: 999px;
  color: white;
  white-space: nowrap;
  align-self: flex-start;
}

.badge-messe {
  background: var(--messe);
}

.badge-arena {
  background: var(--arena);
}

.badge-city {
  background: #005fa3; /* Leipzig-Blau */
  color: #fff;
}

/* Empty */
.empty {
  padding: 1rem;
  color: #777;
  font-style: italic;
}

/* Header – App-Style */
.header-top {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 10px;
}

/* Wochen-Warnbadge */
.week-alert {
  background: #dc2626;
  color: white;
  font-size: .7rem;
  font-weight: 700;
  padding: .25rem .5rem;
  border-radius: 999px;
  white-space: nowrap;
}

/* Navigation */
.week-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .9rem;
}

.nav-btn {
  color: #2563eb;
  text-decoration: none;
  font-weight: 600;
}

.week-label {
  font-weight: 600;
  color: 
  #333;
}

.header-badges {
  display: flex;
  gap: .4rem;
}

.rb-alert {
  background: var(--rb);
}

.holiday-badge {
  background: #fde68a;
  color: #78350f;
  font-size: 0.7rem;
  padding: 2px 6px;
  border-radius: 999px;
  margin-left: 6px;
}

.holiday-alert {
  background: #7c2d12;
}

.day-empty {
  opacity: 0.7;
}

.no-events {
  font-size: 0.85rem;
  color: #777;
  margin: 0.5rem 0 0;
}

.view-switch {
  /*padding: 8px 16px 12px;
  background: #111;
  */
  text-align: center;
  margin-top: 10px;  
}

.week-link {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: #2a2a2a;
  color: #fff;
  font-weight: 600;
  font-size: 0.6rem;
  text-decoration: none;
}

.week-link:active {
  transform: scale(0.96);
  opacity: 0.9;
}

.event-range {
  color: #005fa3;
  font-weight: 600;
  white-space: nowrap;
}

.event-info a {
  color: inherit;
  text-decoration: none;
}

.search-link {
  font-size: 0.85em;
  text-decoration: none;
  opacity: 0.7;
}

.search-link:hover {
  opacity: 1;
}

/********** Werbung *********/
.ad-slot{
  padding: 10px 16px 0;
}

.ad-card{
  border-radius: 14px;
  padding: 12px 12px 10px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.10);
  backdrop-filter: blur(6px);
}

.ad-label{
  font-size: .65rem;
  opacity: .7;
  margin-bottom: 6px;
  letter-spacing: .02em;
}

.ad-link{
  display: grid;
  gap: 2px;
  color: inherit;
  text-decoration: none;
}

.ad-link strong{
  font-size: .9rem;
}

.ad-link span{
  font-size: .78rem;
  opacity: .85;
}

/*NEU*/
.ad-card.has-image .ad-link{
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 10px;
  align-items: center;
}

.ad-image{
  width: 72px;
  height: 72px;
  border-radius: 10px;
  object-fit: cover;
  background: #222;
}

.ad-text{
  display: grid;
  gap: 2px;
}

/* -------------------------------
   Overlay Werbung
-------------------------------- */

.ad-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ad-overlay.hidden {
  display: none;
}

.ad-box {
  background: #111;
  color: #fff;
  width: 90%;
  max-width: 360px;
  border-radius: 14px;
  padding: 20px;
  text-align: center;
  position: relative;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.ad-box img {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 14px;
}

.ad-box h3 {
  margin: 0 0 6px;
  font-size: 1.1rem;
}

.ad-box p {
  font-size: 0.85rem;
  opacity: 0.85;
  margin-bottom: 14px;
}

.ad-box .cta {
  display: inline-block;
  background: #e53935;
  color: #fff;
  padding: 10px 16px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.85rem;
}

.ad-box .close {
  position: absolute;
  top: 8px;
  right: 10px;
  background: none;
  border: none;
  color: #aaa;
  font-size: 1.4rem;
  cursor: pointer;
}

.access-box {
  max-width: 420px;
  margin: 15vh auto;
  padding: 28px;
  border-radius: 18px;
  background: #1a1a1a;
  color: #fff;
  text-align: center;
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}

.access-box h1 {
  font-size: 1.4rem;
  margin-bottom: 12px;
}

.access-box .lead {
  font-size: 0.95rem;
  margin-bottom: 14px;
  opacity: 0.9;
}

.access-box p {
  font-size: 0.85rem;
  opacity: 0.8;
}

.access-box .hint {
  margin-top: 18px;
  font-size: 0.85rem;
  opacity: 0.9;
}

.access-box .cta {
  margin-top: 22px;
  padding: 12px 18px;
  border-radius: 999px;
  background: #25D366;
  color: #000;
  font-weight: 700;
  display: inline-block;
}

/******* JETZT IST SCHLUSS ********/
.access-box {
  max-width: 420px;
  margin: 15vh auto;
  padding: 28px;
  border-radius: 18px;
  background: #1a1a1a;
  color: #fff;
  text-align: center;
}

/****** NEUER HEADER *******/
.app-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #ffffff;
  padding: 12px;
}

/* LOGO */
.header-brand {
  grid-column: 2;
  justify-self: center;
  display: flex;
  align-items: center;
}

.header-brand img {
  height: 16px;
  width: auto;
  display: block;
  margin: 0 auto;
  margin-bottom: 15px;
}

.header-brand img {
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.25));
}

.app-title {
  grid-column: 2;
  text-align: center;
  margin: 0;
  font-size: 1.2rem;
  font-weight: 700;
}

/* BADGES */
.header-badges {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

/* BUTTON */
.view-switch {
  text-align: center;
  margin-bottom: 10px;
}

/* WEEK NAV */
.week-nav {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  font-size: 0.75rem;
}

.week-link {
  display: inline-block;
  padding: 8px 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ff8a00, #ff5e00);
  color: #fff;
  font-weight: 600;
  font-size: 0.75rem;
  text-decoration: none;
  letter-spacing: 0.02em;
  /*box-shadow: 0 4px 10px rgba(255, 120, 0, 0.35);*/
}

.week-link:hover {
  transform: translateY(-1px);
  /*box-shadow: 0 6px 14px rgba(255, 120, 0, 0.45);*/
}

.week-switch {
  background: #346c92;
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  /*box-shadow: 0 3px 8px rgba(255, 120, 0, 0.35);*/
}

.has-hint {
  position: relative;
}

.hint-dot {
  position: absolute;
  top: -4px;
  right: -3px;
  width: 11px;
  height: 11px;
  background: #346c92;              /* dein Radar-Blau */
  border: 1px solid #ffffff;        /* sauberer Kontrast auf weiß */
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(52,108,146,0.6);
  animation: pulse 1.6s infinite;   /* etwas schneller & präsenter */
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(52,108,146,0.6);
    transform: scale(1);
  }
  70% {
    box-shadow: 0 0 0 8px rgba(52,108,146,0);
    transform: scale(1.15);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(52,108,146,0);
    transform: scale(1);
  }
}

.week-nav {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
}

.week-label {
  display: inline-block;          /* wichtig: nur so breit wie der Inhalt */
  padding: 4px 10px;
  background: #f1f3f5;            /* sehr dezentes Grau */
  color: #555;
  border-radius: 999px;           /* pillenförmig */
  font-size: 0.85rem;
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
  text-align: center;
}

.nav-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #1f1f1f;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.1s ease;
}

.nav-btn:hover {
  background: #2e2e2e;
  transform: translateY(-1px);
}

.nav-btn:active {
  transform: translateY(0);
}

.nav-btn.placeholder {
  visibility: hidden;
}

.search-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: #1a1a1a;
  color: #aaa;
  font-size: 0.65rem;
  text-decoration: none;
}

.search-link:hover {
  background: #222;
  color: #fff;
}

.app-title {
  grid-column: 2;
  justify-self: center;
  margin: 0;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.app-title span {
  opacity: 0.92;
}

.app-title {
  grid-column: 2;
  justify-self: center;
  margin: 0;
  padding: 6px 14px;
  border-radius: 999px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* ===============================
   LAYOUT BASIS – STICKY FOOTER
================================ */

html,
body {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
}

/* Hauptinhalt darf wachsen */
main,
.calendar {
  flex: 1;
}

/* ===============================
   FOOTER
================================ */

.app-footer {
  background: #fff;
  border-top: 1px solid #e5e7eb;
  padding: 14px 12px;
  font-size: 0.75rem;
  color: #777;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 24px; /* Abstand zum Content */
}

.app-footer a {
  color: #555;
  text-decoration: none;
}

.app-footer a:hover {
  text-decoration: underline;
}

.footer-love {
  font-weight: 500;
  color: #666;
  white-space: nowrap;
}

.footer-sep {
  opacity: 0.4;
}

/* ===============================
   FIX STICKY HEADER + FOOTER
================================ */

.page-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Der eigentliche Scroll-Container */
.calendar {
  flex: 1;
  overflow-y: auto;
}