/* SocialPic — Oberfläche in der CI der Marco Theis Unternehmensberatung.
   Grundlage: agents/nova/ci-dokumentation/marco-theis.md
   Navy als Struktur- und Textfarbe, Gold als einziger Akzent, Georgia für
   Überschriften, Arial für Fließtext.

   Übernommen aus KiPic und um alles ergänzt, was SocialPic zusätzlich
   braucht: Fokus-Picker, Formatkacheln, Safe-Zone-Bänder und Logo-Proben. */

:root {
  --gold: #E8A020;
  --gold-soft: rgba(232, 160, 32, 0.12);
  --navy: #1A3C6E;
  --navy-dark: #0D2448;
  --dark: #1A1A2E;
  --muted: #6A7487;
  --border: #DDE2EC;
  --bg: #F0F2F7;
  --weiss: #ffffff;
  --gruen: #157347;
  --rot: #B02A37;
  --radius: 6px;
  --shadow: 0 2px 12px rgba(26, 60, 110, 0.08);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--dark);
  line-height: 1.6;
}

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

/* --- Kopf --- */

header {
  background: var(--weiss);
  border-bottom: 3px solid var(--gold);
  padding: 0.9rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.marke { display: flex; align-items: flex-end; gap: 0.7rem; }

/* Logo: drei aufsteigende Balken, bündig unten — wie in der CI beschrieben. */
.balken { display: flex; align-items: flex-end; gap: 5px; height: 34px; }
.balken span { width: 7px; border-radius: 2px 2px 0 0; display: block; }
.balken .b1 { height: 12px; background: var(--gold); }
.balken .b2 { height: 21px; background: var(--navy); }
.balken .b3 { height: 34px; background: var(--dark); }

.marke .name {
  font-family: Georgia, serif;
  font-weight: 900;
  font-size: 1.25rem;
  letter-spacing: 0.06em;
  color: var(--navy);
  line-height: 1;
}
.marke .zusatz {
  display: block;
  font-family: Arial, sans-serif;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 0.3rem;
}

header nav { display: flex; align-items: center; gap: 1.3rem; flex-wrap: wrap; }
header nav a {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
}
header nav a.aktiv { color: var(--gold); }
header nav .wer { font-size: 0.8rem; color: var(--muted); letter-spacing: 0; text-transform: none; }

/* --- Grundgerüst --- */

/* Breiter als in KiPic: Der Fokus-Picker und vier Formatkacheln nebeneinander
   passen in 960 px nicht ohne Umbruch — und ein umgebrochener Formatsatz liest
   sich nicht mehr als eine Reihe. */
main { max-width: 1120px; margin: 2rem auto 4rem; padding: 0 1.5rem; }

h1 {
  font-family: Georgia, serif;
  font-weight: 900;
  font-size: 1.6rem;
  color: var(--navy);
  margin: 0 0 0.4rem;
}
h2 {
  font-family: Georgia, serif;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--navy);
  margin: 1.8rem 0 0.7rem;
}
.unterzeile { color: var(--muted); margin: 0 0 1.6rem; max-width: 62ch; }

.karte {
  background: var(--weiss);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.3rem 1.4rem;
  margin-bottom: 1.2rem;
}

