/* ===========================================================================
   nalug.css — NALUG per-site override on top of the trimmed Pofo theme.
   Mirrors many-lights/northernbricks/css/nb.css (shared form controls) with the
   NALUG brand colour, plus the brand rules the old lean BS5 shell injected inline
   so that already-baked page bodies (btn-nalug, bg-nalug-*, display-card, …)
   keep their styling under Pofo.
   Brand: --nalug-red #d3202a
   =========================================================================== */

:root {
    --nalug-red: #d3202a;
    --nalug-dark: #1c1c1c;
    /* Re-skin Pofo's accent to the NALUG brand. style-nb.css maps every
       deep-pink class (.text-deep-pink, .btn-deep-pink, .bg-deep-pink, …) to
       var(--base-color), which it defaults to pink #C22892. nalug.css loads
       after style-nb.css, so this override turns all those accents red. */
    --base-color: var(--nalug-red);
}

/* ===========================
   Brand carried over from the lean shell (baked pages rely on these)
   =========================== */
.btn-nalug {
    background: var(--nalug-red);
    border-color: var(--nalug-red);
    color: #fff;
}

.btn-nalug:hover,
.btn-nalug:focus {
    background: #b31b23;
    border-color: #b31b23;
    color: #fff;
}

.bg-nalug-red { background: var(--nalug-red); }
/* style-nb.css hardcodes this one as pink rgba(194,40,146,.85) instead of using
   var(--base-color); restate it in NALUG red rgb(211,32,42) = #d3202a. */
.bg-deep-pink-opacity { background-color: rgba(211, 32, 42, 0.85); }
.bg-nalug-blue { background: #2a6ebb; }
.bg-nalug-purple { background: #6f42c1; }
/* brand text colour — used by the Pofo section-block library (icons/accents) */
.text-nalug-red { color: var(--nalug-red) !important; }

/* The trimmed Pofo shell drops WOW.js (see ADR-009). Pofo/animate.css markup that
   was authored with `.wow` / `.animated` (e.g. fadeInLeft) would otherwise sit at
   the animation's start keyframe forever — hidden (visibility/opacity 0) or shoved
   off-screen by a transform, leaving huge phantom gaps. Force the resting state so
   all such baked content shows in place without WOW.js. */
.wow,
.animated {
    visibility: visible !important;
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
}

.section { padding: 4rem 0; }

.display-card {
    color: #fff;
    border-radius: .75rem;
    padding: 2rem;
    height: 100%;
}

.display-card h3 { font-size: 1.15rem; }

.service-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #fff;
    color: var(--nalug-red);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .08);
}

.band {
    background-size: cover;
    background-position: center;
    border-radius: .75rem;
    min-height: 220px;
}

/* ===========================
   Radio Buttons (shared with NB — brand-swapped)
   =========================== */
.form-radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding: 8px 0;
}

.form-radio {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

/* Hide the native radio, keep it accessible */
.form-radio input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

/* Custom visual circle */
.form-radio label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 1rem;
    color: #333;
}

.form-radio label::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #aaa;
    border-radius: 50%;
    background: #fff;
    flex-shrink: 0;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.form-radio input[type="radio"]:checked + label::before {
    background: var(--nalug-red);
    border-color: var(--nalug-red);
    box-shadow: inset 0 0 0 4px #fff; /* creates the inner dot */
}

.form-radio input[type="radio"]:focus + label::before {
    outline: 2px solid var(--nalug-red);
    outline-offset: 2px;
}

/* ===========================
   Checkboxes (shared with NB — brand-swapped)
   =========================== */
.form-check-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding: 8px 0;
}

.form-check {
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.form-check input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.form-check label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: 1rem;
    color: #333;
    line-height: 1.4;
}

.form-check label::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    min-width: 20px; /* prevents squishing in multi-line labels */
    border: 2px solid #aaa;
    border-radius: 3px;
    background: #fff;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.form-check input[type="checkbox"]:checked + label::before {
    background: var(--nalug-red);
    border-color: var(--nalug-red);
    /* Checkmark via SVG data URI — no icon font dependency */
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M13.485 1.929L5.5 9.914 2.515 6.929 1.1 8.343l4.4 4.4 9.4-9.4z'/%3E%3C/svg%3E");
    background-size: 13px;
    background-repeat: no-repeat;
    background-position: center;
}

.form-check input[type="checkbox"]:focus + label::before {
    outline: 2px solid var(--nalug-red);
    outline-offset: 2px;
}

/* ===========================================================================
   CMS content sections — each generated content block is wrapped in
   <section class="page-section"><div class="container">…</div></section>.
   Give them consistent vertical rhythm (replaces the old base-template pt30).
   =========================================================================== */
.page-section {
    padding: 2rem 0;
}

.page-section + .page-section {
    padding-top: 0;
}

/* ===========================================================================
   Navbar dropdown (desktop) — Pofo/bootsnav uses BS3-style <li><a> markup, but
   theme-vendors is Bootstrap 5, whose .dropdown-menu reset strips the padding/
   shadow (items render display:inline, padding:0). Restore the Pofo dropdown box
   here (loaded last, so it wins) with a NALUG-red top accent.
   =========================================================================== */
@media (min-width: 992px) {
    nav.navbar.bootsnav .navbar-nav > li.dropdown > ul.dropdown-menu {
        min-width: 210px;
        padding: 8px 0 !important;
        margin-top: 0;
        background: #fff;
        border: none;
        border-top: 3px solid var(--nalug-red);
        border-radius: 0 0 4px 4px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, .12) !important;
    }

    nav.navbar.bootsnav .navbar-nav > li.dropdown > ul.dropdown-menu > li {
        margin: 0;
    }

    nav.navbar.bootsnav .navbar-nav > li.dropdown > ul.dropdown-menu > li > a {
        display: block !important;
        padding: 8px 22px !important;
        font-size: 14px;
        line-height: 1.4;
        color: #333 !important;
        white-space: nowrap;
    }

    nav.navbar.bootsnav .navbar-nav > li.dropdown > ul.dropdown-menu > li > a:hover,
    nav.navbar.bootsnav .navbar-nav > li.dropdown > ul.dropdown-menu > li > a:focus {
        color: var(--nalug-red) !important;
        background: #f7f7f7;
    }
}

/* Events list (EventsPublic::showPublicEvents) — normalize the mixed bag of
   gallery photos and small brand logos into a uniform, contained thumbnail so
   the blog-post layout reads consistently. Overrides Pofo's .blog-image a>img
   full-bleed rule and any inline width="200px" on the fallback logos. */
#portfolio-item-container .blog-image figure {
    margin: 0;
}

#portfolio-item-container .blog-image img {
    width: 100% !important;
    height: 220px;
    object-fit: contain;
    object-position: center;
}