:root {
    color-scheme: dark;
    --bg: #020617;
    --card: rgba(15, 23, 42, 0.94);
    --border: rgba(148, 163, 184, 0.35);
    --accent: #22c55e;
    --accent-soft: rgba(34, 197, 94, 0.2);
    --accent-strong: #a3e635;
    --text: #e5e7eb;
    --muted: #9ca3af;
    --danger: #fb7185;
    --shadow-soft: 0 22px 60px rgba(15, 23, 42, 0.9);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    min-height: 100vh;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at 0% 0%, rgba(56, 189, 248, 0.16), transparent 55%),
        radial-gradient(circle at 100% 100%, rgba(34, 197, 94, 0.18), transparent 55%),
        #020617;
    color: var(--text);
}

.orb {
    position: fixed;
    border-radius: 999px;
    filter: blur(50px);
    opacity: 0.5;
    z-index: -1;
}

.orb--1 {
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.9), transparent 60%);
    top: -70px;
    left: -70px;
}

.orb--2 {
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(34, 197, 94, 0.9), transparent 60%);
    bottom: -90px;
    right: -80px;
}

.page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.card {
    width: 100%;
    max-width: 480px;
    background: var(--card);
    border-radius: 26px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(20px) saturate(130%);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: "";
    position: absolute;
    inset: -40%;
    background:
        radial-gradient(circle at top, rgba(148, 163, 184, 0.14), transparent 55%),
        radial-gradient(circle at bottom, rgba(34, 197, 94, 0.12), transparent 60%);
    opacity: 0.7;
    pointer-events: none;
}

.card-inner {
    position: relative;
    z-index: 1;
    padding: 1.25rem 1.25rem 1rem;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.5);
    background: rgba(15, 23, 42, 0.9);
    font-size: 0.7rem;
    color: var(--muted);
    margin: 0 auto 0.6rem;
}

.pill-dot {
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: #22c55e;
    box-shadow: 0 0 10px rgba(34, 197, 94, 0.7);
}

h1 {
    font-size: 1.5rem;
    margin: 0.1rem 0 0.3rem;
    text-align: center;
    letter-spacing: 0.02em;
}

.page-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
}

.icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.35rem;
    height: 1.35rem;
    color: var(--accent-strong);
}

.icon svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

.subtitle {
    font-size: 0.84rem;
    color: var(--muted);
    text-align: center;
    margin-bottom: 1.1rem;
}

form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

label {
    display: block;
    font-size: 0.8rem;
    margin-bottom: 0.2rem;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

input {
    width: 100%;
    border-radius: 14px;
    border: 1px solid rgba(30, 64, 175, 0.35);
    background: radial-gradient(circle at top left, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.98));
    padding: 0.55rem 0.7rem;
    color: var(--text);
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.15s, box-shadow 0.15s, background 0.15s, transform 0.08s;
}

input::placeholder {
    color: rgba(148, 163, 184, 0.7);
}

input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 1px var(--accent-soft), 0 0 24px rgba(34, 197, 94, 0.25);
    background: #020617;
    transform: translateY(-0.5px);
}

.field-password .input-with-icon {
    position: relative;
    display: block;
    /* kein flex hier, Input bleibt Vollbreite */
}

.field-password .input-with-icon input {
    padding-right: 2.3rem;
    /* Platz für das Icon rechts */
}

/* Button-Icon im Feld */
.toggle-visibility {
    position: absolute;
    top: 50%;
    right: 0.55rem;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--muted);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    font-size: 1rem;
    line-height: 1;
    width: 1.6rem;
    height: 1.6rem;
}

/* Nur ein Icon gleichzeitig sichtbar */
.toggle-visibility .eye {
    display: none;
    pointer-events: none;
}

.toggle-visibility .eye-open {
    display: inline;
}

.toggle-visibility.is-visible .eye-open {
    display: none;
}

.toggle-visibility.is-visible .eye-closed {
    display: inline;
}



.hint {
    font-size: 0.72rem;
    color: var(--muted);
    margin-top: 0.25rem;
}

.required {
    color: var(--muted);
    font-size: 0.7rem;
}