.hinweis, .fehler, .erfolg {
  border-radius: var(--radius);
  padding: 0.7rem 1rem;
  margin-bottom: 1.2rem;
  font-size: 0.92rem;
  border-left: 3px solid;
}
.hinweis { background: var(--gold-soft); border-color: var(--gold); }
.fehler  { background: #fdecea; border-color: var(--rot); color: var(--rot); }
.erfolg  { background: #e6f4ea; border-color: var(--gruen); color: var(--gruen); }

.klein { font-size: 0.85rem; color: var(--muted); }

/* --- Formularelemente --- */

label { font-size: 0.9rem; }
.feldname {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.35rem;
}

input[type=text], input[type=email], input[type=number], select, textarea {
  font: inherit;
  width: 100%;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--weiss);
  color: var(--dark);
}
input:focus, select:focus, textarea:focus {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
  border-color: var(--gold);
}
input[type=file] { font-size: 0.9rem; }

button, .btn {
  font: inherit;
  font-weight: 700;
  background: var(--navy);
  color: var(--weiss);
  border: none;
  border-radius: var(--radius);
  padding: 0.6rem 1.3rem;
  cursor: pointer;
  display: inline-block;
}
button:hover, .btn:hover { background: var(--navy-dark); text-decoration: none; }
button.gold { background: var(--gold); color: var(--dark); }
button.gold:hover { background: #d38f14; }
button.leise, .btn.leise {
  background: transparent;
  color: var(--navy);
  border: 1px solid var(--border);
  font-weight: 600;
}
button.leise:hover, .btn.leise:hover { background: var(--bg); }
form.inline { display: inline; }

/* --- Auswahlreihen --- */

.arten { display: flex; gap: 1.4rem; flex-wrap: wrap; margin-bottom: 0.9rem; }
.arten label { display: flex; align-items: center; gap: 0.4rem; cursor: pointer; }

.formate { display: flex; gap: 1.4rem; flex-wrap: wrap; }
.formate label { display: flex; align-items: center; gap: 0.4rem; cursor: pointer; }

/* --- Tabellen --- */

table { width: 100%; border-collapse: collapse; }
th, td {
  text-align: left;
  padding: 0.6rem 0.5rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.93rem;
}
th {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
td.zahl, th.zahl { text-align: right; font-variant-numeric: tabular-nums; }
tr.summe td { font-weight: 700; border-top: 2px solid var(--navy); }

.marke-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
}
.marke-badge.admin { background: var(--gold-soft); color: #8a5b06; }
.marke-badge.aus { background: #fdecea; color: var(--rot); }
.marke-badge.ok { background: #e6f4ea; color: var(--gruen); }

/* --- Einstellungen je Kennzeichnungsart --- */

.zwei { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.drei { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0.8rem; }
.feld { margin-bottom: 0.9rem; }

footer {
  max-width: 1120px;
  margin: 0 auto 3rem;
  padding: 0 1.5rem;
  font-size: 0.8rem;
  color: var(--muted);
}

@media (max-width: 760px) {
  .motiv-raster { grid-template-columns: 1fr; }
  .kachel .box { max-width: 100%; }
  .zwei, .drei { grid-template-columns: 1fr; }
  main { margin-top: 1.2rem; }
}

/* --- Motiv im Stapel: Fokus-Picker und Formatkacheln ------------------- */

.motiv-kopf {
  font-size: 0.85rem;
  color: var(--muted);
  word-break: break-all;
  margin-bottom: 0.8rem;
}

.motiv-raster {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 1.4rem;
  align-items: start;
}

/* Der Picker zeigt das ganze Bild — nur dann bildet die Klickposition den
   Fokuspunkt exakt ab. Wäre er selbst beschnitten, träfe der Mandant eine
   andere Stelle als die, die er sieht. */
.picker {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg);
  cursor: crosshair;
  touch-action: none;
  user-select: none;
}
.picker img { display: block; width: 100%; pointer-events: none; }

.punkt {
  position: absolute;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border-radius: 50%;
  border: 2px solid var(--weiss);
  background: var(--gold);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.45);
  pointer-events: none;
}

.kacheln {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-bottom: 1.2rem;
}
.kachel { font-size: 0.72rem; color: var(--muted); text-align: center; }
.kachel .box {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg);
  margin-bottom: 0.25rem;
}

/* Safe-Zones: nur Anzeige. Sie verändern die Ausgabedatei nicht — sie zeigen,
   wo die Plattform später ihre eigene Oberfläche darüberlegt. */
.zone {
  position: absolute;
  left: 0;
  right: 0;
  background: rgba(176, 42, 55, 0.28);
  pointer-events: none;
}
.zone.oben { top: 0; }
.zone.unten { bottom: 0; }

.sammel { display: flex; gap: 1.4rem; align-items: center; flex-wrap: wrap; }
.sammel label { display: flex; align-items: center; gap: 0.5rem; }
.sammel select { width: auto; }

/* --- Logo-Proben und Admin-Probebilder -------------------------------- */

.logo-proben { display: flex; gap: 1rem; flex-wrap: wrap; margin: 0.6rem 0 1rem; }
.probe {
  padding: 1.4rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 12rem;
}
.probe img { max-height: 70px; max-width: 220px; display: block; }
.probe.hell { background: var(--weiss); }
.probe.dunkel { background: var(--dark); border-color: var(--dark); }

.proben { display: flex; gap: 1rem; flex-wrap: wrap; align-items: flex-start;
           margin: 0.8rem 0; }
.proben figure { margin: 0; text-align: center; }

/* Gleiche BREITE, nicht gleiche Höhe. Das ist kein Layoutgeschmack: So werden
   die Formate auch auf dem Telefon angezeigt. Standen sie hier auf gleicher
   Höhe, wirkte ein höhenbezogenes Logo überall gleich groß — genau die
   Täuschung, durch die das Label in 1.91:1 unbemerkt zu klein blieb. */
.proben img {
  width: 190px;
  height: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: block;
}
.proben figcaption { font-size: 0.72rem; color: var(--muted); margin-top: 0.3rem; }

h3 {
  font-family: Georgia, serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--navy);
  margin: 1.4rem 0 0.5rem;
}

/* --- ScenePic: Batch-Ansicht --- */
.balkenwerk { background: var(--border); border-radius: 4px; height: 10px; overflow: hidden; margin-bottom: .6rem; }
.balkenwerk > div { background: var(--gold); height: 100%; transition: width .4s; }
.aktionen { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.motivgruppe { margin: 1.4rem 0; }
.motivgruppe .motiv-kopf { display: flex; align-items: center; gap: .7rem; margin-bottom: .5rem; }
.vorlage { width: 48px; height: 48px; object-fit: contain; background: var(--weiss); border: 1px solid var(--border); border-radius: var(--radius); }
.karten { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: .8rem; }
.bildkarte { margin: 0; background: var(--weiss); border: 3px solid transparent; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.bildkarte img { width: 100%; display: block; }
.bildkarte:focus { outline: none; border-color: var(--navy); }
.bildkarte.gut { border-color: var(--gruen); }
.bildkarte.aus { border-color: var(--rot); }
.bildkarte.aus img { opacity: .35; }
.bildkarte figcaption { display: flex; justify-content: space-between; align-items: center; padding: .3rem .5rem; font-size: .85rem; }
.knoepfe button { padding: .15rem .6rem; font-size: .8rem; }
pre.prompt { white-space: pre-wrap; background: var(--bg); padding: .8rem; border-radius: var(--radius); font-size: .85rem; }
kbd { background: var(--weiss); border: 1px solid var(--border); border-radius: 3px; padding: 0 .35rem; }
td input[type=text] { width: 100%; }

/* --- Hintergründe / Platzierung --- */
.platzierung { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 1rem; align-items: start; }
.vorschau-box { padding: .5rem; }
@media (max-width: 800px) { .platzierung { grid-template-columns: 1fr; } }

/* --- Anbieter-Umschalter --- */
.umschalter { display: inline-flex; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--weiss); }
.umschalter label { margin: 0; padding: .5rem .9rem; cursor: pointer; display: flex; gap: .4rem; align-items: center; }
.umschalter label + label { border-left: 1px solid var(--border); }
.umschalter input { margin: 0; }
.umschalter label:has(input:checked) { background: var(--navy); color: var(--weiss); }
.umschalter label:has(input:checked) .klein { color: #ffd9a0; }
.drei.vier { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
