/* Farbvorschau für die Entscheidung des Vorstands. Gold ist der Standard (in stil.css), hier stehen die Varianten
   und die Leiste am rechten Rand. Nach der Entscheidung: $farbumschalter in public/_php/seite.php auf false setzen
   und diese Datei, farbwahl.js und _php/farbumschalter.php löschen (siehe .agents/todo.md). */

[data-color='emerald'] {
  --primary: #1e7a52;
  --primary-dark: #0f4a31;
  --on-primary: #fff;
  --button: #fff;
  --button-text: #0f4a31;
  --button-hover: #f1ede2;
  --action: #1e7a52;
  --action-dark: #0f4a31;
  --action-text: #fff;
  --link: #1e7a52;
  --pill: #fff;
  --pill-text: #0f4a31;
  --pill-hover: #f1ede2;
}

[data-color='turquoise'] {
  --primary: #167a95;
  --primary-dark: #0d5368;
  --on-primary: #fff;
  --button: #fff;
  --button-text: #0d5368;
  --button-hover: #f1ede2;
  --action: #167a95;
  --action-dark: #0d5368;
  --action-text: #fff;
  --link: #167a95;
  --pill: #fff;
  --pill-text: #0d5368;
  --pill-hover: #f1ede2;
}

[data-color='forest'] {
  --primary: #1f6b2b;
  --primary-dark: #0e3f18;
  --on-primary: #fff;
  --button: #fff;
  --button-text: #0e3f18;
  --button-hover: #f1ede2;
  --action: #1f6b2b;
  --action-dark: #0e3f18;
  --action-text: #fff;
  --link: #1f6b2b;
  --pill: #fff;
  --pill-text: #0e3f18;
  --pill-hover: #f1ede2;
}

[data-color='wine'] {
  --primary: #9b2c3d;
  --primary-dark: #651a28;
  --on-primary: #fff;
  --button: #fff;
  --button-text: #651a28;
  --button-hover: #f1ede2;
  --action: #9b2c3d;
  --action-dark: #651a28;
  --action-text: #fff;
  --link: #9b2c3d;
  --pill: #fff;
  --pill-text: #651a28;
  --pill-hover: #f1ede2;
}

[data-color='copper'] {
  --primary: #b5551a;
  --primary-dark: #7e3510;
  --on-primary: #fff;
  --button: #fff;
  --button-text: #7e3510;
  --button-hover: #f1ede2;
  --action: #b5551a;
  --action-dark: #7e3510;
  --action-text: #fff;
  --link: #a14812;
  --pill: #fff;
  --pill-text: #7e3510;
  --pill-hover: #f1ede2;
}

[data-color='sage'] {
  --primary: #4a7d58;
  --primary-dark: #2f5a3c;
  --on-primary: #fff;
  --button: #fff;
  --button-text: #2f5a3c;
  --button-hover: #f1ede2;
  --action: #4a7d58;
  --action-dark: #2f5a3c;
  --action-text: #fff;
  --link: #3f7050;
  --pill: #fff;
  --pill-text: #2f5a3c;
  --pill-hover: #f1ede2;
}

[data-color='aubergine'] {
  --primary: #5b3f8c;
  --primary-dark: #3b2763;
  --on-primary: #fff;
  --button: #fff;
  --button-text: #3b2763;
  --button-hover: #f1ede2;
  --action: #5b3f8c;
  --action-dark: #3b2763;
  --action-text: #fff;
  --link: #5b3f8c;
  --pill: #fff;
  --pill-text: #3b2763;
  --pill-hover: #f1ede2;
}

[data-color='light'] {
  --primary: #f3ede0;
  --primary-dark: #e6dcc6;
  --on-primary: #1e274a;
  --button: #1e7a52;
  --button-text: #fff;
  --button-hover: #0f4a31;
  --action: #1e7a52;
  --action-dark: #0f4a31;
  --action-text: #fff;
  --link: #1e7a52;
  --pill: #1e7a52;
  --pill-text: #fff;
  --pill-hover: #0f4a31;
}

/* Leiste am rechten Rand */
.color-switcher {
  position: fixed;
  right: calc(0.75rem + env(safe-area-inset-right, 0px));
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  width: 4.5rem;
  padding: 0.7rem 0.4rem;
  background: #12183a;
  color: #fff;
  border-radius: 1rem;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
  font-size: 0.75rem;
  text-align: center;
}

.color-switcher[hidden] {
  display: none;
}

.color-switcher-title {
  margin: 0;
  line-height: 1.25;
}

.color-switcher-title strong {
  display: block;
  font-size: 0.85rem;
}

.color-switcher-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  align-items: center;
}

.color-switcher-button {
  width: 1.9rem;
  height: 1.9rem;
  padding: 0;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.55);
  background: var(--swatch);
  cursor: pointer;
}

.color-switcher-button[aria-pressed='true'] {
  border-color: #fff;
  outline: 3px solid #fff;
  outline-offset: 2px;
}

.color-switcher-close {
  font: inherit;
  font-size: 0.7rem;
  color: #c9d1ef;
  background: none;
  border: 0;
  text-decoration: underline;
  cursor: pointer;
}
