/* ASN Warteliste Nichtmitglieder – Frontend-Styles */

/* ── Grundlayout ─────────────────────────────────── */
.asn-wln-wrap {
    max-width: 960px;
    margin: 0 auto;
    font-size: 1em;
}
.asn-wln-intro p {
    margin: 0 0 20px;
    line-height: 1.6;
}
.asn-wln-header {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

/* ── Karten ──────────────────────────────────────── */
.asn-wln-card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 20px 24px;
    margin-bottom: 24px;
}
.asn-wln-card h3 {
    margin-top: 0;
    margin-bottom: 16px;
    font-size: 1.05em;
    color: #333;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

/* ── Tabelle ─────────────────────────────────────── */
.asn-wln-table-scroll { overflow-x: auto; }
.asn-wln-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}
.asn-wln-table th,
.asn-wln-table td {
    text-align: left;
    padding: 9px 12px;
    border-bottom: 1px solid #f0f0f0;
    vertical-align: middle;
    color: #717171;
}
.asn-wln-table th {
    background: #f8f8f8;
    font-weight: 600;
    font-size: 13px;
    color: #555;
    text-transform: uppercase;
    letter-spacing: .3px;
}
.asn-wln-table tbody tr:hover { background: #fafafa; }

/* Stornierte / aufgenommene Einträge: Rang, Nummer, Personen, Datum durchgestrichen */
.asn-wln-table td.is-struck {
    color: #aaa;
    text-decoration: line-through;
}
.asn-wln-table td.is-struck .asn-wln-code { color: #aaa; }

.asn-wln-code {
    font-family: monospace;
    font-size: 13px;
    background: #f4f4f4;
    padding: 2px 6px;
    border-radius: 3px;
    border: 1px solid #e0e0e0;
    letter-spacing: .5px;
}

/* ── Badges (Status bleibt immer lesbar) ─────────── */
.asn-wln-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    white-space: nowrap;
    text-decoration: none;
}
.asn-wln-badge--aktiv       { background: #e8f4fd; color: #0073aa; }
.asn-wln-badge--aufgenommen { background: #edfaed; color: #2d7a2d; }
.asn-wln-badge--storniert   { background: #fef0f0; color: #c0392b; }

/* ── Buttons ─────────────────────────────────────── */
.asn-wln-btn {
    display: inline-block;
    padding: 9px 20px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    line-height: 1.4;
    transition: background .15s, color .15s, opacity .15s;
}
.asn-wln-btn--primary { background: #0073aa; color: #fff; border-color: #0073aa; }
.asn-wln-btn--primary:hover:not(:disabled) { background: #005d8a; }
.asn-wln-btn--danger { background: #fff; color: #c0392b; border-color: #e8a9a4; }
.asn-wln-btn--danger:hover:not(:disabled) { background: #fef0f0; }
.asn-wln-btn--ghost { background: transparent; color: #555; border-color: #ccc; }
.asn-wln-btn--ghost:hover:not(:disabled) { background: #f5f5f5; }
.asn-wln-btn--sm { padding: 4px 10px; font-size: 12px; }
.asn-wln-btn:disabled { opacity: .55; cursor: not-allowed; }

/* ── Hinweis-Boxen ───────────────────────────────── */
.asn-wln-notice {
    padding: 12px 16px;
    border-radius: 4px;
    font-size: 14px;
    line-height: 1.55;
    margin-bottom: 16px;
}
.asn-wln-notice--info    { background: #e8f4fd; border-left: 3px solid #0073aa; color: #333; }
.asn-wln-notice--warn    { background: #fff8e1; border-left: 3px solid #f0a800; color: #333; }
.asn-wln-notice--error   { background: #fef0f0; border-left: 3px solid #c0392b; color: #c0392b; }
.asn-wln-notice--success { background: #edfaed; border-left: 3px solid #2d7a2d; color: #1e5a1e; }

.asn-wln-empty {
    text-align: center;
    color: #888;
    padding: 20px 0;
    font-style: italic;
}

/* ════════════════════════════════════════════════════
   MODAL
   ════════════════════════════════════════════════════ */
.asn-wln-modal {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}
.asn-wln-modal__backdrop {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,.65);
    z-index: 0;
}
.asn-wln-modal__box {
    position: relative;
    z-index: 1;
    background: #fff;
    border-radius: 8px;
    width: 94%;
    max-width: 520px;
    max-height: 92vh;
    overflow-y: auto;
    padding: 28px 32px 24px;
    box-shadow: 0 12px 48px rgba(0,0,0,.35);
}
.asn-wln-modal__box h3 { margin-top: 0; margin-bottom: 18px; font-size: 1.15em; }
.asn-wln-modal__close {
    position: absolute;
    top: 14px; right: 16px;
    background: none;
    border: none;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    color: #888;
    padding: 0;
}
.asn-wln-modal__close:hover { color: #333; }

/* ── Formular ────────────────────────────────────── */
.asn-wln-form-row { margin-bottom: 14px; }
.asn-wln-form-row label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #444;
    margin-bottom: 5px;
}
.asn-wln-form-row label .req,
.asn-wln-form-row--check .req { color: #c0392b; }
.asn-wln-form-row input[type=text],
.asn-wln-form-row input[type=email],
.asn-wln-form-row select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
}
.asn-wln-form-row input:focus,
.asn-wln-form-row select:focus {
    outline: 2px solid #0073aa;
    outline-offset: 1px;
    border-color: #0073aa;
}
.asn-wln-form-row--half {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
.asn-wln-form-row--check label { display: flex; align-items: flex-start; gap: 8px; font-weight: 500; }
.asn-wln-form-row--check input { margin-top: 3px; }
.asn-wln-code-input {
    font-family: monospace;
    font-size: 22px !important;
    letter-spacing: 6px;
    text-align: center;
}
.asn-wln-field-hint {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    color: #777;
    line-height: 1.4;
}
.asn-wln-form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
}

/* Honeypot: nur für Bots sichtbar */
.asn-wln-hp {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* ── Bearbeiten-Dialog ───────────────────────────── */
.asn-wln-emailchange {
    margin-top: 20px;
    padding-top: 14px;
    border-top: 1px solid #eee;
    font-size: 14px;
}
.asn-wln-emailchange summary { cursor: pointer; font-weight: 600; color: #0073aa; margin-bottom: 10px; }

/* ── Erfolgs-/Nummern-Anzeige ────────────────────── */
.asn-wln-success-box { text-align: center; padding: 12px 0 8px; }
.asn-wln-success-icon {
    width: 52px; height: 52px;
    border-radius: 50%;
    background: #edfaed;
    color: #2d7a2d;
    font-size: 26px;
    line-height: 52px;
    margin: 0 auto 12px;
    border: 2px solid #a9dba9;
}
.asn-wln-success-text { font-size: 16px; font-weight: 600; color: #2d7a2d; margin-bottom: 12px; }
.asn-wln-success-hint { font-size: 13px; color: #777; margin-bottom: 18px; }

.asn-wln-wlnr-display {
    background: #f4f4f4;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 12px 20px;
    margin-bottom: 14px;
    text-align: center;
}
.asn-wln-wlnr-label {
    display: block;
    font-size: 12px;
    color: #777;
    margin-bottom: 4px;
    letter-spacing: .3px;
    text-transform: uppercase;
}
.asn-wln-wlnr-code {
    display: block;
    font-family: monospace;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 2px;
    color: #0073aa;
}
.asn-wln-result-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    margin-bottom: 16px;
    text-align: left;
}
.asn-wln-result-table th { color: #777; font-weight: 500; width: 45%; padding: 4px 8px; }
.asn-wln-result-table td { padding: 4px 8px; font-weight: 600; word-break: break-all; }

/* ── Responsive ──────────────────────────────────── */
@media (max-width: 600px) {
    .asn-wln-modal__box { padding: 20px 16px 16px; }
    .asn-wln-table th,
    .asn-wln-table td   { padding: 7px 8px; font-size: 13px; }
    .asn-wln-card       { padding: 14px; }
    .asn-wln-form-row--half { grid-template-columns: 1fr; }
}
