/* ==========================================================================
   E-Invoice Request — Scoped stylesheet
   All rules are namespaced under .eir-* so they cannot conflict with
   Hub theme 5.x or Elementor widgets on the same page.
   ========================================================================== */

/* ---------- Checkout section wrapper ---------- */
.eir-checkout-section {
    margin-top: 24px;
    margin-bottom: 0;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    overflow: hidden;
}

.eir-checkout-section .eir-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    margin: 0;
    padding: 14px 18px;
    background: #f9f9f9;
    font-size: 15px;
    font-weight: 600;
    color: #333;
    user-select: none;
    border: none;
    transition: background 0.2s;
}

.eir-checkout-section .eir-toggle:hover,
.eir-checkout-section .eir-toggle:focus {
    background: #f1f1f1;
    outline: 2px solid #0073aa;
    outline-offset: -2px;
}

.eir-checkout-section .eir-toggle.is-open {
    border-bottom: 1px solid #e0e0e0;
}

.eir-checkout-section .eir-toggle-icon {
    transition: transform 0.25s ease;
    flex-shrink: 0;
    color: #666;
}

.eir-checkout-section .eir-toggle.is-open .eir-toggle-icon {
    transform: rotate(180deg);
}

.eir-checkout-section .eir-fields {
    padding: 18px 18px 8px;
    background: #fff;
}

.eir-checkout-section .eir-note {
    font-size: 13px;
    color: #666;
    margin-bottom: 16px;
}

/* Checkout fields — neutralise WC's default row padding inside our scope */
.eir-checkout-section .eir-field {
    width: 100% !important;
    float: none !important;
    clear: both;
}

.eir-checkout-section .eir-field label {
    font-size: 14px;
}

/* ---------- My Account page ---------- */
.eir-account-wrap {
    font-size: 15px;
    color: #333;
}

.eir-back-link {
    display: inline-block;
    font-size: 13px;
    color: #0073aa;
    text-decoration: none;
    margin-bottom: 16px;
}

.eir-back-link:hover {
    text-decoration: underline;
}

.eir-heading {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 6px;
    color: #111;
}

.eir-subheading {
    font-size: 14px;
    color: #555;
    margin-bottom: 20px;
}

.eir-empty {
    color: #777;
    font-style: italic;
}

/* ---------- Orders table ---------- */
.eir-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
    font-size: 14px;
}

.eir-table th {
    text-align: left;
    padding: 10px 12px;
    background: #f5f5f5;
    border-bottom: 2px solid #ddd;
    font-weight: 600;
    color: #333;
}

.eir-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}

.eir-table tr:last-child td {
    border-bottom: none;
}

.eir-table a {
    color: #0073aa;
    text-decoration: none;
}

.eir-table a:hover {
    text-decoration: underline;
}

/* ---------- Status badges ---------- */
.eir-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.eir-badge--none       { background: #f0f0f0; color: #777; }
.eir-badge--pending    { background: #fff3cd; color: #856404; }
.eir-badge--processing { background: #cce5ff; color: #004085; }
.eir-badge--issued     { background: #d4edda; color: #155724; }
.eir-badge--rejected   { background: #f8d7da; color: #721c24; }

.eir-issued-icon {
    color: #155724;
    font-size: 13px;
    font-weight: 600;
}

/* ---------- Buttons ---------- */
.eir-btn {
    display: inline-block;
    padding: 8px 18px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    border: none;
    transition: background 0.2s, opacity 0.2s;
    line-height: 1.4;
}

.eir-btn-primary {
    background: #0073aa;
    color: #fff !important;
    margin-top: 8px;
}

.eir-btn-primary:hover {
    background: #005a87;
    color: #fff !important;
    text-decoration: none;
}

.eir-btn-sm {
    padding: 5px 12px;
    font-size: 13px;
    background: #0073aa;
    color: #fff !important;
}

.eir-btn-sm:hover {
    background: #005a87;
    color: #fff !important;
    text-decoration: none;
}

/* ---------- Request form ---------- */
.eir-form {
    max-width: 560px;
    margin-top: 20px;
}

.eir-form-group {
    margin-bottom: 18px;
}

.eir-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
}

.eir-required {
    color: #c0392b;
}

.eir-optional {
    font-weight: 400;
    color: #777;
    font-size: 13px;
}

.eir-input {
    display: block;
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
    color: #333;
    background: #fff;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
}

.eir-input:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.15);
}

.eir-textarea {
    resize: vertical;
    min-height: 80px;
}

.eir-hint {
    display: block;
    font-size: 12px;
    color: #888;
    margin-top: 4px;
}

/* ---------- Status notices on form ---------- */
.eir-status-notice {
    padding: 12px 16px;
    border-radius: 5px;
    font-size: 14px;
    margin-bottom: 18px;
    border-left: 4px solid transparent;
}

.eir-status-pending {
    background: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

.eir-status-issued {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

/* ---------- Responsive ---------- */
@media (max-width: 600px) {
    .eir-table th:nth-child(3),
    .eir-table td:nth-child(3) {
        display: none; /* hide Total on small screens */
    }

    .eir-form {
        max-width: 100%;
    }
}
