/* ==========================================================
   🌐 Ouhud QR – Globales Stylesheet (vereinheitlicht)
   Struktur:
   1. Variablen & Grundlayout
   2. Header & Sidebar
   3. Main Content & Footer
   4. Buttons & Formulare
   5. QR-Generatorseiten (zentral, alle Typen)
   6. Spezialseiten (vCard, Mini)
   7. QR-Stil-Auswahl
   8. Responsive Design
   ========================================================== */


/* === 1. VARIABLEN === */
:root {
  --primary: #0d2a78;
  --primary-dark: #0b1742;
  --accent: #2563eb;
  --bg: #f8f9fc;
  --text: #1e293b;
  --text-light: #e2e8f0;
  --muted: #64748b;
  --white: #ffffff;
}


/* === 2. GRUNDLAYOUT === */
html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  font-family: "Inter", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
}

body {
  opacity: 1;
  transition: opacity 0.25s ease-in-out;
}
body.loaded { opacity: 1; }
body.fade { opacity: 0; }


/* === 3. HEADER === */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 60px;
  background: var(--primary-dark);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.8rem;
  z-index: 1100;
  box-shadow: 0 2px 10px rgba(0,0,0,0.25);
}
.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.logo img { width: 28px; height: 28px; }
.logo-text { font-weight: 700; font-size: 1.2rem; }
.menu-toggle {
  display: none;
  font-size: 1.8rem;
  cursor: pointer;
  color: white;
}


/* === 4. SIDEBAR === */
.sidebar {
  position: fixed;
  top: 60px; left: 0;
  width: 230px;
  height: calc(100vh - 60px);
  background: #0b1742;
  color: var(--text-light);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 2px 0 8px rgba(0,0,0,0.25);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.2) transparent;
  z-index: 1050;
}
.sidebar::-webkit-scrollbar { width: 6px; }
.sidebar::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.2);
  border-radius: 10px;
}
.qr-tabs, .main-tabs { display: flex; flex-direction: column; }
.tab {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.9rem 1.2rem;
  color: #cbd5e1;
  border-left: 3px solid transparent;
  transition: all 0.25s ease;
  font-weight: 500;
  text-decoration: none;
}
.tab:hover {
  background: #10225a;
  color: #fff;
  transform: translateX(4px);
}
.tab.active {
  background: #0d2a78;
  border-left: 3px solid var(--accent);
  color: #fff;
  font-weight: 600;
  box-shadow: inset 0 0 10px rgba(37,99,235,0.25);
}


/* === 5. MAIN CONTENT === */
.main-content {
  margin-left: 230px;
  padding: 4rem 3rem 2rem 3rem;
  min-height: 0;
  background: var(--bg);
  transition: margin-left 0.3s ease;
}
.guest-content {
  margin-left: 0;
  padding: 3rem 2rem;
  background: var(--bg);
  min-height: 0;
}


/* === 6. FOOTER === */
footer.footer {
  background: var(--primary);
  color: white;
  text-align: center;
  padding: 1.2rem 0;
  margin-top: 3rem;
  font-size: 0.95rem;
  border-top: 1px solid rgba(255,255,255,0.15);
}
footer.footer a {
  color: #cbd5f5;
  text-decoration: none;
  margin: 0 6px;
  font-weight: 500;
}
footer.footer a:hover { color: #fff; text-decoration: underline; }


/* === 7. BUTTONS & FORMULARE === */
.btn {
  display: inline-block;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
  padding: 1rem 2rem;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 3px 10px rgba(13, 42, 120, 0.2);
  text-align: center;
}
.btn:hover {
  background: linear-gradient(135deg, var(--accent), var(--primary));
  transform: translateY(-2px);
}
.btn-secondary {
  background: linear-gradient(135deg, #1e3a8a, #0d2a78);
}
.btn-secondary:hover {
  background: linear-gradient(135deg, #0d2a78, #1e3a8a);
}
input, textarea, select {
  width: 100%;
  padding: 0.9rem 1rem;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  font-size: 1rem;
  background: #f9fafb;
  color: #1e293b !important;
  transition: all 0.25s ease;
}
input::placeholder,
textarea::placeholder,
select::placeholder {
  color: #94a3b8 !important;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.2);
}


/* === 8. QR-GENERATOR SEITEN (ALLE zentral) === */
.qr-generator,
.qr-generator.wifi-generator,
.qr-generator.vcard-generator,
.qr-generator.pdf-generator,
.qr-generator.social-generator {
  max-width: 940px;
  margin: 4rem auto;
  background: var(--white);
  padding: 3rem;
  border-radius: 24px;
  box-shadow: 0 10px 35px rgba(13, 42, 120, 0.08);
  border: 1px solid rgba(0, 0, 0, 0.03);
}
.qr-generator h1,
.qr-generator.wifi-generator h1 {
  color: var(--primary);
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.75rem;
}
.qr-generator .subtitle {
  color: var(--muted);
  text-align: center;
  margin-bottom: 2.8rem;
  font-size: 1.1rem;
  line-height: 1.6;
}
.form-group { margin-bottom: 1.6rem; }
label {
  display: block;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.5rem;
}
.qr-generator input,
.qr-generator select,
.qr-generator textarea {
  background: #f9fafb;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 0.9rem 1rem;
  width: 100%;
  color: #1e293b !important;
}
.qr-generator input::placeholder,
.qr-generator textarea::placeholder,
.qr-generator select::placeholder {
  color: #94a3b8 !important;
}
.qr-generator input:focus,
.qr-generator select:focus,
.qr-generator textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.2);
  outline: none;
}

/* Checkbox & Unterbereiche */
.qr-generator .form-group.checkbox label {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 500;
  color: var(--text);
}

/* Ergebnisfeld */
.qr-result {
  margin-top: 2rem;
  background: #f3f6ff;
  border-radius: 16px;
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 4px 15px rgba(13,42,120,0.05);
}


/* === 9. SPEZIAL-SEITEN === */
.vcard-modern,
.vcard-mini {
  display: flex;
  justify-content: center;
  align-items: center;
  background: var(--bg);
  padding: 4rem 1rem;
}
.vcard-card {
  background: var(--white);
  border-radius: 24px;
  box-shadow: 0 10px 35px rgba(13, 42, 120, 0.08);
  max-width: 420px;
  width: 100%;
  text-align: center;
  padding: 2.5rem;
}
.vcard-card h1 {
  color: var(--primary);
  font-size: 1.6rem;
  margin-bottom: 0.3rem;
}


/* === 10. QR-STIL-AUSWAHL === */
.qr-style-section {
  padding: 4rem 2rem;
  background: linear-gradient(180deg, #f8f9fc, #ffffff);
  text-align: center;
}
.style-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  max-width: 1100px;
  margin: 0 auto 3rem;
}
.style-card {
  background: #fff;
  border-radius: 1.2rem;
  box-shadow: 0 4px 16px rgba(13, 42, 120, 0.08);
  padding: 1.5rem;
  transition: all 0.3s ease;
}
.style-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(13,42,120,0.15);
}


/* === 11. RESPONSIVE DESIGN === */
@media (max-width: 900px) {
  .menu-toggle { display: block; }
  .sidebar { left: -240px; transition: left 0.3s ease; }
  .sidebar.show { left: 0; }
  .main-content, .guest-content { margin-left: 0; padding: 1.5rem; }
  .qr-generator { padding: 2rem; max-width: 90%; }
  .btn { width: 100%; }
  .qr-generator h1 { font-size: 1.7rem; }
  .qr-generator .subtitle { font-size: 1rem; margin-bottom: 2rem; }
  .style-grid { grid-template-columns: 1fr; }
}
