/* Shared frontend layout width.
   Keep Bootstrap's mobile/tablet containers, and give larger screens
   a little more usable space without stretching content edge-to-edge. */
@media (min-width: 1200px) {
    .container {
        max-width: calc(100% - 80px);
    }
}

@media (min-width: 1360px) {
    .container {
        max-width: 1280px;
    }
}

/* Shared back-to-top control.
   This component lives in the master layout, so its complete presentation also
   belongs here instead of in individual page stylesheets. */
body .top_btn {
    position: fixed !important;
    right: 22px !important;
    bottom: 22px !important;
    z-index: 1090;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    margin: 0;
    padding: 0;
    border: 1px solid rgba(29, 67, 84, 0.55);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.94);
    color: #1d4354;
    box-shadow: 0 8px 24px rgba(11, 54, 91, 0.14);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(8px);
    transition:
        opacity 180ms ease,
        visibility 180ms ease,
        transform 180ms ease,
        color 180ms ease,
        background-color 180ms ease,
        border-color 180ms ease,
        box-shadow 180ms ease;
    appearance: none;
    -webkit-appearance: none;
}

body .top_btn.is-visible {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

body .top_btn svg {
    display: block;
    width: 19px;
    height: 19px;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}

body .top_btn:hover,
body .top_btn:focus-visible {
    border-color: #65bd45;
    background-color: #f4fbf1;
    color: #0b579e;
    box-shadow: 0 10px 26px rgba(11, 54, 91, 0.2);
    transform: translateY(-2px);
    outline: none;
}

@media (max-width: 575.98px) {
    body .top_btn {
        right: 14px !important;
        bottom: 14px !important;
        width: 38px;
        height: 38px;
    }

    body .top_btn svg {
        width: 17px;
        height: 17px;
    }
}

@media (prefers-reduced-motion: reduce) {
    body .top_btn {
        transition: none;
    }
}
