:root {
    --p-color: #f0f8ff;
}

body {
    background-image: url("../images/globe-h-mk2nwQ6.webp");
    background-size: cover;
}

.custom-form .form-control {
    color: var(--dark-color);
}

.site-header
{
    padding-top: 25px;
    padding-bottom: 0;
}

.site-header .container
{
    max-height: 80px;
    background: rgba(14, 40, 79, 0.92);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    border-bottom: 1px solid rgba(255,255,255,0.06);
    box-shadow:
            0 12px 30px rgba(0,0,0,0.35),
            0 1px 0 rgba(255,255,255,0.06) inset;
}

.active-item
{
    color: #F2CC8F !important;
}
.card
{
    max-width: 24rem;
    background: none;
    border: none;
}
.card-title, .card-text
{
    color: #FFFFFF;
}

.card-title
{
    font-weight: bold;
}

.main-container{
    min-height: 100vh;
    max-height: 100vh;
    overflow-x: auto;
    width: 100%;
}
/* gallery */
* {
    box-sizing: border-box
}

/* Slideshow container */
.slideshow-container {
    max-width: 1000px;
    position: relative;
    margin: auto;
}

/* Hide the images by default */
.mySlides {
    display: none;
}

/* Next & previous buttons */
.prev, .next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    margin-top: -22px;
    padding: 16px;
    color: white;
    font-weight: bold;
    font-size: 18px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    background-color: rgba(0,0,0,0.8);
}

/* Position the "next button" to the right */
.next {
    right: 0;
    border-radius: 3px 0 0 3px;
}

.prev
{
    left:0;
    border-radius: 3px 0 0 3px;
}


/* Number text (1/3 etc) */
.numbertext {
    color: #f2f2f2;
    font-size: 12px;
    padding: 8px 12px;
    position: absolute;
    bottom: 0;
    left: 50%;
    right: 50%;
    width: 100px;
    text-align: center;
    transform: translateX(-50%);
}

/* The dots/bullets/indicators */
.gallery-dot {
    cursor: pointer;
    height: 15px;
    width: 15px;
    margin: 0 2px;
    background-color: #bbb;
    border-radius: 50%;
    display: inline-block;
    transition: background-color 0.6s ease;
}

.active, .gallery-dot:hover {
    background-color: #717171;
}

/*!* Fading animation *!*/
.fade-slides {
    animation-name: fade-slides;
    animation-duration: 1.5s;
}

