/* EHC Essen – Fanshop
   Dunkle Oberflaeche wie in den uebrigen Vereinsanwendungen:
   Anthrazit als Grund, Orange als einzige Signalfarbe.

   Der Fanshop wird am Tresen bedient, oft im Stehen und auf einem Tablet.
   Deshalb sind Knoepfe und Trefferflaechen hier grosszuegiger als in einer
   reinen Verwaltungsmaske. */

:root {
    --bg: #141414;
    --surface: #1c1c1c;
    --surface-2: #232323;
    --surface-3: #2a2a2a;
    --border: #2e2e2e;
    --border-hell: #3a3a3a;
    --text: #f2f2f2;
    --muted: #a3a3a3;
    --muted-2: #767676;

    --orange: #ff4c00;
    --orange-hover: #e64400;
    --orange-dunkel: #cc3d00;

    --gruen: #35c36a;
    --gelb: #f0b429;
    --rot: #e5484d;

    --radius: 10px;
    --radius-klein: 6px;
    --schatten: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .25);
    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
}

a { color: var(--orange); text-decoration: none; }
a:hover { color: var(--orange-hover); text-decoration: underline; }

h1, h2, h3 { line-height: 1.25; margin: 0 0 12px; font-weight: 650; letter-spacing: -.01em; }
h1 { font-size: 28px; }
h2 { font-size: 21px; }
h3 { font-size: 17px; }
p { margin: 0 0 14px; }

.muted { color: var(--muted); }
.klein { font-size: 13px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; }
.rechts { text-align: right; }
.mittig { text-align: center; }
.nowrap { white-space: nowrap; }

/* ---------- Kopfzeile ---------- */

.kopf {
    background: var(--surface);
    border-bottom: 2px solid var(--orange);
}

.kopf-innen {
    max-width: 1180px;
    margin: 0 auto;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
}

.kopf-logo img { height: 46px; width: auto; display: block; }

.kopf-titel {
    font-weight: 650;
    font-size: 17px;
    letter-spacing: .01em;
}
.kopf-titel span { display: block; font-size: 12px; font-weight: 400; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }

.kopf-rechts { margin-left: auto; display: flex; align-items: center; gap: 14px; font-size: 14px; color: var(--muted); }

/* ---------- Navigation im Adminbereich ---------- */

.nav {
    background: var(--surface-2);
    border-bottom: 1px solid var(--border);
}
.nav-innen {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    gap: 4px;
    overflow-x: auto;
}
.nav a {
    color: var(--muted);
    padding: 12px 14px;
    font-size: 14.5px;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
}
.nav a:hover { color: var(--text); text-decoration: none; background: var(--surface-3); }
.nav a.aktiv { color: var(--text); border-bottom-color: var(--orange); }

/* ---------- Grundgeruest ---------- */

main { flex: 1 0 auto; width: 100%; }

.inhalt {
    max-width: 1180px;
    margin: 0 auto;
    padding: 28px 20px 56px;
}
.inhalt-schmal { max-width: 760px; }

.fuss {
    border-top: 1px solid var(--border);
    background: var(--surface);
    color: var(--muted-2);
    font-size: 13px;
}
.fuss-innen {
    max-width: 1180px;
    margin: 0 auto;
    padding: 16px 20px;
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}
.fuss-innen .rechts { margin-left: auto; }

/* ---------- Karten ---------- */

.karte {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
    margin-bottom: 20px;
    box-shadow: var(--schatten);
}
.karte-kopf {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.karte-kopf h2, .karte-kopf h1 { margin: 0; }
.karte-kopf .rechts { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

.seiten-kopf {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 22px;
}
.seiten-kopf .rechts { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- Kennzahlen ---------- */

.kennzahlen {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
    margin-bottom: 22px;
}
.kennzahl {
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 3px solid var(--orange);
    border-radius: var(--radius-klein);
    padding: 16px 18px;
}
.kennzahl .wert { font-size: 28px; font-weight: 680; line-height: 1.1; }
.kennzahl .bezeichnung { color: var(--muted); font-size: 13px; text-transform: uppercase; letter-spacing: .05em; }

/* ---------- Formulare ---------- */

.feld { margin-bottom: 16px; }
.feld-reihe {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0 16px;
}

label {
    display: block;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 6px;
}
label .optional { font-weight: 400; color: var(--muted-2); }

input[type=text], input[type=email], input[type=password], input[type=number],
input[type=date], input[type=time], input[type=url], select, textarea {
    width: 100%;
    padding: 10px 12px;
    background: var(--surface-2);
    border: 1px solid var(--border-hell);
    border-radius: var(--radius-klein);
    color: var(--text);
    font-family: inherit;
    font-size: 15px;
    transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--orange);
    box-shadow: 0 0 0 3px rgba(255, 76, 0, .18);
}
input::placeholder, textarea::placeholder { color: var(--muted-2); }
textarea { resize: vertical; min-height: 90px; }
select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%23a3a3a3' d='M1 1.5 6 6.5l5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 11px;
    padding-right: 34px;
}

.hinweis-feld { font-size: 12.5px; color: var(--muted-2); margin-top: 5px; }

.schalter { display: flex; align-items: center; gap: 9px; margin-bottom: 14px; }
.schalter input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--orange); margin: 0; }
.schalter label { margin: 0; font-weight: 500; }

