/* ==========================================================================
   WEW Specs Table Widget — Frontend Styles
   ========================================================================== */

/* ── Wrapper ────────────────────────────────────────────────────────────── */
.wew-specs-table-wrap {
    overflow: hidden;
    /* clips table corners without adding its own border */
    border-radius: 8px;
}


/* ── Table base ─────────────────────────────────────────────────────────── */
.wew-specs-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    box-sizing: border-box;
    /* The outer frame border goes here so border-collapse merges it with
       adjacent cell borders — zero risk of double lines. */
    border: 1px solid #e8ecf0;
}

/* Auto width variant */
.wew-st-width-auto .wew-specs-table {
    width: auto;
}

/* ── Cells ──────────────────────────────────────────────────────────────── */
.wew-specs-table th,
.wew-specs-table td {
    padding: 10px 14px;
    vertical-align: middle;
    box-sizing: border-box;
    word-break: break-word;
}

/* ── Cell inner: flex container ─────────────────────────────────────────── */
.wew-st-cell-inner {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Icon position: right → reverse flex */
.wew-st-cell-inner.wew-st-icon-right {
    flex-direction: row-reverse;
    justify-content: flex-end;
}

/* ── Cell content elements ──────────────────────────────────────────────── */
.wew-st-cell-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.wew-st-cell-icon i,
.wew-st-cell-icon svg {
    font-size: 18px;
    width: 18px;
    height: 18px;
    display: block;
}

.wew-st-cell-image {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.wew-st-cell-image img {
    display: block;
    width: 40px;
    height: auto;
    object-fit: contain;
}

.wew-st-cell-text {
    line-height: 1.45;
}

/* ── Header rows ───────────────────────────────────────────────────────── */
.wew-st-row-header th {
    background-color: #2d3748;
    color: #ffffff;
    font-weight: 700;
    text-align: left;
    letter-spacing: 0.02em;
}

/* ── Data rows ──────────────────────────────────────────────────────────── */
.wew-st-row-data td {
    background-color: #ffffff;
    text-align: left;
    border-bottom: 1px solid #e8ecf0;
    transition: background-color 200ms ease, color 200ms ease;
}

.wew-st-row-data:last-child td {
    border-bottom: none;
}

/* Zebra striping */
.wew-st-row-data:nth-child(even) td {
    background-color: #f7f9fc;
}

/* Hover */
.wew-st-row-data:hover td {
    /* overridden by Elementor selectors if hover bg is set */
    cursor: default;
}

/* ── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 600px) {

    /* Stack cells vertically on small screens when > 2 columns */
    .wew-specs-table.wew-st-mobile-stack thead {
        display: none;
    }

    .wew-specs-table.wew-st-mobile-stack tbody,
    .wew-specs-table.wew-st-mobile-stack tr,
    .wew-specs-table.wew-st-mobile-stack td {
        display: block;
        width: 100% !important;
    }

    .wew-specs-table.wew-st-mobile-stack tr {
        border-bottom: 2px solid #e8ecf0;
        padding-bottom: 6px;
        margin-bottom: 6px;
    }

    .wew-specs-table.wew-st-mobile-stack tr:last-child {
        border-bottom: none;
        margin-bottom: 0;
    }

    .wew-specs-table.wew-st-mobile-stack td {
        border-bottom: none;
        padding: 4px 12px;
    }

    .wew-specs-table.wew-st-mobile-stack td:first-child {
        padding-top: 10px;
        font-weight: 700;
        font-size: 0.78em;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        opacity: 0.65;
    }
}

/* ── Image-only cells: center content ───────────────────────────────────── */
.wew-st-ct-image_only .wew-st-cell-inner {
    justify-content: inherit;
}