@keyframes fade-slides {
    from {opacity: .4}
    to {opacity: 1}
}
.gallery-img
{
    max-height: 70vh;
    max-width: 80%;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.round-panel
{
    border-radius: 20px;
    background-color: rgba(0,0,0, 0.8);
    padding: 30px;
}

.role-regular-user
{
    border-radius: 5px;
    background-color: #0f5132;
    padding: 2px;
}

.role-moderator
{
    border-radius: 5px;
    background-color: #997404;
    padding: 2px;
}

.role-admin
{
    border-radius: 5px;
    background-color: #fb3838;
    padding: 2px;
}

.role-inactive-user
{
    border-radius: 5px;
    background-color: #d63384;
    padding: 2px;
}
.post-id-chips
{
    border-radius: 5px;
    background-color: #000000;
    padding: 2px;
}

.ai-usage-human
{
    border-radius: 5px;
    background-color: #5d9904;
    padding: 2px;
    color: black;
}
.ai-usage-with-ai
{
    border-radius: 5px;
    background-color: #949904;
    padding: 2px;
    color: black;
}

.ai-usage-text-ai,
.ai-usage-image-ai
{
    border-radius: 5px;
    background-color: #f6d006;
    padding: 2px;
    color: black;
}
.ai-usage-hard-ai
{
    border-radius: 5px;
    background-color: #ffba3b;
    padding: 2px;
    color: black;
}
.ai-usage-full-ai
{
    border-radius: 5px;
    background-color: #FF803B;
    padding: 2px;
    color: black;
}

.post-sticky-label
{
    border-radius: 5px;
    background-color: #13c4ca;
    padding: 2px;
    color: rgba(0, 0, 0, 0.8);
}

.info-panel
{
    border-radius: 20px;
    background-color: #0C0E25;
    padding: 30px;
    color: #FFFFFF;
}
.user-panel
{
    border-radius: 20px;
    background-color: #292c4b;
    padding: 30px;
    color: #FFFFFF;
}

.post-panel
{
    border-radius: 20px;
    background-color: #530202;
    padding: 30px;
    color: #FFFFFF;
}

.post-full-title

.user-panel
{
    border-radius: 20px;
    background-color: #0e284f;
    padding: 30px;
    color: #FFFFFF;
}

.tall-btn
{
    min-height: 70px;
    display: flex;
    margin-right: auto;
    justify-content: center;
    align-items: center;
}

.text-container
{
    background-color: rgba(0,0,0, 0.8);
    min-height: 100vh;
    padding: 120px 30px 20px;
}

.text-container > h1
{
    color: #FFFFFF;
    font-size: 36px;
    text-align: center;
}

.text-container > p
{
    color: #aeafb2;
}
.text-container > p:last-child
{
    margin: 0;
}

.text-container > h5
{
    color: #F2CC8F;
    font-size: 18px;
}
/* ======================= */

.post-short {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

.post-short-media {
    margin: 0;
    flex: 0 0 auto;
}

.post-short-media img {
    display: block;
    width: 120px;
    height: auto;
}

.post-short-body {
    /* щоб заголовок/текст нормально переносились */
    min-width: 0;
    width: 100%;
}

.post-short-title,
.post-full-title
{
    font-size: var(--h3-font-size);
    font-weight: bold;
    overflow-wrap: anywhere;
    word-break: break-word;
    color: var(--secondary-color);
    text-decoration: none;
}
.post-short-date,
.post-full-date
{
    padding-left: 10px;
    padding-right: 10px;
}

.post-full-content
{
    text-align: justify;
    text-justify: inter-word;
    hyphens: auto;
    line-height: 1.6;
}

.chips{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
}

.chip{
    padding:3px 10px;
    border-radius:999px;
    background:rgba(255,255,255,.08);
    border:1px solid rgba(255,255,255,.12);
    font-size:14px;
    text-decoration:none;
    transition: background .15s ease, border-color .15s ease, transform .15s ease;
    line-height: 1.2;
    color: var(--secondary-color);
}

.chip:hover:not(.disabled):not(.active){
    background: rgba(255,255,255,.14);
    border-color: rgba(255,255,255,.24);
    transform: translateY(-1px);
    box-shadow:
            0 8px 22px rgba(0,0,0,.32),
            0 0 0 1px rgba(255,255,255,.06) inset;
}

.chip.disabled{
    opacity:.5;
}

.chip.active
{
    font-weight: bold;
    background:rgba(255,255,255,.3)
}

.chip:focus-visible{
    outline: 2px solid rgba(255, 200, 80, .85);
    outline-offset: 2px;
}

.tag-cloud
{
    position: sticky;
    top: 120px;
}

.login-form .custom-btn
{
    padding: 10px 28px;
}

.contact-caption {
    white-space: nowrap;
}

.post-admin-tabs
{
    border-color: #354181;
}

.post-admin-tabs .nav-link
{
    border-color: #222222;
    background-color: #000000;/* inactive tabs */
    color: #cccccc;
}
.post-admin-tabs .nav-link.active
{
    border-color: #313b71;
    background-color: #313b71;
    color: #FFFFFF;
}

.tab-pane.active
{
    background-color: #313b71;
}

.artifacts-min-h
{
    min-height: 241px;
}

select
{
    margin-left: 5px;
    min-width: 150px;
}

.btn-group
{
    background-color: #000000;
}

.btn-group > button
{
    color: #f2cc8f;
}

pre{
    background-color: #7b2c2c;
    display: block;
    padding: 10px;
    border-radius: 6px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.08);
}

blockquote {
    border-left: 3px solid #7B2C2CCC;
    padding-left: .75rem;
    margin-left: 0;
    color: #555;
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border-radius: 6px;
    border: 1px solid #dee2e6;
    background-color: #7b2c2c;
    margin-bottom: 10px;
}

table td,
table th {
    border: 0;
    border-right: 1px solid #dee2e6;
    border-bottom: 1px solid #dee2e6;
    padding: .5rem .75rem;
}

/* прибрати зайві лінії справа і знизу */
table tr td:last-child,
table tr th:last-child {
    border-right: 0;
}

table tr:last-child td,
table tr:last-child th {
    border-bottom: 0;
}

table th {
    font-weight: 600;
    background-color: rgba(0,0,0,.3);
}

table th *{
    font-weight: 600;
}

span.text-small {
    font-size: 0.85em;
    opacity: 0.9;
}

.avatar-icon
{
    box-sizing: content-box;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.25);
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    overflow: hidden;
    flex: 0 0 auto;
    margin-bottom: 10px;
}

