/* Näringslivsbolaget Stilar v1.0.0
   Centrala stilar för artiklar — slår tema-CSS via specificitet + !important
   Färgpalett: grön #16a34a (primär), navy #1e3a5f (text-accent), gul #f59e0b, blå #3b82f6 */

/* ========================================================================
   TABELLER med grön header
   Använd <tr> med klassen "nlb-thead" eller style="background:#16a34a"
   ======================================================================== */

/* Tabellrubriker med grön bakgrund — vit text alltid */
.entry-content tr[style*="background:#16a34a"] th,
.entry-content tr.nlb-thead th,
.entry-content table.nlb-tabell thead th {
    color: #fff !important;
    background: #16a34a !important;
    font-weight: 600;
    padding: 0.8em 0.9em;
    border: none;
}

/* Generell tabellstil för .nlb-tabell */
.entry-content table.nlb-tabell {
    width: 100%;
    border-collapse: collapse;
    margin: 1em 0;
    font-size: 0.95em;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
}

.entry-content table.nlb-tabell tbody tr:nth-child(even) {
    background: #f9fafb;
}

.entry-content table.nlb-tabell td {
    padding: 0.7em 0.9em;
    border-bottom: 1px solid #e5e7eb;
}

.entry-content table.nlb-tabell tbody tr:last-child td {
    border-bottom: none;
}

/* ========================================================================
   CALLOUT-RUTOR (snabbsvar, info, varning, tips)
   ======================================================================== */

/* Snabbsvar (grön) */
.entry-content .nlb-snabbsvar {
    background: #f0fdf4;
    border-left: 4px solid #16a34a;
    padding: 1.1em 1.4em;
    margin: 1.5em 0;
    border-radius: 0 8px 8px 0;
}
.entry-content .nlb-snabbsvar strong:first-child,
.entry-content .nlb-snabbsvar > p:first-child {
    font-weight: 700;
    color: #14532d;
    font-size: 1.05em;
    margin-bottom: 0.5em;
    display: block;
}

/* Info (blå) */
.entry-content .nlb-info {
    background: #eff6ff;
    border-left: 4px solid #3b82f6;
    padding: 1em 1.3em;
    margin: 1.5em 0;
    border-radius: 0 8px 8px 0;
}
.entry-content .nlb-info strong:first-child {
    color: #1e3a5f;
    font-weight: 700;
}

/* Varning (gul) */
.entry-content .nlb-varning {
    background: #fffbeb;
    border-left: 4px solid #f59e0b;
    padding: 1em 1.3em;
    margin: 1.5em 0;
    border-radius: 0 8px 8px 0;
}
.entry-content .nlb-varning strong:first-child {
    color: #78350f;
    font-weight: 700;
}

/* Tips (ljusgrön) */
.entry-content .nlb-tips {
    background: #ecfdf5;
    border-left: 4px solid #34d399;
    padding: 1em 1.3em;
    margin: 1.5em 0;
    border-radius: 0 8px 8px 0;
}

/* ========================================================================
   INTERNLÄNKSBOX
   ======================================================================== */

.entry-content .nlb-relaterat {
    background: #f0f9ff;
    border-left: 4px solid #3b82f6;
    padding: 1.2em;
    margin: 1.5em 0;
    border-radius: 0 8px 8px 0;
}
.entry-content .nlb-relaterat strong:first-child {
    color: #1e3a5f;
    font-weight: 700;
    display: block;
    margin-bottom: 0.5em;
}
.entry-content .nlb-relaterat ul {
    margin: 0;
    padding-left: 1.3em;
    line-height: 1.8;
}
.entry-content .nlb-relaterat a {
    color: #16a34a;
    text-decoration: none;
    font-weight: 500;
}

/* ========================================================================
   AUTHOR-BYLINE
   ======================================================================== */

.entry-content .nlb-byline {
    display: flex;
    align-items: center;
    gap: 0.8em;
    flex-wrap: wrap;
    margin: 0 0 1.2em;
    padding: 0.8em 1em;
    background: #f8fafc;
    border-radius: 8px;
    font-size: 0.88em;
    color: #475569;
}
.entry-content .nlb-byline strong {
    color: #1e3a5f;
    font-weight: 600;
}

/* ========================================================================
   RESPONSIVE — tabeller blir kort på mobil (≤ 600px)
   ======================================================================== */

@media (max-width: 600px) {
    .entry-content table.nlb-tabell {
        font-size: 0.9em;
    }
    .entry-content table.nlb-tabell.responsive thead {
        display: none;
    }
    .entry-content table.nlb-tabell.responsive tbody tr {
        display: block;
        margin-bottom: 0.8em;
        border: 1px solid #e5e7eb;
        border-left: 4px solid #16a34a;
        border-radius: 6px;
        padding: 0.7em 0.9em;
    }
    .entry-content table.nlb-tabell.responsive tbody tr:nth-child(even) {
        background: #fff;
    }
    .entry-content table.nlb-tabell.responsive td {
        display: block;
        border: none;
        padding: 0.3em 0;
        text-align: left !important;
    }
    .entry-content table.nlb-tabell.responsive td:before {
        content: attr(data-label);
        display: inline-block;
        width: 100px;
        font-weight: 600;
        color: #64748b;
        font-size: 0.78em;
        text-transform: uppercase;
        letter-spacing: 0.03em;
    }
}
