@font-face {
  font-family: 'CircularStd';
  src: url('../fonts/circularstd-book.otf') format('opentype');
  font-weight: 400;
}

@font-face {
  font-family: 'CircularStd';
  src: url('../fonts/circularstd-medium.otf') format('opentype');
  font-weight: 500;
}

@font-face {
  font-family: 'CircularStd';
  src: url('../fonts/circularstd-bold.otf') format('opentype');
  font-weight: 700;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Basis = Mobile (Mobile First). Die Desktop-Ansicht wird in responsive.css
   per min-width-Media-Query ergänzt. */
body {
  background: #f2f1dc;
  padding: 16px 10px;
  font-family: 'CircularStd', Arial, sans-serif;
  font-weight: 400;
  color: #445139;
}

.container {
  max-width: 820px;
  margin: auto;
  background: #faf9f4;
  padding: 28px 20px;
  border-radius: 16px;
  box-shadow: 0 4px 32px rgba(68, 81, 57, 0.1);
}

/* Mobile: Logo steht über dem Titel (gestapelt) */
.form-header {
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 36px;
  padding-bottom: 20px;
  border-bottom: 1.5px solid #ecdfbe;
}

.form-header-text h1 {
  font-size: 1.9rem;
  font-weight: 700;
  color: #445139;
  margin-bottom: 4px;
}

.form-header-text p {
  color: #a2af74;
  font-size: 0.95rem;
  font-weight: 500;
}

.form-header > img {
  width: auto;
  height: 70px;
  border: none;
  outline: none;
  display: block;
  flex-shrink: 0;
  margin: 0;
}

h2 {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #a2af74;
  margin-top: 36px;
  margin-bottom: 18px;
  padding-bottom: 8px;
  border-bottom: 1px solid #ecdfbe;
}

label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: #445139;
  margin-bottom: 6px;
}

input,
select,
textarea {
  width: 100%;
  padding: 10px 14px;
  margin-bottom: 18px;
  border: 1.5px solid #d8d3b8;
  border-radius: 10px;
  background: #ffffff;
  font-family: 'CircularStd', Arial, sans-serif;
  font-size: 0.9rem;
  color: #445139;
  transition: border-color 0.2s;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #445139;
}

input[type="checkbox"],
input[type="radio"] {
  width: auto;
  padding: 0;
  margin-bottom: 0;
  border: none;
  accent-color: #445139;
}

input[type="range"] {
  padding: 0;
  border: none;
  background: transparent;
  accent-color: #445139;
  margin-bottom: 4px;
}

.radio-group,
.checkbox-group {
  display: flex;
  gap: 20px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.radio-group label,
.checkbox-group label {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 0;
  font-size: 0.9rem;
  cursor: pointer;
}

button[type="submit"] {
  background: #445139;
  color: #f2f1dc;
  padding: 14px;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  width: 100%;
  font-family: 'CircularStd', Arial, sans-serif;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  transition: background 0.2s, opacity 0.2s;
  margin-top: 8px;
}

button[type="submit"]:hover {
  background: #2e3828;
}

.gebaeck-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 18px;
}

.gebaeck-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px;
  background: #f5f3e8;
  border: 1.5px solid #ecdfbe;
  border-radius: 10px;
  font-size: 0.9rem;
}

.gebaeck-row small {
  color: #a2af74;
  margin-left: 8px;
  font-size: 0.8rem;
}

.qty-control {
  display: flex;
  align-items: center;
  gap: 12px;
}

.qty-btn {
  background: #445139;
  color: #f2f1dc;
  border: none;
  border-radius: 6px;
  height: 28px;
  font-size: 1rem;
  cursor: pointer;
  padding: 0 10px;
  font-family: 'CircularStd', Arial, sans-serif;
  transition: background 0.2s;
}

.qty-btn:hover {
  background: #2e3828;
}

.qty-value {
  min-width: 20px;
  text-align: center;
  font-weight: 700;
  font-size: 0.95rem;
}

.preis-box {
  display: flex;
  flex-direction: column;
  background: #ecdfbe;
  border: 2px solid #a2af74;
  border-radius: 12px;
  padding: 18px 22px;
  margin-top: 28px;
  margin-bottom: 16px;
  color: #445139;
}

.quittung {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 0;
}

.q-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.q-main {
  font-size: 0.9rem;
  font-weight: 700;
  margin-top: 12px;
}

.q-main:first-child {
  margin-top: 0;
}

.q-sub {
  display: block;
  font-size: 0.8rem;
  font-weight: 400;
  color: #6a7a55;
  padding-left: 16px;
  line-height: 1.8;
}

.q-sub::before {
  content: "· ";
  color: #a2af74;
}