.avatar-icon > img
{
    height: 120px;
    max-width: 120px;
    object-fit: contain;
    display: block;
}

.post-inner-image
{
    display: block;
    max-width: min(80%, 500px);
    height: auto;
    margin: 0.75rem auto; /* по центру */
}

.upload-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
}

.upload-overlay__panel {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    padding: 18px 22px;
    border-radius: 14px;
    background: rgba(20, 20, 30, 0.85);
    backdrop-filter: blur(6px);
}

.upload-overlay__spinner {
    width: 44px;
    height: 44px;
    border-radius: 999px;
    border: 4px solid rgba(255, 255, 255, 0.25);
    border-top-color: rgba(255, 255, 255, 0.95);
    animation: upload-spin 0.9s linear infinite;
}

.upload-overlay__text {
    color: #fff;
    font-size: 14px;
    opacity: 0.9;
}

@keyframes upload-spin {
    to { transform: rotate(360deg); }
}

@media screen and (min-width: 991px) {
    .header-in-menu {
        display: none !important;
    }
}
@media screen and (max-width: 990px) {
    .header-in-head {
        display: none !important;
    }
}

.btn-group.danger-group
{
    background-color: #dc3545;
}
.btn-group.danger-group *
{
    color: #000000;
    font-weight: bold;
}
.btn-group.danger-group *:hover
{
    background-color: #d17681;
    color: rgba(57, 9, 140, 0.99);
}

.attachment-container
{
    margin-top: 1rem;
    width: 100%;
    background-color: #24242b;
    padding: 5px 5px 1rem;
    border-radius: 8px;
}

.attachment-container a
{
    color: #7d0dab;
}

.attachment-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;       /* 🔥 ключове для flex */
    flex: 1 1 auto;     /* займати доступний простір */
}

ul {
    padding-left: 1.2rem; /* місце під маркер */
}

li {
    list-style-position: outside;
}

li a {
    display: inline;
    overflow-wrap: anywhere; /* головне */
    word-break: break-word;  /* fallback */
}


.accordion-button {
    justify-content: flex-end;
    text-align: right;
}
.accordion-button:not(.collapsed) {
    background-color: #664cd3;
    color: #fff;
    box-shadow: none;
}

.accordion-button::after {
    margin-left: 0.5rem;   /* тепер іконка після тексту */
}

.accordion-body
 {
    background-color: #001029;
 }
.accordion-item
{
    color: unset;
    border: none;
}

.accordion-button.collapsed
{
    background-color: #1954b1;
    color: #fff;
}

.accordion-button:not(.collapsed) > .accordion-open,
.accordion-button.collapsed > .accordion-closed
{
    display: inline-block;
}
.accordion-button:not(.collapsed) > .accordion-closed,
.accordion-button.collapsed > .accordion-open
{
    display: none;
}

.post-hidden-type
{
    background-color: #ff4444;
    color: black;
}

.header-row
{
    position: relative;
    z-index: 2;
}

.flag-ua{
    position: absolute;
    z-index: 1;
    top: 0;
    right: 0;
    height: 100%;
    width: 170px;
    backdrop-filter: blur(6px);
    background: linear-gradient(to bottom, rgba(0, 87, 183, 0.7) 50%, rgba(255, 215, 0, 0.7) 50%);
    border-radius: 100px;
}