/*
 * Addon MsgBox: styles. Only for elements the addon itself creates (notice boxes in posts, part A;
 * sitewide announcement banners under the topbar, part B). No logic here, see init.php; class prefix
 * "msgbox". Box look (border/shadow/icon) follows the reference frontend.css; colours are mapped to the 4
 * existing Cheshire status tokens so dark mode works via .cheshire-wrap.cheshire-dark (cheshire.css).
 * NOTE: "warn" is red (error look) and "note" yellow/orange (hint look), not the reverse.
 * @package Cheshire
 * @see addons/MsgBox/init.php
 * SPDX-License-Identifier: GPL-2.0-or-later
 */
.msgbox {
    border-radius: 5px;
    padding: .7rem 1rem .7rem 2.4rem;
    margin: .8rem 0;
    font-size: .9rem;
    line-height: 1.5;
    position: relative;
    box-shadow: 3px 3px 6px 0 rgba(0, 0, 0, .12);
}
.msgbox p { margin: 0; }
.msgbox p + p { margin-top: .4rem; }

/* Icon top left (FontAwesome, part of WBCE, included sitewide). */
.msgbox::before {
    font-family: "FontAwesome";
    font-size: 1.25rem;
    position: absolute;
    left: .65rem;
    top: .6rem;
}
.msgbox-info::before { content: "\f05a"; color: var(--cheshire-info-text, #3465a4); }
.msgbox-tipp::before { content: "\f058"; color: var(--cheshire-success-text, #14892c); }
.msgbox-warn::before { content: "\f057"; color: var(--cheshire-danger-text, #cc0000); }
.msgbox-note::before { content: "\f06a"; color: var(--cheshire-warning-text, #f57900); }

.msgbox-info {
    background: var(--cheshire-info-bg, #fcfcfc);
    border: 1px solid var(--cheshire-info-border, #aab8c6);
    color: var(--cheshire-info-text, #21618C);
}
.msgbox-tipp {
    background: var(--cheshire-success-bg, #f3f9f4);
    border: 1px solid var(--cheshire-success-border, #91c89c);
    color: var(--cheshire-success-text, #1E8449);
}
.msgbox-warn {
    background: var(--cheshire-danger-bg, #fff8f7);
    border: 1px solid var(--cheshire-danger-border, #d04437);
    color: var(--cheshire-danger-text, #7B241C);
}
.msgbox-note {
    background: var(--cheshire-warning-bg, #fffdf6);
    border: 1px solid var(--cheshire-warning-border, #ffeaae);
    color: var(--cheshire-warning-text, #8a6d3b);
}

/* Part B: sitewide banner directly under the topbar; slightly more padding + bold optional title to
   set it apart from the smaller post boxes (part A). Left padding stays so the icon (.msgbox::before)
   keeps its space. */
.msgbox-banner {
    padding: .8rem 1.1rem .8rem 2.6rem;
    margin: 0 0 1rem;
}
.msgbox-banner::before { top: .85rem; left: .8rem; }
.msgbox-banner p:first-child strong { font-size: 1rem; }