.two-cols {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.6rem;
}

@media (min-width: 600px) {
    .card-inner {
        padding: 1.5rem 1.6rem 1.1rem;
    }

    .two-cols {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

button[type="submit"] {
    width: 100%;
    border: none;
    border-radius: 999px;
    padding: 0.65rem 1rem;
    margin-top: 0.25rem;
    background: radial-gradient(circle at 0% 0%, var(--accent-strong), var(--accent));
    color: #022c22;
    font-weight: 600;
    font-size: 0.93rem;
    cursor: pointer;
    box-shadow:
        0 10px 24px rgba(34, 197, 94, 0.6),
        0 0 0 1px rgba(22, 163, 74, 0.6);
    transition: transform 0.1s ease, box-shadow 0.1s ease, filter 0.1s ease, opacity 0.1s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

.btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-icon svg {
    width: 1.1em;
    height: 1.1em;
    fill: currentColor;
}

.btn-icon .spinner {
    display: none;
}

button[type="submit"].is-loading .btn-icon .send-icon {
    display: none;
}

button[type="submit"].is-loading .btn-icon .spinner {
    display: inline;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

button[type="submit"]:hover {
    transform: translateY(-1px);
    box-shadow:
        0 14px 30px rgba(34, 197, 94, 0.75),
        0 0 0 1px rgba(22, 163, 74, 0.8);
    filter: brightness(1.04);
}

button[type="submit"]:active {
    transform: translateY(0);
    box-shadow: 0 8px 20px rgba(34, 197, 94, 0.55);
}

button[type="submit"][disabled] {
    opacity: 0.6;
    cursor: wait;
    transform: none;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.9);
}

.status {
    margin-top: 0.55rem;
    font-size: 0.8rem;
    text-align: center;
    min-height: 1.2em;
}

.status.ok {
    color: #4ade80;
}

.status.error {
    color: var(--danger);
}

.legal {
    margin-top: 1.1rem;
    padding-top: 0.6rem;
    border-top: 1px dashed rgba(148, 163, 184, 0.5);
    font-size: 0.7rem;
    color: var(--muted);
    line-height: 1.4;
}

.legal a {
    color: var(--accent);
    text-decoration: none;
}

.legal a:hover {
    text-decoration: underline;
}

.hp-field {
    position: absolute;
    left: -9999px;
    opacity: 0;
    height: 0;
    width: 0;
    overflow: hidden;
}

@media (min-width: 900px) {
    .card {
        max-width: 520px;
    }
}

.site-footer {
    width: 100%;
    padding: 0.75rem 1.25rem 1.1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.75rem;
    color: var(--muted);
}

.site-footer-inner {
    width: 100%;
    max-width: 960px;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.site-footer-title {
    opacity: 0.85;
}

.site-footer-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    align-items: center;
    justify-content: center;
}

.site-footer-nav a {
    color: var(--accent);
    text-decoration: none;
}

.site-footer-nav a:hover {
    text-decoration: underline;
}

.site-footer-nav .sep {
    opacity: 0.5;
}

@media (min-width: 720px) {
    .site-footer-inner {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
}

body.legal-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    padding: 1.5rem 1rem;
}

.legal-wrapper {
    width: 100%;
    max-width: 880px;
    margin: 0 auto;
    background: var(--card);
    border-radius: 26px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(20px) saturate(130%);
    padding: 1.75rem 1.4rem 1.3rem;
}

@media (min-width: 720px) {
    .legal-wrapper {
        padding: 2rem 2rem 1.6rem;
    }
}

.legal-wrapper h1 {
    font-size: 1.6rem;
    margin: 0 0 0.8rem;
}

.legal-wrapper h2 {
    font-size: 1rem;
    margin: 1.2rem 0 0.3rem;
}

.legal-wrapper p,
.legal-wrapper ul,
.legal-wrapper li {
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--muted);
}

.legal-wrapper ul {
    padding-left: 1.1rem;
    margin: 0.4rem 0 0.6rem;
}

.legal-wrapper a {
    color: var(--accent);
    text-decoration: none;
}

.legal-wrapper a:hover {
    text-decoration: underline;
}
