/* ========= Nugget & Friends – Layout & Style (Bootstrap 4.6, Cerulean) ========= */

/* ---------- Farben & Grundwerte ---------- */
:root{
  --nf-brand:   #2fa4e7;   /* Cerulean Primary */
  --nf-ink:     #0f172a;   /* Text dunkel */
  --nf-muted:   #64748b;   /* Text mutiert */
  --nf-bg-soft: #f7fbff;   /* sehr helles Blau */
  --nf-bg-soft2:#eef6fb;   /* Verlauf unten */
  --nf-border:  #dce9f5;   /* zarter Rand */
}

/* ---------- Seite ---------- */
body{
  background: linear-gradient(180deg, var(--nf-bg-soft) 0%, var(--nf-bg-soft2) 100%);
  color: var(--nf-ink);
}

/* ---------- Karten-Layout: Info links (schmal) + Formular rechts (dominant) ---------- */
.nf-layout{
  max-width: 1150px;
  margin: 2.5rem auto;
  display: grid;
  grid-template-columns: 280px 1fr;
  grid-gap: 2rem;
}

/* ---------- Info-Karte (links) ---------- */
.nf-info{
  background: linear-gradient(180deg, #f3f9ff 0%, #ffffff 90%);
  border: 1px solid var(--nf-border);
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
  box-shadow: 0 2px 12px rgba(30, 64, 175, 0.08);
  font-size: .93rem;
  height: max-content;
}
.nf-info h5{ color: var(--nf-brand); font-weight: 700; margin-bottom: 1rem; }
.nf-info dt{ color: #334155; font-weight: 500; margin-bottom: .15rem; }
.nf-info dd{ color: #111827; font-weight: 600; margin-bottom: .45rem; }
.nf-info ul{ list-style: "✓ "; padding-left: 1rem; color: #334155; margin-bottom: 1rem; }
.nf-info small{ color: var(--nf-muted); }

/* ---------- Formular-Karte (rechts) ---------- */
.nf-form{
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  border: 1px solid var(--nf-border);
  border-radius: 1rem;
  box-shadow: 0 8px 35px rgba(30, 64, 175, 0.06);
  padding: 2rem 2.25rem;
  transition: box-shadow .2s ease-in-out;
}
.nf-form:hover{ box-shadow: 0 12px 45px rgba(30, 64, 175, 0.08); }
.nf-form h3{ color: var(--nf-brand); font-weight: 700; margin-bottom: 1.25rem; }

/* ---------- Kompakt-Stil für Bootstrap 4-Controls ---------- */
.form-compact .form-group{ margin-bottom: .9rem; }
.form-compact .form-control,
.form-compact .custom-select{
  padding: .55rem .75rem;
  font-size: .95rem;
  border-radius: .5rem;
}
.form-compact .col-form-label{ margin-bottom: .25rem; font-size: .9rem; color: #1e293b; }

/* Legenden (Crispy Fieldsets) optional ausblenden, falls doppelt */
.nf-form legend{ display:block; font-weight: 600; font-size: 1.25rem; margin-bottom: .75rem; color: var(--nf-brand);}

/* ---------- Buttons ---------- */
.btn-brand{
  background: linear-gradient(180deg, #42b4f5 0%, var(--nf-brand) 100%);
  border: none;
  font-weight: 600;
  color: #fff;
  border-radius: .6rem;
  transition: all .2s ease-in-out;
}
.btn-brand:hover{
  filter: brightness(1.05);
  box-shadow: 0 4px 10px rgba(47,164,231,.30);
}

/* ---------- Helfer ---------- */
.nf-sep{ margin: 1.5rem 0 1rem; opacity: .5; }
.nf-subtitle{ margin-bottom: .5rem; }
.nf-chip{ display:inline-block; margin:.5rem 0 .25rem; font-weight:600; color:var(--nf-brand); }
.nf-form form{ margin-bottom: 0; } /* keine Extra-Lücke unterm Formular */

/* ---------- Variante: ohne Info-Karte (zentrierte Einzelkarte) ---------- */
.nf-layout.single{
  display: flex;
  justify-content: center;
  max-width: 1150px;
  margin: 2.5rem auto;
}
.nf-layout.single .nf-form{
  max-width: 650px;   /* Standard: schmale Einzelkarte (z. B. kurze Bestätigung) */
  width: 100%;
}

/* ---------- Variante: breite Einzelkarte (Impressum/Datenschutz) exakt wie Gesamtbreite ---------- */
.nf-layout.single.wide{
  max-width: 1150px;  /* exakt wie .nf-layout */
  margin: 2.5rem auto;
  display: flex;
  justify-content: center;
}
.nf-layout.single.wide .nf-form{
  width: 100%;
  max-width: 1150px;  /* gleiche innere Breite wie beide Karten zusammen */
  padding: 2rem 2.5rem;
  border: 1px solid var(--nf-border);
  border-radius: 1rem;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  box-shadow: 0 8px 35px rgba(30, 64, 175, 0.06);
}

/* ---------- Responsive ---------- */
@media (max-width: 992px){
  .nf-layout{ grid-template-columns: 1fr; max-width: 95%; }
  .nf-info{ order: 2; }
  .nf-layout.single, .nf-layout.single.wide{ max-width: 95%; }
  .nf-layout.single .nf-form,
  .nf-layout.single.wide .nf-form{ max-width: 100%; }
}


/* ---- Gleich hohe Label -> Felder in einer Reihe fluchten wieder ---- */
/* Ab md-Viewport: Labels erhalten eine Mindesthöhe, damit Inputs nebeneinander
   immer auf gleicher Höhe starten – egal, ob ein Label 1 oder 2 Zeilen hat. */
@media (min-width: 768px) {
  .form-compact .form-group > label,
  .form-compact .col-form-label,
  .form-compact .control-label {        /* crispy / BS4 Varianten */
    display: flex;
    align-items: flex-end;
    min-height: 2.2rem;                 /* ggf. 2.4rem, wenn deine Label größer sind */
    margin-bottom: .35rem;
    line-height: 1.2;
  }
}

/* ---- Weicheres Feld-Feeling (Rand/Fokus) ---- */
.form-compact .form-control,
.form-compact .custom-select {
  border-color: #e3eef7;
  border-radius: .6rem;
}
.form-compact .form-control:focus,
.form-compact .custom-select:focus {
  border-color: #8fd3fb;
  box-shadow: 0 0 0 .2rem rgba(47,164,231,.15);
  outline: 0;
}

/* Hilfetexte / kleine Hinweise unter Feldern */
.form-compact .form-text,
.form-compact .help-block {
  color: #6b7280;
  font-size: .85rem;
  margin-top: .25rem;
}

/* Etwas mehr Luft zwischen Spalten auf md+ */
@media (min-width: 768px) {
  .form-compact .form-row > [class*="col-"] { padding-right: 14px; padding-left: 14px; }
}

/* --- Fix: gleiche Breite wie Footer-Strich auch im Docker-Build --- */
body.container,
body > .container {
  max-width: 1150px;
  margin: 0 auto;
}
@media (max-width: 991.98px) {
  .nf-info-wrapper { width: 100%; }
  .nf-info-wrapper .btn { width: 100%; }
  .nf-info { margin-bottom: 1rem; }
}
@media (min-width: 992px) {
  #infoCollapse.collapse {
    display: block !important;
    height: auto !important;
    visibility: visible !important;
  }
}

/* Footer: gleich breit wie Inhalt & zentrierter Text */
.site-footer {
  background: transparent;
}

.site-footer .footer-inner {
  border-top: 1px solid var(--nf-border);
  max-width: 1150px;      /* exakt wie .nf-layout */
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
  text-align: center;     /* <--- sorgt für Zentrierung */
}


@media (max-width: 991.98px) {
  .site-footer .footer-inner {
    max-width: 95%;
    padding-left: 0;
    padding-right: 0;
  }
}

/* Mehr Platz für dynamische Mitreisenden-Formsets */
.form-row.align-items-start > .col-md-2 {
  flex: 0 0 25%;   /* statt 16.666% */
  max-width: 25%;
}
.form-row.align-items-start > .col-md-10 {
  flex: 0 0 75%;
  max-width: 75%;
}

/* Bei mittleren Bildschirmen trotzdem stacking erlauben */
@media (max-width: 768px) {
  .form-row.align-items-start > .col-md-2,
  .form-row.align-items-start > .col-md-10 {
    flex: 0 0 100%;
    max-width: 100%;
  }
}

/* Gleicher Stil wie Cerulean-Buttons (helles Blau mit Verlauf) */
.btn-primary {
  background-color: #33b5e5;
  background-image: linear-gradient(to bottom, #33b5e5, #0099cc);
  border: 1px solid #0099cc;
  color: #fff;
  font-weight: 500;
  border-radius: 6px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.2) inset;
  transition: background 0.15s ease-in-out;
}

.btn-primary:hover,
.btn-primary:focus {
  background-color: #0099cc;
  background-image: linear-gradient(to bottom, #0099cc, #33b5e5);
  border-color: #007fa3;
}

.btn-primary:active {
  background-color: #007fa3 !important;
  background-image: none !important;
  border-color: #006f92 !important;
}

/* Weiche Karte wie oben: gleicher Hintergrund, Radius, Schatten, Innenabstand */
.nf-softbox {
  background: #f6fbff;           /* sehr helles Blau wie oben */
  border-radius: 14px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
  padding: 18px;                  /* exakt: keine zweite Innenkarte nötig */
  border: 1px solid rgba(0, 139, 191, 0.08); /* hauchdünner Rand wie oben */
}

/* Headline-Stil wie oben links */
.nf-softbox .nf-title {
  color: #0b88c2;                 /* Cerulean-Primärton */
  font-weight: 700;
  margin-bottom: 12px;
}

/* Inputs wie im großen Formular rechts */
.nf-input {
  height: 40px;                   /* gleiche Höhe */
  border-radius: 10px;            /* gleich rund */
  border: 1px solid #dbe7f0;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
}

.nf-input:focus {
  border-color: #33b5e5;
  box-shadow: 0 0 0 0.2rem rgba(51,181,229,.2);
}

/* Label klein & ruhig wie rechts */
.nf-label {
  font-size: .9rem;
  font-weight: 600;
  color: #6c8aa0;
  margin-bottom: .25rem;
}

/* Cerulean-Button weich, wie dein „Speichern“ */
.btn-cerulean {
  display: inline-block;
  width: 100%;
  border-radius: 24px;
  border: 1px solid #0099cc;
  background-image: linear-gradient(to bottom, #33b5e5, #0099cc);
  color: #fff;
  font-weight: 600;
  padding: .5rem 1rem;
  transition: all .15s ease-in-out;
}

.btn-cerulean:hover,
.btn-cerulean:focus {
  background-image: linear-gradient(to bottom, #0099cc, #33b5e5);
  color: #fff;
}

/* Links unten dezent */
.nf-help a {
  font-size: .9rem;
  color: #1aa3d7;
}
.nf-help a:hover { text-decoration: underline; }

/* Cerulean-Blau, leicht verlaufend, aber eckiger */
.btn-cerulean {
  display: inline-block;
  width: 100%;
  border-radius: 6px;                        /* <-- eckiger */
  border: 1px solid #0099cc;
  background-image: linear-gradient(to bottom, #33b5e5, #0099cc);
  color: #fff;
  font-weight: 600;
  padding: .5rem 1rem;
  font-size: 0.95rem;
  transition: all .15s ease-in-out;
  box-shadow: 0 1px 0 rgba(255,255,255,0.25) inset;
}

.btn-cerulean:hover,
.btn-cerulean:focus {
  background-image: linear-gradient(to bottom, #0099cc, #33b5e5);
  color: #fff;
  text-decoration: none;
}

.btn-cerulean:active {
  background-color: #0086b3 !important;
  background-image: none !important;
  border-color: #007fa3 !important;
}

/* gleiche Optik wie nf-input, aber speziell für <select> */
select.nf-input {
  display: block;
  height: 44px;              /* etwas mehr Luft als 40px */
  line-height: 1.4;          /* kein Pixel-Equalizing */
  padding-top: .375rem;      /* vertikal zentriert */
  padding-bottom: .375rem;
  padding-right: 2.25rem;    /* Platz für den Pfeil rechts */
  /* falls deine nf-input 'appearance' nicht setzt, diese drei weglassen */
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}