/* ---------- GLOBAL ---------- */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
}

#background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-image: url("./SaveTheDate_mobil.svg");
    background-size: auto 100%;
    background-repeat: no-repeat;
    background-position: center top;
    z-index: -1;
}

/* Inhalts-Container */
#content {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* ---------- ADMIN WRAPPER & BURGER ---------- */
#admin-wrapper {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 100; /* <<< WICHTIG: über Modal, aber NICHT über Anmeldung */
}

#admin-box {
    background: rgba(0,0,0,0.6);
    border-radius: 8px;
    height: 45px;
    display: inline-flex;
    align-items: center;
    overflow: hidden;
    cursor: pointer;
    position: relative;
    max-width: 45px;
    transition: max-width 0.4s ease, background 0.3s ease;
}

#admin-box.open {
    max-width: 420px; /* <<< WICHTIG: NICHT 1000px */
    background: rgba(0,0,0,0.75);
    padding-right: 15px;
}

/* ---------- BURGER LINES ---------- */
#burger-area {
    position: relative;
    width: 45px;
    height: 45px;
    flex-shrink: 0;
    cursor: pointer;
}

.burger-line {
    position: absolute;
    left: 10px;
    width: 26px;
    height: 3px;
    background: white;
    border-radius: 2px;
    transition: 0.3s;
}

.burger-line:nth-child(1) { top: 12px; }
.burger-line:nth-child(2) { top: 21px; }
.burger-line:nth-child(3) { top: 30px; }

#admin-box.open .burger-line:nth-child(1) {
    top: 21px;
    transform: rotate(45deg);
}
#admin-box.open .burger-line:nth-child(2) {
    opacity: 0;
}
#admin-box.open .burger-line:nth-child(3) {
    top: 21px;
    transform: rotate(-45deg);
}

/* ---------- ADMIN LOGIN ---------- */
#admin-login {
    min-width: 250px;
    margin-left: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

#admin-login input[type="password"] {
    padding: 10px 14px;
    font-size: 16px;
    background: rgba(65,65,65,1);
    color: white;
    border: none;
    border-radius: 8px;
}

#admin-login button[type="submit"] {
    padding: 10px 14px;
    font-size: 16px;
    background: rgba(65,65,65,1);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

#admin-login button[type="submit"]:hover {
    background: #000;
    color: red;
}

.admin-logged-in #admin-login {
    display: none;
}

/* ---------- ADMIN LINKS ---------- */
#admin-links {	
    flex-wrap: nowrap;
    display: none;
    margin-left: 20px;
    align-items: center;
    gap: 10px;
}

.admin-logged-in #admin-links {
    display: flex;
}

.admin-btn {
    padding: 15px 28px;
    font-size: 18px;
    font-weight: bold;
    background: rgba(65,65,65,1);
    color: white;
    border-radius: 8px;
    text-decoration: none;
    transition: 0.2s;
}

.admin-btn:hover {
    background: #000;
    color: red;
}

/* ---------- ANMELDUNG BUTTON ---------- */
#anmeldung-wrapper {
    margin-top: 47vh;
    width: 100%;
    display: flex;
    justify-content: center;
    z-index: 1; /* <<< WICHTIG: über Admin-Box */
}

#anmeldung-btn {
	margin-top: 12vh;
    padding: 15px 28px;
    font-size: 24px;
    font-weight: bold;
    background: rgba(0,0,0,0.6);
    color: red;
    border-radius: 8px;
    cursor: pointer;
    transition: 0.2s;
}

#anmeldung-btn:hover {
    background: #000;
}

/* Responsive */
@media screen and (max-width: 600px) {
    #anmeldung-btn {
		margin-top: 11vh;
        font-size: 16px;
        padding: 12px 20px;
        width: 70%;
        max-width: 260px;
    }
}

/* ---------- MODAL ---------- */
.modal-backdrop {
    display: none;
    position: fixed;
    top:0; left:0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(3px);
    justify-content: center;
    align-items: center;
    z-index: 50;
}

.modal-box {
    background: rgba(65,65,65,1);
    color: white;
    width: 90%;
    max-width: 900px;
    padding: 0;
    border-radius: 12px;
    box-shadow: 0 0 22px rgba(0,0,0,0.5);
    animation: popIn 0.25s ease forwards;
    transform: scale(0.9);
    opacity: 0;
}

@keyframes popIn {
    to { transform: scale(1); opacity:1; }
}

/* Scrollbarer Inhalt */
.modal-inner {
    padding: 20px;
    max-height: 85vh;
    overflow-y: auto;
    overscroll-behavior: contain;
    width: 100%;
    box-sizing: border-box;

    scrollbar-width: none;
    -ms-overflow-style: none;
}
.modal-inner::-webkit-scrollbar {
    display: none;
}

