/* ==========================================================================
   Inter – self-hosted (SIL Open Font License)
   ========================================================================== */

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('../fonts/inter-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('../fonts/inter-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ==========================================================================
   Site shell – navigation, layout, typography
   ========================================================================== */

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: #f8fafc;
  color: #2d3748;
  min-height: 100vh;
  padding: 0;
  line-height: 1.6;
}

.top-bar {
  background: #20293b;
  height: 6px;
  width: 100%;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 100;
}

.nav { padding: 1rem; margin-top: 6px; }

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand { display: block; height: 40px; }
.nav-brand img { height: 100%; width: auto; display: block; }
.nav-brand:hover { opacity: 0.7; }

.nav-links { display: flex; gap: 2rem; }

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: #718096;
  text-decoration: none;
  transition: color 0.2s;
}

.nav-links a:hover { color: #20293b; }
.nav-links a.active { color: #20293b; font-weight: 600; }

.breadcrumbs {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1rem 0.5rem;
  font-size: 0.85rem;
}

.breadcrumbs a { color: #718096; text-decoration: none; }
.breadcrumbs a:hover { color: #20293b; text-decoration: underline; }
.breadcrumbs span.sep { color: #cbd5e1; margin: 0 0.5rem; }
.breadcrumbs .current { color: #20293b; font-weight: 500; }

.container {
  max-width: 720px;
  margin: 0 auto;
  padding: 1rem 1rem 2rem;
}

.container--about { max-width: 800px; padding-bottom: 3rem; }
.container--doku { max-width: 800px; padding-bottom: 3rem; }
.container--tools-index { padding-bottom: 3rem; }
.container--tool { max-width: 1100px; }

.header { margin-bottom: 2rem; }

.header h1 {
  font-size: 1.75rem;
  font-weight: 300;
  color: #20293b;
  margin-bottom: 0.5rem;
}

.header p { color: #718096; font-size: 0.875rem; }

.header--center { text-align: center; }

.header--tools-index p { font-size: 0.95rem; }

.footer {
  text-align: center;
  margin-top: 2rem;
  color: #94a3b8;
  font-size: 0.75rem;
}

.footer a { color: #20293b; text-decoration: none; }
.footer a:hover { text-decoration: underline; }

.footer--bordered {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid #e2e8f0;
}

/* ==========================================================================
   UI components – cards, forms, buttons, outputs
   ========================================================================== */

.card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

.card--compact { padding: 1.5rem; }

.form-group { margin-bottom: 1.25rem; }

.form-label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #718096;
  margin-bottom: 0.5rem;
}

.form-label .hint { text-transform: none; color: #94a3b8; margin-left: 0.5rem; }
.form-label .required { color: #e53e3e; }
.form-label .param { color: #a0aec0; text-transform: none; margin-left: 0.5rem; }

.form-input,
.form-select,
.method-select {
  width: 100%;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  color: #2d3748;
  font-size: 0.95rem;
  transition: all 0.2s;
}

.form-input::placeholder { color: #a0aec0; }

.form-input:focus,
.form-select:focus,
.method-select:focus {
  outline: none;
  border-color: #20293b;
  box-shadow: 0 0 0 3px rgba(32, 41, 59, 0.15);
  background: #fff;
}

.method-select { cursor: pointer; }

.form-textarea {
  width: 100%;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  color: #2d3748;
  resize: vertical;
  min-height: 160px;
  line-height: 1.5;
  transition: all 0.2s;
}

.form-textarea::placeholder { color: #a0aec0; }

.form-textarea:focus {
  outline: none;
  border-color: #20293b;
  box-shadow: 0 0 0 3px rgba(32, 41, 59, 0.15);
  background: #fff;
}

.form-textarea--mono {
  font-family: monospace;
  min-height: 150px;
}

.range-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.range-row .form-group { flex: 1; min-width: 120px; margin-bottom: 0; }

.primary-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: #20293b;
  border: none;
  border-radius: 0.5rem;
  color: #fff;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.primary-btn:hover { background: #3d4a63; }

.primary-btn:disabled {
  background: #e2e8f0;
  color: #94a3b8;
  cursor: not-allowed;
  transform: none;
}

.primary-btn--large {
  padding: 0.75rem 2rem;
  font-size: 0.9rem;
  font-weight: 600;
}

.primary-btn--large:hover:not(:disabled) { transform: translateY(-1px); }

.secondary-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.75rem 1.25rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  color: #4a5568;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.secondary-btn:hover { border-color: #20293b; color: #20293b; }

.pick-actions { margin: 1.5rem 0; }

.mode-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.mode-tab {
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  background: #f1f5f9;
  color: #718096;
}

.mode-tab:hover { background: #e2e8f0; color: #2d3748; }
.mode-tab.active { background: #20293b; color: #fff; }

.panel { display: none; }
.panel.active { display: block; }

.result-section {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e2e8f0;
}

.result-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #718096;
  margin-bottom: 0.5rem;
}

.result-value {
  font-size: 1.5rem;
  font-weight: 600;
  color: #20293b;
  padding: 1rem;
  background: #f1f5f9;
  border-radius: 0.5rem;
  border: 1px solid #e2e8f0;
  min-height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.result-value.empty {
  color: #94a3b8;
  font-weight: 400;
  font-size: 0.95rem;
}

.divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.5rem 0;
}

.divider-line { flex: 1; height: 1px; background: #e2e8f0; }

.divider-text {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #94a3b8;
}

.output { padding: 1rem 0 0; }

.output-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.output-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #718096;
}

.output-actions { display: flex; gap: 0.5rem; }

.copy-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.75rem;
  background: #20293b;
  border: none;
  border-radius: 0.5rem;
  color: #fff;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.copy-btn:hover { background: #3d4a63; }

.copy-btn:disabled {
  background: #e2e8f0;
  color: #94a3b8;
  cursor: not-allowed;
}

.copy-btn.copied { background: #10b981; }

.copy-btn--outline {
  padding: 0.35rem 0.75rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.4rem;
  background: #fff;
  color: #4a5568;
  font-size: 0.75rem;
}

.copy-btn--outline:hover:not(:disabled) { border-color: #20293b; color: #20293b; background: #fff; }
.copy-btn--outline.copied { border-color: #38a169; color: #38a169; background: #fff; }
.copy-btn--outline:disabled {
  background: #fff;
  border-color: #e2e8f0;
  color: #94a3b8;
}

.output-box {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  padding: 1rem;
  min-height: 60px;
  word-break: break-all;
}

.output-code,
.output-url {
  font-family: monospace;
  font-size: 0.9rem;
  color: #20293b;
}

.output-url { font-size: 0.875rem; }

.output-placeholder { color: #94a3b8; font-size: 0.875rem; }

.output-box.has-output .output-placeholder { display: none; }

.hidden { display: none !important; }

.is-invisible { visibility: hidden; }

.icon-btn {
  padding: 0.5rem;
  background: none;
  border: none;
  color: #718096;
  cursor: pointer;
  border-radius: 0.375rem;
  transition: all 0.2s;
}

.icon-btn:hover { color: #2d3748; background: #edf2f7; }

.actions {
  display: flex;
  justify-content: flex-end;
  margin: 1rem 0;
}

.actions--center {
  justify-content: center;
  margin: 1.5rem 0 1rem;
}

/* ==========================================================================
   Legal pages – Impressum & Datenschutz
   ========================================================================== */

.legal-content {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

.legal-content h2 {
  font-size: 1rem;
  font-weight: 600;
  color: #20293b;
  margin: 1.75rem 0 0.75rem;
}

.legal-content h2:first-child { margin-top: 0; }

.legal-content p,
.legal-content address,
.legal-content ul {
  font-size: 0.9rem;
  color: #4a5568;
  margin-bottom: 0.75rem;
}

.legal-content address { font-style: normal; }

.legal-content ul { padding-left: 1.25rem; }

.legal-content li { margin-bottom: 0.35rem; }

.legal-content h3 {
  font-size: 0.95rem;
  font-weight: 600;
  color: #20293b;
  margin: 1.25rem 0 0.5rem;
}

.legal-toc { list-style: none; padding-left: 0; }

.legal-toc a {
  color: #4a5568;
  text-decoration: none;
}

.legal-toc a:hover { color: #20293b; text-decoration: underline; }

.legal-definitions dt {
  font-size: 0.9rem;
  font-weight: 600;
  color: #20293b;
  margin-top: 0.75rem;
}

.legal-definitions dd {
  font-size: 0.9rem;
  color: #4a5568;
  margin: 0.25rem 0 0;
}

.legal-content p:last-child,
.legal-content ul:last-child { margin-bottom: 0; }

.legal-content a { color: #20293b; }
