/**
 * Kundenmenü — Detailansichten und Formulare: Bestelldetails mit Druckdaten-
 * Upload (WooCommerceOrderUpload), Adressbuch (WooCommerceAddressesEndpoint),
 * Konfigurationen/Archiv (WooCommerceKonfigurationenEndpoint, LegacyDetail-
 * Renderer) und das IBAN-Formular für Gutschriften (IbanRequestForm).
 *
 * Eingebunden über Assets::frontend_account() auf My-Account-Seiten und der
 * Bestellbestätigung (order-received), bewusst mit Priorität 20 NACH Theme-
 * und WooCommerce-CSS, damit die Regeln wie die früheren Inline-Blöcke im
 * Body bei gleicher Spezifität gewinnen. Die Bestellliste selbst liegt in
 * account-orders.css.
 */

/* =========================================================================
   Bestelldetails + Druckdaten-Upload
   ========================================================================= */

.b1-order-details { max-width: 1100px; }
.b1-order-accordion { margin: 0 0 28px; }
.b1-order-accordion > summary {
    display: flex;
    gap: 12px;
    align-items: center;
    list-style: none;
    cursor: pointer;
    background: #ededed;
    color: #555;
    padding: 13px 18px;
    font-size: 20px;
    font-weight: 600;
}
.b1-order-accordion > summary::-webkit-details-marker { display: none; }
.b1-order-accordion__icon::before { content: "+"; }
.b1-order-accordion[open] .b1-order-accordion__icon::before { content: "-"; }
.b1-order-accordion__body { padding: 24px 14px 0; }
.b1-order-row {
    display: grid;
    grid-template-columns: minmax(140px, 240px) 1fr;
    gap: 24px;
    margin: 0 0 14px;
}
.b1-order-row__label { color: #555; }
.b1-order-row__value p { margin: 0 0 9px; }
.b1-upload-form__row {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 24px;
    align-items: start;
    margin: 0 0 14px;
}
.b1-upload-form__component { padding-top: 5px; }
.b1-upload-form__files { min-width: 0; }
.b1-upload-form__file-row {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) auto auto minmax(150px, auto);
    gap: 20px;
    align-items: start;
    margin: 0 0 9px;
    color: #777;
    font-size: 20px;
}
.b1-upload-form__file-name { overflow-wrap: anywhere; }
.b1-upload-form__file-row.is-error { color: #b00020; }
.b1-upload-form__file-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}
.b1-upload-form__file-action {
    display: inline-block;
    background: #eee;
    color: #666 !important;
    border: 0;
    border-radius: 0;
    padding: 3px 10px;
    text-decoration: none;
    line-height: 1.25;
    cursor: pointer;
}
.b1-upload-form__button,
.b1-order-button {
    display: inline-block;
    background: #4f973d;
    color: #fff !important;
    padding: 9px 16px;
    text-decoration: none;
    border: 0;
    border-radius: 0;
    font-weight: 600;
    cursor: pointer;
}
.b1-upload-form__button input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}
.b1-upload-form__hint { margin: 34px 0 16px; max-width: 980px; color: #666; }
.b1-upload-form__submit {
    width: 100%;
    background: #4f973d;
    border: 0;
    padding: 12px 16px;
    color: #fff;
    font-size: 18px;
    cursor: pointer;
}
.b1-price-line {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin: 0 0 17px;
}
.b1-price-line__dots {
    flex: 1;
    border-bottom: 2px dotted #d6d6d6;
    transform: translateY(-4px);
}
.b1-price-line__value { min-width: 120px; text-align: right; }
.b1-price-line.is-strong { font-weight: 700; }
.b1-addresses h3 { font-size: 24px; margin: 0 0 18px; }
.b1-addresses address { font-style: normal; border: 0; padding: 0; margin: 0 0 10px; }
@media (max-width: 720px) {
    .b1-order-row,
    .b1-upload-form__row { grid-template-columns: 1fr; gap: 8px; }
    .b1-upload-form__file-row { grid-template-columns: 1fr; gap: 4px; }
    .b1-price-line__value { min-width: auto; }
}

/* =========================================================================
   Adressbuch: Karten-Liste
   ========================================================================= */

.b1-addr-intro { margin-bottom: 20px; }
.b1-addr-add-btn {
    display: inline-block; background: #71a340; color: #fff !important;
    border-radius: 3px; padding: 12px 24px; font-size: 15px;
    text-decoration: none !important;
}
.b1-addr-add-btn:hover { background: #5f8c34; color: #fff; }
.b1-address-cards {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px; margin-top: 8px;
}
.b1-address-card {
    background: #fff; border: 1px solid #ddd; border-radius: 6px;
    padding: 20px; display: flex; flex-direction: column;
}
.b1-address-card address {
    font-style: normal; margin: 0 0 14px; line-height: 1.6; flex-grow: 1;
}
.b1-addr-badges { margin-bottom: 10px; }
.b1-addr-badge {
    display: inline-block; background: #e8f2e8; color: #1e5c1e;
    border-radius: 3px; font-size: 12px; padding: 3px 10px; margin: 0 6px 6px 0;
}
.b1-card-actions {
    display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
}
.b1-inline-form { display: inline; margin: 0; }
.b1-address-card .b1-btn {
    display: inline-block; background: #f2f2f0; color: #444 !important;
    border: 1px solid #ccc; border-radius: 50px; padding: 6px 16px;
    font-size: 13px; line-height: 1.4; cursor: pointer;
    text-decoration: none !important;
}
.b1-address-card .b1-btn:hover { background: #e6e6e3; color: #222; }
.b1-address-card .b1-btn-danger:hover { color: #c00 !important; border-color: #c00; }
.b1-address-card .b1-btn-small { font-size: 12px; padding: 4px 12px; }
.b1-defaults-caption { font-size: 12px; color: #777; margin: 12px 0 6px; }

/* =========================================================================
   Adressbuch: Formular (an den Konfigurator-Look angelehnt)
   ========================================================================= */

.b1-address-form { max-width: 54rem; }
.b1-address-form .b1-row { display: flex; gap: 16px; }
.b1-address-form .b1-field { flex: 1; margin-bottom: 16px; }
.b1-address-form .b1-field.b1-w30 { flex: 0 0 30%; }
.b1-address-form input[type="text"],
.b1-address-form input[type="tel"],
.b1-address-form input[type="email"],
.b1-address-form select {
    width: 100%; padding: 14px 16px; font-size: 16px;
    border: 1px solid #ddd; border-radius: 4px; background: #fff;
}
.b1-address-form input::placeholder { color: #777; }
.b1-address-form .b1-anrede label { display: inline-block; margin: 0 20px 0 0; }
.b1-address-form .b1-defaults label { display: block; margin-bottom: 8px; }
.b1-address-form .b1-save-btn {
    background: #71a340; color: #fff; border: none; border-radius: 3px;
    padding: 12px 28px; font-size: 16px; cursor: pointer;
}
.b1-address-form .b1-save-btn:hover { background: #5f8c34; }
.b1-address-form .b1-cancel-link { margin-left: 16px; }
@media (max-width: 600px) { .b1-address-form .b1-row { flex-direction: column; gap: 0; } }

/* =========================================================================
   Gutschrift: IBAN-Formular (Bestelldetail + Bestellbestätigung)
   ========================================================================= */

.b1-iban-box       { margin: 0 0 24px; padding: 16px; border: 1px solid #c3c4c7; }
.b1-iban-box--done { background: #f6fff6; }
.b1-iban-box h2    { margin-top: 0; }
.b1-iban-field     { width: 100%; max-width: 420px; }

/* =========================================================================
   Konfigurationen / Archiv-Einträge aus dem Alt-System
   ========================================================================= */

.b1-subtle        { color: #777; }
.b1-hint          { color: #777; font-style: italic; }
.b1-address-plain { font-style: normal; }
.b1-archiv-badge {
    background: #777; color: #fff; border-radius: 3px;
    padding: 2px 8px; font-size: .8em; margin-left: 8px;
}
