/* === ROOT === */

:root {
	--font-size-body: medium;
	--font-size-base: 1rem;
	--footer-a-color: white;
	--font-size-larger: 0rem;
	--font-size-large: 0rem;
	
	--color-invert: black;
  
	--modal-login-background: #eeeff3;
	--modal-link-color: #4a90e2;
	--modal-link-color-hover: #0f3793;
  
	--results-preview-color: #4b4b4b;
	--search-gradient: linear-gradient(100deg, #6e6666, #83848a, #717282);
	
	--footer-link-hover: #00bcd4;
}

[data-theme="dark"] {
	--text-color: rgba(255,240,235,0.8);
	
	--modal-login-background: #121523;
	--modal-link-color: lightblue;
	--modal-link-color-hover: white;
	
	--color-invert: white;
  
	--results-preview-color: #ccc;
	--search-gradient: linear-gradient(100deg, #d5d5d5, var(--text-color), #afafaf);
}

[data-font-size="large"] {
	--font-size-body: large;
	--font-size-larger: 0.1rem;
	--font-size-large: 0.3rem;
}

::selection {
	background-color: #008ed9;
	color: white;
}

/* === Aufbau === */

html {
	scroll-behavior: smooth;
}

body {
	font-family: 'Segoe UI', Tahoma, Geneva, sans-serif;
	margin: 0;
	padding: 0;
	background: var(--bg-color);
	color: var(--text-color);
	overflow-x: hidden;
	font-size: var(--font-size-body);
	position: relative;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}

main {
	flex: 1;
}

/* === LOGIN OVERLAY === */

.modal-overlay {
	z-index: 1000;
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
}

.modal-content {
	background: var(--modal-login-background);
    margin: calc(4rem + 6%) auto;
    padding: 1.75rem 2.25rem;
	padding-top: 3.5rem;
    max-width: 700px;
    position: relative;
    border-radius: 8px;
}

.modal-content a {
	text-decoration: none;
	color: var(--modal-link-color);
	transition: color 0.1s ease;
}

.modal-content a:hover {
	text-decoration: underline;
	color: var(--modal-link-color-hover);
}

.login-form {
	text-align: left;
}

.login-form > :nth-child(2) {
	margin-top: 2rem;
	margin-bottom: 0.5rem;
}

/* Inputs */
.input-group {
    position: relative;
	margin-top: 1rem;
}

/* Label – Position & Animation */
.input-group label {
	position: absolute;
	top: -0.75rem;
	left: 0.75rem;
	background: var(--modal-login-background);
	border-radius: 999px;
    padding: 0 0.75rem;
    transition: 0.2s ease;
}

.modal-content input[type="text"],
.modal-content input[type="password"] {
	width: 100%;
	padding: 0.85rem 0.85rem;
	border: 1px solid #ccc;
	box-sizing: border-box;
	border-radius: 8px;
	font-size: 1rem;
	border: 1px solid #ccc;
    background: transparent;
    outline: none;
    transition: 0.3s ease;
	color: var(--text-color);
}

.modal-content input::placeholder {
	color: black;
	opacity: 0.7;
}

.modal-content input[type="text"]:focus,
.modal-content input[type="password"]:focus {
	border-color: #0072ff;
    box-shadow: 0 0 0 3px rgba(0,114,255,0.15);
}

.modal-content input[type="text"]:hover,
.modal-content input[type="password"]:hover {
	border-color: #0072ff;
}

/* Checkbox Container */
.modal-content .checkbox {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	margin: 0.8rem 0;
	font-size: 0.9rem;
	cursor: pointer;
	user-select: none;
}

/* Moderne Checkbox */
.modal-content .checkbox input[type="checkbox"] {
	appearance: none;
	width: 18px;
	height: 18px;
	margin-bottom: 0.15rem;
	border: 2px solid #ccc;
	border-radius: 4px;
	background: #fff;
	display: inline-block;
	cursor: pointer;
	position: relative;
	transition: all 0.2s ease;
}

.modal-content .checkbox input[type="checkbox"]:checked {
	border-color: #4a90e2;
	background: #4a90e2;
}

.modal-content .checkbox input[type="checkbox"]:checked::after {
	content: "✔";
	position: absolute;
	left: 1.5px;
	top: -4px;
	font-size: 0.9rem;
	color: white;
}

/* Button */
.modal-content .login-form button {
	width: 100%;
	margin-top: 0.35rem;
	padding: 0.85rem;
	background: linear-gradient(135deg, #4a90e2, #357abd);
	color: #fff;
	border: none;
	border-radius: 16px;
	font-size: 1rem;
	letter-spacing: 0.02rem;
	font-weight: 600;
	cursor: pointer;
	transition: box-shadow 0.2s ease;
	box-shadow: 0 4px 8px rgba(53, 122, 189, 0.2);
}

.modal-content .login-form button:hover {
	background: linear-gradient(135deg, #357abd, #2c639c);
	box-shadow: 0 6px 10px rgba(53, 122, 189, 0.25);
}

/* Register Link */
.modal-content .register {
	text-align: center;
	margin: 0;
	margin-top: 15px;
	font-size: 0.9rem;
}

/* = RESET PASS */

.modal-content .reset-password {
	text-align: center;
	margin: 0;
	margin-top: 0.5rem;
	font-size: 0.9rem;
}

.reset-password-input {
	display: none;
	margin-top: 1rem;
}

/* Formular-Layout - alles in einer Zeile */
.reset-password-input form {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.75rem;
}

.forgotPasswordForm-input {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	justify-content: center;
}

.forgot-password-form-input {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	justify-content: center;
}

.forgot-password-form-input label {
	margin: 0;
	align-content: center;
}

/* Label Styling */
.reset-password-input label {
	font-weight: 600;
	font-size: 1rem;
	white-space: nowrap; /* Label bleibt kompakt */
}

/* Input Styling */
.reset-password-input input[type="email"] {
	padding: 8px 10px;
	font-size: 1rem;
	border: 1.8px solid #ddd;
	border-radius: 10px;
	outline-offset: 2px;
	transition: border-color 0.3s ease;
	max-width: 200px;
}

.reset-password-input input[type="email"]:focus {
	border-color: #4a90e2;
	box-shadow: 0 0 5px rgba(74, 144, 226, 0.5);
}

/* Button Styling */
.reset-password-input button {
	padding: 10px 20px;
	font-size: 16px;
	font-weight: 600;
	color: white;
	background-color: #4a90e2;
	border: none;
	border-radius: 12px;
	cursor: pointer;
	transition: background-color 0.3s ease;
	white-space: nowrap;
}

.reset-password-input button:hover {
	background-color: #357ABD;
}

/* Nachricht Styling */
#forgotPasswordMessage {
	margin-top: 1rem;
	margin-bottom: 0;
	margin-left: 15px;
	font-size: 14px;
	font-weight: 600;
	color: inherit; /* wird per JS grün oder rot */
	white-space: nowrap;
}

@media (max-width: 670px) {
	.reset-password-input form {
		justify-content: center !important;
		gap: 1.5rem !important;
	}
}

/* CLOSE BUTTON */

.loginCloseBtn {
	all: unset;
	position: absolute;
	display: flex;
	cursor: pointer;
    top: 10px;
    right: 10px;
}

.loginCloseBtn svg {
	flex: 1;
	width: 26px;
	height: 26px;
	fill: var(--text-color);
	transition: fill 0.2s ease;
}

.loginCloseBtn:hover svg {
	fill: red;
}

#login-message {
	display: none;
	font-weight: 700;
	text-align: center;
    margin-top: 0.5rem;
}

/* === SEARCH RESULTS === */

.search-wrapper {
	display: flex;
	flex-direction: column;
	width: 90%;
	justify-self: center;
	padding-bottom: 2rem;
	position: relative;
	align-self: center;
}

.search-results-wrapper {
    font-family: 'Segoe UI', sans-serif;
    display: flex;
	flex-direction: column;
	gap: 1rem;
    padding: 1rem;
}

/* Titel */
.search-heading {
    font-size: calc(1.8rem + var(--font-size-larger));
	margin: 0;
	font-family: 'Segoe UI', sans-serif;
	margin-bottom: 1rem;
    text-align: center;
}

.search-heading .search-content {
    color: #5a7cff;
}

.search-heading .search-headline {
    background: var(--search-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Grid Layout */
.results-grid {
    display: grid;
    gap: 1rem;
}

/* Ergebnis Card */
.search-result {
    display: block;
    text-decoration: none;
    color: inherit;

    background: rgba(85, 84, 84, 0.1);
    backdrop-filter: blur(12px);

    border-radius: 12px;
    padding: 1.2rem;

    border: 1px solid rgba(255,255,255,0.2);

    transition: all 0.25s ease;
	will-change: transform;
}

/* Hover Effekt */
.search-result:hover {
    transform: scale(1.01);
    background: rgba(255, 255, 255, 0.18);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

/* Inhalt */
.result-title {
	display: inline;
    font-size: calc(1.25rem + var(--font-size-larger));
    background: linear-gradient(140deg, #7158f9, #5a4cf1, #617afd);
	-webkit-background-clip: text;
	-webkit-text-fill-color: transparent;
    margin-bottom: 0.4rem;
	font-weight: 650;
}

.result-preview {
    font-size: 0.95rem;
    color: var(--results-preview-color);
    line-height: 1.5;
}

/* Visueller In-Text Hinweis */

.results-grid .continue-info {
	opacity: 0.6;
	font-size: 0.7rem;
	animation: flickerC 1.45s ease-out infinite;
}

.results-grid .search-result:nth-child(1) .continue-info {
	animation-delay: 0s;
}

/* zweites Element */
.results-grid .search-result:nth-child(2) .continue-info {
	animation-delay: 0.2s;
}

/* drittes Element */
.results-grid .search-result:nth-child(3) .continue-info {
	animation-delay: 0.4s;
}

@keyframes flickerC {
	0% {
		opacity: 0.6;
	}
	50% {
		opacity: 0;
	}
}

/* Highlight */
.result-preview mark {
    background: #94faad;
    padding: 0 0.3rem;
    border-radius: 6px;
}

/* Keine Treffer */
.no-results-box {
    text-align: center;
    padding: 2rem;
    border-radius: 12px;
    background: rgba(255,255,255,0.05);
}

.no-results {
    font-size: calc(1.2rem + var(--font-size-larger));
    color: #aaa;
    margin-bottom: 1rem;
}

/* Button */
.reset-search-btn {
    padding: 0.6rem 1.2rem;
    border: none;
    border-radius: 999px;
	font-size: calc(0.9rem + var(--font-size-larger));
    background: linear-gradient(135deg, #5a7cff, #2c478b);
	color: white;
    cursor: pointer;
    transition: all 0.2s ease;
	will-change: transform;
}

.reset-search-btn svg {
	height: 26px;
	width: 26px;
	fill: white;
}

.reset-search-btn:hover {
    transform: scale(1.05);
    opacity: 0.9;
}

.reset-search-btn:focus {
    transform: scale(0.9);
    opacity: 0.9;
}

/* Floating Button */
.reset-search-btn.floating {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    font-size: calc(1.2rem + var(--font-size-larger));
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* === STATUS BADGES === */

.badge-placeholder {
	display: inline-block;
}

.badge {
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.35rem 0.75rem;
	border-radius: 999px;
	font-size: 0.85rem;
	font-weight: 600;
	font-family: "Inter", system-ui, sans-serif;
	background: rgba(0,0,0,0.04);
	border: 1px solid rgba(0,0,0,0.08);
	transition: transform 0.25s ease, background 0.25s ease;
	cursor: default;
}

.badge:hover {
	background: rgba(0,0,0,0.06);
}

.badge .dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	flex-shrink: 0;
	box-shadow: 0 0 6px currentColor;
}

/* Farben moderner, transparenter */
.badge-green {
	color: #137c45;
	background: rgba(19, 124, 69, 0.1);
	border-color: rgba(19, 124, 69, 0.2);
}
.badge-green .dot {
	background-color: #28c76f;
}

.badge-blue {
	color: #0b6fc2;
	background: rgba(33, 150, 243, 0.1);
	border-color: rgba(33, 150, 243, 0.2);
}
.badge-blue .dot {
	background-color: #2196f3;
}

.badge-orange {
	color: #b45309;
	background: rgba(251, 146, 60, 0.1);
	border-color: rgba(251, 146, 60, 0.2);
}
.badge-orange .dot {
	background-color: #fb8c00;
}

/* optional: kleine Glow-Animation für Dot */
@keyframes badgeDotPulse {
	0%, 100% { transform: scale(1); opacity: 1; }
	50% { transform: scale(1.3); opacity: 0.7; }
}

.badge .dot {
	animation: badgeDotPulse 1.5s infinite ease-in-out;
}


/* === FOOTER === */

/* BACK TO TOP BUTTON */

#backToTop {
	padding: 1rem 0;
	font-size: calc(1rem + var(--font-size-larger));
	color: white;
	border: none;
	cursor: pointer;
	width: 100%;
	background: #0d101c;
	border-top: 1px solid rgba(255, 255, 255,.08);
	position: relative;
	z-index: 100;
}

#backToTop:hover {
	color: var(--footer-link-hover);
}

footer {
	font-family: 'Segoe UI', Tahoma, Geneva, sans-serif;
	color: #aeb7c4;
	border-top: 1px solid rgba(255, 255, 255,.08); 
	background: #0d101c;
	padding-top: 1rem;
	padding-bottom: 1rem;
	padding-left: clamp(1rem, 4vw, 2rem);
	padding-right: clamp(1rem, 4vw, 2rem);
	cursor: default;
	font-size: calc(var(--font-size-larger) + 0.9rem);
	position: relative;
	z-index: 100;
}

.footer-mini-nav,
.footer-kontakt {
	display: flex;
	gap: 10px;
	justify-content: center;
}

.footer-mini-nav a,
.footer-kontakt a {
	color: var(--footer-a-color);
	cursor: pointer;
	text-decoration: none;
}

.footer-kontakt a:hover {
	color: var(--footer-link-hover);
	text-decoration: underline;
}

.footer-mini-nav a:hover span{
	color: var(--footer-link-hover);
	text-decoration: underline;
}

.footer p {
	text-align: center;
}

.bottom-line {
	display: flex;
	justify-content: space-between;
}

.social-links {
	display: flex;
	gap: 0.25rem;
	margin-left: clamp(0rem, 1vw, 5rem);
}

.social-links a {
	color: inherit;
	display: flex;
	flex-wrap: wrap;
	line-height: 1;
	gap: 0.2rem;
	text-decoration: none;
	align-items: center;
	align-content: end;
}

.social-links a svg {
	width: 24px;
	height: 24px;
	pointer-events: none;
	transition: fill 0.2s ease;
}

.social-links a:hover svg {
	fill: white;
}

.version {
	justify-self: end;
}

.version a {
	color: inherit;
	text-decoration: none;
}

.version a:hover {
	text-decoration: underline;
}

.version span {
	font-size: 0.8rem;
	display: flex;
    flex-direction: column;
    align-items: center;
	text-align: center;
}

/* === UNIVERSAL === */

.hidden {
	display: none;
}