:root {
  --text: #000000;
  --overlay: rgba(0, 0, 0, 0.5);
  --panel: #333333;
  --panel-text: #ffffff;
  --success: #1e7f43;
  --danger: #b42318;
  --border: rgba(0, 0, 0, 0.15);
  --soft: rgba(255, 255, 255, 0.92);
  --shadow: 0 14px 40px rgba(0, 0, 0, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Roboto", sans-serif;
  color: var(--text);
}

a {
  color: inherit;
}

.stream-page button,
.secondary-button,
.admin-page button {
  border: none;
  border-radius: 5px;
  padding: 10px 20px;
  font: inherit;
  cursor: pointer;
  text-decoration: none;
}

.stream-page button,
.admin-page button {
  background: #5cb85c;
  color: #ffffff;
}

.stream-page button:hover,
.admin-page button:hover,
.secondary-button:hover {
  opacity: 0.92;
}

.danger-button {
  background: #d9534f;
}

.secondary-button {
  background: #ffffff;
  color: #111111;
  border: 1px solid var(--border);
}

.hidden {
  display: none !important;
}

.stream-page,
.admin-page {
  background-image: url("hintergrund.jpg");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}

.stream-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.stream-page-alt {
  display: block;
  color: #102433;
}

.stream-page header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 10px;
}

.stream-page header img {
  max-width: 100%;
  height: auto;
  object-fit: cover;
}

.stream-page h1 {
  margin: 10px 0;
}

.stream-page h2 {
  margin: 0;
}

.iframe-container {
  width: 80%;
  max-width: 1280px;
  margin-top: 20px;
  padding-top: 45%;
  position: relative;
}

.stream-page iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.link-section {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.link-section a {
  margin: 5px 0;
  color: black;
  text-decoration: none;
}

.landing-shell {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 20px;
}

.landing-hero {
  display: grid;
  gap: 6px;
}

.landing-header,
.player-panel,
.landing-footer {
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid rgba(9, 35, 51, 0.1);
  border-radius: 24px;
  box-shadow: 0 18px 50px rgba(16, 36, 51, 0.08);
  backdrop-filter: blur(8px);
}

.landing-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 8px 4px;
}

.landing-logo-frame {
  width: 210px;
  height: 210px;
  overflow: hidden;
  border-radius: 0;
  background: transparent;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.landing-logo {
  display: block;
  width: 210px;
  max-width: 210px;
  height: auto;
  margin-left: 0;
  margin-top: 0;
  transform: none;
}

.landing-copy {
  width: min(760px, 100%);
  margin-top: -42px;
  margin-left: 0;
  align-self: center;
}

.landing-copy h1 {
  margin: 0 0 2px;
  font-size: clamp(1.25rem, 2vw, 1.8rem);
  line-height: 1;
  color: #102433;
}

.landing-topline {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 0;
}

.city-kicker {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 700;
  color: rgba(16, 36, 51, 0.9);
}

.live-badge {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(18, 115, 64, 0.12);
  color: #0f6a3d;
  font-weight: 700;
  letter-spacing: 0.02em;
  font-size: 0.76rem;
}

.session-card {
  padding: 7px 12px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(9, 35, 51, 0.94), rgba(27, 72, 97, 0.9));
  color: #f5f9fb;
}

.session-label,
.info-label,
.player-kicker {
  margin: 0 0 8px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.session-card h2 {
  margin: 0;
  font-size: clamp(0.9rem, 1.1vw, 1rem);
  line-height: 1.18;
}

.info-ribbon {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-end;
  margin-top: 4px;
  padding: 7px 12px;
  border-radius: 14px;
  background: rgba(240, 246, 249, 0.95);
}

.info-ribbon a {
  font-weight: 700;
  color: #0d4461;
  word-break: break-word;
}

.info-note {
  max-width: 32ch;
  margin: 0;
  color: rgba(16, 36, 51, 0.78);
  line-height: 1.35;
  font-size: 0.95rem;
}

.player-panel {
  padding: 8px;
}

.player-intro {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-end;
  margin-bottom: 8px;
}

.player-note {
  max-width: 42ch;
  margin: 0;
  color: rgba(16, 36, 51, 0.78);
  line-height: 1.35;
  font-size: 0.95rem;
}

.iframe-container-alt {
  width: 100%;
  max-width: none;
  margin-top: 0;
  padding-top: 56.25%;
  overflow: hidden;
  border-radius: 18px;
}

.landing-footer {
  margin-top: 4px;
  padding: 8px 14px;
}

.footer-nav {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-nav a {
  font-weight: 500;
  text-decoration: none;
}

.cookie-overlay {
  display: flex;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--overlay);
  color: var(--panel-text);
  align-items: center;
  justify-content: center;
  text-align: center;
  z-index: 1000;
}

.cookie-box {
  background: var(--panel);
  padding: 20px;
  border-radius: 10px;
}

.cookie-box button {
  margin: 0 10px;
}

.admin-shell {
  width: min(1180px, calc(100% - 24px));
  margin: 0 auto;
  padding: 40px 0;
}

.admin-card,
.admin-panel {
  background: var(--soft);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.admin-card {
  padding: 28px;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.customer-grid {
  grid-template-columns: minmax(0, 860px);
  justify-content: center;
}

.admin-panel {
  padding: 22px;
}

.admin-log-panel {
  grid-column: 1 / -1;
}

.admin-kicker {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
}

.admin-card h1,
.admin-panel h2 {
  margin: 0 0 12px;
}

.admin-copy {
  margin: 0 0 20px;
  line-height: 1.5;
}

.admin-copy-small {
  margin-top: -8px;
  font-size: 0.95rem;
  color: rgba(16, 36, 51, 0.78);
}

.admin-topbar {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 20px;
}

.admin-form {
  display: grid;
  gap: 10px;
}

label {
  font-weight: 700;
}

.toggle-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 400;
}

.toggle-row input {
  width: auto;
  margin: 0;
}

.toggle-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.78);
  font-weight: 400;
}

