/**
 * Hettstedt Live – Frontend Styles
 * Mobile-First · Kadence-kompatibel · News-Portal-Ready
 * v1.0.0
 */

/* ── Custom Properties ──────────────────────────────── */
:root {
  --hl-primary:      #1a73e8;
  --hl-primary-d:    #1557b0;
  --hl-vhs:          #0057b8;
  --hl-lsb:          #e63946;
  --hl-ok:           #2ecc71;
  --hl-warn:         #f39c12;
  --hl-danger:       #e74c3c;
  --hl-text:         #1a1a2e;
  --hl-muted:        #6b7280;
  --hl-border:       #e5e7eb;
  --hl-bg:           #f7f8fc;
  --hl-white:        #ffffff;
  --hl-radius:       12px;
  --hl-shadow:       0 2px 12px rgba(0,0,0,.08);
  --hl-shadow-h:     0 8px 28px rgba(0,0,0,.15);
  --hl-ease:         .22s cubic-bezier(.4,0,.2,1);
}

/* ── Wrapper & Grid ─────────────────────────────────── */
.hettstedt-courses-wrapper { font-family: inherit; max-width: 100%; }

.hettstedt-courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 22px;
}
@media (min-width: 1100px) { .hettstedt-courses-grid { grid-template-columns: repeat(3,1fr); } }
@media (max-width:  639px) { .hettstedt-courses-grid { grid-template-columns: 1fr; gap: 14px; } }

/* ── Filter Bar ─────────────────────────────────────── */
.hl-filter-bar {
  display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end;
  margin-bottom: 26px; padding: 18px;
  background: var(--hl-bg); border: 1px solid var(--hl-border);
  border-radius: var(--hl-radius);
}
.hl-fg { display: flex; flex-direction: column; gap: 4px; flex: 1; min-width: 145px; }
.hl-fg--search { flex: 2; min-width: 200px; }
.hl-filter-bar label {
  font-size: 10.5px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .07em; color: var(--hl-muted);
}
.hl-filter-bar select,
.hl-search {
  padding: 8px 12px; border: 1.5px solid var(--hl-border);
  border-radius: 8px; font-size: 14px; background: var(--hl-white);
  color: var(--hl-text); transition: border-color var(--hl-ease), box-shadow var(--hl-ease);
  -webkit-appearance: none; appearance: none;
}
.hl-filter-bar select:focus,
.hl-search:focus {
  outline: none; border-color: var(--hl-primary);
  box-shadow: 0 0 0 3px rgba(26,115,232,.15);
}
.hl-reset {
  padding: 8px 16px; background: transparent;
  border: 1.5px solid var(--hl-border); border-radius: 8px;
  font-size: 13px; cursor: pointer; color: var(--hl-muted);
  transition: all var(--hl-ease); align-self: flex-end; white-space: nowrap;
}
.hl-reset:hover { border-color: var(--hl-danger); color: var(--hl-danger); }
@media (max-width: 639px) { .hl-filter-bar { flex-direction: column; } .hl-fg { min-width: 100%; } }

/* ── Kurs-Karte ─────────────────────────────────────── */
.hl-card {
  background: var(--hl-white); border-radius: var(--hl-radius);
  box-shadow: var(--hl-shadow); border: 1px solid var(--hl-border);
  display: flex; flex-direction: column; overflow: hidden;
  transition: transform var(--hl-ease), box-shadow var(--hl-ease);
  position: relative;
}
.hl-card:hover { transform: translateY(-3px); box-shadow: var(--hl-shadow-h); }
.hl-card--full      { opacity: .87; }
.hl-card--cancelled { opacity: .6; }
.hl-card--cancelled::after {
  content: 'Abgesagt'; position: absolute; top: 50%; left: 50%;
  transform: translate(-50%,-50%) rotate(-18deg);
  font-size: 26px; font-weight: 900; color: rgba(231,76,60,.3);
  pointer-events: none; letter-spacing: .06em;
}

/* Header */
.hl-card__head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 14px 0;
}

