/**
 * rechnungen.css  v1.0
 * CS Aviation – Rechnungssystem
 * Setzt abrechnungssystem.css (res-abr-*) voraus.
 */

/* ══ RECHNUNGSÜBERSICHT ═══════════════════════════════════════════════════════ */

/* Filter-Bereich */
#res-rech-wrap .res-abr-field label {
    font-size: 0.71rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--abr-text-sub, #4b5a72);
    display: block;
    margin-bottom: 4px;
}

/* Tabellen-Zeile hover: linke Akzentlinie */
#res-rech-tabelle .res-abr-tbl tbody tr:hover td:first-child {
    box-shadow: inset 3px 0 0 #1a3d7c;
}

/* Rechnungsnummer */
.res-rech-nr {
    font-family: 'Courier New', Courier, monospace;
    font-size: 11px;
    font-weight: 700;
    color: #0f2548;
    letter-spacing: 0.06em;
}

/* Bezahlt-Datum Inline-Input */
.res-rech-bezahlt-input:focus {
    outline: none;
    border-color: #1a3d7c !important;
    box-shadow: 0 0 0 3px rgba(26,61,124,0.11);
    background: #fff !important;
}

/* PDF-Download-Link */
.res-rech-pdf-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border: 1px solid #d0d9ea;
    border-radius: 6px;
    background: #fff;
    color: #4b5a72;
    text-decoration: none;
    transition: background 0.12s, color 0.12s, border-color 0.12s;
}
.res-rech-pdf-link:hover {
    background: #1a3d7c;
    border-color: #1a3d7c;
    color: #fff;
}

/* ══ ZAHLUNGSLAUF-MODAL ═══════════════════════════════════════════════════════ */

#res-zl-body .res-abr-tbl tbody tr td:first-child { font-weight: 600; }

/* Summenzeile im Editor */
#res-editor-summen,
#res-ind-summen {
    padding: 10px 14px;
    background: #f4f6fb;
    border: 1px solid #e6ecf5;
    border-radius: 8px;
    font-size: 13px;
    line-height: 1.6;
}

/* Positions-Tabelle im Editor */
#res-editor-pos-tbody input,
#res-ind-pos-tbody input {
    font-family: 'Lato', sans-serif !important;
    transition: border-color 0.15s, box-shadow 0.15s;
}
#res-editor-pos-tbody input:focus,
#res-ind-pos-tbody input:focus {
    outline: none !important;
    border-color: #1a3d7c !important;
    box-shadow: 0 0 0 2px rgba(26,61,124,0.1) !important;
    background: #fff !important;
}

/* ══ EINSTELLUNGEN ════════════════════════════════════════════════════════════ */

#res-rech-einst-wrap .res-abr-field textarea {
    font-family: 'Lato', sans-serif;
    font-size: 13px;
    line-height: 1.55;
}

#res-einst-logo-preview {
    border: 1px solid #d0d9ea;
    border-radius: 6px;
    padding: 4px;
    background: #f4f6fb;
}

/* ══ RECHNUNG (DRUCKANSICHT) ══════════════════════════════════════════════════
   Diese Styles werden direkt in res_rech_render_html() eingebettet (Inline).
   Sie sind hier nur zur Dokumentation — nicht für die WP-Seite selbst.
   ════════════════════════════════════════════════════════════════════════════ */

/* ══ RESPONSIVE ═══════════════════════════════════════════════════════════════ */

@media (max-width: 720px) {
    /* Filter vertikal */
    #res-rech-wrap .res-abr-card-body > div[style*="display:flex"] {
        flex-direction: column !important;
    }

    /* Tabellen-Spalten reduzieren */
    #res-rech-tabelle .res-abr-tbl th:nth-child(3),
    #res-rech-tabelle .res-abr-tbl td:nth-child(3) { display: none; } /* Betrag */

    /* Editor-Positionen: Einheit-Spalte ausblenden */
    #res-editor-pos-tbody td:nth-child(3),
    #res-ind-pos-tbody td:nth-child(3),
    #res-editor-positionen thead th:nth-child(3),
    #res-ind-positionen thead th:nth-child(3) { display: none; }
}