.toggle-card input {
  width: auto;
  margin-top: 3px;
}

.toggle-card span {
  display: grid;
  gap: 4px;
}

.toggle-card small {
  color: rgba(0, 0, 0, 0.68);
  font-size: 0.92rem;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  font: inherit;
  background: #ffffff;
}

textarea {
  resize: vertical;
}

.admin-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.preview-card,
.status-list,
.admin-note,
.log-entry,
.user-item,
.stat-card {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.chart-card {
  margin-top: 14px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.chart-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
}

.chart-head span,
.analytics-live-note {
  color: rgba(0, 0, 0, 0.72);
}

.analytics-chart {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(4px, 1fr));
  gap: 3px;
  align-items: end;
  min-height: 120px;
}

.chart-bar {
  min-height: 8px;
  border-radius: 999px 999px 2px 2px;
  background: linear-gradient(180deg, #5cb85c, #1f5a39);
}

.stat-label {
  display: block;
  font-size: 0.9rem;
  color: rgba(0, 0, 0, 0.7);
  margin-bottom: 6px;
}

.stat-value {
  font-size: 1.6rem;
}

.stat-value-small {
  font-size: 1rem;
  line-height: 1.3;
}

.analytics-toolbar {
  display: flex;
  gap: 12px;
  align-items: end;
  flex-wrap: wrap;
  margin-top: 16px;
}

.analytics-toolbar label {
  margin-bottom: 6px;
}

.analytics-toolbar input {
  max-width: 220px;
}

.analytics-date-note {
  margin: 14px 0 0;
}

.analytics-live-note {
  margin: 8px 0 0;
}

.analytics-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.analytics-breakdown-card,
.comparison-card {
  margin-top: 14px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.analytics-list {
  display: grid;
  gap: 10px;
}

.analytics-list-item,
.analytics-table-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.analytics-list-item span,
.analytics-table-row span {
  min-width: 0;
}

.analytics-table {
  display: grid;
  gap: 10px;
}

.analytics-table-row {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.78);
}

.analytics-table-head {
  font-weight: 700;
  background: rgba(9, 35, 51, 0.08);
}

.analytics-table-head,
.analytics-table-row {
  grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr));
}

.preview-label {
  margin: 0 0 6px;
  font-size: 0.9rem;
  color: rgba(0, 0, 0, 0.7);
}

.preview-title {
  margin: 0 0 10px;
  font-size: 1.2rem;
  font-weight: 700;
}

.preview-mode,
.preview-link {
  margin: 0 0 12px;
}

.status-list p {
  margin: 0 0 10px;
}

.status-list p:last-child {
  margin-bottom: 0;
}

.admin-note {
  margin-top: 16px;
}

.admin-note p {
  margin: 8px 0 0;
}

.admin-note code {
  display: block;
  margin-top: 10px;
  word-break: break-all;
}

.log-list {
  display: grid;
  gap: 12px;
}

.user-list {
  display: grid;
  gap: 12px;
}

.user-list-wrap {
  margin-top: 18px;
}

.user-list-wrap h3 {
  margin: 0 0 12px;
}

.user-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.user-item p {
  margin: 4px 0 0;
  color: rgba(0, 0, 0, 0.7);
}

.log-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.log-entry p,
.log-empty {
  margin: 6px 0 0;
}

.form-message {
  min-height: 24px;
  margin: 0;
}

.admin-credit {
  margin: 18px 0 0;
  font-size: 0.92rem;
  color: rgba(16, 36, 51, 0.72);
  text-align: center;
}

.customer-guide-panel {
  background: rgba(242, 248, 251, 0.95);
}

.customer-steps {
  display: grid;
  gap: 12px;
}

.customer-step {
  padding: 14px 16px;
  border: 1px solid rgba(9, 35, 51, 0.12);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.78);
}

.customer-step strong {
  display: block;
  margin-bottom: 6px;
}

.customer-step p,
.customer-help {
  margin: 0;
  color: rgba(0, 0, 0, 0.72);
  line-height: 1.5;
}

.customer-main-panel h2 {
  margin-bottom: 10px;
}

.form-message.error {
  color: var(--danger);
}

.form-message.success {
  color: var(--success);
}

@media (max-width: 900px) {
  .iframe-container {
    width: 96%;
    padding-top: 56.25%;
  }

  .admin-grid {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }

  .landing-header {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .info-ribbon,
  .player-intro {
    flex-direction: column;
    align-items: flex-start;
  }

  .landing-logo-frame {
    width: 120px;
    height: 120px;
  }

  .landing-logo {
    width: 120px;
    max-width: 120px;
  }

  .landing-copy {
    margin-left: 0;
  }
}

@media (max-width: 640px) {
  .stream-page {
    justify-content: flex-start;
  }

  .landing-shell {
    width: min(100% - 16px, 1240px);
    padding: 16px 0 28px;
  }

  .admin-shell {
    width: min(100% - 16px, 1180px);
    padding: 18px 0;
  }

  .admin-card,
  .admin-panel {
    padding: 20px;
  }

  .admin-topbar,
  .log-head {
    flex-direction: column;
  }

  .admin-actions {
    flex-direction: column;
  }

  .stats-grid,
  .analytics-toolbar {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: stretch;
  }

  .analytics-split {
    grid-template-columns: 1fr;
  }

  .analytics-table-head,
  .analytics-table-row {
    grid-template-columns: 1fr;
  }

  .stream-page button,
  .admin-page button,
  .secondary-button {
    width: 100%;
  }

  .footer-nav {
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }
}
