:root {
    --de-bg: #fff;
    --de-accent: #f5a623;
    --de-border: #f1f3f5;
    --de-text: #2d3436;
    --de-muted: #718096;
    --de-radius: 8px;
    --de-w-price: 95px;
    --de-anim: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 1. Контейнер */
.delivery-estimate {
    max-width: 500px;
    margin-bottom: 20px;
    background: var(--de-bg);
    border: 1px solid var(--de-border);
    border-radius: var(--de-radius);
    overflow: hidden;
    font: 13px/1.4 'Inter', sans-serif;
}

/* 2. Шапка и кнопки */
.delivery-estimate__title, .de-tab-btn, .de-table thead tr, .de-table tbody tr {
    display: flex !important;
    align-items: center;
    padding: 0px 12px;
}

.delivery-estimate__title {
    padding: 8px 12px 0;
    font-weight: 700;
    color: var(--de-text);
    gap: 8px;
}
.delivery-estimate__title i { color: var(--de-accent); }

/* 3. Вкладки */
.de-tabs__nav {
    display: flex;
    padding: 2px;
    background: #e2e8f0;
    margin: 8px 12px;
    border-radius: 10px;
    gap: 2px;
}

.de-tab-btn {
    flex: 1;
    border: none;
    background: 0 0;
    padding: 6px 8px;
    font-weight: 700;
    letter-spacing: .05em;
    color: #64748b;
    cursor: pointer;
    border-radius: 8px;
    transition: var(--de-anim);
    justify-content: center;
}

.de-tab-btn:not(.is-active):hover { background: rgba(255,255,255,.4); color: var(--de-text); }

.de-tab-btn.is-active {
    background: var(--de-bg);
    color: var(--de-text) !important;
    box-shadow: 0 2px 6px rgba(0,0,0,.12);
    transform: translateY(-1px);
}

/* 4. Панели — Grid-стек: все панели в одну ячейку, высота = max */
.de-tabs__body {
    display: grid;
    grid-template-columns: 1fr;
    padding: 0 10px;
}

.de-tab-panel {
    grid-area: 1 / 1;          /* все панели накладываются в одну ячейку  */
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.2s ease;
    min-width: 0;               /* fix flex/grid overflow на узких экранах */
}

.de-tab-panel.is-active {
    visibility: visible;
    opacity: 1;
}

/* 5. Таблица */
.de-table { width: 100%; display: flex !important; flex-direction: column; }

.de-table thead th {
    display: flex !important;
    align-items: flex-end !important;
    justify-content: center;
    font: 700 10px/1.2 sans-serif;
    text-transform: uppercase;
    color: #a0aec0;
    letter-spacing: .05em;
}

.de-table thead th.de-th-name { justify-content: flex-start !important; }
.de-th-name, .de-td-label { flex: 1 1 auto !important; text-align: left !important; }

.de-th-col, .de-td-price { flex: 0 0 var(--de-w-price) !important; width: var(--de-w-price) !important; text-align: center !important; padding: 0 4px; }

.de-td-label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 8px; color: var(--de-text); }
.de-td-price { font-weight: 700; color: var(--de-text); }

.de-table tbody tr {
    padding: 3px 12px;
    border-bottom: 1px solid #f8fafc !important;
    transition: background .2s ease, transform .2s ease;
}

.de-table tbody tr:last-child { border-bottom: 0 !important; }
.de-table tbody tr:not(.de-row-note):hover { background: #f8fafc; }

/* 6. Примечание и Футер */
.de-table tbody tr.de-row-note { display: block !important; padding: 4px 12px !important; border: 0 !important; }

.delivery-estimate__box-size {
    padding: 4px 22px 6px;   /* выровнено с таблицей (10px body padding + 12px внутри) */
    font: italic 11px sans-serif;
    color: var(--de-muted);
    display: flex;
    align-items: center;
    gap: 6px;
}

.delivery-estimate__disclaimer {
    padding: 8px 12px;
    font-size: 11px;
    color: #cbd5e0;
    text-align: center;
}