.preis-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.15rem;
  font-weight: 700;
}

/* Trennlinie nur wenn Quittung-Inhalt vorhanden */
.preis-total-row.with-sep {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1.5px solid #a2af74;
}

/* Persönliche Angaben: Mobile volle Breite (gestapelt),
   Desktop unterschiedlich breite Felder nebeneinander (responsive.css) */
.personal-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0 30px;
  margin-bottom: 10px;
}

.field {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.field label {
  display: block;
  margin-bottom: 6px;
}

/* Datum / Zeit: Mobile volle Breite (Standard), feste Breiten erst ab Desktop (responsive.css) */

.sweetness-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.sweetness-wrap input[type="range"] {
  flex: 1;
  margin-bottom: 0;
}

.matcha-item + .matcha-item {
  margin-top: 12px;
  padding-top: 24px;
  border-top: 1.5px solid #ecdfbe;
}

.matcha-item-header {
  display: none;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.matcha-item-nr {
  font-size: 0.85rem;
  font-weight: 700;
  color: #a2af74;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Optionsfelder: Mobile 1 Spalte, Desktop 2×2 Grid (responsive.css) */
.matcha-opts-pair {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-bottom: 18px;
}

.matcha-opts-pair > div {
  display: flex;
  flex-direction: column;
}

.matcha-opts-pair label:first-child {
  margin-bottom: 8px;
}

.matcha-opts-pair .radio-group,
.matcha-opts-pair .checkbox-group {
  margin-bottom: 0;
}

/* Pill-Buttons für Matcha-Optionen */
.matcha-item .radio-group,
.matcha-item .checkbox-group {
  gap: 6px;
  flex-wrap: wrap;
}

.matcha-item .radio-group label,
.matcha-item .checkbox-group label {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1.5px solid #d8d3b8;
  background: #ffffff;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0;
  gap: 0;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  cursor: pointer;
}

.matcha-item .radio-group label:hover,
.matcha-item .checkbox-group label:hover {
  border-color: #a2af74;
}

/* Quellenangabe 7 Start (Claude Code) – Pill-Buttons: ausgewählte Optionen mit reinem CSS via label:has(input:checked) hervorheben (generiert und an Farbschema angepasst) */
.matcha-item .radio-group label:has(input:checked),
.matcha-item .checkbox-group label:has(input:checked) {
  background: #445139;
  color: #f2f1dc;
  border-color: #445139;
}
/* Quellenangabe 7 Ende */

.matcha-item .radio-group input[type="radio"],
.matcha-item .checkbox-group input[type="checkbox"] {
  display: none;
}

#matcha-add-btn {
  background: transparent;
  color: #445139;
  border: 1.5px solid #445139;
  padding: 9px 18px;
  border-radius: 10px;
  cursor: pointer;
  font-family: 'CircularStd', Arial, sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  width: auto;
  margin-top: 4px;
  margin-bottom: 0;
  transition: background 0.2s, color 0.2s;
}

#matcha-add-btn:hover {
  background: #445139;
  color: #f2f1dc;
}

/* Fehlermeldungen */
.error-msg {
  display: block;
  color: #b03030;
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 6px;
}

.error-summary {
  background: #fdeaea;
  border: 1.5px solid #b03030;
  color: #b03030;
  border-radius: 10px;
  padding: 12px 18px;
  margin-bottom: 20px;
  font-size: 0.9rem;
  font-weight: 500;
}

/* Footer: Mobile untereinander, Desktop nebeneinander (responsive.css) */
.site-footer {
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1.5px solid #ecdfbe;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.footer-info {
  font-size: 0.8rem;
  color: #a2af74;
  margin: 0;
}

.footer-links {
  display: flex;
  gap: 16px;
}

.footer-links a {
  color: #445139;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.8rem;
}

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

/* Bestätigungsseite */
.confirmation-box {
  background: #f5f3e8;
  border: 1.5px solid #a2af74;
  border-radius: 16px;
  padding: 24px 18px;
  margin-top: 20px;
  text-align: center;
}

.confirmation-intro {
  font-size: 1.05rem;
  color: #445139;
  margin-bottom: 24px;
  line-height: 1.6;
}

.confirmation-list {
  list-style: none;
  margin: 0 auto 28px;
  max-width: 360px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.95rem;
  background: #fff;
  border-radius: 12px;
  padding: 20px 24px;
  border: 1.5px solid #ecdfbe;
}

.btn-back {
  display: inline-block;
  background: #445139;
  color: #f2f1dc;
  padding: 12px 28px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  transition: background 0.2s;
}

.btn-back:hover {
  background: #2e3828;
}
