* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: #05080d;
  color: #dbe7f3;
  font-family:
    "Cascadia Mono",
    "Consolas",
    "DejaVu Sans Mono",
    "Liberation Mono",
    "Courier New",
    monospace;
}

body {
  min-height: 100vh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: clamp(20px, 5vw, 64px);
}

main {
  width: 100%;
  max-width: 900px;
}

.art-scroll {
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 12px;
}

.art-words {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(12px, 2vw, 28px);
  width: 100%;
}

.art {
  display: inline-block;
  white-space: nowrap;
  font-size: clamp(8px, 1.05vw, 14px);
  line-height: 1;
  font-weight: 700;
  color: #eef4ff;
  font-variant-ligatures: none;
  text-rendering: geometricPrecision;
}

.line {
  height: 1em;
  white-space: nowrap;
}

.ch {
  display: inline-block;
  width: 0.62em;
  height: 1em;
  line-height: 1em;
  text-align: center;
  overflow: visible;
  vertical-align: top;
}

.message {
  margin-top: clamp(28px, 4vw, 44px);
  margin-left: auto;
  margin-right: auto;
  max-width: 760px;
  color: #aebdcc;
  font-size: clamp(16px, 2vw, 18px);
  line-height: 1.7;
  text-align: center;
}

.status {
  margin-bottom: 10px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.date-line {
  margin: 0 0 18px;
  color: #ffffff;
  font-size: clamp(22px, 4vw, 34px);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.invite span {
  color: #eef4ff;
}

h2 {
  margin: clamp(36px, 5vw, 56px) 0 16px;
  color: #ffffff;
  font-size: clamp(18px, 2.4vw, 22px);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(219, 231, 243, 0.16);
  text-align: center;
}

h3 {
  margin: 0 0 8px;
  color: #eef4ff;
  font-size: clamp(15px, 2vw, 17px);
  letter-spacing: 0.04em;
}

/* Map ------------------------------------------------------------------ */

.map-section {
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.map-wrap {
  position: relative;
  width: 100%;
  max-width: 768px;
  border: 1px solid rgba(219, 231, 243, 0.16);
  border-radius: 6px;
  overflow: hidden;
  line-height: 0;
}

.map-img {
  display: block;
  width: 100%;
  height: auto;
}

.map-pin {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  background: #ff2d2d;
  border: 2px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(255, 45, 45, 0.35);
  pointer-events: none;
}

.map-attr {
  margin: 6px 0 0;
  color: #7f8ea3;
  font-size: 11px;
}

.map-links {
  margin: 14px 0 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px 20px;
  font-size: 15px;
}

.map-warn {
  margin: 10px auto 0;
  max-width: 640px;
  color: #7f8ea3;
  font-size: 13px;
  line-height: 1.7;
}

/* Arrival -------------------------------------------------------------- */

.arrival {
  max-width: 760px;
  color: #aebdcc;
  font-size: clamp(15px, 1.9vw, 17px);
  line-height: 1.7;
}

.cat {
  margin: 22px 0;
}

.cat p {
  margin: 6px 0;
}

.cat ul {
  margin: 8px 0 12px;
  padding-left: 20px;
}

.cat li {
  margin: 4px 0;
}

.cat strong,
.arrival strong {
  color: #eef4ff;
}

.hint {
  color: #7f8ea3;
  font-size: 13px;
}

/* Notice boxes --------------------------------------------------------- */

.notice {
  margin: 22px 0;
  padding: 16px 18px;
  border-radius: 6px;
  border: 1px solid rgba(219, 231, 243, 0.16);
  border-left-width: 4px;
  background: rgba(219, 231, 243, 0.04);
  font-size: 14px;
  line-height: 1.7;
}

.notice strong {
  color: #ffffff;
}

.notice span {
  color: #eef4ff;
}

.notice-holiday {
  border-left-color: #ffb02d;
}

.notice-neighbours {
  border-left-color: #ff2d2d;
}

/* Links ---------------------------------------------------------------- */

a {
  color: #7fb2ff;
  text-decoration: none;
  border-bottom: 1px solid rgba(127, 178, 255, 0.4);
}

a:hover {
  color: #eef4ff;
  border-bottom-color: #eef4ff;
}

a.secondary {
  color: #9aa8bb;
  border-bottom-color: rgba(154, 168, 187, 0.4);
}

/* Form ----------------------------------------------------------------- */

.reg-form {
  max-width: 640px;
}

.reg-form label {
  display: block;
  margin: 10px 0;
  color: #aebdcc;
  font-size: 14px;
}

.reg-form input[type="text"],
.reg-form textarea,
.reg-form select {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 10px 12px;
  background: #0a0f16;
  color: #eef4ff;
  border: 1px solid rgba(219, 231, 243, 0.2);
  border-radius: 5px;
  font-family: inherit;
  font-size: 15px;
}

.reg-form textarea {
  resize: vertical;
}

.reg-form input:focus,
.reg-form textarea:focus,
.reg-form select:focus {
  outline: none;
  border-color: #7fb2ff;
}

.reg-form .row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.reg-form .row label {
  flex: 1 1 180px;
}

.begleit-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 8px 0;
  flex-wrap: wrap;
}

.begleit-row .b-name {
  flex: 2 1 160px;
  padding: 8px 10px;
  background: #0a0f16;
  color: #eef4ff;
  border: 1px solid rgba(219, 231, 243, 0.2);
  border-radius: 5px;
  font-family: inherit;
}

.begleit-row select {
  flex: 1 1 120px;
  padding: 8px 10px;
  background: #0a0f16;
  color: #eef4ff;
  border: 1px solid rgba(219, 231, 243, 0.2);
  border-radius: 5px;
  font-family: inherit;
}

/* Honeypot: hidden from humans, present for bots */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

button.btn-primary,
button.btn-secondary,
button.btn-remove {
  font-family: inherit;
  font-size: 14px;
  cursor: pointer;
  border-radius: 5px;
  padding: 10px 16px;
  border: 1px solid rgba(219, 231, 243, 0.2);
  background: #10203a;
  color: #eef4ff;
}

button.btn-primary {
  margin-top: 16px;
  background: #1f6feb;
  border-color: #1f6feb;
  font-weight: 700;
}

button.btn-primary:disabled {
  opacity: 0.5;
  cursor: default;
}

button.btn-remove {
  padding: 8px 12px;
  background: transparent;
  color: #ff8a8a;
  border-color: rgba(255, 138, 138, 0.4);
}

altcha-widget {
  display: block;
  margin: 16px 0;
  max-width: 360px;
}

.form-result {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 5px;
  font-size: 14px;
}

.form-result.ok {
  border: 1px solid #2ea043;
  background: rgba(46, 160, 67, 0.12);
  color: #b7f0c2;
}

.form-result.error {
  border: 1px solid #ff6b6b;
  background: rgba(255, 107, 107, 0.12);
  color: #ffc4c4;
}

.confirm-box {
  max-width: 640px;
  margin: 20px auto;
  padding: 20px;
  border: 1px solid #2ea043;
  border-radius: 6px;
  background: rgba(46, 160, 67, 0.08);
  text-align: center;
}

.confirm-box .edit-link {
  display: block;
  margin: 12px 0 6px;
  word-break: break-all;
  font-weight: 700;
}

.confirm-box .uuid {
  color: #aebdcc;
  font-size: 13px;
  word-break: break-all;
}

code {
  color: #eef4ff;
  background: rgba(219, 231, 243, 0.08);
  padding: 2px 6px;
  border-radius: 4px;
  word-break: break-all;
}

/* Admin ---------------------------------------------------------------- */

.admin {
  max-width: 1180px;
}

.sums {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 10px 0 4px;
}

.sum-group {
  display: flex;
  gap: 12px;
}

.sums .sum {
  padding: 10px 14px;
  border: 1px solid rgba(219, 231, 243, 0.16);
  border-radius: 6px;
  color: #aebdcc;
  font-size: 13px;
}

.sums .sum .n {
  display: block;
  color: #eef4ff;
  font-size: 22px;
  font-weight: 700;
}

.sums .ok .n {
  color: #7ee787;
}
.sums .maybe .n {
  color: #ffd479;
}
.sums .no .n {
  color: #ff8a8a;
}

.table-scroll {
  width: 100%;
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin-top: 12px;
}

.admin-table th,
.admin-table td {
  border: 1px solid rgba(219, 231, 243, 0.12);
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
}

.admin-table th {
  color: #eef4ff;
  background: rgba(219, 231, 243, 0.04);
}

.admin-table .freitext {
  max-width: 260px;
  white-space: pre-wrap;
  color: #aebdcc;
}

.admin-table .ts {
  color: #7f8ea3;
  white-space: nowrap;
}

.admin-table .hidden-row {
  opacity: 0.45;
}

.begleit .chip {
  display: inline-block;
  margin: 3px 4px 0 0;
  padding: 2px 8px;
  border-radius: 10px;
  background: rgba(127, 178, 255, 0.12);
  color: #c5d2e3;
  font-size: 12px;
}

.admin-table form {
  margin: 0;
}

/* Lineup --------------------------------------------------------------- */

.lineup-list {
  list-style: none;
  margin: 14px 0 0;
  padding: 0;
}

.lineup-list li {
  display: flex;
  gap: 14px;
  align-items: baseline;
  padding: 8px 0;
  border-bottom: 1px dashed rgba(219, 231, 243, 0.15);
}

.lineup-list li:last-child {
  border-bottom: none;
}

.slot-time {
  min-width: 64px;
  color: #7fd1ff;
  font-variant-numeric: tabular-nums;
}

.slot-act {
  color: #eef4ff;
}

/* Awareness ------------------------------------------------------------ */

.notice-awareness {
  border-left-color: #ff5c8a;
}

.notice-awareness p {
  margin: 0 0 10px;
}

.notice-awareness p:last-child {
  margin-bottom: 0;
}

.awareness-head {
  margin: 0 0 12px;
  color: #ffffff;
  font-weight: 700;
  letter-spacing: 0.08em;
  font-size: clamp(15px, 2.2vw, 18px);
  line-height: 1.4;
  text-align: center;
}

/* Centered column for the remaining content sections */
.lineup,
.awareness,
.arrival {
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

/* Coordinates copy button under "Wo?" */
.coords {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0 0 14px;
}

.coord-val {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  color: #eef4ff;
  cursor: pointer;
  border-bottom: 1px dashed rgba(127, 209, 255, 0.5);
}

.coord-val:hover,
.coord-val:focus-visible {
  color: #7fd1ff;
  outline: none;
}

.coord-icon {
  background: none;
  border: none;
  color: #7fd1ff;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  padding: 2px 4px;
}

.coord-icon:hover {
  color: #eef4ff;
}

.coord-feedback {
  color: #7ee787;
  font-size: 13px;
}

/* "Uebersicht aller Buslinien" set apart from the Tabaksweiher list */
.bus-overview {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px dashed rgba(219, 231, 243, 0.15);
  text-align: center;
}

.lineup .hint {
  text-align: center;
}

/* Admin: registrant head + companions as an indented sub-list */
.reg-head {
  color: #eef4ff;
}

.reg-self {
  color: #7f8ea3;
  font-size: 12px;
}

.begleit-list-admin {
  list-style: none;
  margin: 6px 0 0;
  padding: 0 0 0 14px;
  border-left: 2px solid rgba(127, 178, 255, 0.25);
}

.begleit-list-admin li {
  padding: 2px 0;
  font-size: 13px;
  color: #c5d2e3;
}

.muted {
  color: #7f8ea3;
}

/* Admin: sortable column headers */
.admin-table th a {
  color: inherit;
  text-decoration: none;
}

.admin-table th a:hover {
  color: #7fd1ff;
}

.admin-table th .arrow {
  color: #7fd1ff;
}

/* Admin: control bar (auto-refresh dropdown) */
.admin-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin: 6px 0 10px;
  font-size: 13px;
  color: #aebdcc;
}

.admin-controls select {
  background: #0a0f16;
  color: #eef4ff;
  border: 1px solid rgba(219, 231, 243, 0.2);
  border-radius: 5px;
  padding: 6px 8px;
  font-family: inherit;
}

/* News banner (toggled via backend NEWS_ENABLED) */
.news-banner {
  margin: 0 0 20px;
  padding: 14px 18px;
  border-radius: 6px;
  border: 1px solid rgba(127, 209, 255, 0.5);
  border-left: 4px solid #7fd1ff;
  background: rgba(127, 209, 255, 0.1);
  color: #eef4ff;
  font-size: clamp(15px, 2vw, 17px);
  line-height: 1.5;
  text-align: center;
}

/* Back link (edit page) */
.back-link {
  display: inline-block;
  margin-bottom: 8px;
  color: #7fd1ff;
  text-decoration: none;
  font-size: 14px;
}

.back-link:hover {
  text-decoration: underline;
}

@media (max-width: 600px) {
  .art {
    font-size: 8px;
  }

  /* Stack the two logo words on top of each other on narrow screens. */
  .art-words {
    flex-direction: column;
    gap: 4px;
  }

  /* Admin sums: group into three rows on small screens
     (Anmeldungen+Personen / sicher+vielleicht+nicht / Alkohol+alkoholfrei). */
  .sum-group {
    flex-basis: 100%;
  }
}
