/* OpenRanking – UI Basis
   Light/Dark wird über <html class="light|dark"> gesteuert
*/

:root {
  --font:
    "Manrope", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;

  --primary: #2563eb;

  --bg: #f8fafc;
  --pattern-bg: #f8fafc;
  --pattern-dot: rgba(37, 99, 235, 0.06);

  --text: #1f2937;
  --muted: #64748b;

  --card: #ffffff;
  --border: #e2e8f0;

  --input-bg: #f8fafc;
  --input-border: #e2e8f0;
  --input-text: #0f172a;
  --placeholder: rgba(100, 116, 139, 0.8);

  --shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.18);
  --shadow-soft: 0 12px 24px -12px rgba(15, 23, 42, 0.12);

  --radius-xl: 16px;
  --radius-lg: 12px;
  --radius-md: 10px;

  --focus: rgba(37, 99, 235, 0.18);
}

html.dark {
  --bg: #0f172a;
  --pattern-bg: #0f172a;
  --pattern-dot: rgba(37, 99, 235, 0.1);

  --text: #e2e8f0;
  --muted: #94a3b8;

  --card: #0b1224;
  --border: #1e293b;

  --input-bg: rgba(30, 41, 59, 0.35);
  --input-border: #334155;
  --input-text: #e2e8f0;
  --placeholder: rgba(148, 163, 184, 0.7);

  --shadow: none;
  --shadow-soft: none;

  --focus: rgba(37, 99, 235, 0.22);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
}

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

.pattern-bg {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;

  background-color: var(--pattern-bg);
  background-image: radial-gradient(var(--pattern-dot) 1px, transparent 1px);
  background-size: 32px 32px;
}

.container {
  width: 100%;
  max-width: 420px;
}

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 28px;
}

.brand-inner {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.2);
}

.brand-title {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand-title strong {
  font-size: 22px;
  letter-spacing: -0.02em;
}

.brand-sub {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}

.brand-pill {
  height: 4px;
  width: 34px;
  background: var(--primary);
  border-radius: 999px;
}

.brand-tag {
  font-size: 10px;
  font-weight: 800;
  color: color-mix(in srgb, var(--muted) 90%, transparent);
  text-transform: uppercase;
  letter-spacing: 0.2em;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
  box-shadow: var(--shadow);
}

.card h1 {
  margin: 0;
  font-size: 22px;
  letter-spacing: -0.02em;
}

.card p {
  margin: 10px 0 0 0;
  color: var(--muted);
  font-size: 14px;
}

.form {
  margin-top: 22px;
  display: grid;
  gap: 16px;
}

.label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

label {
  font-size: 13px;
  font-weight: 800;
  color: color-mix(in srgb, var(--text) 92%, transparent);
}

.input-wrap {
  position: relative;
}

.input-icon-left,
.input-icon-right {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: color-mix(in srgb, var(--muted) 75%, transparent);
  display: grid;
  place-items: center;
}

.input-icon-left {
  left: 12px;
}
.input-icon-right {
  right: 10px;
}

.input {
  width: 100%;
  padding: 12px 44px 12px 44px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--input-border);
  background: var(--input-bg);
  color: var(--input-text);
  outline: none;
  transition:
    box-shadow 0.15s ease,
    border-color 0.15s ease;
}

.input::placeholder {
  color: var(--placeholder);
}

.input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--focus);
}

.icon-button {
  border: 0;
  background: transparent;
  padding: 8px;
  border-radius: 10px;
  cursor: pointer;
  color: color-mix(in srgb, var(--muted) 75%, transparent);
}

.icon-button:hover {
  color: color-mix(in srgb, var(--text) 85%, transparent);
}

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.checkbox {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
}

.checkbox input {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
}

.button {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-lg);
  border: 0;
  background: var(--primary);
  color: #fff;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: var(--shadow-soft);
}

.button:hover {
  filter: brightness(0.95);
}
.button:focus {
  outline: none;
  box-shadow: 0 0 0 4px var(--focus);
}

.hr {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid color-mix(in srgb, var(--border) 80%, transparent);
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

.footer {
  margin-top: 18px;
  display: grid;
  gap: 14px;
  justify-items: center;
}

.footer-links {
  display: flex;
  gap: 18px;
  font-size: 12px;
  color: color-mix(in srgb, var(--muted) 85%, transparent);
}

.footer-links a {
  color: inherit;
}
.footer-links a:hover {
  color: var(--primary);
}

.hinweis {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 80%, transparent);
}

/* Theme-Schalter */
.theme-toggle {
  position: fixed;
  top: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card) 92%, transparent);
  color: var(--text);
  padding: 8px 10px;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: var(--shadow-soft);
}

.theme-toggle span {
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
}