/* ---------- FORM ELEMENTE ---------- */
.modal-row {
    margin-bottom: 15px;
}

.modal-row label {
    display: block;
    margin-bottom: 4px;
    color: #ccc;
}

.modal-row input,
.modal-row textarea {
    width: 100%;
    padding: 10px;
    background: #1e1e1e;
    color: white;
    border-radius: 8px;
    border: 1px solid #555;
    box-sizing: border-box;
}

/* ---------- FIELDSET KONTAKTPERSON ---------- */
.kontaktperson-group fieldset {
    border: 2px solid #555;
    border-radius: 8px;
    padding: 15px;
    margin: 10px 0;
}

.kontaktperson-group legend {
    font-weight: bold;
    padding: 0 8px;
}

.kontaktperson-group .name-fields {
    display: flex;
    flex-direction: column;
    margin-bottom: 10px;
}

.kontaktperson-group input {
    padding: 8px;
    border-radius: 6px;
    border: 1px solid #555;
    background: #1e1e1e;
    color: white;
}

/* ---------- BUTTONS ---------- */
.modal-submit {
    width: 100%;
    padding: 12px;
    background: rgba(65,65,65,1);
    color: white;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: 0.2s;
}

.modal-submit:hover {
    background: #000;
    color: red;
}

.modal-close {
    width: 100%;
    padding: 10px;
    background: rgba(65,65,65,1);
    color: white;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: 0.2s;
}

.modal-close:hover {
    background: #000;
    color: red;
}

/* ---------- OPTIONEN ---------- */
.options {
    margin-top: 25px;
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.option-block {
    background: #1e1e1e;
    padding: 15px 18px;
    border-radius: 10px;
    border: 1px solid #333;
    box-shadow: 0 0 10px rgba(0,0,0,0.25);
    width: 100%;
    box-sizing: border-box;
}

.option-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: bold;
    font-size: 15px;
    cursor: pointer;
}

.option-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: red;
    cursor: pointer;
}

.sub-info {
    margin-top: 8px;
    font-size: 13px;
    color: #ccc;
    line-height: 1.45;
}

.highlight-link {
    color: #ff4444;
    text-decoration: underline;
}

.highlight-link:hover {
    color: #ff7777;
}

/* ---------- TEILNEHMER-TABELLE ---------- */
#teilnehmerTabelle {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    background: #2a2a2a;
    border-radius: 10px;
    overflow: hidden;
}

#teilnehmerTabelle th {
    background: #1e1e1e;
    padding: 12px;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #333;
}

#teilnehmerTabelle td {
    padding: 10px;
    border-bottom: 1px solid #333;
}

#teilnehmerTabelle tr:last-child td {
    border-bottom: none;
}

#teilnehmerTabelle tr:hover {
    background: rgba(255,255,255,0.05);
}

#teilnehmerTabelle input[type="text"] {
    width: 100%;
    padding: 8px;
    background: #111;
    border: 1px solid #444;
    border-radius: 6px;
    color: white;
}

#teilnehmerTabelle input[type="radio"] {
    width: 20px;
    height: 20px;
    accent-color: red;
    cursor: pointer;
}

/* Zwei Spalten nebeneinander */
.two-cols {
    display: flex;
    gap: 20px;
}

.two-cols .col {
    flex: 1;
}

/* Textfeld statt Input */
.info-field {
    background: #1e1e1e;
    color: white;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #555;
    font-size: 15px;
    box-sizing: border-box;
}

/* Inline-Zeilen */
.inline-row {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 10px;
}

.inline-label {
    font-weight: bold;
    color: #ccc;
    white-space: nowrap;
}

.inline-value {
    background: #1e1e1e;
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid #555;
    min-width: 40px;
    display: inline-block;
    white-space: nowrap;
}

.inline-input {
    background: #1e1e1e;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid #555;
    width: 80px;
    box-sizing: border-box;
    white-space: nowrap;
}

/* ===========================
   SUCCESS MODAL (Auto-Open)
=========================== */

.success-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

/* eigene Box-Klasse, damit keine popIn-Animation greift */
.success-box {
    background: #ffffff;
    padding: 25px 30px;
    border-radius: 12px;
    max-width: 420px;
    width: 90%;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.success-inner {
    padding: 10px;
}

#successModal h2 {
    margin-top: 0;
    color: #d32f2f;
    font-size: 1.6rem;
}

#successModal p {
    margin-top: 10px;
    font-size: 1.1rem;
    color: #333;
}

#successModal .modal-submit {
    background: #d32f2f;
    border: none;
    padding: 10px 22px;
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
    font-size: 1rem;
}

#successModal .modal-submit:hover {
    background: #b71c1c;
}