fieldset { border: 1px solid var(--border); border-radius: var(--radius-klein); padding: 16px; margin: 0 0 18px; }
legend { padding: 0 8px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }

/* Honigtopf: fuer Menschen unsichtbar, fuer Skripte verlockend. */
.honigtopf { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Knoepfe ---------- */

.knopf {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 10px 18px;
    border: 1px solid transparent;
    border-radius: var(--radius-klein);
    background: var(--orange);
    color: #fff;
    font: inherit;
    font-size: 14.5px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background .15s, border-color .15s;
}
.knopf:hover { background: var(--orange-hover); color: #fff; text-decoration: none; }
.knopf:active { background: var(--orange-dunkel); }

.knopf-zweit { background: var(--surface-3); color: var(--text); border-color: var(--border-hell); }
.knopf-zweit:hover { background: #333; color: var(--text); }

.knopf-gefahr { background: transparent; color: var(--rot); border-color: rgba(229, 72, 77, .5); }
.knopf-gefahr:hover { background: rgba(229, 72, 77, .12); color: var(--rot); }

.knopf-klein { padding: 6px 11px; font-size: 13px; }
.knopf-breit { width: 100%; padding: 12px 18px; font-size: 15.5px; }

.knopf-reihe { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 22px; }
.knopf-reihe .rechts { margin-left: auto; }

/* ---------- Meldungen ---------- */

.meldung {
    padding: 13px 16px;
    border-radius: var(--radius-klein);
    border: 1px solid var(--border-hell);
    background: var(--surface-2);
    margin-bottom: 20px;
    font-size: 14.5px;
}
.meldung-ok { border-color: rgba(53, 195, 106, .45); background: rgba(53, 195, 106, .1); }
.meldung-fehler { border-color: rgba(229, 72, 77, .45); background: rgba(229, 72, 77, .1); }
.meldung-hinweis { border-color: rgba(240, 180, 41, .45); background: rgba(240, 180, 41, .1); }

/* ---------- Tabellen ---------- */

.tabelle-rahmen {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
}
table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
thead th {
    text-align: left;
    padding: 11px 14px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: 12.5px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .05em;
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}
tbody td { padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: var(--surface-2); }
td .zweitzeile { color: var(--muted); font-size: 13px; }

.leer { padding: 40px 20px; text-align: center; color: var(--muted); }

/* ---------- Kennzeichnungen ---------- */

.marke {
    display: inline-block;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .02em;
    white-space: nowrap;
    border: 1px solid transparent;
}
.marke-ok { background: rgba(53, 195, 106, .14); color: var(--gruen); border-color: rgba(53, 195, 106, .35); }
.marke-offen { background: rgba(240, 180, 41, .14); color: var(--gelb); border-color: rgba(240, 180, 41, .35); }
.marke-aus { background: rgba(229, 72, 77, .13); color: var(--rot); border-color: rgba(229, 72, 77, .32); }
.marke-grau { background: var(--surface-3); color: var(--muted); border-color: var(--border-hell); }

/* ---------- Bestellannahme ---------- */

/* Zwei Spalten: links die Auswahl, rechts der Warenkorb. Der Warenkorb
   bleibt beim Blaettern stehen — am Tresen wird waehrend der Auswahl
   staendig hineingesehen. */
.shop-raster {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 22px;
    align-items: start;
}

.warenkorb {
    position: sticky;
    top: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-top: 3px solid var(--orange);
    border-radius: var(--radius);
    overflow: hidden;
}
.warenkorb-kopf {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    background: var(--surface-2);
}
.warenkorb-kopf h2 { margin: 0; font-size: 16px; }
.warenkorb-kopf .anzahl { margin-left: auto; color: var(--muted); font-size: 13px; }
.warenkorb-liste { max-height: 46vh; overflow-y: auto; }

.korb-zeile {
    display: flex;
    gap: 10px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}
.korb-zeile:last-child { border-bottom: none; }
.korb-zeile .beschreibung { flex: 1 1 auto; min-width: 0; }
.korb-zeile .beschreibung .name { font-size: 14.5px; font-weight: 600; }
.korb-zeile .beschreibung .sku { color: var(--muted-2); font-size: 12px; }
.korb-zeile .betrag { text-align: right; white-space: nowrap; font-size: 14.5px; font-weight: 600; }
.korb-zeile .beflockung { color: var(--orange); font-size: 12.5px; }

.menge-form { display: flex; align-items: center; gap: 4px; margin-top: 6px; }
.menge-form input[type=number] {
    width: 62px;
    padding: 4px 6px;
    font-size: 13.5px;
    text-align: center;
}
.menge-form button {
    background: transparent;
    border: 1px solid var(--border-hell);
    color: var(--muted);
    border-radius: var(--radius-klein);
    padding: 4px 8px;
    font: inherit;
    font-size: 13px;
    cursor: pointer;
}
.menge-form button:hover { border-color: var(--orange); color: var(--text); }
.menge-form .entfernen:hover { border-color: var(--rot); color: var(--rot); }

.warenkorb-fuss { padding: 14px 16px; border-top: 1px solid var(--border); background: var(--surface-2); }
.summe { display: flex; align-items: baseline; gap: 10px; margin-bottom: 12px; }
.summe .bezeichnung { color: var(--muted); font-size: 13px; text-transform: uppercase; letter-spacing: .05em; }
.summe .wert { margin-left: auto; font-size: 22px; font-weight: 700; }

/* ---------- Kacheln fuer Kategorie, Gruppe und Artikel ---------- */

.kacheln {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 14px;
}
.kachel {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px;
    color: var(--text);
    min-height: 116px;
    transition: border-color .15s, transform .15s;
}
.kachel:hover { border-color: var(--orange); color: var(--text); text-decoration: none; transform: translateY(-2px); }
.kachel .titel { font-size: 16px; font-weight: 650; line-height: 1.3; }
.kachel .zusatz { color: var(--muted); font-size: 13px; }
.kachel .preis { margin-top: auto; font-weight: 650; color: var(--orange); }
.kachel-bild {
    width: 100%;
    height: 132px;
    object-fit: contain;
    background: var(--surface-2);
    border-radius: var(--radius-klein);
}

/* ---------- Artikelzeile mit Mengenwahl ---------- */

.artikel-karte {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 18px;
    margin-bottom: 12px;
}
.artikel-kopf { display: flex; gap: 14px; align-items: flex-start; flex-wrap: wrap; }
.artikel-kopf .beschreibung { flex: 1 1 260px; min-width: 0; }
.artikel-kopf .name { font-size: 16px; font-weight: 650; }
.artikel-kopf .sku { color: var(--muted-2); font-size: 12.5px; }
.artikel-kopf .preis { font-size: 19px; font-weight: 700; white-space: nowrap; }
.artikel-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; margin-top: 12px; }
.artikel-form .feld { margin: 0; }
.artikel-form input[type=number] { width: 84px; }
.artikel-form .beflockung-felder { display: flex; gap: 10px; flex-wrap: wrap; }
.artikel-form .beflockung-felder input[name=schriftzug] { width: 190px; }
.artikel-form .beflockung-felder input[name=nummer] { width: 96px; }

.beflockung-hinweis {
    margin-top: 10px;
    padding: 10px 12px;
    border-left: 3px solid var(--orange);
    background: var(--surface-2);
    border-radius: 0 var(--radius-klein) var(--radius-klein) 0;
    font-size: 13.5px;
    color: var(--muted);
}

.artikel-bild-klein {
    width: 72px;
    height: 72px;
    object-fit: contain;
    background: var(--surface-2);
    border-radius: var(--radius-klein);
    flex: 0 0 auto;
}

/* ---------- Beleg nach dem Abschluss ---------- */

.beleg { max-width: 720px; }
.beleg-kopf {
    display: flex;
    align-items: center;
    gap: 14px;
    border-bottom: 2px solid var(--orange);
    padding-bottom: 14px;
    margin-bottom: 18px;
}
.beleg-nummer { margin-left: auto; font-size: 20px; font-weight: 700; }
.erfolg-symbol {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(53, 195, 106, .15);
    border: 2px solid var(--gruen);
    color: var(--gruen);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    flex: 0 0 auto;
}

/* ---------- Filterleiste ---------- */

.filter {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: flex-end;
    margin-bottom: 18px;
}
.filter .feld { margin: 0; }
.filter input[type=text], .filter select { min-width: 190px; }

.brotkrumen { color: var(--muted); font-size: 13.5px; margin-bottom: 10px; }
.brotkrumen a { color: var(--muted); }
.brotkrumen a:hover { color: var(--orange); }

/* ---------- Anmeldemaske ---------- */

.login-seite {
    max-width: 420px;
    margin: 8vh auto;
    padding: 0 20px;
}
.login-logo { text-align: center; margin-bottom: 26px; }
.login-logo img { height: 72px; }

/* ---------- Kleine Bildschirme ---------- */

@media (max-width: 980px) {
    .shop-raster { grid-template-columns: minmax(0, 1fr); }
    .warenkorb { position: static; }
}

@media (max-width: 640px) {
    .inhalt { padding: 20px 14px 40px; }
    .karte { padding: 18px 16px; }
    h1 { font-size: 23px; }
    .kopf-innen { padding: 12px 14px; gap: 12px; }
    .kopf-logo img { height: 38px; }
    .kennzahl .wert { font-size: 24px; }
    .knopf-reihe .rechts { margin-left: 0; width: 100%; }
}

@media print {
    .kopf, .nav, .fuss, .knopf, .knopf-reihe, .warenkorb, .filter { display: none !important; }
    body { background: #fff; color: #000; }
    .karte, .tabelle-rahmen { border-color: #ccc; box-shadow: none; background: #fff; }
}