/* Badges */
.hl-badge {
  font-size: 10.5px; font-weight: 700; letter-spacing: .05em;
  padding: 3px 10px; border-radius: 20px; text-transform: uppercase;
}
.hl-badge--vhs          { background: rgba(0,87,184,.12);    color: var(--hl-vhs); }
.hl-badge--lsb          { background: rgba(230,57,70,.12);   color: var(--hl-lsb); }
.hl-badge--status-available { background: rgba(46,204,113,.14); color: #1a7a46; }
.hl-badge--status-full      { background: rgba(243,156,18,.14); color: #9a6200; }
.hl-badge--status-cancelled { background: rgba(231,76,60,.1);   color: var(--hl-danger); }

/* Body */
.hl-card__body {
  padding: 12px 14px; flex: 1;
  display: flex; flex-direction: column; gap: 9px;
}
.hl-card__title { font-size: 15.5px; font-weight: 700; line-height: 1.35; color: var(--hl-text); margin: 0; }
.hl-cat-tag {
  display: inline-block; font-size: 11px; font-weight: 500;
  color: var(--hl-primary); background: #eef3fc;
  padding: 2px 9px; border-radius: 4px;
}

/* Meta-Liste */
.hl-meta-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 5px; }
.hl-meta-list li {
  display: flex; align-items: flex-start; gap: 7px;
  font-size: 12.5px; color: var(--hl-muted); line-height: 1.45;
}
.hl-meta-list li span { flex-shrink: 0; font-size: 13px; }

/* Auslastungsbalken */
.hl-bar { display: flex; align-items: center; gap: 9px; margin-top: 2px; }
.hl-bar__track { flex: 1; height: 5px; background: var(--hl-border); border-radius: 3px; overflow: hidden; }
.hl-bar__fill  { height: 100%; background: var(--hl-ok); border-radius: 3px; transition: width .4s ease; }
.hl-bar__fill--critical { background: var(--hl-warn); }
.hl-bar__text  { font-size: 11px; color: var(--hl-muted); white-space: nowrap; }

/* Footer */
.hl-card__foot {
  display: flex; justify-content: space-between; align-items: center;
  padding: 11px 14px; border-top: 1px solid var(--hl-border);
  background: #fafafa; margin-top: auto;
}
.hl-price { font-size: 17px; font-weight: 800; color: var(--hl-text); }
.hl-btn {
  display: inline-block; padding: 8px 18px;
  background: var(--hl-primary); color: #fff !important;
  font-size: 12.5px; font-weight: 600; border-radius: 8px;
  text-decoration: none; transition: background var(--hl-ease), transform var(--hl-ease);
}
.hl-btn:hover { background: var(--hl-primary-d); transform: scale(1.03); }
.hl-btn--disabled {
  background: var(--hl-border) !important; color: var(--hl-muted) !important;
  cursor: not-allowed; transform: none !important;
}

/* ── Leer-Zustand ───────────────────────────────────── */
.hl-empty {
  grid-column: 1 / -1; text-align: center; padding: 56px 20px;
  color: var(--hl-muted); font-size: 15px;
  background: var(--hl-bg); border-radius: var(--hl-radius);
  border: 2px dashed var(--hl-border);
}

/* ── Load More ──────────────────────────────────────── */
.hl-load-more-wrap { text-align: center; margin-top: 34px; }
.hl-load-more {
  padding: 12px 38px; background: var(--hl-primary); color: #fff;
  font-size: 14.5px; font-weight: 600; border: none; border-radius: 10px;
  cursor: pointer; font-family: inherit;
  transition: background var(--hl-ease), transform var(--hl-ease), opacity var(--hl-ease);
}
.hl-load-more:hover  { background: var(--hl-primary-d); transform: translateY(-2px); }
.hl-load-more:disabled { opacity: .6; cursor: not-allowed; transform: none; }

/* ── Skeleton ───────────────────────────────────────── */
.hl-skeleton {
  background: linear-gradient(90deg,#f0f0f0 25%,#e0e0e0 50%,#f0f0f0 75%);
  background-size: 200% 100%; animation: hl-shimmer 1.4s infinite;
  border-radius: 5px; display: block;
}
@keyframes hl-shimmer { 0%{background-position:200% 0} 100%{background-position:-200% 0} }

/* ── Print ──────────────────────────────────────────── */
@media print {
  .hl-filter-bar, .hl-load-more-wrap, .hl-btn { display: none; }
  .hettstedt-courses-grid { grid-template-columns: repeat(2,1fr); gap: 10px; }
  .hl-card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }
}

.hl-card__detail-link {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--hl-primary, #1a73e8);
  padding: 6px 14px;
  border: 1.5px solid var(--hl-primary, #1a73e8);
  border-radius: 7px;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--hl-ease), color var(--hl-ease);
  white-space: nowrap;
}
.hl-card__detail-link:hover {
  background: var(--hl-primary, #1a73e8);
  color: #fff !important;
  text-decoration: none;
}
.hl-card__detail-link--disabled {
  border-color: #e5e7eb;
  color: #aaa !important;
  cursor: default;
}