/* trusselfeed-link.css - Frontend styles */

/* ─── Markert tekst ────────────────────────────────────────────────────────── */

.trusselfeed-link {
    background: linear-gradient(120deg, #ffecd2 0%, #fcb69f 100%);
    color: #7b3f00;
    padding: 2px 6px;
    border-radius: 4px;
    border-bottom: 2px dotted #e07b39;
    cursor: pointer;
    display: inline;
    transition: all 0.2s ease;
}

.trusselfeed-link:hover {
    background: linear-gradient(120deg, #f093fb 0%, #f5576c 100%);
    color: white;
    border-bottom-color: transparent;
}

.trusselfeed-link:focus-visible {
    outline: 2px solid #e07b39;
    outline-offset: 2px;
}

/* ─── Modal overlay ─────────────────────────────────────────────────────────── */

.tfl-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tfl-modal-inner {
    background: #fff;
    border-radius: 8px;
    padding: 32px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

/* ─── Modal innhold ─────────────────────────────────────────────────────────── */

.tfl-modal-close,
.tfl-modal-back {
    background: none;
    border: none;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    color: #999;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.15s, color 0.15s;
}

.tfl-modal-close:focus-visible,
.tfl-modal-back:focus-visible { outline: 2px solid #0073aa; outline-offset: 2px; }

.tfl-modal-title {
    margin: 0 0 16px;
    font-size: 20px;
    color: #1a1a1a;
    padding-right: 32px; /* plass til lukkeknapp */
}

.tfl-modal-spinner {
    color: #999;
    font-size: 14px;
    padding: 20px 0 60px 0;
    text-align: center;
}

.tfl-modal-content {
    font-size: 15px;
    line-height: 1.7;
    color: #333;
}

.tfl-modal-content p      { margin: 0 0 1em; }
.tfl-modal-content h1,
.tfl-modal-content h2,
.tfl-modal-content h3,
.tfl-modal-content h4     { margin: 1.2em 0 0.4em; color: #1a1a1a; }
.tfl-modal-content ul,
.tfl-modal-content ol     { margin: 0 0 1em 1.4em; }
.tfl-modal-content a      { color: #0073aa; }
.tfl-modal-content img    { max-width: 100%; height: auto; border-radius: 4px; }

.tfl-error {
    color: #c0392b;
    font-size: 14px;
}

/* ─── Responsiv ─────────────────────────────────────────────────────────────── */

@media (max-width: 480px) {
    .tfl-modal-inner {
        padding: 24px 16px;
        max-height: 90vh;
    }
}

/* ─── Print ──────────────────────────────────────────────────────────────────── */

@media print {
    .tfl-modal { display: none !important; }
    .trusselfeed-link { background: none; border-bottom: 1px solid #ccc; color: inherit; }
}
