/* Withdrawal page */
.ml-elallas,
.ml-elallas * {
    box-sizing: border-box;
}

.ml-elallas {
    width: 100%;
    max-width: var(--ml-content-max-width, 1120px);
    margin: 0;
    color: var(--ml-color-text, #242424);
}

.ml-elallas-page-intro {
    max-width: 760px;
    margin: 0 0 clamp(1.25rem, 2.5vw, 2rem);
}

.ml-elallas-page-intro > :last-child,
.ml-elallas-intro > :last-child,
.ml-elallas-statement > :last-child {
    margin-bottom: 0;
}

.ml-elallas-card {
    width: 100%;
    margin: 0 0 clamp(1.5rem, 3vw, 2.5rem);
    padding: clamp(1rem, 2.4vw, 1.75rem);
    border: 1px solid var(--ml-color-border, rgba(18, 18, 18, 0.12));
    border-radius: var(--ml-radius-md, 12px);
    background: var(--ml-color-white, #fff);
    box-shadow: var(--ml-shadow-sm, 0 8px 18px rgba(18, 18, 18, 0.08));
}

.ml-elallas-lookup-form {
    max-width: 620px;
}

.ml-elallas-form-grid {
    display: block;
    width: 100%;
}

.ml-elallas-field {
    display: block;
    width: 100%;
    margin: 0 0 1rem;
}

.ml-elallas-field label {
    display: block;
    margin: 0 0 0.35rem;
    color: var(--ml-color-ink, #121212);
    font-weight: var(--ml-font-weight-bold, 700);
}

.ml-elallas-field input {
    width: 100%;
    max-width: none;
}

.ml-elallas-actions {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    margin: 1.25rem 0 0;
}

.ml-elallas-actions .ml-button {
    min-width: 190px;
}

.ml-elallas .ml-button[disabled],
.ml-elallas .ml-button[disabled]:hover,
.ml-elallas .ml-button[disabled]:focus {
    border-color: transparent;
    background: var(--ml-color-surface-strong, #e3e3e3);
    color: var(--ml-color-muted, #67697c);
    box-shadow: none;
    cursor: not-allowed;
    opacity: 1;
    transform: none;
}

/* Sections */
.ml-elallas-section-head {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    width: 100%;
    margin-bottom: clamp(1.1rem, 2vw, 1.6rem);
}

.ml-elallas-section-head .ml-section__title {
    margin: 0;
}

.ml-elallas-intro {
    max-width: 820px;
    color: var(--ml-color-muted, #67697c);
    font-size: clamp(1rem, 0.96rem + 0.18vw, 1.1rem);
    line-height: 1.5;
}

.ml-elallas-order-details {
    margin: 0 0 clamp(1.25rem, 2.5vw, 2rem);
    padding: clamp(1rem, 2vw, 1.5rem);
    border: 1px solid var(--ml-color-border, rgba(18, 18, 18, 0.12));
    border-left: 5px solid var(--ml-color-blue, #345995);
    border-radius: var(--ml-radius-sm, 8px);
    background: var(--ml-color-surface-soft, #f4f4f4);
}

.ml-elallas-order-details h3 {
    margin: 0 0 1rem;
    color: var(--ml-color-ink, #121212);
    font-size: clamp(1.25rem, 1.12rem + 0.45vw, 1.6rem);
}

.ml-elallas-details-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
}

.ml-elallas-detail {
    flex: 1 1 calc(33.333% - 1rem);
    min-width: 220px;
    padding: 0.85rem;
    border: 1px solid var(--ml-color-border, rgba(18, 18, 18, 0.12));
    border-radius: var(--ml-radius-sm, 8px);
    background: var(--ml-color-white, #fff);
}

.ml-elallas-detail strong,
.ml-elallas-detail span {
    display: block;
}

.ml-elallas-detail strong {
    margin-bottom: 0.25rem;
    color: var(--ml-color-muted, #67697c);
    font-size: var(--ml-font-size-xs, 0.75rem);
    font-weight: var(--ml-font-weight-bold, 700);
    letter-spacing: 0.045em;
    line-height: 1.2;
    text-transform: uppercase;
}

.ml-elallas-detail span {
    color: var(--ml-color-ink, #121212);
    font-size: clamp(0.95rem, 0.92rem + 0.12vw, 1.05rem);
    font-weight: var(--ml-font-weight-medium, 500);
    line-height: 1.4;
    overflow-wrap: anywhere;
}

.ml-elallas-detail address {
    margin: 0;
    font-style: normal;
}

/* Product rows */
.ml-elallas-items {
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--ml-color-border, rgba(18, 18, 18, 0.12));
    border-radius: var(--ml-radius-md, 12px);
    background: var(--ml-color-white, #fff);
}

.ml-elallas-items__head,
.ml-elallas-items__body {
    display: block;
    width: 100%;
}

.ml-elallas-items__row {
    display: flex;
    align-items: stretch;
    width: 100%;
}

.ml-elallas-items__row--head {
    background: var(--ml-color-ink, #121212);
    color: var(--ml-color-white, #fff);
    font-size: clamp(0.7rem, 0.67rem + 0.08vw, 0.78rem);
    font-weight: var(--ml-font-weight-bold, 700);
    letter-spacing: 0.035em;
    line-height: 1.2;
    text-transform: uppercase;
}

.ml-elallas-items__row--item {
    border-top: 1px solid var(--ml-color-border, rgba(18, 18, 18, 0.12));
    background: var(--ml-color-white, #fff);
}

.ml-elallas-items__body .ml-elallas-items__row--item:nth-child(even) {
    background: var(--ml-color-surface-soft, #f4f4f4);
}

.ml-elallas-items__row--item.is-not-eligible {
    background: rgba(210, 25, 31, 0.045);
}

.mentha-elallas-cell {
    display: flex;
    align-items: center;
    min-width: 0;
    padding: 0.85rem 0.75rem;
    border-right: 1px solid var(--ml-color-border, rgba(18, 18, 18, 0.12));
    line-height: 1.35;
}

.mentha-elallas-cell:last-child {
    border-right: 0;
}

.mentha-elallas-cell--product {
    flex: 1 1 360px;
    justify-content: flex-start;
}

.mentha-elallas-cell--unit,
.mentha-elallas-cell--line-total {
    flex: 0 0 120px;
    justify-content: flex-end;
    color: var(--ml-color-ink, #121212);
    font-weight: var(--ml-font-weight-bold, 700);
    text-align: right;
    white-space: nowrap;
}

.mentha-elallas-cell--qty {
    flex: 0 0 130px;
    justify-content: center;
    color: var(--ml-color-ink, #121212);
    font-weight: var(--ml-font-weight-bold, 700);
    text-align: center;
}

.mentha-elallas-cell--eligible {
    flex: 0 0 140px;
    justify-content: center;
    text-align: center;
}

.mentha-elallas-cell--select {
    flex: 0 0 150px;
    justify-content: center;
    text-align: center;
}

.mentha-elallas-product-name {
    color: var(--ml-color-ink, #121212);
    font-size: clamp(0.95rem, 0.91rem + 0.16vw, 1.06rem);
    font-weight: var(--ml-font-weight-bold, 700);
    hyphens: none;
    line-height: 1.35;
    overflow-wrap: anywhere;
    word-break: normal;
}

.mentha-elallas-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 54px;
    padding: 0.35rem 0.6rem;
    border-radius: var(--ml-radius-pill, 999px);
    font-size: var(--ml-font-size-sm, 0.875rem);
    font-weight: var(--ml-font-weight-bold, 700);
    line-height: 1;
}

.mentha-elallas-status.is-yes {
    background: rgba(52, 89, 149, 0.13);
    color: var(--ml-color-blue, #345995);
}

.mentha-elallas-status.is-no {
    background: rgba(210, 25, 31, 0.11);
    color: var(--ml-color-primary, #d2191f);
}

.ml-elallas-qty {
    width: 100%;
    max-width: 86px;
    min-width: 70px;
    min-height: 2.6rem;
    margin: 0;
    padding: 0.45rem 2rem 0.45rem 0.65rem;
    font-weight: var(--ml-font-weight-bold, 700);
}

.ml-elallas-qty:disabled {
    cursor: not-allowed;
    opacity: 0.65;
}

.ml-elallas-items--summary .mentha-elallas-cell--product {
    flex-basis: 420px;
}

.ml-elallas-items--summary .mentha-elallas-cell--qty {
    flex-basis: 110px;
}

.ml-elallas-items--summary .mentha-elallas-cell--unit,
.ml-elallas-items--summary .mentha-elallas-cell--line-total {
    flex-basis: 150px;
}

/* Totals and confirmation */
.ml-elallas-total {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: 100%;
    margin-top: 1.25rem;
    padding: clamp(0.9rem, 1.8vw, 1.2rem);
    border: 1px solid rgba(52, 89, 149, 0.24);
    border-radius: var(--ml-radius-sm, 8px);
    background: rgba(52, 89, 149, 0.075);
    color: var(--ml-color-ink, #121212);
}

.ml-elallas-total strong {
    font-size: clamp(1rem, 0.96rem + 0.18vw, 1.12rem);
}

.ml-elallas-total__value,
.ml-elallas-total > span {
    color: var(--ml-color-blue, #345995);
    font-size: clamp(1.2rem, 1.08rem + 0.45vw, 1.5rem);
    font-weight: var(--ml-font-weight-black, 900);
    line-height: 1;
    text-align: right;
    white-space: nowrap;
}

.ml-elallas-statement {
    margin-top: 1.25rem;
    padding: 1rem 1.1rem;
    border-left: 5px solid var(--ml-color-accent, #d4a018);
    border-radius: 0 var(--ml-radius-sm, 8px) var(--ml-radius-sm, 8px) 0;
    background: var(--ml-color-surface-soft, #f4f4f4);
    color: var(--ml-color-ink, #121212);
    font-weight: var(--ml-font-weight-medium, 500);
}

.ml-elallas-notice {
    width: 100%;
    max-width: var(--ml-content-max-width, 1120px);
}

@media (max-width: 979.98px) {
    .ml-elallas-items {
        overflow: visible;
        border: 0;
        border-radius: 0;
        background: transparent;
    }

    .ml-elallas-items__head {
        display: none;
    }

    .ml-elallas-items__body {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }

    .ml-elallas-items__row--item,
    .ml-elallas-items__body .ml-elallas-items__row--item:nth-child(even),
    .ml-elallas-items__row--item.is-not-eligible {
        display: flex;
        flex-wrap: wrap;
        overflow: hidden;
        border: 1px solid var(--ml-color-border, rgba(18, 18, 18, 0.12));
        border-radius: var(--ml-radius-md, 12px);
        background: var(--ml-color-white, #fff);
        box-shadow: var(--ml-shadow-sm, 0 8px 18px rgba(18, 18, 18, 0.08));
    }

    .mentha-elallas-cell,
    .mentha-elallas-cell--product,
    .mentha-elallas-cell--unit,
    .mentha-elallas-cell--qty,
    .mentha-elallas-cell--line-total,
    .mentha-elallas-cell--eligible,
    .mentha-elallas-cell--select,
    .ml-elallas-items--summary .mentha-elallas-cell--product,
    .ml-elallas-items--summary .mentha-elallas-cell--qty,
    .ml-elallas-items--summary .mentha-elallas-cell--unit,
    .ml-elallas-items--summary .mentha-elallas-cell--line-total {
        display: flex;
        flex: 1 1 50%;
        justify-content: space-between;
        gap: 1rem;
        min-width: 0;
        padding: 0.8rem;
        border-right: 0;
        border-bottom: 1px solid var(--ml-color-border, rgba(18, 18, 18, 0.12));
        text-align: right;
        white-space: normal;
    }

    .mentha-elallas-cell::before {
        content: attr(data-label);
        flex: 0 1 52%;
        color: var(--ml-color-muted, #67697c);
        font-size: var(--ml-font-size-xs, 0.75rem);
        font-weight: var(--ml-font-weight-bold, 700);
        letter-spacing: 0.035em;
        line-height: 1.25;
        text-align: left;
        text-transform: uppercase;
    }

    .mentha-elallas-cell--product {
        display: block;
        flex-basis: 100%;
        text-align: left;
    }

    .ml-elallas-items__row--item > :last-child {
        flex-basis: 100%;
    }

    .mentha-elallas-cell--product::before {
        display: block;
        margin-bottom: 0.35rem;
    }

    .ml-elallas-items__row--item > :last-child {
        border-bottom: 0;
    }
}

@media (max-width: 639.98px) {
    .ml-elallas-card {
        padding: 1rem;
        border-radius: var(--ml-radius-sm, 8px);
        box-shadow: none;
    }

    .ml-elallas-detail {
        flex-basis: 100%;
        min-width: 0;
    }

    .mentha-elallas-cell,
    .mentha-elallas-cell--product,
    .mentha-elallas-cell--unit,
    .mentha-elallas-cell--qty,
    .mentha-elallas-cell--line-total,
    .mentha-elallas-cell--eligible,
    .mentha-elallas-cell--select,
    .ml-elallas-items--summary .mentha-elallas-cell--product,
    .ml-elallas-items--summary .mentha-elallas-cell--qty,
    .ml-elallas-items--summary .mentha-elallas-cell--unit,
    .ml-elallas-items--summary .mentha-elallas-cell--line-total {
        flex-basis: 100%;
    }

    .ml-elallas-total {
        align-items: flex-start;
        flex-direction: column;
    }

    .ml-elallas-total__value,
    .ml-elallas-total > span {
        text-align: left;
    }

    .ml-elallas-actions {
        align-items: stretch;
    }

    .ml-elallas-actions .ml-button {
        width: 100%;
        min-width: 0;
    }
}
